void *cache, *_data = data;
u32 oid;
- BUG_ON(OID_NUM_LAST <= n);
+ BUG_ON(n >= OID_NUM_LAST);
BUG_ON(extra > isl_oid[n].range);
if (!priv->mib)
int dlen;
u32 oid;
- BUG_ON(OID_NUM_LAST <= n);
+ BUG_ON(n >= OID_NUM_LAST);
dlen = isl_oid[n].size;
oid = isl_oid[n].oid;
void *cache, *_res = NULL;
u32 oid;
- BUG_ON(OID_NUM_LAST <= n);
+ BUG_ON(n >= OID_NUM_LAST);
BUG_ON(extra > isl_oid[n].range);
res->ptr = NULL;
void
mgt_set(islpci_private *priv, enum oid_num_t n, void *data)
{
- BUG_ON(OID_NUM_LAST <= n);
+ BUG_ON(n >= OID_NUM_LAST);
BUG_ON(priv->mib[n] == NULL);
memcpy(priv->mib[n], data, isl_oid[n].size);
void
mgt_get(islpci_private *priv, enum oid_num_t n, void *res)
{
- BUG_ON(OID_NUM_LAST <= n);
+ BUG_ON(n >= OID_NUM_LAST);
BUG_ON(priv->mib[n] == NULL);
BUG_ON(res == NULL);