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
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4C75838A.2080304@candelatech.com>
Date:	Wed, 25 Aug 2010 13:56:42 -0700
From:	Ben Greear <greearb@...delatech.com>
To:	Stephen Hemminger <shemminger@...tta.com>
CC:	netdev@...r.kernel.org
Subject: Re: [net-next 1/2] qdisc:  Allow qdiscs to provide backpressure up
 the stack.

On 08/25/2010 01:44 PM, Stephen Hemminger wrote:
> On Wed, 25 Aug 2010 12:00:50 -0700

>>   struct Qdisc {
>>   	int 			(*enqueue)(struct sk_buff *skb, struct Qdisc *dev);
>> +	int 			(*try_enqueue)(struct sk_buff *, struct Qdisc *dev); /* May return NET_XMIT_BUSY and NOT free skb. */
>>
>
>
> There aren't that many qdisc modules; just fix them all and change
> semantics of enqueue.  How do you expect to handle the retry? Spinning
> at the higher level is a bad idea and there is no non-racy way to get
> a callback to make forward progress.

It may only make sense for things like macvlan at this point, since
it is already valid to return NET_XMIT_BUSY and not free the SKB
when you call dev->hard_start_xmit().

Using the try_ logic for sockets and such would probably require a good
deal more work, and probably is something I'd not attempt any time
soon (there are others who know that code better, so maybe they'd
be able & willing to do that work).

If/when all the calling code knows how to do the retry logic properly,
then we could have a single enqueue method, but I think to allow
incremental changes, it's best to have the two methods for now.

Thanks,
Ben

-- 
Ben Greear <greearb@...delatech.com>
Candela Technologies Inc  http://www.candelatech.com

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ