aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWarner Losh <imp@FreeBSD.org>2025-03-10 20:46:48 +0000
committerWarner Losh <imp@FreeBSD.org>2025-03-11 02:33:15 +0000
commit048d6ca31d968a79cfcde30295eff475582b1915 (patch)
tree20749cb3b07c2e302fd5e42395caf12b075a2160
parent717adecbbb5293d8386caa866c21421ef9eeb22c (diff)
umass: Remove some 20-year-old dead code
A REQUEST SENSE CDB was just copied into the cmd buffer, so testing for INQUIRY will always fail. Remove the dead code. This code was added, apparently by mistake in 2003. 8541fbec7900e merged changes from NetBSD's umass_scsipi.c 1.8 to address some BBB bulk-in clear problems. NetBSD had fixed a problem in the FORCE_SHORT_INQUIRY quirk code they had ported from FreeBSD that FreeBSD also needed. That merge also included the dead code, which was not in NetBSD. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D49311
-rw-r--r--sys/dev/usb/storage/umass.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/sys/dev/usb/storage/umass.c b/sys/dev/usb/storage/umass.c
index 58f36e756dce..3e5cc9a7e084 100644
--- a/sys/dev/usb/storage/umass.c
+++ b/sys/dev/usb/storage/umass.c
@@ -2523,10 +2523,6 @@ umass_cam_cb(struct umass_softc *sc, union ccb *ccb, uint32_t residue,
if (umass_std_transform(sc, ccb, &sc->cam_scsi_sense.opcode,
sizeof(sc->cam_scsi_sense))) {
- if ((sc->sc_quirks & FORCE_SHORT_INQUIRY) &&
- (sc->sc_transfer.cmd_data[0] == INQUIRY)) {
- ccb->csio.sense_len = SHORT_INQUIRY_LENGTH;
- }
umass_command_start(sc, DIR_IN, &ccb->csio.sense_data.error_code,
ccb->csio.sense_len, ccb->ccb_h.timeout,
&umass_cam_sense_cb, ccb);