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: <1388213953.24123.2.camel@joe-AO722>
Date:	Fri, 27 Dec 2013 22:59:13 -0800
From:	Joe Perches <joe@...ches.com>
To:	Ding Tianhong <dingtianhong@...wei.com>,
	Sjur Brændeland 
	<sjur.brandeland@...ricsson.com>
Cc:	Dmitry Tarnyagin <dmitry.tarnyagin@...kless.no>,
	"David S. Miller" <davem@...emloft.net>,
	Netdev <netdev@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH net-next v2 20/20] net: caif: slight optimization of
 addr compare

On Sat, 2013-12-28 at 14:18 +0800, Ding Tianhong wrote:
> Use possibly more efficient ether_addr_equal
> to instead of memcmp.

This may be a distinction without difference, but
is a CAIF seghead also an ethernet address?

> diff --git a/net/caif/cfrfml.c b/net/caif/cfrfml.c
[]
> @@ -79,7 +79,7 @@ static struct cfpkt *rfm_append(struct cfrfml *rfml, char *seghead,
[]
>  	/* Verify correct header */
> -	if (memcmp(seghead, rfml->seghead, 6) != 0)
> +	if (!ether_addr_equal(seghead, rfml->seghead))


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ