1. 18 6月, 2013 1 次提交
  2. 10 6月, 2013 22 次提交
  3. 29 5月, 2013 1 次提交
  4. 15 5月, 2013 1 次提交
  5. 26 4月, 2013 2 次提交
    • A
      USB: OMAP: ISP1301 needs USB_PHY · c3c683ea
      Arnd Bergmann 提交于
      The Kconfig entry for USB_OMAP unconditionally selects USB_ISP1301,
      which is now only visible when USB_PHY is also enabled.
      
      This adds an appropriate dependency and enables USB_PHY in the omap1
      defconfig, avoiding these build warnings:
      
      warning: (USB_OHCI_HCD && USB_OMAP) selects ISP1301_OMAP which has unmet direct dependencies (USB_SUPPORT && USB_PHY && I2C && ARCH_OMAP_OTG)
      
      Also fix a Makefile typo while we're at it.
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Cc: Felipe Balbi <balbi@ti.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      c3c683ea
    • A
      USB: lpc32xx: ISP1301 needs USB_PHY · 64e98a79
      Arnd Bergmann 提交于
      The Kconfig entry for USB_LPC32XX unconditionally selects USB_ISP1301,
      which is now only visible when USB_PHY is also enabled.
      
      This adds an appropriate dependency and enables USB_PHY in the msm
      defconfig, avoiding these build errors:
      
      warning: (USB_LPC32XX) selects USB_ISP1301 which has unmet direct dependencies (USB_SUPPORT && USB_PHY && (USB || USB_GADGET) && I2C)
      drivers/built-in.o: In function `usb_hcd_nxp_probe':
      drivers/usb/host/ohci-nxp.c:224: undefined reference to `isp1301_get_client'
      drivers/built-in.o: In function `lpc32xx_udc_probe':
      drivers/usb/gadget/lpc32xx_udc.c:3071: undefined reference to `isp1301_get_client'
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Cc: Felipe Balbi <balbi@ti.com>
      Cc: Roland Stigge <stigge@antcom.de>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      64e98a79
  6. 03 4月, 2013 6 次提交
    • A
      usb: gadget: serial: convert to new interface of f_obex · d1412794
      Andrzej Pietrasiewicz 提交于
      f_obex is now a self-contained module. We need to teach
      serial.c about it.
      Signed-off-by: NAndrzej Pietrasiewicz <andrzej.p@samsung.com>
      Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      d1412794
    • A
      usb: gadget: f_obex: convert to new function interface with backward compatibility · 1d8fc251
      Andrzej Pietrasiewicz 提交于
      Converting f_obex to the new function interface requires converting
      the f_obex's function code and its users.
      
      This patch converts the f_obex.c to the new function interface.
      The file is now compiled into a separate usb_f_obex.ko module.
      
      The old function interface is provided by means of preprocessor
      conditional directives. After all users are converted, the old interface
      can be removed.
      Signed-off-by: NAndrzej Pietrasiewicz <andrzej.p@samsung.com>
      Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      1d8fc251
    • A
    • A
      usb: gadget: f_serial: convert to new function interface with backward compatibility · 60540ea2
      Andrzej Pietrasiewicz 提交于
      Converting f_serial to the new function interface requires converting
      the f_serial's function code and its users.
      
      This patch converts the f_serial.c to the new function interface.
      
      The file is now compiled into a separate usb_f_serial.ko module.
      The old function interface is provided by means of preprocessor
      conditional directives. After all users are converted, the old interface
      can be removed.
      Signed-off-by: NAndrzej Pietrasiewicz <andrzej.p@samsung.com>
      Signed-off-by: NKyungmin Park <kyungmin.park@samsung.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      60540ea2
    • S
      usb: gadget: the start of the configfs interface · 88af8bbe
      Sebastian Andrzej Siewior 提交于
      |# modprobe dummy_hcd num=2
      |# modprobe libcomposite
      
      |# lsmod
      |Module                  Size  Used by
      |libcomposite           31648  0
      |dummy_hcd              19871  0
      
      |# mkdir /sys/kernel/config/usb_gadget/oha
      |# cd /sys/kernel/config/usb_gadget/oha
      |# mkdir configs/def.1
      |# mkdir configs/def.2
      |# mkdir functions/acm.ttyS1
      |# mkdir strings/0x1
      |mkdir: cannot create directory `strings/0x1': Invalid argument
      |# mkdir strings/0x409
      |# mkdir strings/1033
      |mkdir: cannot create directory `strings/1033': File exists
      |# mkdir strings/1032
      |# mkdir configs/def.1/strings/0x409
      |# mkdir configs/def.2/strings/0x409
      
      |#find . -ls
      |   975    0 drwxr-xr-x   5 root     root            0 Dec 23 17:40 .
      |   978    0 drwxr-xr-x   4 root     root            0 Dec 23 17:43 ./strings
      |  4100    0 drwxr-xr-x   2 root     root            0 Dec 23 17:43 ./strings/1032
      |   995    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./strings/1032/serialnumber
      |   996    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./strings/1032/product
      |   997    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./strings/1032/manufacturer
      |  2002    0 drwxr-xr-x   2 root     root            0 Dec 23 17:41 ./strings/0x409
      |   998    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./strings/0x409/serialnumber
      |   999    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./strings/0x409/product
      |  1000    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./strings/0x409/manufacturer
      |   977    0 drwxr-xr-x   4 root     root            0 Dec 23 17:41 ./configs
      |  4081    0 drwxr-xr-x   3 root     root            0 Dec 23 17:41 ./configs/def.2
      |  4082    0 drwxr-xr-x   3 root     root            0 Dec 23 17:42 ./configs/def.2/strings
      |  2016    0 drwxr-xr-x   2 root     root            0 Dec 23 17:42 ./configs/def.2/strings/0x409
      |  1001    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./configs/def.2/strings/0x409/configuration
      |  1002    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./configs/def.2/bmAttributes
      |  1003    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./configs/def.2/MaxPower
      |   979    0 drwxr-xr-x   3 root     root            0 Dec 23 17:42 ./configs/def.1
      |   980    0 drwxr-xr-x   3 root     root            0 Dec 23 17:42 ./configs/def.1/strings
      |  5122    0 drwxr-xr-x   2 root     root            0 Dec 23 17:42 ./configs/def.1/strings/0x409
      |  1004    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./configs/def.1/strings/0x409/configuration
      |  1005    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./configs/def.1/bmAttributes
      |  1006    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./configs/def.1/MaxPower
      |   976    0 drwxr-xr-x   3 root     root            0 Dec 23 17:41 ./functions
      |   981    0 drwxr-xr-x   2 root     root            0 Dec 23 17:41 ./functions/acm.ttyS1
      |  1007    0 -r--r--r--   1 root     root         4096 Dec 23 17:43 ./functions/acm.ttyS1/port_num
      |  1008    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./UDC
      |  1009    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./bcdUSB
      |  1010    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./bcdDevice
      |  1011    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./idProduct
      |  1012    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./idVendor
      |  1013    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./bMaxPacketSize0
      |  1014    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./bDeviceProtocol
      |  1015    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./bDeviceSubClass
      |  1016    0 -rw-r--r--   1 root     root         4096 Dec 23 17:43 ./bDeviceClass
      
      |# cat functions/acm.ttyS1/port_num
      |0
      |# ls -lah /dev/ttyGS*
      |crw-rw---T 1 root dialout 252, 0 Dec 23 17:41 /dev/ttyGS0
      |
      |# echo 0x1234 > idProduct
      |# echo 0xabcd > idVendor
      |# echo 1122 > strings/0x409/serialnumber
      |# echo "The manufacturer" > strings/0x409/manufacturer
      |# echo 1 > strings/1032/manufacturer
      |# echo 1sa > strings/1032/product
      |# echo tada > strings/1032/serialnumber
      |echo "Primary configuration" > configs/def.1/strings/0x409/configuration
      |# echo "Secondary configuration" > configs/def.2/strings/0x409/configuration
      |# ln -s functions/acm.ttyS1 configs/def.1/
      |# ln -s functions/acm.ttyS1 configs/def.2/
      |find configs/def.1/ -ls
      |   979    0 drwxr-xr-x   3 root     root            0 Dec 23 17:49 configs/def.1/
      |  6264    0 lrwxrwxrwx   1 root     root            0 Dec 23 17:48 configs/def.1/acm.ttyS1 -> ../../../../usb_gadget/oha/functions/acm.ttyS1
      |   980    0 drwxr-xr-x   3 root     root            0 Dec 23 17:42 configs/def.1/strings
      |  5122    0 drwxr-xr-x   2 root     root            0 Dec 23 17:49 configs/def.1/strings/0x409
      |  6284    0 -rw-r--r--   1 root     root         4096 Dec 23 17:47 configs/def.1/strings/0x409/configuration
      |  6285    0 -rw-r--r--   1 root     root         4096 Dec 23 17:49 configs/def.1/bmAttributes
      |  6286    0 -rw-r--r--   1 root     root         4096 Dec 23 17:49 configs/def.1/MaxPower
      |
      |echo 120 > configs/def.1/MaxPower
      |
      |# ls -lh /sys/class/udc/
      |total 0
      |lrwxrwxrwx 1 root root 0 Dec 23 17:50 dummy_udc.0 -> ../../devices/platform/dummy_udc.0/udc/dummy_udc.0
      |lrwxrwxrwx 1 root root 0 Dec 23 17:50 dummy_udc.1 -> ../../devices/platform/dummy_udc.1/udc/dummy_udc.1
      |# echo dummy_udc.0 > UDC
      |# lsusb
      |Bus 001 Device 002: ID abcd:1234 Unknown
      |
      |lsusb -d abcd:1234 -v
      |Device Descriptor:
      …
      |  idVendor           0xabcd Unknown
      |  idProduct          0x1234
      |  bcdDevice            3.06
      |  iManufacturer           1 The manufacturer
      |  iProduct                2
      |  iSerial                 3 1122
      |  bNumConfigurations      2
      …
      |echo "" > UDC
      
      v5…v6
      - wired up strings with usb_gstrings_attach()
      - add UDC attribe. Write "udc-name" will bind the gadget. Write an empty
        string (it should contain \n since 0 bytes write get optimzed away)
        will unbind the UDC from the gadget. The name of available UDCs can be
        obtained from /sys/class/udc/
      
      v4…v5
      - string rework. This will add a strings folder incl. language code like
          strings/409/manufacturer
        as suggested by Alan.
      - rebased ontop reworked functions.c which has usb_function_instance
        which is used prior after "mkdir acm.instance" and can be directly
        used for configuration via configfs.
      
      v3…v4
       - moved functions from the root folde down to the gadget as suggested
         by Michał
       - configs have now their own configs folder as suggested by Michał.
         The folder is still name.bConfigurationValue where name becomes the
         sConfiguration. Is this usefull should we just stilc
         configs/bConfigurationValue/ ?
       - added configfs support to the ACM function. The port_num attribute is
         exported by f_acm. An argument has been added to the USB alloc
         function to distinguish between "old" (use facm_configure() to
         configure and configfs interface (expose a config_node).
         The port_num is currently a dumb counter. It will
         require some function re-work to make it work.
      
      scheduled for v5:
      - sym linking function into config.
      
      v2…v3
      - replaced one ifndef by ifdef as suggested by Micahał
      - strstr()/strchr() function_make as suggested by Micahł
      - replace [iSerialNumber|iProduct|iManufacturer] with
        [sSerialNumber|sProduct|sManufacturer] as suggested by Alan
      - added creation of config descriptors
      
      v1…v2
      - moved gadgets from configfs' root directory into /udcs/ within our
        "usb_gadget" folder. Requested by Andrzej & Michał
      - use a dot as a delimiter between function's name and its instance's name
        as suggested by Michał
      - renamed all config_item_type, configfs_group_operations, make_group,
        drop_item as suggested by suggested by Andrzej to remain consisten
        within this file and within other configfs users
      - Since configfs.c and functions.c are now part of the udc-core module,
        the module itself is now called udc. Also added a tiny ifdef around
        init code becuase udc-core is subsys init and this is too early for
        configfs in the built-in case. In the module case, we can only have
        one init function.
      Signed-off-by: NSebastian Andrzej Siewior <bigeasy@linutronix.de>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      88af8bbe
    • S
      usb: gadget: nokia: use function framework for ACM · 15761826
      Sebastian Andrzej Siewior 提交于
      This patch converts the acm_ms gadget to make use of the function
      framework to request the ACM function.
      
      The "old" include interface for acm is now removed since nokia was the
      last user of it (for ACM).
      Signed-off-by: NSebastian Andrzej Siewior <bigeasy@linutronix.de>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      15761826
  7. 02 4月, 2013 1 次提交
    • B
      usb: gadget/uvc: Port UVC webcam gadget to use videobuf2 framework · d6925225
      Bhupesh Sharma 提交于
      This patch reworks the videobuffer management logic present in the UVC
      webcam gadget and ports it to use the "more apt" videobuf2 framework for
      video buffer management.
      
      To support routing video data captured from a real V4L2 video capture
      device with a "zero copy" operation on videobuffers (as they pass from
      the V4L2 domain to UVC domain via a user-space application), we need to
      support USER_PTR IO method at the UVC gadget side.
      
      So the V4L2 capture device driver can still continue to use MMAP IO
      method and now the user-space application can just pass a pointer to the
      video buffers being dequeued from the V4L2 device side while queueing
      them at the UVC gadget end. This ensures that we have a "zero-copy"
      design as the videobuffers pass from the V4L2 capture device to the UVC
      gadget.
      
      Note that there will still be a need to apply UVC specific payload
      headers on top of each UVC payload data, which will still require a copy
      operation to be performed in the 'encode' routines of the UVC gadget.
      
      This patch also addresses one issue found out while porting the UVC
      gadget to videobuf2 framework:
      	- In case the usb requests queued by the gadget get completed
      	  with a status of -ESHUTDOWN (disconnected from host),
      	  the queue of videobuf2 should be cancelled to ensure that the
      	  application space daemon is not left in a state waiting for
      	  a vb2 to be successfully absorbed at the USB side.
      Signed-off-by: NBhupesh Sharma <bhupesh.sharma@st.com>
      Signed-off-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      d6925225
  8. 27 3月, 2013 2 次提交
    • R
      usb: Fix compile error by selecting USB_OTG_UTILS · c8fa48d3
      Roland Stigge 提交于
      The current lpc32xx_defconfig breaks like this, caused by recent phy
      restructuring:
      
        LD      init/built-in.o
      drivers/built-in.o: In function `usb_hcd_nxp_probe':
      drivers/usb/host/ohci-nxp.c:224: undefined reference to `isp1301_get_client'
      drivers/built-in.o: In function `lpc32xx_udc_probe':
      drivers/usb/gadget/lpc32xx_udc.c:3104: undefined reference to
      `isp1301_get_client' distcc[27867] ERROR: compile (null) on localhost failed
      make: *** [vmlinux] Error 1
      
      Caused by 1c208881 (usb: Makefile: fix
      drivers/usb/phy/ Makefile entry)
      
      This patch fixes this by selecting USB_OTG_UTILS in Kconfig which
      causes the phy driver to be built again.
      Signed-off-by: NRoland Stigge <stigge@antcom.de>
      Acked-by: NFelipe Balbi <balbi@ti.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      c8fa48d3
    • F
      usb: gadget: mv_u3d: drop ARCH dependency · 60630c2e
      Felipe Balbi 提交于
      this driver compiles fine everywhere which
      means we can use linux-next to compile it
      for us frequently.
      
      By dropping the arch dependency, we also
      ensure driver writers don't add virtual
      arch-depdencies to the driver by e.g. using
      the wrong headers.
      
      While at that, fix Marvell's USB3 PHY dependency,
      that's the driver which depends on CPU_MM3, not
      mv_u3d_core.
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      60630c2e
  9. 22 3月, 2013 1 次提交
  10. 18 3月, 2013 2 次提交
  11. 09 2月, 2013 1 次提交