bnx2x: fix assignment of signed expression to unsigned variable

fix for incorrect assignment of signed expression to unsigned variable.

Signed-off-by: Kumar Amit Mehta <gmate.amit@gmail.com>
Acked-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Kumar Amit Mehta
2013-03-23 20:10:25 +00:00
committed by David S. Miller
parent 9b46922e15
commit 8fe7f99a9e

View File

@@ -2139,12 +2139,12 @@ static u8 bnx2x_dcbnl_get_cap(struct net_device *netdev, int capid, u8 *cap)
break;
default:
BNX2X_ERR("Non valid capability ID\n");
rval = -EINVAL;
rval = 1;
break;
}
} else {
DP(BNX2X_MSG_DCB, "DCB disabled\n");
rval = -EINVAL;
rval = 1;
}
DP(BNX2X_MSG_DCB, "capid %d:%x\n", capid, *cap);
@@ -2170,12 +2170,12 @@ static int bnx2x_dcbnl_get_numtcs(struct net_device *netdev, int tcid, u8 *num)
break;
default:
BNX2X_ERR("Non valid TC-ID\n");
rval = -EINVAL;
rval = 1;
break;
}
} else {
DP(BNX2X_MSG_DCB, "DCB disabled\n");
rval = -EINVAL;
rval = 1;
}
return rval;
@@ -2390,12 +2390,12 @@ static u8 bnx2x_dcbnl_get_featcfg(struct net_device *netdev, int featid,
break;
default:
BNX2X_ERR("Non valid featrue-ID\n");
rval = -EINVAL;
rval = 1;
break;
}
} else {
DP(BNX2X_MSG_DCB, "DCB disabled\n");
rval = -EINVAL;
rval = 1;
}
return rval;
@@ -2431,12 +2431,12 @@ static u8 bnx2x_dcbnl_set_featcfg(struct net_device *netdev, int featid,
break;
default:
BNX2X_ERR("Non valid featrue-ID\n");
rval = -EINVAL;
rval = 1;
break;
}
} else {
DP(BNX2X_MSG_DCB, "dcbnl call not valid\n");
rval = -EINVAL;
rval = 1;
}
return rval;