1. 20 Oct, 2013 9 commits
    • Troy Kisky's avatar
      usb: gadget: mv_udc: fix typo in error message · d0928794
      Troy Kisky authored
      
      
      Change 'nfo=' to 'info='
      Signed-off-by: default avatarTroy Kisky <troy.kisky@boundarydevices.com>
      d0928794
    • Troy Kisky's avatar
      usb: gadget: ether: return error from rx_submit if no request · 71fc5f91
      Troy Kisky authored
      
      
      This prevents a crash if tftpboot is given a bad filename.
      
      rx_req will be released by eth_reset_config
      which is called by eth_disconnect,
      which is called using the .disconnect member of usb_gadget_driver by mv_pullup in mv_udc
      which is called using the .pullup member of usb_gadget_ops by usb_gadget_disconnect
      which is called by usb_eth_halt
      which is called using the .halt member of eth_device by eth_halt
      which is called by TftpHandler when TFTP_ERR_FILE_NOT_FOUND or TFTP_ERR_ACCESS_DENIED occurs
      
      I trigger this with the following commands
      setenv ipaddr 10.0.0.2 && setenv netmask 255.255.255.0 && setenv serverip 10.0.0.1
      setenv usbnet_devaddr 00:11:22:33:44:55 && setenv usbnet_hostaddr 00:aa:bb:cc:dd:ee
      setenv ethprime usb_ether && setenv ethact usb_ether && setenv ncip 10.0.0.1
      tftpboot 10800000 10.0.0.1:missing_file
      Signed-off-by: default avatarTroy Kisky <troy.kisky@boundarydevices.com>
      71fc5f91
    • Troy Kisky's avatar
      usb: gadget: ether set wMaxPacketSize · 43880ce5
      Troy Kisky authored
      
      
      set wMaxPacketSize for full speed descriptors
      fs_source_desc, fs_sink_desc to 64.
      
      Full-speed bulk endpoint can have a maximum packet size of
      8, 16, 32, or 64 bytes, so choice 64.
      
      The hs_source_desc, hs_sink_desc, already have their wMaxPacketSize
      set to 512. That is the only legal value for high speed bulk endpoints.
      
      Strictly speaking, this patch is not needed because
      usb_ep_autoconfig will call ep_matches which will
      override wMaxPacketSize for BULK endpoints only with
      the size associated with the endpoint setup by the udc driver.
      But if you want to rely on this, you may as well combine the
      full speed descriptor with the high speed descriptor to
      minimize confusion.
      Signed-off-by: default avatarTroy Kisky <troy.kisky@boundarydevices.com>
      43880ce5
    • Dan Murphy's avatar
      OMAP5: USB: Add OMAP xHCI file and header · 2d2358ac
      Dan Murphy authored
      
      
      Add the OMAP file for the xHCI Host controller
      This code will initilialize the proper components within the
      OMAP5 to enable the xHCI host controller.
      Signed-off-by: default avatarDan Murphy <dmurphy@ti.com>
      2d2358ac
    • Dan Murphy's avatar
      ARM: OMAP5: Power: Add new function to turn on SMPS10 · 1bd435bc
      Dan Murphy authored
      
      
      Add new functionality to turn on SMPS10 regulator.
      This supplies the VBUS to devices connected to the
      USB host ports
      Signed-off-by: default avatarDan Murphy <dmurphy@ti.com>
      1bd435bc
    • Julius Werner's avatar
      exynos: usb: Switch USB VBUS GPIOs to be device tree configured · 4a271cb1
      Julius Werner authored
      
      
      Some Exynos boards, such as the SMDK5250, control USB port power through
      a GPIO pin. For now this had been hardcoded in the exynos5-dt board
      file, but not all boards use the same pin, requiring local changes to
      support different boards.
      
      This patch moves the GPIO initialization into the USB host controller
      drivers which they belong to, and uses the samsung,vbus-gpio parameter
      in the device tree to configure it.
      Signed-off-by: default avatarJulius Werner <jwerner@chromium.org>
      Signed-off-by: default avatarVivek Gautam <gautam.vivek@samsung.com>
      Cc: Simon Glass <sjg@chromium.org>
      Cc: Minkyu Kang <mk7.kang@samsung.com>
      Cc: Marek Vasut <marex@denx.de>
      4a271cb1
    • Vivek Gautam's avatar
      USB: XHCI: Add xHCI host controller support for Exynos5 · 13194f3b
      Vivek Gautam authored
      
      
      This adds driver layer for xHCI controller in Samsung's
      exynos5 soc. This interacts with xHCI host controller stack.
      Signed-off-by: default avatarVikas C Sajjan <vikas.sajjan@samsung.com>
      Signed-off-by: default avatarVivek Gautam <gautam.vivek@samsung.com>
      Cc: Julius Werner <jwerner@chromium.org>
      Cc: Simon Glass <sjg@chromium.org>
      Cc: Minkyu Kang <mk7.kang@samsung.com>
      Cc: Dan Murphy <dmurphy@ti.com>
      Cc: Marek Vasut <marex@denx.de>
      13194f3b
    • Vivek Gautam's avatar
      USB: xHCI: Add stack support for xHCI · 5853e133
      Vivek Gautam authored
      
      
      This adds stack layer for eXtensible Host Controller Interface
      which facilitates use of USB 3.0 in host mode.
      
      Adapting xHCI host controller driver in linux-kernel
      by Sarah Sharp to needs in u-boot.
      
      Initial porting from Linux kernel version 3.4, with following
      top commit history of drivers/usb/host/xhci* :
      cf84055 xHCI: Cleanup isoc transfer ring when TD length mismatch found
      
      This adds the basic xHCI host controller driver with bare minimum
      features:
      - Control/Bulk transfer support has been added with required
        infrastructure for necessary xHC data structures.
      - Stream protocol hasn't been supported yet.
      - No support for quirky devices has been added.
      Signed-off-by: default avatarVikas C Sajjan <vikas.sajjan@samsung.com>
      Signed-off-by: default avatarJulius Werner <jwerner@chromium.org>
      Signed-off-by: default avatarVivek Gautam <gautam.vivek@samsung.com>
      Cc: Simon Glass <sjg@chromium.org>
      Cc: Minkyu Kang <mk7.kang@samsung.com>
      Cc: Dan Murphy <dmurphy@ti.com>
      Cc: Marek Vasut <marex@denx.de>
      5853e133
    • Vivek Gautam's avatar
      usb: Move 'bmRequestType' USB device request macros from EHCI header · e3d7440c
      Vivek Gautam authored
      
      
      Macros defining bmRequestType field of USB device request,
      given in table 9.2 USB 2.0 spec, are rather generic macros
      which can be further used by other Host controller stacks.
      So moving them to usb_defs header.
      Signed-off-by: default avatarVivek Gautam <gautam.vivek@samsung.com>
      Cc: Julius Werner <jwerner@chromium.org>
      Cc: Simon Glass <sjg@chromium.org>
      Cc: Minkyu Kang <mk7.kang@samsung.com>
      Cc: Dan Murphy <dmurphy@ti.com>
      Cc: Marek Vasut <marex@denx.de>
      e3d7440c
  2. 16 Oct, 2013 1 commit
  3. 15 Oct, 2013 6 commits
  4. 14 Oct, 2013 4 commits
  5. 10 Oct, 2013 1 commit
  6. 09 Oct, 2013 1 commit
    • Paul Burton's avatar
      mtd: driver _read() returns max_bitflips; mtd_read() returns -EUCLEAN · 40462e54
      Paul Burton authored
      
      
      Linux modified the MTD driver interface in commit edbc4540 (with the
      same name as this commit). The effect is that calls to mtd_read will
      not return -EUCLEAN if the number of ECC-corrected bit errors is below
      a certain threshold, which defaults to the strength of the ECC. This
      allows -EUCLEAN to stop indicating "some bits were corrected" and begin
      indicating "a large number of bits were corrected, the data held in
      this region of flash may be lost soon". UBI makes use of this and when
      -EUCLEAN is returned from mtd_read it will move data to another block
      of flash. Without adopting this interface change UBI on U-boot attempts
      to move data between blocks every time a single bit is corrected using
      the ECC, which is a very common occurance on some devices.
      
      For some devices where bit errors are common enough, UBI can get stuck
      constantly moving data around because each block it attempts to use has
      a single bit error. This condition is hit when wear_leveling_worker
      attempts to move data from one PEB to another in response to an
      -EUCLEAN/UBI_IO_BITFLIPS error. When this happens ubi_eba_copy_leb is
      called to perform the data copy, and after the data is written it is
      read back to check its validity. If that read returns UBI_IO_BITFLIPS
      (in response to an MTD -EUCLEAN) then ubi_eba_copy_leb returns 1 to
      wear_leveling worker, which then proceeds to schedule the destination
      PEB for erasure. This leads to erase_worker running on the PEB, and
      following a successful erase wear_leveling_worker is called which
      begins this whole cycle all over again. The end result is that (without
      UBI debug output enabled) the boot appears to simply hang whilst in
      reality U-boot busily works away at destroying a block of the NAND
      flash. Debug output from this situation:
      
        UBI DBG: ensure_wear_leveling: schedule scrubbing
        UBI DBG: wear_leveling_worker: scrub PEB 1027 to PEB 4083
        UBI DBG: ubi_io_read_vid_hdr: read VID header from PEB 1027
        UBI DBG: ubi_io_read: read 4096 bytes from PEB 1027:4096
        UBI DBG: ubi_eba_copy_leb: copy LEB 0:0, PEB 1027 to PEB 4083
        UBI DBG: ubi_eba_copy_leb: read 1040384 bytes of data
        UBI DBG: ubi_io_read: read 1040384 bytes from PEB 1027:8192
        UBI: fixable bit-flip detected at PEB 1027
        UBI DBG: ubi_io_write_vid_hdr: write VID header to PEB 4083
        UBI DBG: ubi_io_write: write 4096 bytes to PEB 4083:4096
        UBI DBG: ubi_io_read_vid_hdr: read VID header from PEB 4083
        UBI DBG: ubi_io_read: read 4096 bytes from PEB 4083:4096
        UBI DBG: ubi_io_write: write 4096 bytes to PEB 4083:8192
        UBI DBG: ubi_io_read: read 4096 bytes from PEB 4083:8192
        UBI: fixable bit-flip detected at PEB 4083
        UBI DBG: schedule_erase: schedule erasure of PEB 4083, EC 55, torture 0
        UBI DBG: erase_worker: erase PEB 4083 EC 55
        UBI DBG: sync_erase: erase PEB 4083, old EC 55
        UBI DBG: do_sync_erase: erase PEB 4083
        UBI DBG: sync_erase: erased PEB 4083, new EC 56
        UBI DBG: ubi_io_write_ec_hdr: write EC header to PEB 4083
        UBI DBG: ubi_io_write: write 4096 bytes to PEB 4083:0
        UBI DBG: ensure_wear_leveling: schedule scrubbing
        UBI DBG: wear_leveling_worker: scrub PEB 1027 to PEB 4083
        ...
      
      This patch adopts the interface change as in Linux commit edbc4540 in
      order to avoid such situations. Given that none of the drivers under
      drivers/mtd return -EUCLEAN, this should only affect those using
      software ECC. I have tested that it works on a board which is
      currently out of tree, but which I hope to be able to begin
      upstreaming soon.
      Signed-off-by: default avatarPaul Burton <paul.burton@imgtec.com>
      Acked-by: default avatarStefan Roese <sr@denx.de>
      40462e54
  7. 08 Oct, 2013 3 commits
  8. 07 Oct, 2013 15 commits