lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Mon, 10 Sep 2012 08:12:27 +0200 From: Eric Dumazet <eric.dumazet@...il.com> To: Alan Ott <alan@...nal11.us> Cc: Alexander Smirnov <alex.bluesman.smirnov@...il.com>, Dmitry Eremin-Solenikov <dbaryshkov@...il.com>, slapin@...fans.org, Tony Cheneau <tony.cheneau@...esiak.org>, linux-zigbee-devel@...ts.sourceforge.net, netdev@...r.kernel.org Subject: Re: RFC: mac802154 Packet Queueing and Slave Devices On Sun, 2012-09-09 at 20:43 -0400, Alan Ott wrote: > Hi, > > Tony and I were recently talking about packet queueing on 802.15.4. What > currently happens (in net/mac802154/tx.c) is that each tx packet (skb) > is stuck on a work queue, and the worker function then sends each packet > to the hardware driver in order. > > The problem with this is that it defeats the netif flow control. And qdisc ability to better control bufferbloat... By the way, mac802154_tx() looks buggy : if (!(priv->phy->channels_supported[page] & (1 << chan))) { WARN_ON(1); // Here, a kfree_skb(skb) is missing. return NETDEV_TX_OK; } if (skb_cow_head(skb, priv->hw.extra_tx_headroom)) { dev_kfree_skb(skb); // should be kfree_skb(skb) return NETDEV_TX_OK; } work = kzalloc(sizeof(struct xmit_work), GFP_ATOMIC); if (!work) return NETDEV_TX_BUSY; NETDEV_TX_BUSY is going to loop. So if there is really no more memory, its a deadlock. You should instead kfree_skb(skb) and return NETDEV_TX_OK. Also mac802154_wpan_xmit() returns NETDEV_TX_OK without kfree_skb(skb) here : if (chan == MAC802154_CHAN_NONE || page >= WPAN_NUM_PAGES || chan >= WPAN_NUM_CHANNELS) return NETDEV_TX_OK; -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists