Skip to content
Snippets Groups Projects
Commit 679b2ec8 authored by Diego Elio Pettenò's avatar Diego Elio Pettenò Committed by Martin K. Petersen
Browse files

scsi: sr: remove references to BLK_DEV_SR_VENDOR, leave it enabled

This kernel configuration is basically enabling/disabling sr driver quirks
detection. While these quirks are for fairly rare devices (very old CD
burners, and a glucometer), the additional detection of these models is a
very minimal amount of code.

The logic behind the quirks is always built into the sr driver.

This also removes the config from all the defconfig files that are enabling
this already.

Link: https://lore.kernel.org/r/20200223191144.726-1-flameeyes@flameeyes.com


Reviewed-by: default avatarJens Axboe <axboe@kernel.dk>
Signed-off-by: default avatarDiego Elio Pettenò <flameeyes@flameeyes.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 30f6d494
No related branches found
No related tags found
No related merge requests found
......@@ -73,7 +73,6 @@ CONFIG_RAID_ATTRS=m
CONFIG_SCSI=y
CONFIG_BLK_DEV_SD=y
CONFIG_BLK_DEV_SR=m
CONFIG_BLK_DEV_SR_VENDOR=y
CONFIG_CHR_DEV_SG=m
CONFIG_SCSI_MULTI_LUN=y
CONFIG_SCSI_CONSTANTS=y
......
......@@ -137,7 +137,6 @@ CONFIG_CONNECTOR=y
CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_SD=y
CONFIG_BLK_DEV_SR=y
CONFIG_BLK_DEV_SR_VENDOR=y
CONFIG_CHR_DEV_SG=y
CONFIG_SCSI_CONSTANTS=y
CONFIG_SCSI_SPI_ATTRS=y
......
......@@ -135,7 +135,6 @@ CONFIG_CONNECTOR=y
CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_SD=y
CONFIG_BLK_DEV_SR=y
CONFIG_BLK_DEV_SR_VENDOR=y
CONFIG_CHR_DEV_SG=y
CONFIG_SCSI_CONSTANTS=y
CONFIG_SCSI_SPI_ATTRS=y
......
......@@ -115,15 +115,6 @@ config BLK_DEV_SR
<file:Documentation/scsi/scsi.txt>.
The module will be called sr_mod.
config BLK_DEV_SR_VENDOR
bool "Enable vendor-specific extensions (for SCSI CDROM)"
depends on BLK_DEV_SR
help
This enables the usage of vendor specific SCSI commands. This is
required to support multisession CDs with old NEC/TOSHIBA cdrom
drives (and HP Writers). If you have such a drive and get the first
session only, try saying Y here; everybody else says N.
config CHR_DEV_SG
tristate "SCSI generic support"
depends on SCSI
......
......@@ -67,9 +67,6 @@
void sr_vendor_init(Scsi_CD *cd)
{
#ifndef CONFIG_BLK_DEV_SR_VENDOR
cd->vendor = VENDOR_SCSI3;
#else
const char *vendor = cd->device->vendor;
const char *model = cd->device->model;
......@@ -118,7 +115,6 @@ void sr_vendor_init(Scsi_CD *cd)
CDC_PLAY_AUDIO
);
}
#endif
}
......@@ -132,10 +128,8 @@ int sr_set_blocklength(Scsi_CD *cd, int blocklength)
struct ccs_modesel_head *modesel;
int rc, density = 0;
#ifdef CONFIG_BLK_DEV_SR_VENDOR
if (cd->vendor == VENDOR_TOSHIBA)
density = (blocklength > 2048) ? 0x81 : 0x83;
#endif
buffer = kmalloc(512, GFP_KERNEL | GFP_DMA);
if (!buffer)
......@@ -223,7 +217,6 @@ int sr_cd_check(struct cdrom_device_info *cdi)
}
break;
#ifdef CONFIG_BLK_DEV_SR_VENDOR
case VENDOR_NEC:{
unsigned long min, sec, frame;
cgc.cmd[0] = 0xde;
......@@ -316,7 +309,6 @@ int sr_cd_check(struct cdrom_device_info *cdi)
sector = buffer[11] + (buffer[10] << 8) +
(buffer[9] << 16) + (buffer[8] << 24);
break;
#endif /* CONFIG_BLK_DEV_SR_VENDOR */
default:
/* should not happen */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment