]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: bcm_sf2: cleanup bcm_sf2_cfp_rule_get() a little
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 7 Feb 2017 13:15:27 +0000 (16:15 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 8 Feb 2017 18:27:06 +0000 (13:27 -0500)
commit5359d15b00be8b444ff691c6ac6275cf717a6db2
treea8558eaf3e54f9a65ab9f11f5755c192883a01f0
parent21510411ad0d2314a30eafbc13d01a265bf7ba3f
net: dsa: bcm_sf2: cleanup bcm_sf2_cfp_rule_get() a little

This patch doesn't affect how the code works.

My static checker complains that the mask and shift doesn't make sense
because 0xffffff << 16 goes beyond the end of 32 bits.  It should be
0xffff instead but the existing code won't cause runtime bugs.

Also the casting here is not needed and not consistent with the rest of
the code.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/bcm_sf2_cfp.c