From deaf0437bc3c1a82255241867c00180ecb3b6e54 Mon Sep 17 00:00:00 2001 From: n_hibma Date: Fri, 24 Oct 2008 21:52:50 +0000 Subject: [PATCH] Make the driver compile on FBSD6 as well. Up the speed on the E220 ID as it is a part which is used in other devices that are capable of HSPA speeds. --- sys/dev/usb/u3g.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sys/dev/usb/u3g.c b/sys/dev/usb/u3g.c index c8357a0110df..77386b012430 100644 --- a/sys/dev/usb/u3g.c +++ b/sys/dev/usb/u3g.c @@ -46,7 +46,9 @@ #include +#if __FreeBSD_version >= 800000 #include "opt_u3g.h" +#endif #include "usbdevs.h" //#define U3G_DEBUG @@ -134,7 +136,7 @@ static const struct u3g_dev_type_s u3g_devs[] = { {{ USB_VENDOR_QUALCOMMINC, USB_PRODUCT_QUALCOMMINC_CDMA_MSM }, U3GSP_CDMA, U3GFL_STUB_WAIT }, /* OEM: Huawei */ {{ USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_MOBILE }, U3GSP_HSDPA, U3GFL_HUAWEI_INIT }, - {{ USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_E220 }, U3GSP_HSDPA, U3GFL_HUAWEI_INIT }, + {{ USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_E220 }, U3GSP_HSPA, U3GFL_HUAWEI_INIT }, /* OEM: Novatel */ {{ USB_VENDOR_NOVATEL, USB_PRODUCT_NOVATEL_CDMA_MODEM }, U3GSP_CDMA, U3GFL_STUB_WAIT }, {{ USB_VENDOR_NOVATEL, USB_PRODUCT_NOVATEL_ES620 }, U3GSP_UMTS, U3GFL_STUB_WAIT }, // XXX @@ -298,7 +300,9 @@ u3g_attach(device_t self) portno, i, ucom->sc_bulkin_no, ucom->sc_bulkout_no); -#if __FreeBSD_version < 800000 +#if __FreeBSD_version < 700000 + ucom_attach_tty(ucom, MINOR_CALLOUT, devnamefmt, portno); +#elif __FreeBSD_version < 800000 ucom_attach_tty(ucom, TS_CALLOUT, devnamefmt, portno); #else ucom_attach_tty(ucom, devnamefmt, portno);