summaryrefslogtreecommitdiffstats
path: root/target/linux/atheros/patches-3.3/110-ar2313_ethernet.patch
diff options
context:
space:
mode:
authornbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-05-06 21:19:14 +0000
committernbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>2012-05-06 21:19:14 +0000
commitd4d537811bcf327b603605aea8d20295ef317f06 (patch)
tree044abda1179e26bc1161e60d5a06a7ff784c9bab /target/linux/atheros/patches-3.3/110-ar2313_ethernet.patch
parentecb548b2e5e00f2cfe5689859dded4a9b0b08adf (diff)
kernel: rewrite the phy packet hook, put it in the network stack to avoid having to keep non-upstream ethernet driver changes
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@31637 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/atheros/patches-3.3/110-ar2313_ethernet.patch')
-rw-r--r--target/linux/atheros/patches-3.3/110-ar2313_ethernet.patch9
1 files changed, 3 insertions, 6 deletions
diff --git a/target/linux/atheros/patches-3.3/110-ar2313_ethernet.patch b/target/linux/atheros/patches-3.3/110-ar2313_ethernet.patch
index d3060da44..47c9dd622 100644
--- a/target/linux/atheros/patches-3.3/110-ar2313_ethernet.patch
+++ b/target/linux/atheros/patches-3.3/110-ar2313_ethernet.patch
@@ -32,7 +32,7 @@
+obj-$(CONFIG_NET_VENDOR_AR231X) += ar231x.o
--- /dev/null
+++ b/drivers/net/ethernet/ar231x/ar231x.c
-@@ -0,0 +1,1282 @@
+@@ -0,0 +1,1279 @@
+/*
+ * ar231x.c: Linux driver for the Atheros AR231x Ethernet device.
+ *
@@ -784,7 +784,7 @@
+ if (sp->rx_skb[idx])
+ break;
+
-+ skb = netdev_alloc_skb(dev, AR2313_BUFSIZE);
++ skb = netdev_alloc_skb_ip_align(dev, AR2313_BUFSIZE);
+ if (!skb) {
+ printk("\n\n\n\n %s: No memory in system\n\n\n\n",
+ __FUNCTION__);
@@ -795,7 +795,6 @@
+ * Make sure IP header starts on a fresh cache line.
+ */
+ skb->dev = dev;
-+ skb_reserve(skb, RX_OFFSET);
+ sp->rx_skb[idx] = skb;
+
+ rd = (ar231x_descr_t *) & sp->rx_ring[idx];
@@ -867,7 +866,7 @@
+
+ } else {
+ /* alloc new buffer. */
-+ skb_new = netdev_alloc_skb(dev, AR2313_BUFSIZE + RX_OFFSET);
++ skb_new = netdev_alloc_skb_ip_align(dev, AR2313_BUFSIZE);
+ if (skb_new != NULL) {
+
+ skb = sp->rx_skb[idx];
@@ -881,8 +880,6 @@
+ netif_rx(skb);
+
+ skb_new->dev = dev;
-+ /* 16 bit align */
-+ skb_reserve(skb_new, RX_OFFSET);
+ /* reset descriptor's curr_addr */
+ rxdesc->addr = virt_to_phys(skb_new->data);
+