Thread (70 messages) 70 messages, 11 authors, 2004-10-02

Re: generic 802.11 stack

From: "David S. Miller" <davem@davemloft.net>
Date: 2004-10-01 22:53:10

Why this change?

-extern void hh_data_is_too_small(void);
+static void hh_data_is_too_small(void)
+{
+    printk(KERN_ERR "hh_data_is_too_small\n");
+}

We don't define the function because it is meant to
cause a compile time error if hh->hh_data is too small to
hold the full p80211_data_header structure.  Please undo
this change.

And therefore undo this change too:

-	if (sizeof(hh->hh_data) < sizeof(*p))
+	if (sizeof(hh->hh_data) < sizeof(*p)) {
 		hh_data_is_too_small();
+        return -1;
+    }

Next, what's this?

-	dev->hard_header	= p80211_header;
+	dev->hard_header    	= p80211_header;
 	dev->rebuild_header 	= p80211_rebuild_header;

Your merely changing the tab character after dev->hard_header
into spaces.  Please don't do this.  This makes a lot of white
space noise when making diffs against the original davem-p80211
code thus making it harder to review the changes you actually made.

Next:

+    dev->mtu                = 2304;
+    dev->type               = ARPHRD_IEEE80211;

Is this really the correct default MTU for wireless devices?
@@ -342,7 +343,7 @@ int p80211_recv_cfackpoll(struct sk_buff
 static struct packet_type p80211_packet_type = {
 	.type	=	__constant_htons(ETH_P_802_11),
 	.func	=	p80211_rcv,
-	.data	=	(void *) 1, /* understands shared SKBs */
+	.af_packet_priv	=	(void *) 1, /* understands shared SKBs */
 };
 
You can just remove this line entirely for 2.6.x kernels.

Otherwise looks fine :-)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help