diff options
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/ipmi/ipmi_msghandler.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/char/ipmi/ipmi_msghandler.c b/drivers/char/ipmi/ipmi_msghandler.c index 0097f06fa67b..d745004281d0 100644 --- a/drivers/char/ipmi/ipmi_msghandler.c +++ b/drivers/char/ipmi/ipmi_msghandler.c | |||
@@ -481,7 +481,7 @@ int ipmi_validate_addr(struct ipmi_addr *addr, int len) | |||
481 | } | 481 | } |
482 | 482 | ||
483 | if ((addr->channel == IPMI_BMC_CHANNEL) | 483 | if ((addr->channel == IPMI_BMC_CHANNEL) |
484 | || (addr->channel >= IPMI_NUM_CHANNELS) | 484 | || (addr->channel >= IPMI_MAX_CHANNELS) |
485 | || (addr->channel < 0)) | 485 | || (addr->channel < 0)) |
486 | return -EINVAL; | 486 | return -EINVAL; |
487 | 487 | ||
@@ -1321,7 +1321,7 @@ static int i_ipmi_request(ipmi_user_t user, | |||
1321 | unsigned char ipmb_seq; | 1321 | unsigned char ipmb_seq; |
1322 | long seqid; | 1322 | long seqid; |
1323 | 1323 | ||
1324 | if (addr->channel >= IPMI_NUM_CHANNELS) { | 1324 | if (addr->channel >= IPMI_MAX_CHANNELS) { |
1325 | spin_lock_irqsave(&intf->counter_lock, flags); | 1325 | spin_lock_irqsave(&intf->counter_lock, flags); |
1326 | intf->sent_invalid_commands++; | 1326 | intf->sent_invalid_commands++; |
1327 | spin_unlock_irqrestore(&intf->counter_lock, flags); | 1327 | spin_unlock_irqrestore(&intf->counter_lock, flags); |