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: <20141205.213112.1199355931404701216.davem@davemloft.net>
Date:	Fri, 05 Dec 2014 21:31:12 -0800 (PST)
From:	David Miller <davem@...emloft.net>
To:	weiyang@...ux.vnet.ibm.com
Cc:	netdev@...r.kernel.org, gideonn@...lanox.com, edumazet@...gle.com,
	amirv@...lanox.com
Subject: Re: [PATCH net] net/mlx4_en: correct the endianness of
 doorbell_qpn on big endian platform

From: Wei Yang <weiyang@...ux.vnet.ibm.com>
Date: Sun, 30 Nov 2014 10:43:51 +0800

> In commit 6a4e812 (net/mlx4_en: Avoid calling bswap in tx fast path), we store
> doorbell_qpn in big endian to avoid bswap(). Then we try to write it directly
> by iowrite32() instead of iowrite32be().
> 
> This works fine on little endian platform, while has some problem on big
> endian platform. Here is the definition in general:
> 
> 	#define iowrite32(v, addr)	writel((v), (addr))
> 	#define writel(b,addr)		__raw_writel(__cpu_to_le32(b),addr)
> 
> On little endian platform, the value is not swapped before write. While on big
> endian platform, the value is swapped. This is not expected to happen.
> 
> This patch does the swap on big endian platform before it is written.
> 
> Signed-off-by: Wei Yang <weiyang@...ux.vnet.ibm.com>

Guys, let's figure out what we are doing with this patch.
--
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