diff options
| -rw-r--r-- | pci/pci-change-pci-subsystem-maintainer.patch | 36 | ||||
| -rw-r--r-- | pci/pci-pci-iommu-iotlb-flushing-speedup.patch | 201 | ||||
| -rw-r--r-- | pci/pci-pci_alloc_child_bus-mustn-t-be-__devinit.patch | 33 | ||||
| -rw-r--r-- | pci/pci-pci_bus_size_cardbus-mustn-t-be-__devinit.patch | 33 | ||||
| -rw-r--r-- | pci/pci-pci_scan_device-mustn-t-be-__devinit.patch | 33 | ||||
| -rw-r--r-- | pci/pci-pci_setup_bridge-mustn-t-be-__devinit.patch | 33 | ||||
| -rw-r--r-- | series | 16 | ||||
| -rw-r--r-- | usb/usb-add-hp-hs2300-broadband-wireless-module-to-sierra.c.patch | 29 | ||||
| -rw-r--r-- | usb/usb-remove-unnecessary-type-casting-of-urb-context.patch | 4 | ||||
| -rw-r--r-- | usb/usb-replace-remaining-__function__-occurrences.patch | 46 | ||||
| -rw-r--r-- | usb/usb-serial-more-fixes-and-groundwork-for-tty-changes.patch | 2 | ||||
| -rw-r--r-- | usb/usb-serial-remove-unneeded-number-endpoints-settings.patch | 2 | ||||
| -rw-r--r-- | usb/usb-serial-sierra-add-new-dev-group.patch | 4 | ||||
| -rw-r--r-- | usb/usb-serial-sierra-clean-up.patch | 4 | ||||
| -rw-r--r-- | usb/usb-usbfs-export-the-urb_no_interrupt-flag-to-userspace.patch | 90 |
15 files changed, 529 insertions, 37 deletions
diff --git a/pci/pci-change-pci-subsystem-maintainer.patch b/pci/pci-change-pci-subsystem-maintainer.patch new file mode 100644 index 00000000000000..1f2b3e57f7dfce --- /dev/null +++ b/pci/pci-change-pci-subsystem-maintainer.patch @@ -0,0 +1,36 @@ +From jbarnes@virtuousgeek.org Fri Apr 18 14:57:07 2008 +From: Greg Kroah-Hartman <gregkh@suse.de> +Date: Thu, 17 Apr 2008 10:22:27 -0700 +Subject: PCI: Change PCI subsystem MAINTAINER +Cc: Jesse Barnes <jbarnes@virtuousgeek.org> +Message-ID: <200804171022.27529.jbarnes@virtuousgeek.org> +Content-Disposition: inline + +Jesse foolishly volunteered to handle PCI patches. Update MAINTAINERS to +reflect this. + +Woho! Time to kick back and relax... + +Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + MAINTAINERS | 5 ++--- + 1 file changed, 2 insertions(+), 3 deletions(-) + +--- a/MAINTAINERS ++++ b/MAINTAINERS +@@ -3068,11 +3068,10 @@ L: linux-pci@atrey.karlin.mff.cuni.cz + S: Supported + + PCI SUBSYSTEM +-P: Greg Kroah-Hartman +-M: gregkh@suse.de ++P: Jesse Barnes ++M: jbarnes@virtuousgeek.org + L: linux-kernel@vger.kernel.org + L: linux-pci@atrey.karlin.mff.cuni.cz +-T: quilt kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/ + S: Supported + + PCI HOTPLUG CORE diff --git a/pci/pci-pci-iommu-iotlb-flushing-speedup.patch b/pci/pci-pci-iommu-iotlb-flushing-speedup.patch new file mode 100644 index 00000000000000..2cd68ab21122d2 --- /dev/null +++ b/pci/pci-pci-iommu-iotlb-flushing-speedup.patch @@ -0,0 +1,201 @@ +From akpm@linux-foundation.org Fri Apr 18 14:56:22 2008 +From: mark gross <mgross@linux.intel.com> +Date: Fri, 18 Apr 2008 13:53:58 -0700 +Subject: PCI: pci-iommu-iotlb-flushing-speedup +To: greg@kroah.com +Cc: linux-pci@atrey.karlin.mff.cuni.cz, akpm@linux-foundation.org, mgross@linux.intel.com, grundler@parisc-linux.org +Message-ID: <200804182053.m3IKrwfM015144@imap1.linux-foundation.org> + + +From: mark gross <mgross@linux.intel.com> + +The following patch is an update to use an array instead of a list of +IOVA's in the implementation of defered iotlb flushes. It takes +inspiration from sba_iommu.c + +I like this implementation better as it encapsulates the batch process +within intel-iommu.c, and no longer touches iova.h (which is shared) + +Performance data: Netperf 32byte UDP streaming +2.6.25-rc3-mm1: +IOMMU-strict : 58Mps @ 62% cpu +NO-IOMMU : 71Mbs @ 41% cpu +List-based IOMMU-default-batched-IOTLB flush: 66Mbps @ 57% cpu + +with this patch: +IOMMU-strict : 73Mps @ 75% cpu +NO-IOMMU : 74Mbs @ 42% cpu +Array-based IOMMU-default-batched-IOTLB flush: 72Mbps @ 62% cpu + +Signed-off-by: <mgross@linux.intel.com> +Cc: Grant Grundler <grundler@parisc-linux.org> +Signed-off-by: Andrew Morton <akpm@linux-foundation.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/pci/intel-iommu.c | 76 ++++++++++++++++++++++++---------------------- + drivers/pci/iova.h | 2 - + 2 files changed, 40 insertions(+), 38 deletions(-) + +--- a/drivers/pci/intel-iommu.c ++++ b/drivers/pci/intel-iommu.c +@@ -59,8 +59,17 @@ static void flush_unmaps_timeout(unsigne + DEFINE_TIMER(unmap_timer, flush_unmaps_timeout, 0, 0); + + static struct intel_iommu *g_iommus; ++ ++#define HIGH_WATER_MARK 250 ++struct deferred_flush_tables { ++ int next; ++ struct iova *iova[HIGH_WATER_MARK]; ++ struct dmar_domain *domain[HIGH_WATER_MARK]; ++}; ++ ++static struct deferred_flush_tables *deferred_flush; ++ + /* bitmap for indexing intel_iommus */ +-static unsigned long *g_iommus_to_flush; + static int g_num_of_iommus; + + static DEFINE_SPINLOCK(async_umap_flush_lock); +@@ -68,10 +77,6 @@ static LIST_HEAD(unmaps_to_do); + + static int timer_on; + static long list_size; +-static int high_watermark; +- +-static struct dentry *intel_iommu_debug, *debug; +- + + static void domain_remove_dev_info(struct dmar_domain *domain); + +@@ -1692,7 +1697,7 @@ int __init init_dmars(void) + struct dmar_rmrr_unit *rmrr; + struct pci_dev *pdev; + struct intel_iommu *iommu; +- int nlongs, i, ret, unit = 0; ++ int i, ret, unit = 0; + + /* + * for each drhd +@@ -1711,17 +1716,16 @@ int __init init_dmars(void) + */ + } + +- nlongs = BITS_TO_LONGS(g_num_of_iommus); +- g_iommus_to_flush = kzalloc(nlongs * sizeof(unsigned long), GFP_KERNEL); +- if (!g_iommus_to_flush) { +- printk(KERN_ERR "Intel-IOMMU: " +- "Allocating bitmap array failed\n"); +- return -ENOMEM; +- } +- + g_iommus = kzalloc(g_num_of_iommus * sizeof(*iommu), GFP_KERNEL); + if (!g_iommus) { +- kfree(g_iommus_to_flush); ++ ret = -ENOMEM; ++ goto error; ++ } ++ ++ deferred_flush = kzalloc(g_num_of_iommus * ++ sizeof(struct deferred_flush_tables), GFP_KERNEL); ++ if (!deferred_flush) { ++ kfree(g_iommus); + ret = -ENOMEM; + goto error; + } +@@ -1970,42 +1974,48 @@ error: + + static void flush_unmaps(void) + { +- struct iova *node, *n; +- unsigned long flags; +- int i; ++ int i, j; + +- spin_lock_irqsave(&async_umap_flush_lock, flags); + timer_on = 0; + + /* just flush them all */ + for (i = 0; i < g_num_of_iommus; i++) { +- if (test_and_clear_bit(i, g_iommus_to_flush)) ++ if (deferred_flush[i].next) { + iommu_flush_iotlb_global(&g_iommus[i], 0); ++ for (j = 0; j < deferred_flush[i].next; j++) { ++ __free_iova(&deferred_flush[i].domain[j]->iovad, ++ deferred_flush[i].iova[j]); ++ } ++ deferred_flush[i].next = 0; ++ } + } + +- list_for_each_entry_safe(node, n, &unmaps_to_do, list) { +- /* free iova */ +- list_del(&node->list); +- __free_iova(&((struct dmar_domain *)node->dmar)->iovad, node); +- +- } + list_size = 0; +- spin_unlock_irqrestore(&async_umap_flush_lock, flags); + } + + static void flush_unmaps_timeout(unsigned long data) + { ++ unsigned long flags; ++ ++ spin_lock_irqsave(&async_umap_flush_lock, flags); + flush_unmaps(); ++ spin_unlock_irqrestore(&async_umap_flush_lock, flags); + } + + static void add_unmap(struct dmar_domain *dom, struct iova *iova) + { + unsigned long flags; ++ int next, iommu_id; + + spin_lock_irqsave(&async_umap_flush_lock, flags); +- iova->dmar = dom; +- list_add(&iova->list, &unmaps_to_do); +- set_bit((dom->iommu - g_iommus), g_iommus_to_flush); ++ if (list_size == HIGH_WATER_MARK) ++ flush_unmaps(); ++ ++ iommu_id = dom->iommu - g_iommus; ++ next = deferred_flush[iommu_id].next; ++ deferred_flush[iommu_id].domain[next] = dom; ++ deferred_flush[iommu_id].iova[next] = iova; ++ deferred_flush[iommu_id].next++; + + if (!timer_on) { + mod_timer(&unmap_timer, jiffies + msecs_to_jiffies(10)); +@@ -2054,8 +2064,6 @@ static void intel_unmap_single(struct de + * queue up the release of the unmap to save the 1/6th of the + * cpu used up by the iotlb flush operation... + */ +- if (list_size > high_watermark) +- flush_unmaps(); + } + } + +@@ -2380,10 +2388,6 @@ int __init intel_iommu_init(void) + if (dmar_table_init()) + return -ENODEV; + +- high_watermark = 250; +- intel_iommu_debug = debugfs_create_dir("intel_iommu", NULL); +- debug = debugfs_create_u32("high_watermark", S_IWUGO | S_IRUGO, +- intel_iommu_debug, &high_watermark); + iommu_init_mempool(); + dmar_init_reserved_ranges(); + +--- a/drivers/pci/iova.h ++++ b/drivers/pci/iova.h +@@ -24,8 +24,6 @@ struct iova { + struct rb_node node; + unsigned long pfn_hi; /* IOMMU dish out addr hi */ + unsigned long pfn_lo; /* IOMMU dish out addr lo */ +- struct list_head list; +- void *dmar; + }; + + /* holds all the iova translations for a domain */ diff --git a/pci/pci-pci_alloc_child_bus-mustn-t-be-__devinit.patch b/pci/pci-pci_alloc_child_bus-mustn-t-be-__devinit.patch new file mode 100644 index 00000000000000..097e91e81a5483 --- /dev/null +++ b/pci/pci-pci_alloc_child_bus-mustn-t-be-__devinit.patch @@ -0,0 +1,33 @@ +From akpm@linux-foundation.org Fri Apr 18 14:54:40 2008 +From: Adrian Bunk <bunk@kernel.org> +Date: Fri, 18 Apr 2008 13:53:55 -0700 +Subject: PCI: pci_alloc_child_bus() mustn't be __devinit +To: greg@kroah.com +Cc: linux-pci@atrey.karlin.mff.cuni.cz, akpm@linux-foundation.org, bunk@kernel.org +Message-ID: <200804182053.m3IKrt0m015127@imap1.linux-foundation.org> + +From: Adrian Bunk <bunk@kernel.org> + +WARNING: drivers/pci/built-in.o(.text+0xc4c): Section mismatch in reference from the function pci_add_new_bus() to the function .devinit.text:pci_alloc_child_bus() + +Signed-off-by: Adrian Bunk <bunk@kernel.org> +Signed-off-by: Andrew Morton <akpm@linux-foundation.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/pci/probe.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +--- a/drivers/pci/probe.c ++++ b/drivers/pci/probe.c +@@ -399,8 +399,8 @@ static struct pci_bus * pci_alloc_bus(vo + return b; + } + +-static struct pci_bus * __devinit +-pci_alloc_child_bus(struct pci_bus *parent, struct pci_dev *bridge, int busnr) ++static struct pci_bus *pci_alloc_child_bus(struct pci_bus *parent, ++ struct pci_dev *bridge, int busnr) + { + struct pci_bus *child; + int i; diff --git a/pci/pci-pci_bus_size_cardbus-mustn-t-be-__devinit.patch b/pci/pci-pci_bus_size_cardbus-mustn-t-be-__devinit.patch new file mode 100644 index 00000000000000..62d27f9cfe2bea --- /dev/null +++ b/pci/pci-pci_bus_size_cardbus-mustn-t-be-__devinit.patch @@ -0,0 +1,33 @@ +From akpm@linux-foundation.org Fri Apr 18 14:55:35 2008 +From: Adrian Bunk <bunk@kernel.org> +Date: Fri, 18 Apr 2008 13:53:56 -0700 +Subject: PCI: pci_bus_size_cardbus() mustn't be __devinit +To: greg@kroah.com +Cc: linux-pci@atrey.karlin.mff.cuni.cz, akpm@linux-foundation.org, bunk@kernel.org +Message-ID: <200804182053.m3IKruWr015138@imap1.linux-foundation.org> + + +From: Adrian Bunk <bunk@kernel.org> + +WARNING: drivers/pci/built-in.o(.text+0x28e1f): Section mismatch in reference from the function pci_bus_size_bridges() to the function .devinit.text:pci_bus_size_cardbus() + +Signed-off-by: Adrian Bunk <bunk@kernel.org> +Signed-off-by: Andrew Morton <akpm@linux-foundation.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/pci/setup-bus.c | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +--- a/drivers/pci/setup-bus.c ++++ b/drivers/pci/setup-bus.c +@@ -407,8 +407,7 @@ static int pbus_size_mem(struct pci_bus + return 1; + } + +-static void __devinit +-pci_bus_size_cardbus(struct pci_bus *bus) ++static void pci_bus_size_cardbus(struct pci_bus *bus) + { + struct pci_dev *bridge = bus->self; + struct resource *b_res = &bridge->resource[PCI_BRIDGE_RESOURCES]; diff --git a/pci/pci-pci_scan_device-mustn-t-be-__devinit.patch b/pci/pci-pci_scan_device-mustn-t-be-__devinit.patch new file mode 100644 index 00000000000000..3d95a4dbbe8e51 --- /dev/null +++ b/pci/pci-pci_scan_device-mustn-t-be-__devinit.patch @@ -0,0 +1,33 @@ +From akpm@linux-foundation.org Fri Apr 18 14:55:07 2008 +From: Adrian Bunk <bunk@kernel.org> +Date: Fri, 18 Apr 2008 13:53:55 -0700 +Subject: PCI: pci_scan_device() mustn't be __devinit +To: greg@kroah.com +Cc: linux-pci@atrey.karlin.mff.cuni.cz, akpm@linux-foundation.org, bunk@kernel.org +Message-ID: <200804182053.m3IKru3m015135@imap1.linux-foundation.org> + + +From: Adrian Bunk <bunk@kernel.org> + +WARNING: drivers/pci/built-in.o(.text+0x150f): Section mismatch in reference from the function pci_scan_single_device() to the function .devinit.text:pci_scan_device() + +Signed-off-by: Adrian Bunk <bunk@kernel.org> +Signed-off-by: Andrew Morton <akpm@linux-foundation.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/pci/probe.c | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +--- a/drivers/pci/probe.c ++++ b/drivers/pci/probe.c +@@ -875,8 +875,7 @@ EXPORT_SYMBOL(alloc_pci_dev); + * Read the config data for a PCI device, sanity-check it + * and fill in the dev structure... + */ +-static struct pci_dev * __devinit +-pci_scan_device(struct pci_bus *bus, int devfn) ++static struct pci_dev *pci_scan_device(struct pci_bus *bus, int devfn) + { + struct pci_dev *dev; + u32 l; diff --git a/pci/pci-pci_setup_bridge-mustn-t-be-__devinit.patch b/pci/pci-pci_setup_bridge-mustn-t-be-__devinit.patch new file mode 100644 index 00000000000000..998e24e1a6bce9 --- /dev/null +++ b/pci/pci-pci_setup_bridge-mustn-t-be-__devinit.patch @@ -0,0 +1,33 @@ +From akpm@linux-foundation.org Fri Apr 18 14:55:59 2008 +From: Adrian Bunk <bunk@kernel.org> +Date: Fri, 18 Apr 2008 13:53:57 -0700 +Subject: PCI: pci_setup_bridge() mustn't be __devinit +To: greg@kroah.com +Cc: linux-pci@atrey.karlin.mff.cuni.cz, akpm@linux-foundation.org, bunk@kernel.org +Message-ID: <200804182053.m3IKrvCu015141@imap1.linux-foundation.org> + + +From: Adrian Bunk <bunk@kernel.org> + +WARNING: drivers/pci/built-in.o(.text+0x28ee9): Section mismatch in reference from the function pci_bus_assign_resources() to the function .devinit.text:pci_setup_bridge() + +Signed-off-by: Adrian Bunk <bunk@kernel.org> +Signed-off-by: Andrew Morton <akpm@linux-foundation.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/pci/setup-bus.c | 3 +-- + 1 file changed, 1 insertion(+), 2 deletions(-) + +--- a/drivers/pci/setup-bus.c ++++ b/drivers/pci/setup-bus.c +@@ -145,8 +145,7 @@ EXPORT_SYMBOL(pci_setup_cardbus); + config space writes, so it's quite possible that an I/O window of + the bridge will have some undesirable address (e.g. 0) after the + first write. Ditto 64-bit prefetchable MMIO. */ +-static void __devinit +-pci_setup_bridge(struct pci_bus *bus) ++static void pci_setup_bridge(struct pci_bus *bus) + { + struct pci_dev *bridge = bus->self; + struct pci_bus_region region; @@ -107,15 +107,17 @@ pci/pci-hotplug-fakephp-return-success-not-enodev-when-bus-rescan-is-triggered.p pci/pci-replace-remaining-__function__-occurrences.patch -# usb patches queued for 2.6.25 (bugfixes, new ids, etc.) -#usb/usb-obscure-maxon-bp3-usb-device-support-16d8-6280-for-option-driver.patch -#usb/usb-option.c-add-more-device-ids.patch -#usb/usb-support-more-huawei-data-card-product-ids.patch -#usb/usb-option-add-new-vendor-id-and-device-id-for-amoi-hsdpa-modem.patch -#usb/usb-remove-broken-usb-serial-num_endpoints-check.patch +pci/pci-pci_alloc_child_bus-mustn-t-be-__devinit.patch +pci/pci-pci_scan_device-mustn-t-be-__devinit.patch +pci/pci-pci_bus_size_cardbus-mustn-t-be-__devinit.patch +pci/pci-pci_setup_bridge-mustn-t-be-__devinit.patch +pci/pci-pci-iommu-iotlb-flushing-speedup.patch +pci/pci-change-pci-subsystem-maintainer.patch +# usb patches queued for 2.6.25 (bugfixes, new ids, etc.) usb/usb-cp2101-add-new-device-ids.patch usb/usb-fix-memory-leak-in-mon_stat_release.patch +usb/usb-add-hp-hs2300-broadband-wireless-module-to-sierra.c.patch # resume rework usb/usb-ehci-carry-out-port-handover-during-each-root-hub-resume.patch @@ -228,6 +230,7 @@ usb/usb-add-documentation-about-callbacks.patch usb/usb-cdc-acm-signedness-fix.patch usb/usb-ehci-qh_completions-cleanup-and-bugfix.patch usb/usb-fix-compile-problems-in-ehci-hcd.patch +usb/usb-usbfs-export-the-urb_no_interrupt-flag-to-userspace.patch usb/usb-replace-remaining-__function__-occurrences.patch usb/usb-serial-more-fixes-and-groundwork-for-tty-changes.patch @@ -294,3 +297,4 @@ ldp/net-add-et131x-driver.patch #f2.patch + diff --git a/usb/usb-add-hp-hs2300-broadband-wireless-module-to-sierra.c.patch b/usb/usb-add-hp-hs2300-broadband-wireless-module-to-sierra.c.patch new file mode 100644 index 00000000000000..f0ac0558975210 --- /dev/null +++ b/usb/usb-add-hp-hs2300-broadband-wireless-module-to-sierra.c.patch @@ -0,0 +1,29 @@ +From seife@suse.de Fri Apr 18 14:59:53 2008 +From: Stefan Seyfried <seife@suse.de> +Date: Thu, 17 Apr 2008 07:47:34 +0200 +Subject: USB: Add HP hs2300 Broadband Wireless Module to sierra.c +To: Greg Kroah-Hartman <gregkh@suse.de> +Message-ID: <20080417054734.GA5493@suse.de> +Content-Disposition: inline + + +Add the HP hs2300 Broadband Wireless Module (relabeled MC8775) USB IDs + +Signed-off-by: Stefan Seyfried <seife@suse.de> +Cc: stable <stable@kernel.org> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/usb/serial/sierra.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/drivers/usb/serial/sierra.c ++++ b/drivers/usb/serial/sierra.c +@@ -164,6 +164,7 @@ static struct usb_device_id id_table [] + { USB_DEVICE(0x1199, 0x6812) }, /* Sierra Wireless MC8775 & AC 875U */ + { USB_DEVICE(0x1199, 0x6813) }, /* Sierra Wireless MC8775 (Thinkpad internal) */ + { USB_DEVICE(0x1199, 0x6815) }, /* Sierra Wireless MC8775 */ ++ { USB_DEVICE(0x03f0, 0x1e1d) }, /* HP hs2300 a.k.a MC8775 */ + { USB_DEVICE(0x1199, 0x6820) }, /* Sierra Wireless AirCard 875 */ + { USB_DEVICE(0x1199, 0x6832) }, /* Sierra Wireless MC8780*/ + { USB_DEVICE(0x1199, 0x6833) }, /* Sierra Wireless MC8781*/ diff --git a/usb/usb-remove-unnecessary-type-casting-of-urb-context.patch b/usb/usb-remove-unnecessary-type-casting-of-urb-context.patch index 066a9e8d4bae56..d1ea1ab315335a 100644 --- a/usb/usb-remove-unnecessary-type-casting-of-urb-context.patch +++ b/usb/usb-remove-unnecessary-type-casting-of-urb-context.patch @@ -908,7 +908,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> int result; --- a/drivers/usb/serial/sierra.c +++ b/drivers/usb/serial/sierra.c -@@ -456,7 +456,7 @@ static void sierra_indat_callback(struct +@@ -457,7 +457,7 @@ static void sierra_indat_callback(struct dbg("%s: %p", __func__, urb); endpoint = usb_pipeendpoint(urb->pipe); @@ -917,7 +917,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> if (status) { dbg("%s: nonzero status: %d on endpoint %02x.", -@@ -486,7 +486,7 @@ static void sierra_instat_callback(struc +@@ -487,7 +487,7 @@ static void sierra_instat_callback(struc { int err; int status = urb->status; diff --git a/usb/usb-replace-remaining-__function__-occurrences.patch b/usb/usb-replace-remaining-__function__-occurrences.patch index 80705ea18ce60d..6262660549061a 100644 --- a/usb/usb-replace-remaining-__function__-occurrences.patch +++ b/usb/usb-replace-remaining-__function__-occurrences.patch @@ -148,7 +148,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> /* data interface returns incoming bytes, or we got unthrottled */ --- a/drivers/usb/core/devio.c +++ b/drivers/usb/core/devio.c -@@ -1511,60 +1511,60 @@ static int usbdev_ioctl(struct inode *in +@@ -1530,60 +1530,60 @@ static int usbdev_ioctl(struct inode *in switch (cmd) { case USBDEVFS_CONTROL: @@ -219,7 +219,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> ret = proc_submiturb(ps, p); if (ret >= 0) inode->i_mtime = CURRENT_TIME; -@@ -1573,60 +1573,60 @@ static int usbdev_ioctl(struct inode *in +@@ -1592,60 +1592,60 @@ static int usbdev_ioctl(struct inode *in #ifdef CONFIG_COMPAT case USBDEVFS_SUBMITURB32: @@ -14881,7 +14881,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> room = port->bulk_out_size - (safe ? 2 : 0); --- a/drivers/usb/serial/sierra.c +++ b/drivers/usb/serial/sierra.c -@@ -255,7 +255,7 @@ static int sierra_send_setup(struct usb_ +@@ -256,7 +256,7 @@ static int sierra_send_setup(struct usb_ struct sierra_port_private *portdata; __u16 interface = 0; @@ -14890,7 +14890,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> portdata = usb_get_serial_port_data(port); -@@ -285,24 +285,24 @@ static int sierra_send_setup(struct usb_ +@@ -286,24 +286,24 @@ static int sierra_send_setup(struct usb_ static void sierra_rx_throttle(struct usb_serial_port *port) { @@ -14919,7 +14919,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> tty_termios_copy_hw(port->tty->termios, old_termios); sierra_send_setup(port); } -@@ -356,14 +356,14 @@ static void sierra_outdat_callback(struc +@@ -357,14 +357,14 @@ static void sierra_outdat_callback(struc int status = urb->status; unsigned long flags; @@ -14936,7 +14936,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> spin_lock_irqsave(&portdata->lock, flags); --portdata->outstanding_urbs; -@@ -385,12 +385,12 @@ static int sierra_write(struct usb_seria +@@ -386,12 +386,12 @@ static int sierra_write(struct usb_seria portdata = usb_get_serial_port_data(port); @@ -14951,7 +14951,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> return 0; } portdata->outstanding_urbs++; -@@ -412,7 +412,7 @@ static int sierra_write(struct usb_seria +@@ -413,7 +413,7 @@ static int sierra_write(struct usb_seria memcpy(buffer, buf, count); @@ -14960,7 +14960,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> usb_fill_bulk_urb(urb, serial->dev, usb_sndbulkpipe(serial->dev, -@@ -423,7 +423,7 @@ static int sierra_write(struct usb_seria +@@ -424,7 +424,7 @@ static int sierra_write(struct usb_seria status = usb_submit_urb(urb, GFP_ATOMIC); if (status) { dev_err(&port->dev, "%s - usb_submit_urb(write bulk) failed " @@ -14969,7 +14969,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> count = status; goto error; } -@@ -453,14 +453,14 @@ static void sierra_indat_callback(struct +@@ -454,14 +454,14 @@ static void sierra_indat_callback(struct unsigned char *data = urb->transfer_buffer; int status = urb->status; @@ -14986,7 +14986,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> } else { tty = port->tty; if (urb->actual_length) { -@@ -468,7 +468,7 @@ static void sierra_indat_callback(struct +@@ -469,7 +469,7 @@ static void sierra_indat_callback(struct tty_insert_flip_string(tty, data, urb->actual_length); tty_flip_buffer_push(tty); } else { @@ -14995,7 +14995,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> } /* Resubmit urb so we continue receiving */ -@@ -490,15 +490,15 @@ static void sierra_instat_callback(struc +@@ -491,15 +491,15 @@ static void sierra_instat_callback(struc struct sierra_port_private *portdata = usb_get_serial_port_data(port); struct usb_serial *serial = port->serial; @@ -15014,7 +15014,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> return; } if ((req_pkt->bRequestType == 0xA1) && -@@ -508,7 +508,7 @@ static void sierra_instat_callback(struc +@@ -509,7 +509,7 @@ static void sierra_instat_callback(struc urb->transfer_buffer + sizeof(struct usb_ctrlrequest)); @@ -15023,7 +15023,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> old_dcd_state = portdata->dcd_state; portdata->cts_state = 1; -@@ -520,11 +520,11 @@ static void sierra_instat_callback(struc +@@ -521,11 +521,11 @@ static void sierra_instat_callback(struc old_dcd_state && !portdata->dcd_state) tty_hangup(port->tty); } else { @@ -15037,7 +15037,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> /* Resubmit urb so we continue receiving IRQ data */ if (status != -ESHUTDOWN) { -@@ -532,7 +532,7 @@ static void sierra_instat_callback(struc +@@ -533,7 +533,7 @@ static void sierra_instat_callback(struc err = usb_submit_urb(urb, GFP_ATOMIC); if (err) dbg("%s: resubmit intr urb failed. (%d)", @@ -15046,7 +15046,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> } } -@@ -541,14 +541,14 @@ static int sierra_write_room(struct usb_ +@@ -542,14 +542,14 @@ static int sierra_write_room(struct usb_ struct sierra_port_private *portdata = usb_get_serial_port_data(port); unsigned long flags; @@ -15063,7 +15063,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> return 0; } spin_unlock_irqrestore(&portdata->lock, flags); -@@ -558,7 +558,7 @@ static int sierra_write_room(struct usb_ +@@ -559,7 +559,7 @@ static int sierra_write_room(struct usb_ static int sierra_chars_in_buffer(struct usb_serial_port *port) { @@ -15072,7 +15072,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> /* * We can't really account for how much data we -@@ -579,7 +579,7 @@ static int sierra_open(struct usb_serial +@@ -580,7 +580,7 @@ static int sierra_open(struct usb_serial portdata = usb_get_serial_port_data(port); @@ -15081,7 +15081,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> /* Set some sane defaults */ portdata->rts_state = 1; -@@ -591,7 +591,7 @@ static int sierra_open(struct usb_serial +@@ -592,7 +592,7 @@ static int sierra_open(struct usb_serial if (!urb) continue; if (urb->dev != serial->dev) { @@ -15090,7 +15090,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> urb->dev, serial->dev); continue; } -@@ -629,7 +629,7 @@ static void sierra_close(struct usb_seri +@@ -630,7 +630,7 @@ static void sierra_close(struct usb_seri struct usb_serial *serial = port->serial; struct sierra_port_private *portdata; @@ -15099,7 +15099,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> portdata = usb_get_serial_port_data(port); portdata->rts_state = 0; -@@ -659,7 +659,7 @@ static int sierra_startup(struct usb_ser +@@ -660,7 +660,7 @@ static int sierra_startup(struct usb_ser int i; int j; @@ -15108,7 +15108,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> /* Set Device mode to D0 */ sierra_set_power_state(serial->dev, 0x0000); -@@ -674,7 +674,7 @@ static int sierra_startup(struct usb_ser +@@ -675,7 +675,7 @@ static int sierra_startup(struct usb_ser portdata = kzalloc(sizeof(*portdata), GFP_KERNEL); if (!portdata) { dbg("%s: kmalloc for sierra_port_private (%d) failed!.", @@ -15117,7 +15117,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> return -ENOMEM; } spin_lock_init(&portdata->lock); -@@ -695,7 +695,7 @@ static int sierra_startup(struct usb_ser +@@ -696,7 +696,7 @@ static int sierra_startup(struct usb_ser urb = usb_alloc_urb(0, GFP_KERNEL); if (urb == NULL) { dbg("%s: alloc for in port failed.", @@ -15126,7 +15126,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> continue; } /* Fill URB using supplied data. */ -@@ -717,7 +717,7 @@ static void sierra_shutdown(struct usb_s +@@ -718,7 +718,7 @@ static void sierra_shutdown(struct usb_s struct usb_serial_port *port; struct sierra_port_private *portdata; diff --git a/usb/usb-serial-more-fixes-and-groundwork-for-tty-changes.patch b/usb/usb-serial-more-fixes-and-groundwork-for-tty-changes.patch index 53075074ce57e5..d465d938a562a5 100644 --- a/usb/usb-serial-more-fixes-and-groundwork-for-tty-changes.patch +++ b/usb/usb-serial-more-fixes-and-groundwork-for-tty-changes.patch @@ -562,7 +562,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> static int safe_startup (struct usb_serial *serial) --- a/drivers/usb/serial/sierra.c +++ b/drivers/usb/serial/sierra.c -@@ -565,6 +565,8 @@ static int sierra_chars_in_buffer(struct +@@ -566,6 +566,8 @@ static int sierra_chars_in_buffer(struct * have sent out, but hasn't made it through to the * device as we can't see the backend here, so just * tell the tty layer that everything is flushed. diff --git a/usb/usb-serial-remove-unneeded-number-endpoints-settings.patch b/usb/usb-serial-remove-unneeded-number-endpoints-settings.patch index 7f5510e422d3cd..bcacb634071105 100644 --- a/usb/usb-serial-remove-unneeded-number-endpoints-settings.patch +++ b/usb/usb-serial-remove-unneeded-number-endpoints-settings.patch @@ -581,7 +581,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> .write_room = safe_write_room, --- a/drivers/usb/serial/sierra.c +++ b/drivers/usb/serial/sierra.c -@@ -745,9 +745,6 @@ static struct usb_serial_driver sierra_d +@@ -746,9 +746,6 @@ static struct usb_serial_driver sierra_d .description = "Sierra USB modem", .id_table = id_table, .usb_driver = &sierra_driver, diff --git a/usb/usb-serial-sierra-add-new-dev-group.patch b/usb/usb-serial-sierra-add-new-dev-group.patch index 2e877ed61be803..1f5f9c6a031349 100644 --- a/usb/usb-serial-sierra-add-new-dev-group.patch +++ b/usb/usb-serial-sierra-add-new-dev-group.patch @@ -71,9 +71,9 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> /* Check if in installer mode */ if (truinstall && id->driver_info == DEVICE_INSTALLER) { dev_dbg(&udev->dev, "%s", "FOUND TRU-INSTALL DEVICE(SW)\n"); -@@ -164,14 +200,18 @@ static struct usb_device_id id_table [] - { USB_DEVICE(0x1199, 0x6813) }, /* Sierra Wireless MC8775 (Thinkpad internal) */ +@@ -165,14 +201,18 @@ static struct usb_device_id id_table [] { USB_DEVICE(0x1199, 0x6815) }, /* Sierra Wireless MC8775 */ + { USB_DEVICE(0x03f0, 0x1e1d) }, /* HP hs2300 a.k.a MC8775 */ { USB_DEVICE(0x1199, 0x6820) }, /* Sierra Wireless AirCard 875 */ + { USB_DEVICE(0x1199, 0x6821) }, /* Sierra Wireless AirCard 875U */ { USB_DEVICE(0x1199, 0x6832) }, /* Sierra Wireless MC8780*/ diff --git a/usb/usb-serial-sierra-clean-up.patch b/usb/usb-serial-sierra-clean-up.patch index 7d92346450b7a9..c6dac2f1425f10 100644 --- a/usb/usb-serial-sierra-clean-up.patch +++ b/usb/usb-serial-sierra-clean-up.patch @@ -77,7 +77,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> enable, /* __u16 value */ 0x0000, /* __u16 index */ NULL, /* void *data */ -@@ -452,7 +451,7 @@ static void sierra_instat_callback(struc +@@ -453,7 +452,7 @@ static void sierra_instat_callback(struc struct usb_serial *serial = port->serial; dbg("%s", __FUNCTION__); @@ -86,7 +86,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> if (status == 0) { struct usb_ctrlrequest *req_pkt = -@@ -482,7 +481,7 @@ static void sierra_instat_callback(struc +@@ -483,7 +482,7 @@ static void sierra_instat_callback(struc tty_hangup(port->tty); } else { dbg("%s: type %x req %x", __FUNCTION__, diff --git a/usb/usb-usbfs-export-the-urb_no_interrupt-flag-to-userspace.patch b/usb/usb-usbfs-export-the-urb_no_interrupt-flag-to-userspace.patch new file mode 100644 index 00000000000000..3937e05571bbc8 --- /dev/null +++ b/usb/usb-usbfs-export-the-urb_no_interrupt-flag-to-userspace.patch @@ -0,0 +1,90 @@ +From stern@rowland.harvard.edu Fri Apr 18 14:59:20 2008 +From: Alan Stern <stern@rowland.harvard.edu> +Date: Thu, 17 Apr 2008 10:18:11 -0400 (EDT) +Subject: USB: usbfs: export the URB_NO_INTERRUPT flag to userspace +To: Greg KH <greg@kroah.com> +Cc: USB list <linux-usb@vger.kernel.org> +Message-ID: <Pine.LNX.4.44L0.0804171017060.4869-100000@iolanthe.rowland.org> + + +This patch (as1079) cleans up the way URB_* flags are exported in +usbfs. + + The URB_NO_INTERRUPT flag is now exported (this is the + only behavioral change). + + USBDEVFS_URB_* macros are added for URB_NO_FSBR, + URB_ZERO_PACKET, and URB_NO_INTERRUPT, making explicit the + fact that the kernel accepts them. + + The flag matching takes into account that the URB_* values + may change as the kernel evolves, whereas the USBDEVFS_URB_* + values must remain fixed since they are a user API. + +Signed-off-by: Alan Stern <stern@rowland.harvard.edu> +Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + +--- + drivers/usb/core/devio.c | 27 +++++++++++++++++++++++---- + include/linux/usbdevice_fs.h | 7 +++++-- + 2 files changed, 28 insertions(+), 6 deletions(-) + +--- a/drivers/usb/core/devio.c ++++ b/drivers/usb/core/devio.c +@@ -948,8 +948,11 @@ static int proc_do_submiturb(struct dev_ + int ret, ifnum = -1; + int is_in; + +- if (uurb->flags & ~(USBDEVFS_URB_ISO_ASAP|USBDEVFS_URB_SHORT_NOT_OK| +- URB_NO_FSBR|URB_ZERO_PACKET)) ++ if (uurb->flags & ~(USBDEVFS_URB_ISO_ASAP | ++ USBDEVFS_URB_SHORT_NOT_OK | ++ USBDEVFS_URB_NO_FSBR | ++ USBDEVFS_URB_ZERO_PACKET | ++ USBDEVFS_URB_NO_INTERRUPT)) + return -EINVAL; + if (!uurb->buffer) + return -EINVAL; +@@ -1104,8 +1107,24 @@ static int proc_do_submiturb(struct dev_ + as->urb->pipe = (uurb->type << 30) | + __create_pipe(ps->dev, uurb->endpoint & 0xf) | + (uurb->endpoint & USB_DIR_IN); +- as->urb->transfer_flags = uurb->flags | +- (is_in ? URB_DIR_IN : URB_DIR_OUT); ++ ++ /* This tedious sequence is necessary because the URB_* flags ++ * are internal to the kernel and subject to change, whereas ++ * the USBDEVFS_URB_* flags are a user API and must not be changed. ++ */ ++ u = (is_in ? URB_DIR_IN : URB_DIR_OUT); ++ if (uurb->flags & USBDEVFS_URB_ISO_ASAP) ++ u |= URB_ISO_ASAP; ++ if (uurb->flags & USBDEVFS_URB_SHORT_NOT_OK) ++ u |= URB_SHORT_NOT_OK; ++ if (uurb->flags & USBDEVFS_URB_NO_FSBR) ++ u |= URB_NO_FSBR; ++ if (uurb->flags & USBDEVFS_URB_ZERO_PACKET) ++ u |= URB_ZERO_PACKET; ++ if (uurb->flags & USBDEVFS_URB_NO_INTERRUPT) ++ u |= URB_NO_INTERRUPT; ++ as->urb->transfer_flags = u; ++ + as->urb->transfer_buffer_length = uurb->buffer_length; + as->urb->setup_packet = (unsigned char *)dr; + as->urb->start_frame = uurb->start_frame; +--- a/include/linux/usbdevice_fs.h ++++ b/include/linux/usbdevice_fs.h +@@ -77,8 +77,11 @@ struct usbdevfs_connectinfo { + unsigned char slow; + }; + +-#define USBDEVFS_URB_SHORT_NOT_OK 1 +-#define USBDEVFS_URB_ISO_ASAP 2 ++#define USBDEVFS_URB_SHORT_NOT_OK 0x01 ++#define USBDEVFS_URB_ISO_ASAP 0x02 ++#define USBDEVFS_URB_NO_FSBR 0x20 ++#define USBDEVFS_URB_ZERO_PACKET 0x40 ++#define USBDEVFS_URB_NO_INTERRUPT 0x80 + + #define USBDEVFS_URB_TYPE_ISO 0 + #define USBDEVFS_URB_TYPE_INTERRUPT 1 |
