aboutsummaryrefslogtreecommitdiffstats
path: root/net/bridge/br_netfilter.c
diff options
context:
space:
mode:
authorSylvain "ythier" Hitier <sylvain.hitier@gmail.com>2014-10-07 13:40:34 +0000
committerDavid S. Miller <davem@davemloft.net>2014-10-07 13:16:06 -0400
commit88b09a6d958af6c458acf055ee2eb5bc9564efda (patch)
treee93e299214daca641fb792799b8a4eaf324a3319 /net/bridge/br_netfilter.c
parentbna: allow transmit tagged frames (diff)
downloadlinux-dev-88b09a6d958af6c458acf055ee2eb5bc9564efda.tar.xz
linux-dev-88b09a6d958af6c458acf055ee2eb5bc9564efda.zip
3c59x: fix bad split of cpu_to_le32(pci_map_single())
In commit 6f2b6a3005b2c34c39f207a87667564f64f2f91a, # 3c59x: Add dma error checking and recovery the intent is to split out the mapping from the byte-swapping in order to insert a dma_mapping_error() check. Kinda this semantic patch: // See http://coccinelle.lip6.fr/ // // Beware, grouik-and-dirty! @@ expression DEV, X, Y, Z; @@ - cpu_to_le32(pci_map_single(DEV, X, Y, Z)) + dma_addr_t addr = pci_map_single(DEV, X, Y, Z); + if (dma_mapping_error(&DEV->dev, addr)) + /* snip */; + cpu_to_le32(addr) However, the #else part (of the #if DO_ZEROCOPY test) is changed this way: - cpu_to_le32(pci_map_single(DEV, X, Y, Z)) + dma_addr_t addr = cpu_to_le32(pci_map_single(DEV, X, Y, Z)); // ^^^^^^^^^^^ // That mismatches the 3 other changes! + if (dma_mapping_error(&DEV->dev, addr)) + /* snip */; + cpu_to_le32(addr) Let's remove the leftover cpu_to_le32() for coherency. v2: Better changelog. v3: Add Acked-by Fixes: 6f2b6a3005b2c34c39f207a87667564f64f2f91a # 3c59x: Add dma error checking and recovery Acked-by: Neil Horman <nhorman@tuxdriver.com> Signed-off-by: Sylvain "ythier" Hitier <sylvain.hitier@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bridge/br_netfilter.c')
0 files changed, 0 insertions, 0 deletions