diff options
author | n_hibma <n_hibma@FreeBSD.org> | 2014-08-05 09:35:25 +0000 |
---|---|---|
committer | n_hibma <n_hibma@FreeBSD.org> | 2014-08-05 09:35:25 +0000 |
commit | 7cb9d0139b7fbaa1a047ddb52ee3674df1c313f4 (patch) | |
tree | 577b057dbce538b559954f7059b20e85d8b21acc /sys/dev/usb/usb_msctest.c | |
parent | 279fc7be5ae5836a609b3592ac578899683622f1 (diff) | |
download | FreeBSD-src-7cb9d0139b7fbaa1a047ddb52ee3674df1c313f4.zip FreeBSD-src-7cb9d0139b7fbaa1a047ddb52ee3674df1c313f4.tar.gz |
Add a second Huawei SCSI eject command as USB mode switch config files
sometimes use one or the other. Maybe newer Huawei modems switched.
Add a quirk for it as well.
PR: 145319
Submitted by: rozhuk.im gmail.com
Diffstat (limited to 'sys/dev/usb/usb_msctest.c')
-rw-r--r-- | sys/dev/usb/usb_msctest.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sys/dev/usb/usb_msctest.c b/sys/dev/usb/usb_msctest.c index df4277c..1d3520f 100644 --- a/sys/dev/usb/usb_msctest.c +++ b/sys/dev/usb/usb_msctest.c @@ -103,6 +103,9 @@ static uint8_t scsi_cmotech_eject[] = { 0xff, 0x52, 0x44, 0x45, 0x56, 0x43, static uint8_t scsi_huawei_eject[] = { 0x11, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; +static uint8_t scsi_huawei_eject2[] = { 0x11, 0x06, 0x20, 0x00, 0x00, 0x01, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00 }; static uint8_t scsi_tct_eject[] = { 0x06, 0xf5, 0x04, 0x02, 0x52, 0x70 }; static uint8_t scsi_sync_cache[] = { 0x35, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; @@ -840,6 +843,11 @@ usb_msc_eject(struct usb_device *udev, uint8_t iface_index, int method) &scsi_huawei_eject, sizeof(scsi_huawei_eject), USB_MS_HZ); break; + case MSC_EJECT_HUAWEI2: + err = bbb_command_start(sc, DIR_IN, 0, NULL, 0, + &scsi_huawei_eject2, sizeof(scsi_huawei_eject2), + USB_MS_HZ); + break; case MSC_EJECT_TCT: /* * TCTMobile needs DIR_IN flag. To get it, we |