diff options
-rw-r--r-- | drivers/message/fusion/mptctl.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/message/fusion/mptctl.c b/drivers/message/fusion/mptctl.c index a3856ed90aef..1dcc13a52c7e 100644 --- a/drivers/message/fusion/mptctl.c +++ b/drivers/message/fusion/mptctl.c | |||
@@ -1307,8 +1307,10 @@ mptctl_getiocinfo (unsigned long arg, unsigned int data_size) | |||
1307 | else | 1307 | else |
1308 | karg->adapterType = MPT_IOCTL_INTERFACE_SCSI; | 1308 | karg->adapterType = MPT_IOCTL_INTERFACE_SCSI; |
1309 | 1309 | ||
1310 | if (karg->hdr.port > 1) | 1310 | if (karg->hdr.port > 1) { |
1311 | kfree(karg); | ||
1311 | return -EINVAL; | 1312 | return -EINVAL; |
1313 | } | ||
1312 | port = karg->hdr.port; | 1314 | port = karg->hdr.port; |
1313 | 1315 | ||
1314 | karg->port = port; | 1316 | karg->port = port; |