Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6
authorLinus Torvalds <torvalds@linux-foundation.org>
Sat, 23 Oct 2010 03:30:48 +0000 (20:30 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sat, 23 Oct 2010 03:30:48 +0000 (20:30 -0700)
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (141 commits)
  USB: mct_u232: fix broken close
  USB: gadget: amd5536udc.c: fix error path
  USB: imx21-hcd - fix off by one resource size calculation
  usb: gadget: fix Kconfig warning
  usb: r8a66597-udc: Add processing when USB was removed.
  mxc_udc: add workaround for ENGcm09152 for i.MX35
  USB: ftdi_sio: add device ids for ScienceScope
  USB: musb: AM35x: Workaround for fifo read issue
  USB: musb: add musb support for AM35x
  USB: AM35x: Add musb support
  usb: Fix linker errors with CONFIG_PM=n
  USB: ohci-sh - use resource_size instead of defining its own resource_len macro
  USB: isp1362-hcd - use resource_size instead of defining its own resource_len macro
  USB: isp116x-hcd - use resource_size instead of defining its own resource_len macro
  USB: xhci: Fix compile error when CONFIG_PM=n
  USB: accept some invalid ep0-maxpacket values
  USB: xHCI: PCI power management implementation
  USB: xHCI: bus power management implementation
  USB: xHCI: port remote wakeup implementation
  USB: xHCI: port power management implementation
  ...

Manually fix up (non-data) conflict: the SCSI merge gad renamed the
'hw_sector_size' member to 'physical_block_size', and the USB tree
brought a new use of it.

13 files changed:
1  2 
Documentation/devices.txt
MAINTAINERS
arch/arm/mach-mx3/mach-cpuimx35.c
arch/arm/mach-omap2/board-am3517evm.c
arch/powerpc/sysdev/fsl_soc.c
drivers/block/ub.c
drivers/scsi/sd.c
drivers/scsi/sr.c
drivers/usb/gadget/inode.c
drivers/usb/gadget/printer.c
drivers/usb/misc/iowarrior.c
drivers/usb/serial/ftdi_sio.c
include/scsi/scsi.h

index 6a08fd731d2870321ceaa5a68b52b609cc6dced4,3cab6b342017794cf47615589a500141a26757b8..c58abf1ccc715cfd729c8ed455fcd7e084e6de5a
@@@ -239,7 -239,6 +239,7 @@@ Your cooperation is appreciated
                  0 = /dev/tty          Current TTY device
                  1 = /dev/console      System console
                  2 = /dev/ptmx         PTY master multiplex
 +                3 = /dev/ttyprintk    User messages via printk TTY device
                 64 = /dev/cua0         Callout device for ttyS0
                    ...
                255 = /dev/cua191       Callout device for ttyS191
                175 = /dev/usb/legousbtower15   16th USB Legotower device
                176 = /dev/usb/usbtmc1  First USB TMC device
                   ...
-               192 = /dev/usb/usbtmc16 16th USB TMC device
+               191 = /dev/usb/usbtmc16 16th USB TMC device
+               192 = /dev/usb/yurex1   First USB Yurex device
+                  ...
+               209 = /dev/usb/yurex16  16th USB Yurex device
                240 = /dev/usb/dabusb0  First daubusb device
                    ...
                243 = /dev/usb/dabusb3  Fourth dabusb device
diff --combined MAINTAINERS
index 060e32ab35fb71c4bbee1303114d79b6b2bf91cb,8dac57f53d870f32db9a1ac43c7c4965a7d3dccf..9a0432de91417ed7729f0cc5729c467954cc4e45
@@@ -157,11 -157,9 +157,11 @@@ S:       Maintaine
  F:    drivers/net/r8169.c
  
  8250/16?50 (AND CLONE UARTS) SERIAL DRIVER
 +M:    Greg Kroah-Hartman <gregkh@suse.de>
  L:    linux-serial@vger.kernel.org
  W:    http://serial.sourceforge.net
 -S:    Orphan
 +S:    Maintained
 +T:    quilt kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/
  F:    drivers/serial/8250*
  F:    include/linux/serial_8250.h
  
@@@ -992,23 -990,11 +992,23 @@@ S:      Supporte
  F:    arch/arm/mach-shmobile/
  F:    drivers/sh/
  
 +ARM/TELECHIPS ARM ARCHITECTURE
 +M:    "Hans J. Koch" <hjk@linutronix.de>
 +L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
 +S:    Maintained
 +F:    arch/arm/plat-tcc/
 +F:    arch/arm/mach-tcc8k/
 +
  ARM/TECHNOLOGIC SYSTEMS TS7250 MACHINE SUPPORT
  M:    Lennert Buytenhek <kernel@wantstofly.org>
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
  S:    Maintained
  
 +ARM/TETON BGA MACHINE SUPPORT
 +M:    Mark F. Brown <mark.brown314@gmail.com>
 +L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
 +S:    Maintained
 +
  ARM/THECUS N2100 MACHINE SUPPORT
  M:    Lennert Buytenhek <kernel@wantstofly.org>
  L:    linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
@@@ -1541,8 -1527,6 +1541,8 @@@ T:      git git://git.kernel.org/pub/scm/lin
  S:    Supported
  F:    Documentation/filesystems/ceph.txt
  F:    fs/ceph
 +F:    net/ceph
 +F:    include/linux/ceph
  
  CERTIFIED WIRELESS USB (WUSB) SUBSYSTEM:
  M:    David Vrabel <david.vrabel@csr.com>
@@@ -2066,16 -2050,14 +2066,16 @@@ F:   drivers/block/drbd
  F:    lib/lru_cache.c
  F:    Documentation/blockdev/drbd/
  
 -DRIVER CORE, KOBJECTS, AND SYSFS
 +DRIVER CORE, KOBJECTS, DEBUGFS AND SYSFS
  M:    Greg Kroah-Hartman <gregkh@suse.de>
  T:    quilt kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/
  S:    Supported
  F:    Documentation/kobject.txt
  F:    drivers/base/
  F:    fs/sysfs/
 +F:    fs/debugfs/
  F:    include/linux/kobj*
 +F:    include/linux/debugfs.h
  F:    lib/kobj*
  
  DRM DRIVERS
@@@ -3257,12 -3239,6 +3257,12 @@@ F:    drivers/net/irda
  F:    include/net/irda/
  F:    net/irda/
  
 +IRQ SUBSYSTEM
 +M:    Thomas Gleixner <tglx@linutronix.de>
 +S:    Maintained
 +T:    git git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git irq/core
 +F:    kernel/irq/
 +
  ISAPNP
  M:    Jaroslav Kysela <perex@perex.cz>
  S:    Maintained
@@@ -3355,12 -3331,6 +3355,12 @@@ F:    fs/jbd*
  F:    include/linux/ext*jbd*.h
  F:    include/linux/jbd*.h
  
 +JSM Neo PCI based serial card
 +M:    Breno Leitao <leitao@linux.vnet.ibm.com>
 +L:    linux-serial@vger.kernel.org
 +S:    Maintained
 +F:    drivers/serial/jsm/
 +
  K8TEMP HARDWARE MONITORING DRIVER
  M:    Rudolf Marek <r.marek@assembler.cz>
  L:    lm-sensors@lm-sensors.org
@@@ -4835,15 -4805,6 +4835,15 @@@ F:    fs/qnx4
  F:    include/linux/qnx4_fs.h
  F:    include/linux/qnxtypes.h
  
 +RADOS BLOCK DEVICE (RBD)
 +F:    include/linux/qnxtypes.h
 +M:    Yehuda Sadeh <yehuda@hq.newdream.net>
 +M:    Sage Weil <sage@newdream.net>
 +M:    ceph-devel@vger.kernel.org
 +S:    Supported
 +F:    drivers/block/rbd.c
 +F:    drivers/block/rbd_types.h
 +
  RADEON FRAMEBUFFER DISPLAY DRIVER
  M:    Benjamin Herrenschmidt <benh@kernel.crashing.org>
  L:    linux-fbdev@vger.kernel.org
@@@ -5973,6 -5934,14 +5973,14 @@@ S:    Maintaine
  F:    Documentation/usb/acm.txt
  F:    drivers/usb/class/cdc-acm.*
  
+ USB ATTACHED SCSI
+ M:    Matthew Wilcox <willy@linux.intel.com>
+ M:    Sarah Sharp <sarah.a.sharp@linux.intel.com>
+ L:    linux-usb@vger.kernel.org
+ L:    linux-scsi@vger.kernel.org
+ S:    Supported
+ F:    drivers/usb/storage/uas.c
  USB BLOCK DRIVER (UB ub)
  M:    Pete Zaitcev <zaitcev@redhat.com>
  L:    linux-usb@vger.kernel.org
index 8533bf04284a1fc682db1a7fc15897a097a61e2d,4d161b3fca6505b9a5dcb8aa5ba3ea5d92c60462..9fde873f5889c6292ae6ea97f5011bd632d54aa4
@@@ -31,7 -31,6 +31,7 @@@
  #include <linux/usb/otg.h>
  #include <linux/usb/ulpi.h>
  #include <linux/fsl_devices.h>
 +#include <linux/i2c-gpio.h>
  
  #include <asm/mach-types.h>
  #include <asm/mach/arch.h>
@@@ -44,6 -43,7 +44,6 @@@
  #include <mach/iomux-mx35.h>
  #include <mach/mxc_nand.h>
  #include <mach/mxc_ehci.h>
 -#include <mach/ulpi.h>
  
  #include "devices-imx35.h"
  #include "devices.h"
@@@ -53,16 -53,39 +53,16 @@@ static const struct imxuart_platform_da
  };
  
  static const struct imxi2c_platform_data
 -eukrea_cpuimx35_i2c0_data __initconst = {
 -      .bitrate = 50000,
 +              eukrea_cpuimx35_i2c0_data __initconst = {
 +      .bitrate =              100000,
  };
  
 -#define TSC2007_IRQGPIO               (2 * 32 + 2)
 -static int ts_get_pendown_state(void)
 -{
 -      int val = 0;
 -      gpio_free(TSC2007_IRQGPIO);
 -      gpio_request(TSC2007_IRQGPIO, NULL);
 -      gpio_direction_input(TSC2007_IRQGPIO);
 -
 -      val = gpio_get_value(TSC2007_IRQGPIO);
 -
 -      gpio_free(TSC2007_IRQGPIO);
 -      gpio_request(TSC2007_IRQGPIO, NULL);
 -
 -      return val ? 0 : 1;
 -}
 -
 -static int ts_init(void)
 -{
 -      gpio_request(TSC2007_IRQGPIO, NULL);
 -      return 0;
 -}
 -
  static struct tsc2007_platform_data tsc2007_info = {
        .model                  = 2007,
        .x_plate_ohms           = 180,
 -      .get_pendown_state      = ts_get_pendown_state,
 -      .init_platform_hw       = ts_init,
  };
  
 +#define TSC2007_IRQGPIO               (2 * 32 + 2)
  static struct i2c_board_info eukrea_cpuimx35_i2c_devices[] = {
        {
                I2C_BOARD_INFO("pcf8563", 0x51),
@@@ -75,6 -98,7 +75,6 @@@
  };
  
  static struct platform_device *devices[] __initdata = {
 -      &mxc_fec_device,
        &imx_wdt_device0,
  };
  
@@@ -111,18 -135,18 +111,18 @@@ static struct pad_desc eukrea_cpuimx35_
  };
  
  static const struct mxc_nand_platform_data
 -eukrea_cpuimx35_nand_board_info __initconst = {
 +              eukrea_cpuimx35_nand_board_info __initconst = {
        .width          = 1,
        .hw_ecc         = 1,
        .flash_bbt      = 1,
  };
  
 -static struct mxc_usbh_platform_data otg_pdata = {
 +static struct mxc_usbh_platform_data __maybe_unused otg_pdata = {
        .portsc = MXC_EHCI_MODE_UTMI,
        .flags  = MXC_EHCI_INTERFACE_DIFF_UNI,
  };
  
 -static struct mxc_usbh_platform_data usbh1_pdata = {
 +static struct mxc_usbh_platform_data __maybe_unused usbh1_pdata = {
        .portsc = MXC_EHCI_MODE_SERIAL,
        .flags  = MXC_EHCI_INTERFACE_SINGLE_UNI | MXC_EHCI_INTERNAL_PHY |
                  MXC_EHCI_IPPUE_DOWN,
  static struct fsl_usb2_platform_data otg_device_pdata = {
        .operating_mode = FSL_USB2_DR_DEVICE,
        .phy_mode       = FSL_USB2_PHY_UTMI,
+       .workaround     = FLS_USB2_WORKAROUND_ENGCM09152,
  };
  
  static int otg_mode_host;
@@@ -156,7 -181,6 +157,7 @@@ static void __init mxc_board_init(void
        mxc_iomux_v3_setup_multiple_pads(eukrea_cpuimx35_pads,
                        ARRAY_SIZE(eukrea_cpuimx35_pads));
  
 +      imx35_add_fec(NULL);
        platform_add_devices(devices, ARRAY_SIZE(devices));
  
        imx35_add_imx_uart0(&uart_pdata);
                        ARRAY_SIZE(eukrea_cpuimx35_i2c_devices));
        imx35_add_imx_i2c0(&eukrea_cpuimx35_i2c0_data);
  
 -#if defined(CONFIG_USB_ULPI)
 -      if (otg_mode_host) {
 -              otg_pdata.otg = otg_ulpi_create(&mxc_ulpi_access_ops,
 -                              ULPI_OTG_DRVVBUS | ULPI_OTG_DRVVBUS_EXT);
 -
 +      if (otg_mode_host)
                mxc_register_device(&mxc_otg_host, &otg_pdata);
 -      }
 -      mxc_register_device(&mxc_usbh1, &usbh1_pdata);
 -#endif
 -      if (!otg_mode_host)
 +      else
                mxc_register_device(&mxc_otg_udc_device, &otg_device_pdata);
  
 +      mxc_register_device(&mxc_usbh1, &usbh1_pdata);
 +
  #ifdef CONFIG_MACH_EUKREA_MBIMXSD35_BASEBOARD
        eukrea_mbimxsd35_baseboard_init();
  #endif
@@@ -189,6 -218,8 +190,6 @@@ struct sys_timer eukrea_cpuimx35_timer 
  
  MACHINE_START(EUKREA_CPUIMX35, "Eukrea CPUIMX35")
        /* Maintainer: Eukrea Electromatique */
 -      .phys_io        = MX35_AIPS1_BASE_ADDR,
 -      .io_pg_offst    = ((MX35_AIPS1_BASE_ADDR_VIRT) >> 18) & 0xfffc,
        .boot_params    = MX3x_PHYS_OFFSET + 0x100,
        .map_io         = mx35_map_io,
        .init_irq       = mx35_init_irq,
index f85c8da17e8bb8bcf69bbf208b2030277c3879be,9ac9de6bb97066ddd4d086faf1d0d3a097a191f9..d547036aff3f2cb640da7905cf75ec8f22f6aff7
@@@ -375,6 -375,31 +375,31 @@@ static void __init am3517_evm_init_irq(
        omap_gpio_init();
  }
  
+ static struct omap_musb_board_data musb_board_data = {
+       .interface_type         = MUSB_INTERFACE_ULPI,
+       .mode                   = MUSB_OTG,
+       .power                  = 500,
+ };
+ static __init void am3517_evm_musb_init(void)
+ {
+       u32 devconf2;
+       /*
+        * Set up USB clock/mode in the DEVCONF2 register.
+        */
+       devconf2 = omap_ctrl_readl(AM35XX_CONTROL_DEVCONF2);
+       /* USB2.0 PHY reference clock is 13 MHz */
+       devconf2 &= ~(CONF2_REFFREQ | CONF2_OTGMODE | CONF2_PHY_GPIOMODE);
+       devconf2 |=  CONF2_REFFREQ_13MHZ | CONF2_SESENDEN | CONF2_VBDTCTEN
+                       | CONF2_DATPOL;
+       omap_ctrl_writel(devconf2, AM35XX_CONTROL_DEVCONF2);
+       usb_musb_init(&musb_board_data);
+ }
  static const struct ehci_hcd_omap_platform_data ehci_pdata __initconst = {
        .port_mode[0] = EHCI_HCD_OMAP_MODE_PHY,
  #if defined(CONFIG_PANEL_SHARP_LQ043T1DG01) || \
  
  #ifdef CONFIG_OMAP_MUX
  static struct omap_board_mux board_mux[] __initdata = {
+       /* USB OTG DRVVBUS offset = 0x212 */
+       OMAP3_MUX(SAD2D_MCAD23, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLDOWN),
        { .reg_offset = OMAP_MUX_TERMINATOR },
  };
  #else
@@@ -459,9 -486,14 +486,12 @@@ static void __init am3517_evm_init(void
                                ARRAY_SIZE(am3517evm_i2c1_boardinfo));
        /*Ethernet*/
        am3517_evm_ethernet_init(&am3517_evm_emac_pdata);
+       /* MUSB */
+       am3517_evm_musb_init();
  }
  
  MACHINE_START(OMAP3517EVM, "OMAP3517/AM3517 EVM")
 -      .phys_io        = 0x48000000,
 -      .io_pg_offst    = ((0xd8000000) >> 18) & 0xfffc,
        .boot_params    = 0x80000100,
        .map_io         = omap3_map_io,
        .reserve        = omap_reserve,
index 6c67d9ebf1669e80886614e1e3d3b78528716e62,49a51f134c517b1f146f443878f86092f669ed56..19e5015e039be1636aad915214a4f938964eb5a2
@@@ -209,192 -209,23 +209,29 @@@ static int __init of_add_fixed_phys(voi
  arch_initcall(of_add_fixed_phys);
  #endif /* CONFIG_FIXED_PHY */
  
- static enum fsl_usb2_phy_modes determine_usb_phy(const char *phy_type)
- {
-       if (!phy_type)
-               return FSL_USB2_PHY_NONE;
-       if (!strcasecmp(phy_type, "ulpi"))
-               return FSL_USB2_PHY_ULPI;
-       if (!strcasecmp(phy_type, "utmi"))
-               return FSL_USB2_PHY_UTMI;
-       if (!strcasecmp(phy_type, "utmi_wide"))
-               return FSL_USB2_PHY_UTMI_WIDE;
-       if (!strcasecmp(phy_type, "serial"))
-               return FSL_USB2_PHY_SERIAL;
-       return FSL_USB2_PHY_NONE;
- }
- static int __init fsl_usb_of_init(void)
- {
-       struct device_node *np;
-       unsigned int i = 0;
-       struct platform_device *usb_dev_mph = NULL, *usb_dev_dr_host = NULL,
-               *usb_dev_dr_client = NULL;
-       int ret;
-       for_each_compatible_node(np, NULL, "fsl-usb2-mph") {
-               struct resource r[2];
-               struct fsl_usb2_platform_data usb_data;
-               const unsigned char *prop = NULL;
-               memset(&r, 0, sizeof(r));
-               memset(&usb_data, 0, sizeof(usb_data));
-               ret = of_address_to_resource(np, 0, &r[0]);
-               if (ret)
-                       goto err;
-               of_irq_to_resource(np, 0, &r[1]);
-               usb_dev_mph =
-                   platform_device_register_simple("fsl-ehci", i, r, 2);
-               if (IS_ERR(usb_dev_mph)) {
-                       ret = PTR_ERR(usb_dev_mph);
-                       goto err;
-               }
-               usb_dev_mph->dev.coherent_dma_mask = 0xffffffffUL;
-               usb_dev_mph->dev.dma_mask = &usb_dev_mph->dev.coherent_dma_mask;
-               usb_data.operating_mode = FSL_USB2_MPH_HOST;
-               prop = of_get_property(np, "port0", NULL);
-               if (prop)
-                       usb_data.port_enables |= FSL_USB2_PORT0_ENABLED;
-               prop = of_get_property(np, "port1", NULL);
-               if (prop)
-                       usb_data.port_enables |= FSL_USB2_PORT1_ENABLED;
-               prop = of_get_property(np, "phy_type", NULL);
-               usb_data.phy_mode = determine_usb_phy(prop);
-               ret =
-                   platform_device_add_data(usb_dev_mph, &usb_data,
-                                            sizeof(struct
-                                                   fsl_usb2_platform_data));
-               if (ret)
-                       goto unreg_mph;
-               i++;
-       }
-       for_each_compatible_node(np, NULL, "fsl-usb2-dr") {
-               struct resource r[2];
-               struct fsl_usb2_platform_data usb_data;
-               const unsigned char *prop = NULL;
-               if (!of_device_is_available(np))
-                       continue;
-               memset(&r, 0, sizeof(r));
-               memset(&usb_data, 0, sizeof(usb_data));
-               ret = of_address_to_resource(np, 0, &r[0]);
-               if (ret)
-                       goto unreg_mph;
-               of_irq_to_resource(np, 0, &r[1]);
-               prop = of_get_property(np, "dr_mode", NULL);
-               if (!prop || !strcmp(prop, "host")) {
-                       usb_data.operating_mode = FSL_USB2_DR_HOST;
-                       usb_dev_dr_host = platform_device_register_simple(
-                                       "fsl-ehci", i, r, 2);
-                       if (IS_ERR(usb_dev_dr_host)) {
-                               ret = PTR_ERR(usb_dev_dr_host);
-                               goto err;
-                       }
-               } else if (prop && !strcmp(prop, "peripheral")) {
-                       usb_data.operating_mode = FSL_USB2_DR_DEVICE;
-                       usb_dev_dr_client = platform_device_register_simple(
-                                       "fsl-usb2-udc", i, r, 2);
-                       if (IS_ERR(usb_dev_dr_client)) {
-                               ret = PTR_ERR(usb_dev_dr_client);
-                               goto err;
-                       }
-               } else if (prop && !strcmp(prop, "otg")) {
-                       usb_data.operating_mode = FSL_USB2_DR_OTG;
-                       usb_dev_dr_host = platform_device_register_simple(
-                                       "fsl-ehci", i, r, 2);
-                       if (IS_ERR(usb_dev_dr_host)) {
-                               ret = PTR_ERR(usb_dev_dr_host);
-                               goto err;
-                       }
-                       usb_dev_dr_client = platform_device_register_simple(
-                                       "fsl-usb2-udc", i, r, 2);
-                       if (IS_ERR(usb_dev_dr_client)) {
-                               ret = PTR_ERR(usb_dev_dr_client);
-                               goto err;
-                       }
-               } else {
-                       ret = -EINVAL;
-                       goto err;
-               }
-               prop = of_get_property(np, "phy_type", NULL);
-               usb_data.phy_mode = determine_usb_phy(prop);
-               if (usb_dev_dr_host) {
-                       usb_dev_dr_host->dev.coherent_dma_mask = 0xffffffffUL;
-                       usb_dev_dr_host->dev.dma_mask = &usb_dev_dr_host->
-                               dev.coherent_dma_mask;
-                       if ((ret = platform_device_add_data(usb_dev_dr_host,
-                                               &usb_data, sizeof(struct
-                                               fsl_usb2_platform_data))))
-                               goto unreg_dr;
-               }
-               if (usb_dev_dr_client) {
-                       usb_dev_dr_client->dev.coherent_dma_mask = 0xffffffffUL;
-                       usb_dev_dr_client->dev.dma_mask = &usb_dev_dr_client->
-                               dev.coherent_dma_mask;
-                       if ((ret = platform_device_add_data(usb_dev_dr_client,
-                                               &usb_data, sizeof(struct
-                                               fsl_usb2_platform_data))))
-                               goto unreg_dr;
-               }
-               i++;
-       }
-       return 0;
- unreg_dr:
-       if (usb_dev_dr_host)
-               platform_device_unregister(usb_dev_dr_host);
-       if (usb_dev_dr_client)
-               platform_device_unregister(usb_dev_dr_client);
- unreg_mph:
-       if (usb_dev_mph)
-               platform_device_unregister(usb_dev_mph);
- err:
-       return ret;
- }
- arch_initcall(fsl_usb_of_init);
  #if defined(CONFIG_FSL_SOC_BOOKE) || defined(CONFIG_PPC_86xx)
  static __be32 __iomem *rstcr;
  
  static int __init setup_rstcr(void)
  {
        struct device_node *np;
 -      np = of_find_node_by_name(NULL, "global-utilities");
 -      if ((np && of_get_property(np, "fsl,has-rstcr", NULL))) {
 -              rstcr = of_iomap(np, 0) + 0xb0;
 -              if (!rstcr)
 -                      printk (KERN_EMERG "Error: reset control register "
 -                                      "not mapped!\n");
 -      } else if (ppc_md.restart == fsl_rstcr_restart)
 +
 +      for_each_node_by_name(np, "global-utilities") {
 +              if ((of_get_property(np, "fsl,has-rstcr", NULL))) {
 +                      rstcr = of_iomap(np, 0) + 0xb0;
 +                      if (!rstcr)
 +                              printk (KERN_ERR "Error: reset control "
 +                                              "register not mapped!\n");
 +                      break;
 +              }
 +      }
 +
 +      if (!rstcr && ppc_md.restart == fsl_rstcr_restart)
                printk(KERN_ERR "No RSTCR register, warm reboot won't work\n");
  
        if (np)
                of_node_put(np);
 +
        return 0;
  }
  
diff --combined drivers/block/ub.c
index b5690a045a01076c782a575b4e846af64d0306c5,f3fd454e28f9b06cfd76916a9d79b27888c65775..9ae3bb713286f0d0d3a959a81f7f4b4db5cde1db
@@@ -28,7 -28,7 +28,7 @@@
  #include <linux/timer.h>
  #include <linux/scatterlist.h>
  #include <linux/slab.h>
 -#include <linux/smp_lock.h>
 +#include <linux/mutex.h>
  #include <scsi/scsi.h>
  
  #define DRV_NAME "ub"
@@@ -248,7 -248,6 +248,7 @@@ struct ub_completion 
        spinlock_t lock;
  };
  
 +static DEFINE_MUTEX(ub_mutex);
  static inline void ub_init_completion(struct ub_completion *x)
  {
        x->done = 0;
@@@ -397,7 -396,7 +397,7 @@@ static int ub_probe_lun(struct ub_dev *
  #else
  
  static const struct usb_device_id ub_usb_ids[] = {
-       { USB_INTERFACE_INFO(USB_CLASS_MASS_STORAGE, US_SC_SCSI, US_PR_BULK) },
+       { USB_INTERFACE_INFO(USB_CLASS_MASS_STORAGE, USB_SC_SCSI, USB_PR_BULK) },
        { }
  };
  
@@@ -1716,9 -1715,9 +1716,9 @@@ static int ub_bd_unlocked_open(struct b
  {
        int ret;
  
 -      lock_kernel();
 +      mutex_lock(&ub_mutex);
        ret = ub_bd_open(bdev, mode);
 -      unlock_kernel();
 +      mutex_unlock(&ub_mutex);
  
        return ret;
  }
@@@ -1731,9 -1730,9 +1731,9 @@@ static int ub_bd_release(struct gendis
        struct ub_lun *lun = disk->private_data;
        struct ub_dev *sc = lun->udev;
  
 -      lock_kernel();
 +      mutex_lock(&ub_mutex);
        ub_put(sc);
 -      unlock_kernel();
 +      mutex_unlock(&ub_mutex);
  
        return 0;
  }
@@@ -1748,9 -1747,9 +1748,9 @@@ static int ub_bd_ioctl(struct block_dev
        void __user *usermem = (void __user *) arg;
        int ret;
  
 -      lock_kernel();
 +      mutex_lock(&ub_mutex);
        ret = scsi_cmd_ioctl(disk->queue, disk, mode, cmd, usermem);
 -      unlock_kernel();
 +      mutex_unlock(&ub_mutex);
  
        return ret;
  }
diff --combined drivers/scsi/sd.c
index 20295774bf70c8c800ff0cd0eb1fe7b1488ec989,ff4c9a3aa5b26396935fc8927a378d3e4ed5e1fd..57d1e3e1bd4478548f89ef9f3a472ee4418c71b3
@@@ -477,7 -477,7 +477,7 @@@ static int scsi_setup_discard_cmnd(stru
  
  static int scsi_setup_flush_cmnd(struct scsi_device *sdp, struct request *rq)
  {
 -      rq->timeout = SD_TIMEOUT;
 +      rq->timeout = SD_FLUSH_TIMEOUT;
        rq->retries = SD_MAX_RETRIES;
        rq->cmd[0] = SYNCHRONIZE_CACHE;
        rq->cmd_len = 10;
@@@ -1072,7 -1072,7 +1072,7 @@@ static int sd_sync_cache(struct scsi_di
                 * flush everything.
                 */
                res = scsi_execute_req(sdp, cmd, DMA_NONE, NULL, 0, &sshdr,
 -                                     SD_TIMEOUT, SD_MAX_RETRIES, NULL);
 +                                     SD_FLUSH_TIMEOUT, SD_MAX_RETRIES, NULL);
                if (res == 0)
                        break;
        }
@@@ -1498,6 -1498,9 +1498,9 @@@ static int read_capacity_16(struct scsi
        unsigned long long lba;
        unsigned sector_size;
  
+       if (sdp->no_read_capacity_16)
+               return -EINVAL;
        do {
                memset(cmd, 0, 16);
                cmd[0] = SERVICE_ACTION_IN;
        }
  
        /* Logical blocks per physical block exponent */
 -      sdkp->hw_sector_size = (1 << (buffer[13] & 0xf)) * sector_size;
 +      sdkp->physical_block_size = (1 << (buffer[13] & 0xf)) * sector_size;
  
        /* Lowest aligned logical block */
        alignment = ((buffer[14] & 0x3f) << 8 | buffer[15]) * sector_size;
                struct request_queue *q = sdp->request_queue;
  
                sdkp->thin_provisioning = 1;
 -              q->limits.discard_granularity = sdkp->hw_sector_size;
 +              q->limits.discard_granularity = sdkp->physical_block_size;
                q->limits.max_discard_sectors = 0xffffffff;
  
                if (buffer[14] & 0x40) /* TPRZ */
@@@ -1626,6 -1629,15 +1629,15 @@@ static int read_capacity_10(struct scsi
        sector_size = get_unaligned_be32(&buffer[4]);
        lba = get_unaligned_be32(&buffer[0]);
  
 -              sdkp->hw_sector_size = sector_size;
+       if (sdp->no_read_capacity_16 && (lba == 0xffffffff)) {
+               /* Some buggy (usb cardreader) devices return an lba of
+                  0xffffffff when the want to report a size of 0 (with
+                  which they really mean no media is present) */
+               sdkp->capacity = 0;
++              sdkp->physical_block_size = sector_size;
+               return sector_size;
+       }
        if ((sizeof(sdkp->capacity) == 4) && (lba == 0xffffffff)) {
                sd_printk(KERN_ERR, sdkp, "Too big for this kernel. Use a "
                        "kernel compiled with support for large block "
        }
  
        sdkp->capacity = lba + 1;
 -      sdkp->hw_sector_size = sector_size;
 +      sdkp->physical_block_size = sector_size;
        return sector_size;
  }
  
@@@ -1756,10 -1768,10 +1768,10 @@@ got_data
                                  (unsigned long long)sdkp->capacity,
                                  sector_size, cap_str_10, cap_str_2);
  
 -                      if (sdkp->hw_sector_size != sector_size)
 +                      if (sdkp->physical_block_size != sector_size)
                                sd_printk(KERN_NOTICE, sdkp,
                                          "%u-byte physical blocks\n",
 -                                        sdkp->hw_sector_size);
 +                                        sdkp->physical_block_size);
                }
        }
  
        else if (sector_size == 256)
                sdkp->capacity >>= 1;
  
 -      blk_queue_physical_block_size(sdp->request_queue, sdkp->hw_sector_size);
 +      blk_queue_physical_block_size(sdp->request_queue,
 +                                    sdkp->physical_block_size);
        sdkp->device->sector_size = sector_size;
  }
  
@@@ -2040,24 -2051,14 +2052,24 @@@ static void sd_read_block_limits(struc
                lba_count = get_unaligned_be32(&buffer[20]);
                desc_count = get_unaligned_be32(&buffer[24]);
  
 -              if (lba_count) {
 -                      q->limits.max_discard_sectors =
 -                              lba_count * sector_sz >> 9;
 -
 -                      if (desc_count)
 +              if (lba_count && desc_count) {
 +                      if (sdkp->tpvpd && !sdkp->tpu)
 +                              sdkp->unmap = 0;
 +                      else
                                sdkp->unmap = 1;
                }
  
 +              if (sdkp->tpvpd && !sdkp->tpu && !sdkp->tpws) {
 +                      sd_printk(KERN_ERR, sdkp, "Thin provisioning is " \
 +                                "enabled but neither TPU, nor TPWS are " \
 +                                "set. Disabling discard!\n");
 +                      goto out;
 +              }
 +
 +              if (lba_count)
 +                      q->limits.max_discard_sectors =
 +                              lba_count * sector_sz >> 9;
 +
                granularity = get_unaligned_be32(&buffer[28]);
  
                if (granularity)
@@@ -2098,31 -2099,6 +2110,31 @@@ static void sd_read_block_characteristi
        kfree(buffer);
  }
  
 +/**
 + * sd_read_thin_provisioning - Query thin provisioning VPD page
 + * @disk: disk to query
 + */
 +static void sd_read_thin_provisioning(struct scsi_disk *sdkp)
 +{
 +      unsigned char *buffer;
 +      const int vpd_len = 8;
 +
 +      if (sdkp->thin_provisioning == 0)
 +              return;
 +
 +      buffer = kmalloc(vpd_len, GFP_KERNEL);
 +
 +      if (!buffer || scsi_get_vpd_page(sdkp->device, 0xb2, buffer, vpd_len))
 +              goto out;
 +
 +      sdkp->tpvpd = 1;
 +      sdkp->tpu   = (buffer[5] >> 7) & 1;     /* UNMAP */
 +      sdkp->tpws  = (buffer[5] >> 6) & 1;     /* WRITE SAME(16) with UNMAP */
 +
 + out:
 +      kfree(buffer);
 +}
 +
  static int sd_try_extended_inquiry(struct scsi_device *sdp)
  {
        /*
@@@ -2145,7 -2121,7 +2157,7 @@@ static int sd_revalidate_disk(struct ge
        struct scsi_disk *sdkp = scsi_disk(disk);
        struct scsi_device *sdp = sdkp->device;
        unsigned char *buffer;
 -      unsigned ordered;
 +      unsigned flush = 0;
  
        SCSI_LOG_HLQUEUE(3, sd_printk(KERN_INFO, sdkp,
                                      "sd_revalidate_disk\n"));
                sd_read_capacity(sdkp, buffer);
  
                if (sd_try_extended_inquiry(sdp)) {
 +                      sd_read_thin_provisioning(sdkp);
                        sd_read_block_limits(sdkp);
                        sd_read_block_characteristics(sdkp);
                }
  
        /*
         * We now have all cache related info, determine how we deal
 -       * with ordered requests.  Note that as the current SCSI
 -       * dispatch function can alter request order, we cannot use
 -       * QUEUE_ORDERED_TAG_* even when ordered tag is supported.
 +       * with flush requests.
         */
 -      if (sdkp->WCE)
 -              ordered = sdkp->DPOFUA
 -                      ? QUEUE_ORDERED_DRAIN_FUA : QUEUE_ORDERED_DRAIN_FLUSH;
 -      else
 -              ordered = QUEUE_ORDERED_DRAIN;
 +      if (sdkp->WCE) {
 +              flush |= REQ_FLUSH;
 +              if (sdkp->DPOFUA)
 +                      flush |= REQ_FUA;
 +      }
  
 -      blk_queue_ordered(sdkp->disk->queue, ordered);
 +      blk_queue_flush(sdkp->disk->queue, flush);
  
        set_capacity(disk, sdkp->capacity);
        kfree(buffer);
@@@ -2287,10 -2264,11 +2299,10 @@@ static void sd_probe_async(void *data, 
        index = sdkp->index;
        dev = &sdp->sdev_gendev;
  
 -      if (index < SD_MAX_DISKS) {
 -              gd->major = sd_major((index & 0xf0) >> 4);
 -              gd->first_minor = ((index & 0xf) << 4) | (index & 0xfff00);
 -              gd->minors = SD_MINORS;
 -      }
 +      gd->major = sd_major((index & 0xf0) >> 4);
 +      gd->first_minor = ((index & 0xf) << 4) | (index & 0xfff00);
 +      gd->minors = SD_MINORS;
 +
        gd->fops = &sd_fops;
        gd->private_data = &sdkp->driver;
        gd->queue = sdkp->device->request_queue;
@@@ -2380,12 -2358,6 +2392,12 @@@ static int sd_probe(struct device *dev
        if (error)
                goto out_put;
  
 +      if (index >= SD_MAX_DISKS) {
 +              error = -ENODEV;
 +              sdev_printk(KERN_WARNING, sdp, "SCSI disk (sd) name space exhausted.\n");
 +              goto out_free_index;
 +      }
 +
        error = sd_format_disk_name("sd", index, gd->disk_name, DISK_NAME_LEN);
        if (error)
                goto out_free_index;
diff --combined drivers/scsi/sr.c
index e148341079b5108f873a4f26d86344984a488292,b811dd0eb240e77bd0e3751db5978d9c3b13ee23..d7b383c96d5d5811620345e8e4397a9dccbc1ab8
@@@ -44,6 -44,7 +44,6 @@@
  #include <linux/init.h>
  #include <linux/blkdev.h>
  #include <linux/mutex.h>
 -#include <linux/smp_lock.h>
  #include <linux/slab.h>
  #include <asm/uaccess.h>
  
@@@ -75,7 -76,6 +75,7 @@@ MODULE_ALIAS_SCSI_DEVICE(TYPE_WORM)
         CDC_CD_R|CDC_CD_RW|CDC_DVD|CDC_DVD_R|CDC_DVD_RAM|CDC_GENERIC_PACKET| \
         CDC_MRW|CDC_MRW_W|CDC_RAM)
  
 +static DEFINE_MUTEX(sr_mutex);
  static int sr_probe(struct device *);
  static int sr_remove(struct device *);
  static int sr_done(struct scsi_cmnd *);
@@@ -470,24 -470,24 +470,24 @@@ static int sr_block_open(struct block_d
        struct scsi_cd *cd;
        int ret = -ENXIO;
  
 -      lock_kernel();
 +      mutex_lock(&sr_mutex);
        cd = scsi_cd_get(bdev->bd_disk);
        if (cd) {
                ret = cdrom_open(&cd->cdi, bdev, mode);
                if (ret)
                        scsi_cd_put(cd);
        }
 -      unlock_kernel();
 +      mutex_unlock(&sr_mutex);
        return ret;
  }
  
  static int sr_block_release(struct gendisk *disk, fmode_t mode)
  {
        struct scsi_cd *cd = scsi_cd(disk);
 -      lock_kernel();
 +      mutex_lock(&sr_mutex);
        cdrom_release(&cd->cdi, mode);
        scsi_cd_put(cd);
 -      unlock_kernel();
 +      mutex_unlock(&sr_mutex);
        return 0;
  }
  
@@@ -499,7 -499,7 +499,7 @@@ static int sr_block_ioctl(struct block_
        void __user *argp = (void __user *)arg;
        int ret;
  
 -      lock_kernel();
 +      mutex_lock(&sr_mutex);
  
        /*
         * Send SCSI addressing ioctls directly to mid level, send other
        ret = scsi_ioctl(sdev, cmd, argp);
  
  out:
 -      unlock_kernel();
 +      mutex_unlock(&sr_mutex);
        return ret;
  }
  
@@@ -862,10 -862,16 +862,16 @@@ static void get_capabilities(struct scs
  static int sr_packet(struct cdrom_device_info *cdi,
                struct packet_command *cgc)
  {
+       struct scsi_cd *cd = cdi->handle;
+       struct scsi_device *sdev = cd->device;
+       if (cgc->cmd[0] == GPCMD_READ_DISC_INFO && sdev->no_read_disc_info)
+               return -EDRIVE_CANT_DO_THIS;
        if (cgc->timeout <= 0)
                cgc->timeout = IOCTL_TIMEOUT;
  
-       sr_do_ioctl(cdi->handle, cgc);
+       sr_do_ioctl(cd, cgc);
  
        return cgc->stat;
  }
index 3f1d771c8be584c28c54d356e8238de954626c32,e2e8eda83f0dd522936245955af150430a57cbc6..d1d72d946b04d465014b593e7cd6c39604a57f4e
@@@ -33,6 -33,7 +33,6 @@@
  #include <linux/sched.h>
  #include <linux/slab.h>
  #include <linux/poll.h>
 -#include <linux/smp_lock.h>
  
  #include <linux/device.h>
  #include <linux/moduleparam.h>
@@@ -1774,7 -1775,6 +1774,6 @@@ static struct usb_gadget_driver gadgetf
        .speed          = USB_SPEED_FULL,
  #endif
        .function       = (char *) driver_desc,
-       .bind           = gadgetfs_bind,
        .unbind         = gadgetfs_unbind,
        .setup          = gadgetfs_setup,
        .disconnect     = gadgetfs_disconnect,
@@@ -1797,7 -1797,6 +1796,6 @@@ static int gadgetfs_probe (struct usb_g
  
  static struct usb_gadget_driver probe_driver = {
        .speed          = USB_SPEED_HIGH,
-       .bind           = gadgetfs_probe,
        .unbind         = gadgetfs_nop,
        .setup          = (void *)gadgetfs_nop,
        .disconnect     = gadgetfs_nop,
@@@ -1907,7 -1906,7 +1905,7 @@@ dev_config (struct file *fd, const cha
  
        /* triggers gadgetfs_bind(); then we can enumerate. */
        spin_unlock_irq (&dev->lock);
-       value = usb_gadget_register_driver (&gadgetfs_driver);
+       value = usb_gadget_probe_driver(&gadgetfs_driver, gadgetfs_bind);
        if (value != 0) {
                kfree (dev->buf);
                dev->buf = NULL;
@@@ -2046,7 -2045,7 +2044,7 @@@ gadgetfs_fill_super (struct super_bloc
                return -ESRCH;
  
        /* fake probe to determine $CHIP */
-       (void) usb_gadget_register_driver (&probe_driver);
+       (void) usb_gadget_probe_driver(&probe_driver, gadgetfs_probe);
        if (!CHIP)
                return -ENODEV;
  
index 327a92a137b4613d76b1838e742177d7f931c6fe,ded080a1c8ce5f3967824b4d89abd7e03d0ef9f6..2fc8636316c550eb8019799e99299e5551f2aac0
@@@ -884,8 -884,7 +884,8 @@@ static const struct file_operations pri
        .fsync =        printer_fsync,
        .poll =         printer_poll,
        .unlocked_ioctl = printer_ioctl,
 -      .release =      printer_close
 +      .release =      printer_close,
 +      .llseek =       noop_llseek,
  };
  
  /*-------------------------------------------------------------------------*/
@@@ -1348,7 -1347,7 +1348,7 @@@ printer_unbind(struct usb_gadget *gadge
        set_gadget_data(gadget, NULL);
  }
  
- static int __ref
+ static int __init
  printer_bind(struct usb_gadget *gadget)
  {
        struct printer_dev      *dev;
@@@ -1544,7 -1543,6 +1544,6 @@@ static struct usb_gadget_driver printer
        .speed          = DEVSPEED,
  
        .function       = (char *) driver_desc,
-       .bind           = printer_bind,
        .unbind         = printer_unbind,
  
        .setup          = printer_setup,
@@@ -1580,11 -1578,11 +1579,11 @@@ init(void
                return status;
        }
  
-       status = usb_gadget_register_driver(&printer_driver);
+       status = usb_gadget_probe_driver(&printer_driver, printer_bind);
        if (status) {
                class_destroy(usb_gadget_class);
                unregister_chrdev_region(g_printer_devno, 1);
-               DBG(dev, "usb_gadget_register_driver %x\n", status);
+               DBG(dev, "usb_gadget_probe_driver %x\n", status);
        }
  
        return status;
index 9b50db2570194404313c2b894227cc0dd3dba4c8,8ed8d05750d42a587599b97c803e81eb4998cc84..3756641987762f3ff196bcb16601610a164a883a
@@@ -374,7 -374,7 +374,7 @@@ static ssize_t iowarrior_write(struct f
        case USB_DEVICE_ID_CODEMERCS_IOWPV2:
        case USB_DEVICE_ID_CODEMERCS_IOW40:
                /* IOW24 and IOW40 use a synchronous call */
-               buf = kmalloc(8, GFP_KERNEL);   /* 8 bytes are enough for both products */
+               buf = kmalloc(count, GFP_KERNEL);
                if (!buf) {
                        retval = -ENOMEM;
                        goto exit;
@@@ -730,7 -730,6 +730,7 @@@ static const struct file_operations iow
        .open = iowarrior_open,
        .release = iowarrior_release,
        .poll = iowarrior_poll,
 +      .llseek = noop_llseek,
  };
  
  static char *iowarrior_devnode(struct device *dev, mode_t *mode)
index 891c20e3bb380c23eaade72d084db909988057e9,160b3c60c0c4c497d713a2e758d3352d90273cc8..37b57c785cc730eca86e98fc4d01323d7579dc34
@@@ -177,6 -177,7 +177,7 @@@ static struct usb_device_id id_table_co
        { USB_DEVICE(FTDI_VID, FTDI_OPENDCC_SNIFFER_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_OPENDCC_THROTTLE_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_OPENDCC_GATEWAY_PID) },
+       { USB_DEVICE(FTDI_VID, FTDI_OPENDCC_GBM_PID) },
        { USB_DEVICE(INTERBIOMETRICS_VID, INTERBIOMETRICS_IOBOARD_PID) },
        { USB_DEVICE(INTERBIOMETRICS_VID, INTERBIOMETRICS_MINI_IOBOARD_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_SPROG_II) },
        { USB_DEVICE(FTDI_VID, FTDI_RRCIRKITS_LOCOBUFFER_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_ASK_RDR400_PID) },
        { USB_DEVICE(ICOM_ID1_VID, ICOM_ID1_PID) },
-       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_TMU_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_ACG_HFDUAL_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_YEI_SERVOCENTER31_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_THORLABS_PID) },
                .driver_info = (kernel_ulong_t)&ftdi_jtag_quirk },
        { USB_DEVICE(RATOC_VENDOR_ID, RATOC_PRODUCT_ID_USB60F) },
        { USB_DEVICE(FTDI_VID, FTDI_REU_TINY_PID) },
+       /* Papouch devices based on FTDI chip */
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_SB485_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_AP485_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_SB422_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_SB485_2_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_AP485_2_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_SB422_2_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_SB485S_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_SB485C_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_LEC_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_SB232_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_TMU_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_IRAMP_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_DRAK5_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_QUIDO8x8_PID) },
        { USB_DEVICE(PAPOUCH_VID, PAPOUCH_QUIDO4x4_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_QUIDO2x2_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_QUIDO10x1_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_QUIDO30x3_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_QUIDO60x3_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_QUIDO2x16_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_QUIDO3x32_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_DRAK6_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_UPSUSB_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_MU_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_SIMUKEY_PID) },
        { USB_DEVICE(PAPOUCH_VID, PAPOUCH_AD4USB_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_GMUX_PID) },
+       { USB_DEVICE(PAPOUCH_VID, PAPOUCH_GMSR_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_DOMINTELL_DGQG_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_DOMINTELL_DUSB_PID) },
        { USB_DEVICE(ALTI2_VID, ALTI2_N3_PID) },
        { USB_DEVICE(FTDI_VID, XVERVE_SIGNALYZER_SH4_PID),
                .driver_info = (kernel_ulong_t)&ftdi_jtag_quirk },
        { USB_DEVICE(FTDI_VID, SEGWAY_RMP200_PID) },
+       { USB_DEVICE(FTDI_VID, ACCESIO_COM4SM_PID) },
        { USB_DEVICE(IONICS_VID, IONICS_PLUGCOMPUTER_PID),
                .driver_info = (kernel_ulong_t)&ftdi_jtag_quirk },
        { USB_DEVICE(FTDI_VID, FTDI_CHAMSYS_24_MASTER_WING_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_CHAMSYS_MAXI_WING_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_CHAMSYS_MEDIA_WING_PID) },
        { USB_DEVICE(FTDI_VID, FTDI_CHAMSYS_WING_PID) },
+       { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_LOGBOOKML_PID) },
+       { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_LS_LOGBOOK_PID) },
+       { USB_DEVICE(FTDI_VID, FTDI_SCIENCESCOPE_HS_LOGBOOK_PID) },
        { },                                    /* Optional parameter entry */
        { }                                     /* Terminating entry */
  };
@@@ -1559,6 -1592,7 +1592,7 @@@ static int ftdi_sio_port_probe(struct u
        ftdi_set_max_packet_size(port);
        if (read_latency_timer(port) < 0)
                priv->latency = 16;
+       write_latency_timer(port);
        create_sysfs_attrs(port);
        return 0;
  }
@@@ -1687,8 -1721,6 +1721,6 @@@ static int ftdi_open(struct tty_struct 
  
        dbg("%s", __func__);
  
-       write_latency_timer(port);
        /* No error checking for this (will get errors later anyway) */
        /* See ftdi_sio.h for description of what is reset */
        usb_control_msg(dev, usb_sndctrlpipe(dev, 0),
@@@ -2028,8 -2060,6 +2060,6 @@@ static void ftdi_set_termios(struct tty
                                "urb failed to set to rts/cts flow control\n");
                }
  
-               /* raise DTR/RTS */
-               set_mctrl(port, TIOCM_DTR | TIOCM_RTS);
        } else {
                /*
                 * Xon/Xoff code
                        }
                }
  
-               /* lower DTR/RTS */
-               clear_mctrl(port, TIOCM_DTR | TIOCM_RTS);
        }
        return;
  }
@@@ -2168,7 -2196,6 +2196,7 @@@ static int ftdi_ioctl(struct tty_struc
         * - mask passed in arg for lines of interest
         *   (use |'ed TIOCM_RNG/DSR/CD/CTS for masking)
         * Caller should use TIOCGICOUNT to see which one it was.
 +       * (except that the driver doesn't support it !)
         *
         * This code is borrowed from linux/drivers/char/serial.c
         */
diff --combined include/scsi/scsi.h
index d63533a4a59e6b658ae82041d57e19350438b442,1418e9010f3e6c4be4cfce67ab645bfa2eeca1af..216af8538cc9383c0732b0c3fc260f33150f65c7
@@@ -31,12 -31,6 +31,12 @@@ struct scsi_cmnd
  #define SCSI_MAX_SG_CHAIN_SEGMENTS    SCSI_MAX_SG_SEGMENTS
  #endif
  
 +/*
 + * DIX-capable adapters effectively support infinite chaining for the
 + * protection information scatterlist
 + */
 +#define SCSI_MAX_PROT_SG_SEGMENTS     0xFFFF
 +
  /*
   * Special value for scanning to specify scanning or rescanning of all
   * possible channels, (target) ids, or luns on a given shost.
@@@ -73,6 -67,7 +73,7 @@@
  #define SEND_DIAGNOSTIC       0x1d
  #define ALLOW_MEDIUM_REMOVAL  0x1e
  
+ #define READ_FORMAT_CAPACITIES 0x23
  #define SET_WINDOW            0x24
  #define READ_CAPACITY         0x25
  #define READ_10               0x28
  #define WRITE_SAME            0x41
  #define UNMAP               0x42
  #define READ_TOC              0x43
+ #define READ_HEADER           0x44
  #define LOG_SELECT            0x4c
  #define LOG_SENSE             0x4d
  #define XDWRITEREAD_10        0x53