Skip to content

Commit

Permalink
skbuff: remove skb_dma_map/unmap
Browse files Browse the repository at this point in the history
The two functions skb_dma_map/unmap are unsafe to use as they cause
problems when packets are cloned and sent to multiple devices while a HW
IOMMU is enabled.  Due to this it is best to remove the code so it is not
used by any other network driver maintainters.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Alexander Duyck authored and David S. Miller committed Dec 3, 2009
1 parent f4188d8 commit c81c2d9
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 74 deletions.
8 changes: 0 additions & 8 deletions include/linux/skbuff.h
Original file line number Diff line number Diff line change
Expand Up @@ -416,14 +416,6 @@ struct sk_buff {

#include <asm/system.h>

#ifdef CONFIG_HAS_DMA
#include <linux/dma-mapping.h>
extern int skb_dma_map(struct device *dev, struct sk_buff *skb,
enum dma_data_direction dir);
extern void skb_dma_unmap(struct device *dev, struct sk_buff *skb,
enum dma_data_direction dir);
#endif

static inline struct dst_entry *skb_dst(const struct sk_buff *skb)
{
return (struct dst_entry *)skb->_skb_dst;
Expand Down
1 change: 0 additions & 1 deletion net/core/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ obj-y := sock.o request_sock.o skbuff.o iovec.o datagram.o stream.o scm.o \
gen_stats.o gen_estimator.o net_namespace.o

obj-$(CONFIG_SYSCTL) += sysctl_net_core.o
obj-$(CONFIG_HAS_DMA) += skb_dma_map.o

obj-y += dev.o ethtool.o dev_mcast.o dst.o netevent.o \
neighbour.o rtnetlink.o utils.o link_watch.o filter.o
Expand Down
65 changes: 0 additions & 65 deletions net/core/skb_dma_map.c

This file was deleted.

0 comments on commit c81c2d9

Please sign in to comment.