Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/usb Remove UMASS_QUIRK_NO_START_STOP and UMASS_QUIRK...



details:   https://anonhg.NetBSD.org/src/rev/edee97931792
branches:  trunk
changeset: 551604:edee97931792
user:      mycroft <mycroft%NetBSD.org@localhost>
date:      Mon Sep 08 19:30:59 2003 +0000

description:
Remove UMASS_QUIRK_NO_START_STOP and UMASS_QUIRK_NO_MAX_LUN.

diffstat:

 sys/dev/usb/umass.c        |   7 +--
 sys/dev/usb/umass_quirks.c |  72 +++++----------------------------------------
 sys/dev/usb/umass_scsipi.c |  11 +-----
 sys/dev/usb/umassvar.h     |  12 +++----
 4 files changed, 18 insertions(+), 84 deletions(-)

diffs (235 lines):

diff -r 67a54bcf4f6f -r edee97931792 sys/dev/usb/umass.c
--- a/sys/dev/usb/umass.c       Mon Sep 08 19:17:29 2003 +0000
+++ b/sys/dev/usb/umass.c       Mon Sep 08 19:30:59 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: umass.c,v 1.97 2003/09/04 00:02:59 mycroft Exp $       */
+/*     $NetBSD: umass.c,v 1.98 2003/09/08 19:30:59 mycroft Exp $       */
 /*-
  * Copyright (c) 1999 MAEKAWA Masahide <bishop%rr.iij4u.or.jp@localhost>,
  *                   Nick Hibma <n_hibma%freebsd.org@localhost>
@@ -94,7 +94,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: umass.c,v 1.97 2003/09/04 00:02:59 mycroft Exp $");
+__KERNEL_RCSID(0, "$NetBSD: umass.c,v 1.98 2003/09/08 19:30:59 mycroft Exp $");
 
 #include "atapibus.h"
 #include "scsibus.h"
@@ -439,8 +439,7 @@
        /*
         * Get the maximum LUN supported by the device.
         */
-       if (sc->sc_wire == UMASS_WPROTO_BBB &&
-           !(sc->sc_quirks & UMASS_QUIRK_NO_MAX_LUN)) {
+       if (sc->sc_wire == UMASS_WPROTO_BBB) {
                err = umass_bbb_get_max_lun(sc, &sc->maxlun);
                if (err) {
                        printf("%s: unable to get Max Lun: %s\n",
diff -r 67a54bcf4f6f -r edee97931792 sys/dev/usb/umass_quirks.c
--- a/sys/dev/usb/umass_quirks.c        Mon Sep 08 19:17:29 2003 +0000
+++ b/sys/dev/usb/umass_quirks.c        Mon Sep 08 19:30:59 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: umass_quirks.c,v 1.48 2003/09/08 16:06:57 tron Exp $   */
+/*     $NetBSD: umass_quirks.c,v 1.49 2003/09/08 19:31:00 mycroft Exp $        */
 
 /*
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: umass_quirks.c,v 1.48 2003/09/08 16:06:57 tron Exp $");
+__KERNEL_RCSID(0, "$NetBSD: umass_quirks.c,v 1.49 2003/09/08 19:31:00 mycroft Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -61,17 +61,9 @@
 Static void umass_fixup_yedata(struct umass_softc *);
 
 Static const struct umass_quirk umass_quirks[] = {
-       { { USB_VENDOR_ACDC, USB_PRODUCT_ACDC_PEN },
-         UMASS_WPROTO_BBB, UMASS_CPROTO_SCSI,  
-         UMASS_QUIRK_NO_START_STOP, 
-         0,
-         UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO, 
-         NULL, NULL
-       },
-
        { { USB_VENDOR_FUJIPHOTO, USB_PRODUCT_FUJIPHOTO_MASS0100 },
          UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_NO_START_STOP,
+         0,
          PQUIRK_NOTUR | PQUIRK_NOSENSE,
          UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
          NULL, NULL
@@ -79,7 +71,7 @@
 
        { { USB_VENDOR_INSYSTEM, USB_PRODUCT_INSYSTEM_USBCABLE },
          UMASS_WPROTO_CBI, UMASS_CPROTO_ATAPI,
-         UMASS_QUIRK_NO_START_STOP,
+         0,
          PQUIRK_NOTUR,
          UMATCH_VENDOR_PRODUCT,
          umass_init_insystem, NULL
@@ -104,23 +96,7 @@
 
        { { USB_VENDOR_MELCO, USB_PRODUCT_MELCO_DUBPXXG },
          UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_FORCE_SHORT_INQUIRY | UMASS_QUIRK_NO_START_STOP,
-         0,
-         UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
-         NULL, NULL
-       },
-
-       { { USB_VENDOR_MINOLTA, USB_PRODUCT_MINOLTA_S304 },
-         UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_NO_START_STOP,
-         0,
-         UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
-         NULL, NULL
-       },
-
-       { { USB_VENDOR_MINOLTA, USB_PRODUCT_MINOLTA_X },
-         UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_NO_START_STOP,
+         UMASS_QUIRK_FORCE_SHORT_INQUIRY,
          0,
          UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
          NULL, NULL
@@ -166,14 +142,6 @@
          NULL, NULL
        },
 
-       { { USB_VENDOR_ONSPEC, USB_PRODUCT_ONSPEC_MD1II },
-         UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_NO_START_STOP,
-         0,
-         UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
-         NULL, NULL
-       },
-
        { { USB_VENDOR_PEN, USB_PRODUCT_PEN_MOBILEDRIVE },
          UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
          0,
@@ -182,14 +150,6 @@
          NULL, NULL
        },
 
-       { { USB_VENDOR_PEN, USB_PRODUCT_PEN_USBDISK },
-         UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_NO_START_STOP,
-         0,
-         UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
-         NULL, NULL
-       },
-
        { { USB_VENDOR_PILOTECH, USB_PRODUCT_PILOTECH_CRW600 },
          UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
          0,
@@ -224,7 +184,7 @@
 
        { { USB_VENDOR_SHUTTLE, USB_PRODUCT_SHUTTLE_EUSB },
          UMASS_WPROTO_CBI_I, UMASS_CPROTO_ATAPI,
-         UMASS_QUIRK_NO_START_STOP,
+         0,
          PQUIRK_NOTUR,
          UMATCH_VENDOR_PRODUCT,
          umass_init_shuttle, NULL
@@ -232,28 +192,12 @@
 
        { { USB_VENDOR_SHUTTLE, USB_PRODUCT_SHUTTLE_ZIOMMC },
          UMASS_WPROTO_CBI_I, UMASS_CPROTO_ATAPI,
-         UMASS_QUIRK_NO_START_STOP,
+         0,
          PQUIRK_NOTUR,
          UMATCH_VENDOR_PRODUCT,
          NULL, NULL
        },
 
-       { { USB_VENDOR_SIIG, USB_PRODUCT_SIIG_UISDMC2S }, 
-         UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_NO_START_STOP,
-         0,
-         UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
-         NULL,NULL
-       }, 
-
-       { { USB_VENDOR_SIIG, USB_PRODUCT_SIIG_MULTICARDREADER }, 
-         UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_NO_START_STOP,
-         0,
-         UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
-         NULL,NULL
-       }, 
-
        { { USB_VENDOR_SONY, USB_PRODUCT_SONY_DSC },
          UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
          0,
@@ -296,7 +240,7 @@
 
        { { USB_VENDOR_GENESYS,USB_PRODUCT_GENESYS_GL641USB },
          UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
-         UMASS_QUIRK_FORCE_SHORT_INQUIRY | UMASS_QUIRK_NO_START_STOP,
+         UMASS_QUIRK_FORCE_SHORT_INQUIRY,
          0,
          UMATCH_DEVCLASS_DEVSUBCLASS_DEVPROTO,
          NULL, NULL
diff -r 67a54bcf4f6f -r edee97931792 sys/dev/usb/umass_scsipi.c
--- a/sys/dev/usb/umass_scsipi.c        Mon Sep 08 19:17:29 2003 +0000
+++ b/sys/dev/usb/umass_scsipi.c        Mon Sep 08 19:30:59 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: umass_scsipi.c,v 1.9 2003/02/16 23:14:08 augustss Exp $        */
+/*     $NetBSD: umass_scsipi.c,v 1.10 2003/09/08 19:31:00 mycroft Exp $        */
 
 /*
  * Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -38,7 +38,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: umass_scsipi.c,v 1.9 2003/02/16 23:14:08 augustss Exp $");
+__KERNEL_RCSID(0, "$NetBSD: umass_scsipi.c,v 1.10 2003/09/08 19:31:00 mycroft Exp $");
 
 #include "atapibus.h"
 #include "scsibus.h"
@@ -290,13 +290,6 @@
 
                /* XXX should use transform */
 
-               if (cmd->opcode == START_STOP &&
-                   (sc->sc_quirks & UMASS_QUIRK_NO_START_STOP)) {
-                       /*printf("%s: START_STOP\n", USBDEVNAME(sc->sc_dev));*/
-                       xs->error = XS_NOERROR;
-                       goto done;
-               }
-
                if (cmd->opcode == INQUIRY &&
                    (sc->sc_quirks & UMASS_QUIRK_FORCE_SHORT_INQUIRY)) {
                        /*
diff -r 67a54bcf4f6f -r edee97931792 sys/dev/usb/umassvar.h
--- a/sys/dev/usb/umassvar.h    Mon Sep 08 19:17:29 2003 +0000
+++ b/sys/dev/usb/umassvar.h    Mon Sep 08 19:30:59 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: umassvar.h,v 1.19 2003/02/22 05:18:50 tsutsui Exp $    */
+/*     $NetBSD: umassvar.h,v 1.20 2003/09/08 19:31:01 mycroft Exp $    */
 /*-
  * Copyright (c) 1999 MAEKAWA Masahide <bishop%rr.iij4u.or.jp@localhost>,
  *                   Nick Hibma <n_hibma%freebsd.org@localhost>
@@ -176,12 +176,10 @@
 #define UMASS_CPROTO_ISD_ATA   5
 
        u_int32_t               sc_quirks;
-#define        UMASS_QUIRK_RS_NO_CLEAR_UA       0x00000002
-#define        UMASS_QUIRK_NO_START_STOP        0x00000004
-#define        UMASS_QUIRK_FORCE_SHORT_INQUIRY  0x00000008
-#define        UMASS_QUIRK_WRONG_CSWSIG         0x00000010
-#define UMASS_QUIRK_NO_MAX_LUN           0x00000020
-#define        UMASS_QUIRK_WRONG_CSWTAG         0x00000040
+#define        UMASS_QUIRK_RS_NO_CLEAR_UA       0x00000001
+#define        UMASS_QUIRK_FORCE_SHORT_INQUIRY  0x00000002
+#define        UMASS_QUIRK_WRONG_CSWSIG         0x00000004
+#define        UMASS_QUIRK_WRONG_CSWTAG         0x00000008
 
        u_int32_t               sc_busquirks;
 



Home | Main Index | Thread Index | Old Index