summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/sr.c
diff options
context:
space:
mode:
authorDamien Le Moal <dlemoal@kernel.org>2023-05-11 03:13:39 +0200
committerMartin K. Petersen <martin.petersen@oracle.com>2023-05-22 23:05:19 +0200
commita6cdc35fab0d813d54744abe2af07d6c49c07d6e (patch)
tree6ede7a9a0285db907aec8206a219bef1a1b150ac /drivers/scsi/sr.c
parentscsi: core: Rename and move get_scsi_ml_byte() (diff)
downloadlinux-a6cdc35fab0d813d54744abe2af07d6c49c07d6e.tar.xz
linux-a6cdc35fab0d813d54744abe2af07d6c49c07d6e.zip
scsi: core: Support retrieving sub-pages of mode pages
Allow scsi_mode_sense() to retrieve sub-pages of mode pages by adding the subpage argument. Change all the current caller sites to specify the subpage 0. Signed-off-by: Damien Le Moal <dlemoal@kernel.org> Reviewed-by: Hannes Reinecke <hare@suse.de> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Bart Van Assche <bvanassche@acm.org> Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com> Link: https://lore.kernel.org/r/20230511011356.227789-7-nks@flawful.org Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/sr.c')
-rw-r--r--drivers/scsi/sr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/sr.c b/drivers/scsi/sr.c
index 12869e6d4ebd..cd5b08689c1a 100644
--- a/drivers/scsi/sr.c
+++ b/drivers/scsi/sr.c
@@ -825,7 +825,7 @@ static int get_capabilities(struct scsi_cd *cd)
scsi_test_unit_ready(cd->device, SR_TIMEOUT, MAX_RETRIES, &sshdr);
/* ask for mode page 0x2a */
- rc = scsi_mode_sense(cd->device, 0, 0x2a, buffer, ms_len,
+ rc = scsi_mode_sense(cd->device, 0, 0x2a, 0, buffer, ms_len,
SR_TIMEOUT, 3, &data, NULL);
if (rc < 0 || data.length > ms_len ||