doc: Fix comparison operator
PATCH 1/1 doc: Fix comparison operator
From: Olaf Mandel <[email protected]>
Align the documentation with the include/linux/etherdevice.h , which is where this example comes from. The return value from the check was inverted in the documentation.
Signed-off-by Olaf Mandel <[email protected]>
Signed-off-by Marek Vasut <[email protected]>
Cc Albert ARIBAUD <[email protected]>
Cc Tom Rini <[email protected]>
--- doc/README.unaligned-memory-access.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
doc/README.unaligned-memory-access.txt +1 -1
@@ -154,7 +154,7 @@ bool ether_addr_equal(const u8 *addr1, const u8 *addr2) #else const u16 *a = (const u16 *)addr1; const u16 *b = (const u16 *)addr2; - return ((a[0] ^ b[0]) | (a[1] ^ b[1]) | (a[2] ^ b[2])) != 0; + return ((a[0] ^ b[0]) | (a[1] ^ b[1]) | (a[2] ^ b[2])) == 0; #endif }
Signature · 1 line
2.0.0
Quoted 10 lines · Marek Vasut
From: Olaf Mandel <[email protected]>
Align the documentation with the
include/linux/etherdevice.h, which is where this example comes from. The return value from the check was inverted in the documentation.Signed-off-by Olaf Mandel <[email protected]>Signed-off-by Marek Vasut <[email protected]>Cc Albert ARIBAUD <[email protected]>Cc Tom Rini <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 836 bytes Desc: Digital signature URL: <http://lists.denx.de/pipermail/u-boot/attachments/20141027/5b146316/attachment.pgp>