summaryrefslogtreecommitdiffstats
path: root/drivers/block/nvme-scsi.c
diff options
context:
space:
mode:
authorVishal Verma <vishal.l.verma@linux.intel.com>2013-05-13 14:55:18 -0600
committerMatthew Wilcox <matthew.r.wilcox@intel.com>2013-05-17 09:10:38 -0400
commit710a143dd870cd660b5ae26bb94b6da854376e91 (patch)
tree4349e99f8439f1f780d41a98acc26e3cf322ea28 /drivers/block/nvme-scsi.c
parent76e0310c2d5a4fb62f674af7dad16f544950fc13 (diff)
downloadop-kernel-dev-710a143dd870cd660b5ae26bb94b6da854376e91.zip
op-kernel-dev-710a143dd870cd660b5ae26bb94b6da854376e91.tar.gz
NVMe: Fix a signedness bug in nvme_trans_modesel_get_mp
nvme_trans_modesel_get_mp() was defined with a unsigned return type, but can return signed values. Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Vishal Verma <vishal.l.verma@linux.intel.com> Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
Diffstat (limited to 'drivers/block/nvme-scsi.c')
-rw-r--r--drivers/block/nvme-scsi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/block/nvme-scsi.c b/drivers/block/nvme-scsi.c
index 64bde68..102de2f 100644
--- a/drivers/block/nvme-scsi.c
+++ b/drivers/block/nvme-scsi.c
@@ -1653,7 +1653,7 @@ static void nvme_trans_modesel_save_bd(struct nvme_ns *ns, u8 *parm_list,
}
}
-static u16 nvme_trans_modesel_get_mp(struct nvme_ns *ns, struct sg_io_hdr *hdr,
+static int nvme_trans_modesel_get_mp(struct nvme_ns *ns, struct sg_io_hdr *hdr,
u8 *mode_page, u8 page_code)
{
int res = SNTI_TRANSLATION_SUCCESS;
OpenPOWER on IntegriCloud