diff options
author | Julian Wiedmann <jwi@linux.ibm.com> | 2018-07-19 12:43:56 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-07-21 10:12:30 -0700 |
commit | ba86ceee9d1b5aa71fe3db75b2ec5452c9a48307 (patch) | |
tree | d4af4b1cab727029b75e594f83c5cf99ecefed75 /arch/powerpc | |
parent | d2a274b25be7218f8400037868a756640e8a4b0d (diff) | |
download | linux-ba86ceee9d1b5aa71fe3db75b2ec5452c9a48307.tar.bz2 |
s390/qeth: merge linearize-check into HW header construction
When checking whether an skb needs to be linearized to fit into an IO
buffer, it's desirable to consider the skb's final size and layout
(ie. after the HW header was added). But a subsequent linearization can
then cause the re-positioned HW header to violate its alignment
restrictions.
Dealing with this situation in two different code paths is quite tricky.
This patch integrates a) linearize-check and b) HW header construction
into one 3 step-sequence:
1. evaluate how the HW header needs to be added (to identify if it takes
up an additional buffer element), then
2. check if the required buffer elements exceed the device's limit.
Linearize when necessary and re-evaluate the HW header placement.
3. Add the HW header in the best-possible way:
a) push, without taking up an additional buffer element
b) push, but consume another buffer element
c) allocate a header object from the cache.
Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/powerpc')
0 files changed, 0 insertions, 0 deletions