staging: slicoss: Use inplace convert with __be32 *

This patch fixes "cast to restricted __be32"
sparse warning.

remove  temporary value assignment and use inplace
__be32 conversion for ntohl function which is can
get big endian format

Signed-off-by: Ebru Akagunduz <ebru.akagunduz@gmail.com>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Ebru Akagunduz 2014-10-23 16:10:16 +03:00 committed by Greg Kroah-Hartman
parent e31a0e6280
commit 438c582602
1 changed files with 1 additions and 2 deletions

View File

@ -596,8 +596,7 @@ static void slic_mac_address_config(struct adapter *adapter)
u32 value2;
__iomem struct slic_regs *slic_regs = adapter->slic_regs;
value = *(u32 *) &adapter->currmacaddr[2];
value = ntohl(value);
value = ntohl(*(__be32 *) &adapter->currmacaddr[2]);
slic_reg32_write(&slic_regs->slic_wraddral, value, FLUSH);
slic_reg32_write(&slic_regs->slic_wraddrbl, value, FLUSH);