summaryrefslogtreecommitdiff
path: root/arch/um/os-Linux/drivers/tuntap_kern.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/um/os-Linux/drivers/tuntap_kern.c')
-rw-r--r--arch/um/os-Linux/drivers/tuntap_kern.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/arch/um/os-Linux/drivers/tuntap_kern.c b/arch/um/os-Linux/drivers/tuntap_kern.c
index 9ade1f892ac8..9d384807b077 100644
--- a/arch/um/os-Linux/drivers/tuntap_kern.c
+++ b/arch/um/os-Linux/drivers/tuntap_kern.c
@@ -35,20 +35,15 @@ static void tuntap_init(struct net_device *dev, void *data)
printk("\n");
}
-static int tuntap_read(int fd, struct sk_buff **skb,
- struct uml_net_private *lp)
+static int tuntap_read(int fd, struct sk_buff *skb, struct uml_net_private *lp)
{
- *skb = ether_adjust_skb(*skb, ETH_HEADER_OTHER);
- if (*skb == NULL)
- return -ENOMEM;
- return net_read(fd, skb_mac_header(*skb),
- (*skb)->dev->mtu + ETH_HEADER_OTHER);
+ return net_read(fd, skb_mac_header(skb),
+ skb->dev->mtu + ETH_HEADER_OTHER);
}
-static int tuntap_write(int fd, struct sk_buff **skb,
- struct uml_net_private *lp)
+static int tuntap_write(int fd, struct sk_buff *skb, struct uml_net_private *lp)
{
- return net_write(fd, (*skb)->data, (*skb)->len);
+ return net_write(fd, skb->data, skb->len);
}
const struct net_kern_info tuntap_kern_info = {