Skip to content

Commit

Permalink
net: vlan: Fixed signedness in vlan_group_prealloc_vid()
Browse files Browse the repository at this point in the history
After commit d018684 ("net: vlan: Avoid using BUG() in
vlan_proto_idx()"), vlan_proto_idx() was changed to return a signed
integer, however one of its called: vlan_group_prealloc_vid() was still
using an unsigned integer for its return value, fix that.

Fixes: d018684 ("net: vlan: Avoid using BUG() in vlan_proto_idx()")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Florian Fainelli authored and David S. Miller committed Sep 28, 2020
1 parent 4cd4b36 commit 0675c28
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion net/8021q/vlan.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,9 @@ static int vlan_group_prealloc_vid(struct vlan_group *vg,
__be16 vlan_proto, u16 vlan_id)
{
struct net_device **array;
unsigned int pidx, vidx;
unsigned int vidx;
unsigned int size;
int pidx;

ASSERT_RTNL();

Expand Down

0 comments on commit 0675c28

Please sign in to comment.