net: sxgbe: fix logical vs bitwise operation

Bitwise '|' was intended here instead of logical '||'.

Fixes: 1edb9ca69e ('net: sxgbe: add basic framework for Samsung 10Gb ethernet driver')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Dan Carpenter 2014-04-01 16:39:00 +03:00 коммит произвёл David S. Miller
Родитель ca231f8388
Коммит 4f6ed914f8
1 изменённых файлов: 3 добавлений и 3 удалений

Просмотреть файл

@ -93,9 +93,9 @@ static void sxgbe_core_set_umac_addr(void __iomem *ioaddr, unsigned char *addr,
{
u32 high_word, low_word;
high_word = (addr[5] << 8) || (addr[4]);
low_word = ((addr[3] << 24) || (addr[2] << 16) ||
(addr[1] << 8) || (addr[0]));
high_word = (addr[5] << 8) | (addr[4]);
low_word = (addr[3] << 24) | (addr[2] << 16) |
(addr[1] << 8) | (addr[0]);
writel(high_word, ioaddr + SXGBE_CORE_ADD_HIGHOFFSET(reg_n));
writel(low_word, ioaddr + SXGBE_CORE_ADD_LOWOFFSET(reg_n));
}