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-next>] [day] [month] [year] [list]
Date:	Tue, 06 Jan 2009 11:18:54 +0100
From:	Oliver Hartkopp <oliver@...tkopp.net>
To:	David Miller <davem@...emloft.net>
CC:	Urs Thuermann <urs.thuermann@...kswagen.de>,
	Linux Netdev List <netdev@...r.kernel.org>
Subject: [RESEND] can: omit unneeded skb_clone() calls

The AF_CAN core delivered always cloned sk_buffs to the AF_CAN
protocols, although this was _only_ needed by the can-raw protocol.
With this (additionally documented) change, the AF_CAN core calls the
callback functions of the registered AF_CAN protocols with the original
(uncloned) sk_buff pointer and let's the can-raw protocol do the
skb_clone() itself which omits all unneeded skb_clone() calls for other
AF_CAN protocols.

Signed-off-by: Oliver Hartkopp <oliver@...tkopp.net>
Signed-off-by: Urs Thuermann <urs.thuermann@...kswagen.de>
---

Hello Dave,

this is a simple (and tested) improvement to omit superfluous skb_clone() 
calls in the CAN core.

Please check if it's ok for the current merge window as it is not really a fix.

If it's not ok, i'll resubmit it when net-next-2.6 re-opens.

The resend was due to a removal of these parentheses:

-	if ((!ro->recv_own_msgs) && (skb->sk == sk))
+	if (!ro->recv_own_msgs && skb->sk == sk)


Thanks,
Oliver


View attachment "omit_skbclone_resend.patch" of type "text/x-patch" (3452 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ