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: <20120403.172958.144419545310336164.davem@davemloft.net>
Date:	Tue, 03 Apr 2012 17:29:58 -0400 (EDT)
From:	David Miller <davem@...emloft.net>
To:	dwmw2@...radead.org
Cc:	paulus@...ba.org, netdev@...r.kernel.org
Subject: Re: [PATCH] ppp: Don't stop and restart queue on every TX packet

From: David Woodhouse <dwmw2@...radead.org>
Date: Mon, 26 Mar 2012 11:03:42 +0100

> For every transmitted packet, ppp_start_xmit() will stop the netdev
> queue and then, if appropriate, restart it. This causes the TX softirq
> to run, entirely gratuitously.
> 
> This is "only" a waste of CPU time in the normal case, but it's actively
> harmful when the PPP device is a TEQL slave ― the wakeup will cause the
> offending device to receive the next TX packet from the TEQL queue, when
> it *should* have gone to the next slave in the list. We end up seeing
> large bursts of packets on just *one* slave device, rather than using
> the full available bandwidth over all slaves.
> 
> This patch fixes the problem by *not* unconditionally stopping the queue
> in ppp_start_xmit(). It adds a return value from ppp_xmit_process()
> which indicates whether the queue should be stopped or not.
> 
> It *doesn't* remove the call to netif_wake_queue() from
> ppp_xmit_process(), because other code paths (especially from
> ppp_output_wakeup()) need it there and it's messy to push it out to the
> other callers to do it based on the return value. So we leave it in
> place ― it's a no-op in the case where the queue wasn't stopped, so it's
> harmless in the TX path.
> 
> Signed-off-by: David Woodhouse <David.Woodhouse@...el.com>

Applied, thanks.  But:

> --- drivers/net/ppp/ppp_generic.c~	2012-01-26 00:39:32.000000000 +0000
> +++ drivers/net/ppp/ppp_generic.c	2012-03-26 10:32:31.286744147 +0100

Please -p1 root your patches in the future.
--
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