mirror of
https://github.com/hanwckf/immortalwrt-mt798x.git
synced 2025-01-10 19:12:33 +08:00
ipq40xx/806x: add u9300 4G driver
From @ksong008 dalao
This commit is contained in:
parent
6607b2e3ad
commit
e9ec7de18e
@ -0,0 +1,46 @@
|
||||
--- a/drivers/net/usb/qmi_wwan.c
|
||||
+++ b/drivers/net/usb/qmi_wwan.c
|
||||
@@ -1297,6 +1297,7 @@ static const struct usb_device_id products[] = {
|
||||
{QMI_FIXED_INTF(0x03f0, 0x9d1d, 1)}, /* HP lt4120 Snapdragon X5 LTE */
|
||||
{QMI_FIXED_INTF(0x22de, 0x9061, 3)}, /* WeTelecom WPD-600N */
|
||||
{QMI_QUIRK_SET_DTR(0x1e0e, 0x9001, 5)}, /* SIMCom 7100E, 7230E, 7600E ++ */
|
||||
+ {QMI_FIXED_INTF(0x1c9e, 0x9b3c, 4)}, /* LONGSUNG_U9300 */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0121, 4)}, /* Quectel EC21 Mini PCIe */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0191, 4)}, /* Quectel EG91 */
|
||||
{QMI_FIXED_INTF(0x2c7c, 0x0296, 4)}, /* Quectel BG96 */
|
||||
--- a/drivers/usb/serial/option.c
|
||||
+++ b/drivers/usb/serial/option.c
|
||||
@@ -381,6 +381,7 @@ static void option_instat_callback(struct urb *urb);
|
||||
* Mobidata, etc sell under their own brand names.
|
||||
*/
|
||||
#define LONGCHEER_VENDOR_ID 0x1c9e
|
||||
+#define LONGSUNG_U9300_PRODUCT_ID 0x9b3c
|
||||
|
||||
/* 4G Systems products */
|
||||
/* This is the 4G XS Stick W14 a.k.a. Mobilcom Debitel Surf-Stick *
|
||||
@@ -571,6 +572,16 @@ static void option_instat_callback(struct urb *urb);
|
||||
/* Device needs ZLP */
|
||||
#define ZLP BIT(17)
|
||||
|
||||
+struct option_blacklist_info {
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_SENDSETUP */
|
||||
+ const unsigned long sendsetup;
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_RESERVED_IF */
|
||||
+ const unsigned long reserved;
|
||||
+};
|
||||
+
|
||||
+static const struct option_blacklist_info longsung_u9300_blacklist = {
|
||||
+ .reserved = BIT(4),
|
||||
+};
|
||||
|
||||
static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(OPTION_VENDOR_ID, OPTION_PRODUCT_COLT) },
|
||||
@@ -605,6 +616,8 @@ static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, QUANTA_PRODUCT_GLE) },
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, 0xea42),
|
||||
.driver_info = RSVD(4) },
|
||||
+ { USB_DEVICE(LONGCHEER_VENDOR_ID,LONGSUNG_U9300_PRODUCT_ID),
|
||||
+ .driver_info = (kernel_ulong_t)&longsung_u9300_blacklist},
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c05, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c1f, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c23, USB_CLASS_COMM, 0x02, 0xff) },
|
@ -0,0 +1,46 @@
|
||||
--- a/drivers/net/usb/qmi_wwan.c
|
||||
+++ b/drivers/net/usb/qmi_wwan.c
|
||||
@@ -1292,6 +1292,7 @@ static const struct usb_device_id products[] = {
|
||||
{QMI_FIXED_INTF(0x03f0, 0x9d1d, 1)}, /* HP lt4120 Snapdragon X5 LTE */
|
||||
{QMI_FIXED_INTF(0x22de, 0x9061, 3)}, /* WeTelecom WPD-600N */
|
||||
{QMI_QUIRK_SET_DTR(0x1e0e, 0x9001, 5)}, /* SIMCom 7100E, 7230E, 7600E ++ */
|
||||
+ {QMI_FIXED_INTF(0x1c9e, 0x9b3c, 4)}, /* LONGSUNG_U9300 */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0121, 4)}, /* Quectel EC21 Mini PCIe */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0191, 4)}, /* Quectel EG91 */
|
||||
{QMI_FIXED_INTF(0x2c7c, 0x0296, 4)}, /* Quectel BG96 */
|
||||
--- a/drivers/usb/serial/option.c
|
||||
+++ b/drivers/usb/serial/option.c
|
||||
@@ -384,6 +384,7 @@ static void option_instat_callback(struct urb *urb);
|
||||
* Mobidata, etc sell under their own brand names.
|
||||
*/
|
||||
#define LONGCHEER_VENDOR_ID 0x1c9e
|
||||
+#define LONGSUNG_U9300_PRODUCT_ID 0x9b3c
|
||||
|
||||
/* 4G Systems products */
|
||||
/* This is the 4G XS Stick W14 a.k.a. Mobilcom Debitel Surf-Stick *
|
||||
@@ -574,6 +575,16 @@ static void option_instat_callback(struct urb *urb);
|
||||
/* Device needs ZLP */
|
||||
#define ZLP BIT(17)
|
||||
|
||||
+struct option_blacklist_info {
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_SENDSETUP */
|
||||
+ const unsigned long sendsetup;
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_RESERVED_IF */
|
||||
+ const unsigned long reserved;
|
||||
+};
|
||||
+
|
||||
+static const struct option_blacklist_info longsung_u9300_blacklist = {
|
||||
+ .reserved = BIT(4),
|
||||
+};
|
||||
|
||||
static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(OPTION_VENDOR_ID, OPTION_PRODUCT_COLT) },
|
||||
@@ -608,6 +619,8 @@ static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, QUANTA_PRODUCT_GLE) },
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, 0xea42),
|
||||
.driver_info = RSVD(4) },
|
||||
+ { USB_DEVICE(LONGCHEER_VENDOR_ID,LONGSUNG_U9300_PRODUCT_ID),
|
||||
+ .driver_info = (kernel_ulong_t)&longsung_u9300_blacklist},
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c05, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c1f, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c23, USB_CLASS_COMM, 0x02, 0xff) },
|
@ -0,0 +1,46 @@
|
||||
--- a/drivers/net/usb/qmi_wwan.c
|
||||
+++ b/drivers/net/usb/qmi_wwan.c
|
||||
@@ -1292,6 +1292,7 @@ static const struct usb_device_id products[] = {
|
||||
{QMI_FIXED_INTF(0x03f0, 0x9d1d, 1)}, /* HP lt4120 Snapdragon X5 LTE */
|
||||
{QMI_FIXED_INTF(0x22de, 0x9061, 3)}, /* WeTelecom WPD-600N */
|
||||
{QMI_QUIRK_SET_DTR(0x1e0e, 0x9001, 5)}, /* SIMCom 7100E, 7230E, 7600E ++ */
|
||||
+ {QMI_FIXED_INTF(0x1c9e, 0x9b3c, 4)}, /* LONGSUNG_U9300 */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0121, 4)}, /* Quectel EC21 Mini PCIe */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0191, 4)}, /* Quectel EG91 */
|
||||
{QMI_FIXED_INTF(0x2c7c, 0x0296, 4)}, /* Quectel BG96 */
|
||||
--- a/drivers/usb/serial/option.c
|
||||
+++ b/drivers/usb/serial/option.c
|
||||
@@ -384,6 +384,7 @@ static void option_instat_callback(struct urb *urb);
|
||||
* Mobidata, etc sell under their own brand names.
|
||||
*/
|
||||
#define LONGCHEER_VENDOR_ID 0x1c9e
|
||||
+#define LONGSUNG_U9300_PRODUCT_ID 0x9b3c
|
||||
|
||||
/* 4G Systems products */
|
||||
/* This is the 4G XS Stick W14 a.k.a. Mobilcom Debitel Surf-Stick *
|
||||
@@ -574,6 +575,16 @@ static void option_instat_callback(struct urb *urb);
|
||||
/* Device needs ZLP */
|
||||
#define ZLP BIT(17)
|
||||
|
||||
+struct option_blacklist_info {
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_SENDSETUP */
|
||||
+ const unsigned long sendsetup;
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_RESERVED_IF */
|
||||
+ const unsigned long reserved;
|
||||
+};
|
||||
+
|
||||
+static const struct option_blacklist_info longsung_u9300_blacklist = {
|
||||
+ .reserved = BIT(4),
|
||||
+};
|
||||
|
||||
static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(OPTION_VENDOR_ID, OPTION_PRODUCT_COLT) },
|
||||
@@ -608,6 +619,8 @@ static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, QUANTA_PRODUCT_GLE) },
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, 0xea42),
|
||||
.driver_info = RSVD(4) },
|
||||
+ { USB_DEVICE(LONGCHEER_VENDOR_ID,LONGSUNG_U9300_PRODUCT_ID),
|
||||
+ .driver_info = (kernel_ulong_t)&longsung_u9300_blacklist},
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c05, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c1f, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c23, USB_CLASS_COMM, 0x02, 0xff) },
|
@ -0,0 +1,46 @@
|
||||
--- a/drivers/net/usb/qmi_wwan.c
|
||||
+++ b/drivers/net/usb/qmi_wwan.c
|
||||
@@ -1297,6 +1297,7 @@ static const struct usb_device_id products[] = {
|
||||
{QMI_FIXED_INTF(0x03f0, 0x9d1d, 1)}, /* HP lt4120 Snapdragon X5 LTE */
|
||||
{QMI_FIXED_INTF(0x22de, 0x9061, 3)}, /* WeTelecom WPD-600N */
|
||||
{QMI_QUIRK_SET_DTR(0x1e0e, 0x9001, 5)}, /* SIMCom 7100E, 7230E, 7600E ++ */
|
||||
+ {QMI_FIXED_INTF(0x1c9e, 0x9b3c, 4)}, /* LONGSUNG_U9300 */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0121, 4)}, /* Quectel EC21 Mini PCIe */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0191, 4)}, /* Quectel EG91 */
|
||||
{QMI_FIXED_INTF(0x2c7c, 0x0296, 4)}, /* Quectel BG96 */
|
||||
--- a/drivers/usb/serial/option.c
|
||||
+++ b/drivers/usb/serial/option.c
|
||||
@@ -381,6 +381,7 @@ static void option_instat_callback(struct urb *urb);
|
||||
* Mobidata, etc sell under their own brand names.
|
||||
*/
|
||||
#define LONGCHEER_VENDOR_ID 0x1c9e
|
||||
+#define LONGSUNG_U9300_PRODUCT_ID 0x9b3c
|
||||
|
||||
/* 4G Systems products */
|
||||
/* This is the 4G XS Stick W14 a.k.a. Mobilcom Debitel Surf-Stick *
|
||||
@@ -571,6 +572,16 @@ static void option_instat_callback(struct urb *urb);
|
||||
/* Device needs ZLP */
|
||||
#define ZLP BIT(17)
|
||||
|
||||
+struct option_blacklist_info {
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_SENDSETUP */
|
||||
+ const unsigned long sendsetup;
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_RESERVED_IF */
|
||||
+ const unsigned long reserved;
|
||||
+};
|
||||
+
|
||||
+static const struct option_blacklist_info longsung_u9300_blacklist = {
|
||||
+ .reserved = BIT(4),
|
||||
+};
|
||||
|
||||
static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(OPTION_VENDOR_ID, OPTION_PRODUCT_COLT) },
|
||||
@@ -605,6 +616,8 @@ static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, QUANTA_PRODUCT_GLE) },
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, 0xea42),
|
||||
.driver_info = RSVD(4) },
|
||||
+ { USB_DEVICE(LONGCHEER_VENDOR_ID,LONGSUNG_U9300_PRODUCT_ID),
|
||||
+ .driver_info = (kernel_ulong_t)&longsung_u9300_blacklist},
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c05, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c1f, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c23, USB_CLASS_COMM, 0x02, 0xff) },
|
@ -0,0 +1,46 @@
|
||||
--- a/drivers/net/usb/qmi_wwan.c
|
||||
+++ b/drivers/net/usb/qmi_wwan.c
|
||||
@@ -1297,6 +1297,7 @@ static const struct usb_device_id products[] = {
|
||||
{QMI_FIXED_INTF(0x03f0, 0x9d1d, 1)}, /* HP lt4120 Snapdragon X5 LTE */
|
||||
{QMI_FIXED_INTF(0x22de, 0x9061, 3)}, /* WeTelecom WPD-600N */
|
||||
{QMI_QUIRK_SET_DTR(0x1e0e, 0x9001, 5)}, /* SIMCom 7100E, 7230E, 7600E ++ */
|
||||
+ {QMI_FIXED_INTF(0x1c9e, 0x9b3c, 4)}, /* LONGSUNG_U9300 */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0121, 4)}, /* Quectel EC21 Mini PCIe */
|
||||
{QMI_QUIRK_SET_DTR(0x2c7c, 0x0191, 4)}, /* Quectel EG91 */
|
||||
{QMI_FIXED_INTF(0x2c7c, 0x0296, 4)}, /* Quectel BG96 */
|
||||
--- a/drivers/usb/serial/option.c
|
||||
+++ b/drivers/usb/serial/option.c
|
||||
@@ -381,6 +381,7 @@ static void option_instat_callback(struct urb *urb);
|
||||
* Mobidata, etc sell under their own brand names.
|
||||
*/
|
||||
#define LONGCHEER_VENDOR_ID 0x1c9e
|
||||
+#define LONGSUNG_U9300_PRODUCT_ID 0x9b3c
|
||||
|
||||
/* 4G Systems products */
|
||||
/* This is the 4G XS Stick W14 a.k.a. Mobilcom Debitel Surf-Stick *
|
||||
@@ -571,6 +572,16 @@ static void option_instat_callback(struct urb *urb);
|
||||
/* Device needs ZLP */
|
||||
#define ZLP BIT(17)
|
||||
|
||||
+struct option_blacklist_info {
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_SENDSETUP */
|
||||
+ const unsigned long sendsetup;
|
||||
+ /* bitfield of interface numbers for OPTION_BLACKLIST_RESERVED_IF */
|
||||
+ const unsigned long reserved;
|
||||
+};
|
||||
+
|
||||
+static const struct option_blacklist_info longsung_u9300_blacklist = {
|
||||
+ .reserved = BIT(4),
|
||||
+};
|
||||
|
||||
static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(OPTION_VENDOR_ID, OPTION_PRODUCT_COLT) },
|
||||
@@ -605,6 +616,8 @@ static const struct usb_device_id option_ids[] = {
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, QUANTA_PRODUCT_GLE) },
|
||||
{ USB_DEVICE(QUANTA_VENDOR_ID, 0xea42),
|
||||
.driver_info = RSVD(4) },
|
||||
+ { USB_DEVICE(LONGCHEER_VENDOR_ID,LONGSUNG_U9300_PRODUCT_ID),
|
||||
+ .driver_info = (kernel_ulong_t)&longsung_u9300_blacklist},
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c05, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c1f, USB_CLASS_COMM, 0x02, 0xff) },
|
||||
{ USB_DEVICE_AND_INTERFACE_INFO(HUAWEI_VENDOR_ID, 0x1c23, USB_CLASS_COMM, 0x02, 0xff) },
|
Loading…
x
Reference in New Issue
Block a user