]> 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)
commitce684fd93c47b719cd1dc35716483dd854665500
treea8558eaf3e54f9a65ab9f11f5755c192883a01f0
parent40883e6f64d76b75cf86336f47d5df2e001629c5
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