Thread (5 messages) flat view 5 messages, 3 authors, 2009-08-12

Re: [PATCH 1/2] mac802154: add a software MAC 802.15.4 implementation

From: Johannes Berg <johannes@sipsolutions.net>
Date: 2009-08-12 13:14:31
Also in: linux-wireless

On Wed, 2009-08-12 at 17:06 +0400, Dmitry Eremin-Solenikov wrote:
quoted
In addition to that, you can't put anything into skb->cb, then push the
frame to the master netdev, and expect things in skb->cb to still be
there when the frame arrives at the master netdev. Not sure you do that
(I hope not because that would be very buggy), but eventually you'll
probably find that you do want that, etc.
Hmm. It works for us. Could you please tell me more about the problems
with skb->cb ?
Uh, well, you don't own the skb->cb between dev_queue_xmit() and
ndo_start_xmit(). In fact, your phy_cb data will be overwritten by the
qdisc.

So your code is completely and utterly broken just like mac80211 was for
a long time.

Also, looking into this a bit more, I see no reason to allocate a work
struct every time you get a frame -- better just queue them up and stick
everything else into skb->cb. In fact, you don't need a master netdev
here anyway, just move all code from ieee802154_master_hard_start_xmit()
into ieee802154_net_xmit().

johannes

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help