Re: [PATCH net-next 0/4] r8152: firmware support

2014-08-22 Thread David Miller
From: Hayes Wang Date: Wed, 20 Aug 2014 16:58:35 +0800 > Parsing, checking, and writing the firmware. You haven't told us why you need to do this. These are just programming registers in the chip, and I see no reason to not keep these in the driver with real code. I'm not applying this series,

Re: [PATCH v2 2/3] usb: Add LED trigger for USB host activity

2014-08-22 Thread Bryan Wu
On Fri, Aug 22, 2014 at 5:08 PM, Michal Sojka wrote: > With this patch, USB host activity can be signaled by blinking a LED. > > This should work with all host controllers. Tested only with musb. > > Signed-off-by: Michal Sojka > --- > drivers/usb/core/Kconfig | 9 + > drivers/usb/core

Re: [PATCH v2 0/3] LED triggers for USB host and device

2014-08-22 Thread Bryan Wu
On Fri, Aug 22, 2014 at 5:08 PM, Michal Sojka wrote: > This adds LED triggers for USB host and device. > > Changes from v1: > - Moved from drivers/leds/ to drivers/usb/ > - Improved Kconfig help > - Linked with other modules rather than being standalone modules > > Michal Sojka (3): > usb: Add m

[PATCH v2 1/3] usb: Add missing #include

2014-08-22 Thread Michal Sojka
linux/usb/hcd.h needs the definition of struct usb_bus. Signed-off-by: Michal Sojka --- include/linux/usb/hcd.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/linux/usb/hcd.h b/include/linux/usb/hcd.h index 485cd5e..b43f0fe 100644 --- a/include/linux/usb/hcd.h +++ b/include/linux/us

[PATCH v2 3/3] usb: Add LED trigger for USB gadget activity

2014-08-22 Thread Michal Sojka
With this patch, USB gadget activity can be signaled by blinking a LED. Since there is no generic code where to put the trigger for all USB controllers, each USB controller needs to call the trigger individually. This patch adds the call only for the musb controller where I can test it. Signed-of

[PATCH v2 0/3] LED triggers for USB host and device

2014-08-22 Thread Michal Sojka
This adds LED triggers for USB host and device. Changes from v1: - Moved from drivers/leds/ to drivers/usb/ - Improved Kconfig help - Linked with other modules rather than being standalone modules Michal Sojka (3): usb: Add missing #include usb: Add LED trigger for USB host activity usb: Ad

[PATCH v2 2/3] usb: Add LED trigger for USB host activity

2014-08-22 Thread Michal Sojka
With this patch, USB host activity can be signaled by blinking a LED. This should work with all host controllers. Tested only with musb. Signed-off-by: Michal Sojka --- drivers/usb/core/Kconfig | 9 + drivers/usb/core/Makefile | 1 + drivers/usb/core/hcd.c| 2 ++ drivers/usb/cor

Re: [PATCH 1/2] leds: usb: Add LED trigger for USB gadget activity

2014-08-22 Thread Michal Sojka
On Fri, Aug 22 2014, Greg Kroah-Hartman wrote: > On Fri, Aug 22, 2014 at 10:39:03AM -0700, Bryan Wu wrote: >> On Fri, Aug 22, 2014 at 4:53 AM, Michal Sojka wrote: >> > With this patch, USB gadget activity can be signaled by blinking a LED. >> > >> > Since there is no generic code where to put the

Re: [PATCH 1/2] leds: usb: Add LED trigger for USB gadget activity

2014-08-22 Thread Michal Sojka
Hi Felipe, On Fri, Aug 22 2014, Felipe Balbi wrote: > Hi, > > On Fri, Aug 22, 2014 at 01:53:12PM +0200, Michal Sojka wrote: >> With this patch, USB gadget activity can be signaled by blinking a LED. >> >> Since there is no generic code where to put the trigger for all USB >> controllers, each USB

Re: [PATCH 1/2] leds: usb: Add LED trigger for USB gadget activity

2014-08-22 Thread Bryan Wu
On Fri, Aug 22, 2014 at 2:42 PM, Greg Kroah-Hartman wrote: > On Fri, Aug 22, 2014 at 10:39:03AM -0700, Bryan Wu wrote: >> On Fri, Aug 22, 2014 at 4:53 AM, Michal Sojka wrote: >> > With this patch, USB gadget activity can be signaled by blinking a LED. >> > >> > Since there is no generic code wher

Re: [PATCH 1/2] leds: usb: Add LED trigger for USB gadget activity

2014-08-22 Thread Felipe Balbi
Hi, On Fri, Aug 22, 2014 at 01:53:12PM +0200, Michal Sojka wrote: > With this patch, USB gadget activity can be signaled by blinking a LED. > > Since there is no generic code where to put the trigger for all USB > controllers, each USB controller needs to call the trigger individually. > This pat

Re: [PATCH v2] usb: dwc3: add tracepoints to aid debugging

2014-08-22 Thread Felipe Balbi
Hi, On Fri, Aug 22, 2014 at 09:26:55PM +, Paul Zimmerman wrote: > > diff --git a/drivers/usb/dwc3/debug.c b/drivers/usb/dwc3/debug.c > > new file mode 100644 > > index 000..6d01e0c > > --- /dev/null > > +++ b/drivers/usb/dwc3/debug.c > > @@ -0,0 +1,33 @@ > > +/** > > + * debug.c - DesignWa

Re: [PATCH 1/2] leds: usb: Add LED trigger for USB gadget activity

2014-08-22 Thread Greg Kroah-Hartman
On Fri, Aug 22, 2014 at 10:39:03AM -0700, Bryan Wu wrote: > On Fri, Aug 22, 2014 at 4:53 AM, Michal Sojka wrote: > > With this patch, USB gadget activity can be signaled by blinking a LED. > > > > Since there is no generic code where to put the trigger for all USB > > controllers, each USB control

RE: [PATCH v2] usb: dwc3: add tracepoints to aid debugging

2014-08-22 Thread Paul Zimmerman
> From: Felipe Balbi [mailto:ba...@ti.com] > Sent: Friday, August 22, 2014 1:47 PM > > On Tue, Aug 19, 2014 at 11:36:05PM +, Paul Zimmerman wrote: > > > From: Felipe Balbi > > Date: Wed, 30 Apr 2014 17:45:10 -0500 > > > diff --git a/drivers/usb/dwc3/debug.c b/drivers/usb/dwc3/debug.c > > >

Re: [PATCHv2 10/13] usb: dwc2: initialize the spin_lock for both host and gadget

2014-08-22 Thread Felipe Balbi
Hi, On Fri, Aug 22, 2014 at 08:52:23PM +, Paul Zimmerman wrote: > > From: dingu...@altera.com [mailto:dingu...@altera.com] > > Sent: Wednesday, July 30, 2014 8:21 AM > > > > Move spin_lock_init to common location for both host and gadget. > > > > Signed-off-by: Dinh Nguyen > > --- > > driv

Re: [RFC PATCH 19/20] xhci: v1.0 scatterlist enqueue support (td-fragment rework)

2014-08-22 Thread Dan Williams
On Fri, Aug 22, 2014 at 10:57 AM, Alan Stern wrote: > On Fri, 22 Aug 2014, Dan Williams wrote: > >> v1.0 hosts require that TD-fragments (portions of a TD that do not end >> on a MPB boundary) not cross a TRB segment boundary. This constraint is >> in addition to the constraint that a TRB may not

RE: [PATCHv2 10/13] usb: dwc2: initialize the spin_lock for both host and gadget

2014-08-22 Thread Paul Zimmerman
> From: dingu...@altera.com [mailto:dingu...@altera.com] > Sent: Wednesday, July 30, 2014 8:21 AM > > Move spin_lock_init to common location for both host and gadget. > > Signed-off-by: Dinh Nguyen > --- > drivers/usb/dwc2/hcd.c |1 - > drivers/usb/dwc2/platform.c |1 + > 2 files c

Re: [PATCH v2] usb: dwc3: add tracepoints to aid debugging

2014-08-22 Thread Felipe Balbi
Hi, On Tue, Aug 19, 2014 at 11:36:05PM +, Paul Zimmerman wrote: > > From: Felipe Balbi [mailto:ba...@ti.com] > > Sent: Tuesday, August 19, 2014 3:02 PM > > > > I didn't have time to test this yet (other than build testing), but how > > does this one look ? Now we will print cute little string

Re: Kernel 3.16.0 USB crash

2014-08-22 Thread Hans de Goede
Hi, On 08/15/2014 09:44 AM, Claudio Bizzarri wrote: >> On Thu, Aug 14, 2014 at 11:46:33AM +0200, Hans de Goede wrote: >>> Hi, > ... >>> >>> Can you collect "lsusb -v" output for the drive in question when connected >>> through an usb-3 port (the uas module does not need to be loaded). > > Here ls

Re: [PATCH 1/1] HID: usbhid: add usb_clear_halt determination for next hid_start_in

2014-08-22 Thread Alan Stern
On Sat, 23 Aug 2014, vichy wrote: > from your patch, I have some questions: > a. in Alan's version, if both HID_CLEAR_HALT and HID_RESET_PENDING are > set, hid_reset will both "clear ep halt" and "reset devcie". > But in original one, even HID_CLEAR_HALT and HID_RESET_PENDING are > both set, hid_r

Re: [RFC PATCH 19/20] xhci: v1.0 scatterlist enqueue support (td-fragment rework)

2014-08-22 Thread Alan Stern
On Fri, 22 Aug 2014, Dan Williams wrote: > v1.0 hosts require that TD-fragments (portions of a TD that do not end > on a MPB boundary) not cross a TRB segment boundary. This constraint is > in addition to the constraint that a TRB may not specify a transfer that > crosses a 64K boundary. This ena

Re: Trace with v3.17-rc1 while trying to enable power saving for pci device

2014-08-22 Thread Julian Wollrath
Hi, > I just tried out the current git master (commit 5317821c08) and got > the following trace: > [ 25.637181] [ cut here ] > [ 25.637191] WARNING: CPU: 0 PID: 756 at fs/proc/generic.c:521 > remove_proc_entry+0x170/0x180() [ 25.637194] remove_proc_entry: > removing n

Re: [PATCH 1/2] leds: usb: Add LED trigger for USB gadget activity

2014-08-22 Thread Bryan Wu
On Fri, Aug 22, 2014 at 4:53 AM, Michal Sojka wrote: > With this patch, USB gadget activity can be signaled by blinking a LED. > > Since there is no generic code where to put the trigger for all USB > controllers, each USB controller needs to call the trigger individually. > This patch adds the ca

Re: [PATCH 1/1] HID: usbhid: add usb_clear_halt determination for next hid_start_in

2014-08-22 Thread vichy
hi alan and all: > I recently posted (but did not submit) a more comprehensive solution to > this and other related problems. For example, HID devices typically > run at low speed or full speed. When attached through a hub to an EHCI > controller (very common on modern systems), unplugging the d

Re: [PATCH v2 1/5] ARM: dts: remove old USB2 PHY node hook for Arndale

2014-08-22 Thread Andreas Färber
Am 22.08.2014 18:59, schrieb Bartlomiej Zolnierkiewicz: > drivers/usb/phy/phy-samsung-usb2 driver got replaced by > drivers/phy/phy-samsung-usb2 one. Remove the leftover hook > from Arndale dts file. > > Signed-off-by: Bartlomiej Zolnierkiewicz > Acked-by: Kyungmin Park > Reviewed-by: Vivek Gau

Re: [Bug 80711] [PATCH]SG_FLAG_LUN_INHIBIT is no longer implemented and there's not way to prevent the kernel from using the 2nd cdb byte for the LUN

2014-08-22 Thread Alan Stern
On Fri, 22 Aug 2014, James Bottomley wrote: > On Fri, 2014-08-22 at 10:53 -0400, Alan Stern wrote: > > Sending the initial INQUIRY command to LUNs larger than 0 involves a > > chicken-and-egg problem -- we don't know whether to fill in the LUN > > bits in the command until we know the SCSI level,

[RFC PATCH 20/20] xhci: unit test ring enqueue/dequeue routines

2014-08-22 Thread Dan Williams
Given the complexity of satisfying xhci 1.0+ host trb boundary constraints, provide a test case that exercises inserting mid-segment links into a ring. The linker --wrap= option is used to not pollute the global identifier space and to make it clear which standard xhci driver routines are being mo

[RFC PATCH 19/20] xhci: v1.0 scatterlist enqueue support (td-fragment rework)

2014-08-22 Thread Dan Williams
v1.0 hosts require that TD-fragments (portions of a TD that do not end on a MPB boundary) not cross a TRB segment boundary. This constraint is in addition to the constraint that a TRB may not specify a transfer that crosses a 64K boundary. This enabling permits the driver to accept scatterlists of

[RFC PATCH 15/20] xhci: kill ->num_trbs_free_temp in struct xhci_ring

2014-08-22 Thread Dan Williams
This can simply be done inline in xhci_queue_isoc_tx(). Signed-off-by: Dan Williams --- drivers/usb/host/xhci-ring.c |6 +++--- drivers/usb/host/xhci.h |1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c in

[RFC PATCH 14/20] xhci: power-of-2 ring sizes

2014-08-22 Thread Dan Williams
In preparation for dynamic ring expansion while walking scatterlists for v1.0+ xhci hosts force the ring sizes to be a power-of-2. This property combined with the conversion of segments to a doubly linked list allows for translating ring pointers to integers enabling simple math to interrogate the

[RFC PATCH 18/20] xhci: add xhci_ring_reap_td() helper

2014-08-22 Thread Dan Williams
TDs from endpoint rings are open-coded cleaned up in a duplicate fashion in two places. Provide common helper. This is later used to as a place to inject ring-type-specific post-reap operations. Signed-off-by: Dan Williams --- drivers/usb/host/xhci-ring.c | 17 + 1 files chan

[RFC PATCH 17/20] xhci: combine xhci_queue_bulk_tx() and queue_bulk_sg_tx()

2014-08-22 Thread Dan Williams
The only difference between these two routines is that the latter handles a scatterlist of more than one entry. Fake a single entry scatterlist for the non-sg case, and delete the duplicate code. Signed-off-by: Dan Williams --- drivers/usb/host/xhci-ring.c | 158 +--

[RFC PATCH 16/20] xhci: refactor prepare_transfer()

2014-08-22 Thread Dan Williams
In preparation for honoring xhci-v1.0+ td-fragment handling rules break out the subroutines of prepare_transfer(). Rather than calculating the number of trbs required and expanding the ring, v1.0+ hosts will dynamically resize the ring as it discovers td-fragments that end up straddling a segment

[RFC PATCH 13/20] xhci: use %pad for printing dma_addr_t

2014-08-22 Thread Dan Williams
Clean up verbose (unsigned long long) casts. Signed-off-by: Dan Williams --- drivers/usb/host/xhci-dbg.c | 70 - drivers/usb/host/xhci-mem.c | 46 --- drivers/usb/host/xhci-ring.c | 41 +++- drivers/us

[RFC PATCH 09/20] xhci: introduce ring ops to handle event vs non-event rings

2014-08-22 Thread Dan Williams
It's confusing (to me at least) to keep on remembering the differences between event rings (managed by the hardware) and non-event rings managed by the host. Replace "if (ring->type == FOO)" branches with ring ops that are specific to the type of ring. This is a tradeoff of direct code readabilit

[RFC PATCH 08/20] xhci: refactor inc_enq(), share a common advance_enq() with prepare_ring()

2014-08-22 Thread Dan Williams
There are two locations where we advance the enqueue pointer through a chain of link trbs, in inc_enq() and prepare_ring(). Factor that into a common advance_enq(). Also, in preparation for per-ring operations factor out the differences between the event-rings, chain-quirk-rings and normal endpoi

[RFC PATCH 12/20] xhci: introduce struct xhci_ring_pointer

2014-08-22 Thread Dan Williams
Consolidate ring pointer tracking variables into their own type. This simplifies the calling convention of some routines and allows for the later introduction of integer ring index variables. Signed-off-by: Dan Williams --- drivers/usb/host/xhci-dbg.c |8 + drivers/usb/host/xhci-mem.c |

[RFC PATCH 10/20] xhci: clarify "ring valid" checks

2014-08-22 Thread Dan Williams
All rings have ->dequeue = ->enqueue = "first trb in first segment", so it is redundant to check if ->dequeue is NULL when ->ring is set. Signed-off-by: Dan Williams --- drivers/usb/host/xhci-hub.c |5 ++--- drivers/usb/host/xhci-ring.c |2 +- 2 files changed, 3 insertions(+), 4 deletio

[RFC PATCH 07/20] xhci: make xhci_segments doubly linked

2014-08-22 Thread Dan Williams
In preparation for dynamic ring expansion while walking scatterlists for v1.0+ xhci hosts make it possible to walk backwards through ring segments. Certainly this could be done in an open-coded fashion, but it improves readability to use established list manipulation helper routines. Signed-off-b

[RFC PATCH 00/20] xhci: implement xhci-v1+ td-fragment rules, test

2014-08-22 Thread Dan Williams
Sending as an RFC primarily to get feedback on the unit testing approach while there's still time to yell at me in person at LinuxCon. Including Rusty in pursuit of comments on how to do mocked interfaces for testing purposes in-tree. === This series updates the xhci driver to honor all the rule

[RFC PATCH 11/20] xhci: provide helpers for retrieving 'enqueue' and 'dequeue' pointers

2014-08-22 Thread Dan Williams
In prepartion for converting ring management from pointers to power-of-2 indexes, introduce xhci_ring_dequeue(), xhci_ring_enqueue(), xhci_ring_set_dequeue(), and xhci_ring_set_enqueue(). Signed-off-by: Dan Williams --- drivers/usb/host/xhci-dbg.c | 16 ++-- drivers/usb/host/xhci-mem.c | 1

[RFC PATCH 04/20] xhci: increase trb segment size, kill ->segment_pool

2014-08-22 Thread Dan Williams
TRB segments are allocated relatively infrequently and would benefit from being larger (to reduce probability of overrunning a segment in a TD fragment). We already burn a page satisfying a single segment allocation, so there's little reason to not allocate in page-sized chunks in the first instan

[RFC PATCH 05/20] xhci: prepare for mid-segment link-trbs

2014-08-22 Thread Dan Williams
Break the assumption that link-trbs are always located at the end of a segment. Introduce ->link to struct xhci_segment and use that every place that looks up the link-trb for a segment. This is meant to be functionally equivalent to the existing driver and is just a search and replace for hard c

[RFC PATCH 03/20] xhci: introduce xhci_to_dev

2014-08-22 Thread Dan Williams
Replace many occurrences of xhci_to_hcd(xhci)->self.controller with a helper. Signed-off-by: Dan Williams --- drivers/usb/host/xhci-mem.c | 29 - drivers/usb/host/xhci.c |6 +++--- drivers/usb/host/xhci.h | 13 + 3 files changed, 24 inserti

[RFC PATCH 06/20] xhci: drop 'xhci' argument to last_trb

2014-08-22 Thread Dan Williams
last_trb() can simply distinguish event rings by the ring ->type. With this in place the 'xhci' parameter can be removed from last_trb_on_last_seg(), next_trb(), and inc_deq(). Signed-off-by: Dan Williams --- drivers/usb/host/xhci-ring.c | 75 -- 1 file

Re: [PATCH 0/5] usb: phy: samsung: remove old USB PHY code

2014-08-22 Thread Bartlomiej Zolnierkiewicz
by Kukjin Kim. > Are we deleting the phy drivers or not ? Yes, we are deleting them. It has been agreed on by Kishon and Vivek. > Please rebase on v3.17-rc1 and resend with all Acks in place. Done: https://lkml.org/lkml/2014/8/22/446 Please note that if you want to apply it t

[RFC PATCH 01/20] xhci: cleanup remaining cycle bit toggles via ternary conditional

2014-08-22 Thread Dan Williams
These can simply be toggled via xor. Signed-off-by: Dan Williams --- drivers/usb/host/xhci-ring.c | 12 ++-- 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c index 749fc68eb5c1..0efbbf0b6233 100644 --- a/drivers/

[RFC PATCH 02/20] xhci: remove invalid cast of xhci to a usb_device in xhci_log_ctx trace

2014-08-22 Thread Dan Williams
An xhci controller device is a pci or a platform device, never a usb_device. Cc: Xenia Ragiadakou Signed-off-by: Dan Williams --- drivers/usb/host/xhci-trace.h |5 - 1 files changed, 0 insertions(+), 5 deletions(-) diff --git a/drivers/usb/host/xhci-trace.h b/drivers/usb/host/xhci-trac

Re: [RFC 1/2] USB: OTG: Hold wakeupsource when VBUS present

2014-08-22 Thread Felipe Balbi
Hi, On Fri, Aug 22, 2014 at 03:19:32PM +0530, Kiran Kumar Raparthy wrote: > From: Todd Poynor > > USB: OTG: Hold wakeupsource when VBUS present > > Enabled by default, can disable with: I would turn this around and make it disabled by default so that it doesn't change behavior for distro kerne

Re: [PATCH v3 6/9] usb: allow to supply the PHY in the drivers when using HCD

2014-08-22 Thread Sergei Shtylyov
On 08/22/2014 08:53 PM, Sergei Shtylyov wrote: This patch modify the generic code handling PHYs to allow them to be supplied from the drivers. This adds checks to ensure no PHY was already there when looking for one in the generic code. This also makes sure we do not modify its state in the gene

[PATCH v2 0/5] usb: phy: samsung: remove old USB PHY code

2014-08-22 Thread Bartlomiej Zolnierkiewicz
Hi, This patch series removes the old Samsung USB PHY drivers that got replaced by the new ones using the generic PHY layer. Depends on: - v3.17-rc1 branch of Linus' kernel Changes since v1 (https://lkml.org/lkml/2014/8/14/241): - rebased on v3.17-rc1 kernel - added Acked-by-s from Kishon Vijay

[PATCH v2 4/5] usb: phy: samsung: remove old USB 3.0 PHY driver

2014-08-22 Thread Bartlomiej Zolnierkiewicz
drivers/usb/phy/phy-samsung-usb3 driver got replaced by drivers/phy/phy-samsung-usb3 one and is no longer used. Signed-off-by: Bartlomiej Zolnierkiewicz Acked-by: Kyungmin Park Reviewed-by: Vivek Gautam Reviewed-by: Jingoo Han Acked-by: Kishon Vijay Abraham I Cc: Kamil Debski --- drivers/us

[PATCH v2 2/5] ARM: dts: remove old USB2 PHY node for Exynos5250

2014-08-22 Thread Bartlomiej Zolnierkiewicz
drivers/usb/phy/phy-samsung-usb2 driver got replaced by drivers/phy/phy-samsung-usb2 one. Remove the leftover USB2 PHY node (EHCI/OHCI USB nodes are using the new one already) from Exynos5250 dtsi file. Signed-off-by: Bartlomiej Zolnierkiewicz Acked-by: Kyungmin Park Reviewed-by: Vivek Gautam

[PATCH v2 1/5] ARM: dts: remove old USB2 PHY node hook for Arndale

2014-08-22 Thread Bartlomiej Zolnierkiewicz
drivers/usb/phy/phy-samsung-usb2 driver got replaced by drivers/phy/phy-samsung-usb2 one. Remove the leftover hook from Arndale dts file. Signed-off-by: Bartlomiej Zolnierkiewicz Acked-by: Kyungmin Park Reviewed-by: Vivek Gautam Reviewed-by: Jingoo Han Acked-by: Kishon Vijay Abraham I Cc: Ma

[PATCH v2 3/5] usb: phy: samsung: remove old USB 2.0 PHY driver

2014-08-22 Thread Bartlomiej Zolnierkiewicz
drivers/usb/phy/phy-samsung-usb2 driver got replaced by drivers/phy/phy-samsung-usb2 one and is no longer used. Signed-off-by: Bartlomiej Zolnierkiewicz Acked-by: Kyungmin Park Reviewed-by: Vivek Gautam Reviewed-by: Jingoo Han Acked-by: Kishon Vijay Abraham I Cc: Kamil Debski --- drivers/us

[PATCH v2 5/5] usb: phy: samsung: remove old common USB PHY code

2014-08-22 Thread Bartlomiej Zolnierkiewicz
drivers/usb/phy/phy-samsung-usb[2,3] drivers got replaced by drivers/phy/phy-samsung-usb[2,3] ones and the old common Samsung USB PHY code is no longer used. Signed-off-by: Bartlomiej Zolnierkiewicz Acked-by: Kyungmin Park Reviewed-by: Vivek Gautam Reviewed-by: Jingoo Han Acked-by: Kishon Vija

Re: [PATCH v3 6/9] usb: allow to supply the PHY in the drivers when using HCD

2014-08-22 Thread Sergei Shtylyov
Hello. On 08/22/2014 07:50 PM, Antoine Ténart wrote: This patch modify the generic code handling PHYs to allow them to be supplied from the drivers. This adds checks to ensure no PHY was already there when looking for one in the generic code. This also makes sure we do not modify its state in t

Re: [PATCH] usb: phy: twl4030-usb: Fix regressions to runtime PM on omaps

2014-08-22 Thread Tony Lindgren
* Kishon Vijay Abraham I [140821 21:52]: > > > > Kishon, this regression fix would be nice to get into the v3.17-rc > > series if no objections. If you don't have other fixes, I can also > > queue via arm-soc with proper acks. > > I can queue this one up once put_autosuspend() is used. Great, t

Re: [PATCH] usb: phy: twl4030-usb: Fix lost interrupts after ID pin goes down

2014-08-22 Thread Tony Lindgren
Hi, * Grazvydas Ignotas [140822 06:21]: > Hi, > > On Thu, Aug 21, 2014 at 7:48 PM, Tony Lindgren wrote: > > Commit 249751f22380 ("usb: phy: twl4030-usb: poll for ID disconnect") > > added twl4030_id_workaround_work() to deal with lost interrupts > > after ID pin goes down. However, this current

Re: [PATCH v2] drivers: usb: gadget: fusb300_udc.h: Fix typo in include guard

2014-08-22 Thread Felipe Balbi
Hi, On Fri, Aug 22, 2014 at 05:21:12PM +0200, Rasmus Villemoes wrote: > Felipe Balbi writes: > > > On Fri, Aug 22, 2014 at 04:44:33PM +0200, Rasmus Villemoes wrote: > >> Clearly this was meant to be an include guard, but a trailing > >> underscore was missing. It has been this way since the file

[PATCH v3 1/9] usb: move the OTG state from the USB PHY to the OTG structure

2014-08-22 Thread Antoine Ténart
Before using the PHY framework instead of the USB PHY one, we need to move the OTG state into another place, since it won't be available when USB PHY isn't used. This patch moves the OTG state into the OTG structure, and makes all the needed modifications in the drivers using the OTG state. Signed

[PATCH v3 0/9] usb: add support for the generic PHY framework

2014-08-22 Thread Antoine Ténart
Hi all, This is an attempt to add more common USB code aware of the generic PHY framework, while keeping the compatibility for the USB PHY one. It does not add the full support, some USB PHY specific functions not being available currently in the generic PHY subsystem (e.g. usb_phy_set_power()). B

[PATCH v3 6/9] usb: allow to supply the PHY in the drivers when using HCD

2014-08-22 Thread Antoine Ténart
This patch modify the generic code handling PHYs to allow them to be supplied from the drivers. This adds checks to ensure no PHY was already there when looking for one in the generic code. This also makes sure we do not modify its state in the generic HCD functions, it was provided by the driver.

[PATCH v3 4/9] usb: rename phy to usb_phy in HCD

2014-08-22 Thread Antoine Ténart
The USB PHY member of the HCD structure is renamed to 'usb_phy' and modifications are done in all drivers accessing it. Signed-off-by: Antoine Ténart Acked-by: Alan Stern --- drivers/usb/chipidea/host.c | 2 +- drivers/usb/core/hcd.c| 20 ++-- drivers/usb/core/hub.c

[PATCH v3 5/9] usb: rename gen_phy to phy in HCD

2014-08-22 Thread Antoine Ténart
The patch adding support to the generic PHY framework introduced a 'gen_phy' member in the HCD structure. Rename it to 'phy' to have a consistent USB framework. Signed-off-by: Antoine Ténart Acked-by: Alan Stern --- drivers/usb/core/hcd.c | 22 +++--- include/linux/usb/hcd.h |

[PATCH v3 7/9] usb: rename transceiver and phy to usb_phy in ChipIdea

2014-08-22 Thread Antoine Ténart
This patch prepares the introduction of the generic PHY support in the USB ChipIdea common functions. The USB PHY member of the ChipIdea structure ('transceiver') is renamed to 'usb_phy', the 'phy' member of the ChipIdea pdata structure is renamed to 'usb_phy' and modifications are done in all driv

[PATCH v3 8/9] usb: chipidea: move usb_otg into struct ci_hdrc

2014-08-22 Thread Antoine Ténart
Move the usb_otg member from struct usb_phy to struct ci_hdrc. Rework its initialization taking in account this modification. Signed-off-by: Antoine Ténart --- drivers/usb/chipidea/ci.h | 1 + drivers/usb/chipidea/host.c| 8 +++- drivers/usb/chipidea/otg_fsm.c | 15 ++-

[PATCH v3 3/9] usb: add support to the generic PHY framework in OTG

2014-08-22 Thread Antoine Ténart
This patch adds support of the PHY framework in OTG and keeps the USB PHY compatibility. Here the only modification is to add PHY member in the OTG structure, along with the USB PHY one. Signed-off-by: Antoine Ténart --- include/linux/usb/otg.h | 3 +++ 1 file changed, 3 insertions(+) diff --gi

[PATCH v3 2/9] usb: rename phy to usb_phy in OTG

2014-08-22 Thread Antoine Ténart
This patch prepares the introduction of the generic PHY support in the USB OTG common functions. The USB PHY member of the OTG structure is renamed to 'usb_phy' and modifications are done in all drivers accessing it. Renaming this pointer will allow to keep the compatibility for USB PHY drivers. S

[PATCH v3 9/9] usb: chipidea: add support to the generic PHY framework in ChipIdea

2014-08-22 Thread Antoine Ténart
This patch adds support of the PHY framework for ChipIdea drivers. Changes are done in both the ChipIdea common code and in the drivers accessing the PHY. This is done by adding a new PHY member in ChipIdea's structures and by taking care of it in the code. Signed-off-by: Antoine Ténart --- driv

Re: [Bug 80711] [PATCH]SG_FLAG_LUN_INHIBIT is no longer implemented and there's not way to prevent the kernel from using the 2nd cdb byte for the LUN

2014-08-22 Thread James Bottomley
On Fri, 2014-08-22 at 10:53 -0400, Alan Stern wrote: > On Thu, 21 Aug 2014, Christoph Hellwig wrote: > > > On Thu, Aug 21, 2014 at 05:43:41PM -0400, Martin K. Petersen wrote: > > > Alan> Okay, here's a patch that implements the suggestion, except that I > > > Alan> put the flag in the Scsi_Host s

[PATCH] Including XHCI_TRUST_TX_LENGTH for Renesas uPD720202 USB 3.0 chip.

2014-08-22 Thread Rodrigo Severo
Renesas uPD720202 USB 3.0 chip needs XHCI_TRUST_TX_LENGTH quirk workaround as per below logs produced when using a Diammond video capture dongle: Aug 21 18:07:33 [kernel] handle_tx_event: 67 callbacks suppressed Aug 21 18:07:33 [kernel] xhci_hcd :01:00.0: WARN Successful completion on short

Re: [Bug 80711] [PATCH]SG_FLAG_LUN_INHIBIT is no longer implemented and there's not way to prevent the kernel from using the 2nd cdb byte for the LUN

2014-08-22 Thread Alan Stern
On Fri, 22 Aug 2014, Christoph Hellwig wrote: > On Fri, Aug 22, 2014 at 10:53:42AM -0400, Alan Stern wrote: > > Good idea. An enhanced patch is below. If I can get a Tested-By: from > > Tiziano and one or two Acked-By: responses, I'll submit this for the > > current and stable kernels. > > > >

Re: [PATCH v2] drivers: usb: gadget: fusb300_udc.h: Fix typo in include guard

2014-08-22 Thread Rasmus Villemoes
Felipe Balbi writes: > On Fri, Aug 22, 2014 at 04:44:33PM +0200, Rasmus Villemoes wrote: >> Clearly this was meant to be an include guard, but a trailing >> underscore was missing. It has been this way since the file was >> introduced in 0fe6f1d1 ("usb: udc: add Faraday fusb300 driver"). >> > >

Re: [Bug 80711] [PATCH]SG_FLAG_LUN_INHIBIT is no longer implemented and there's not way to prevent the kernel from using the 2nd cdb byte for the LUN

2014-08-22 Thread Martin K. Petersen
> "Alan" == Alan Stern writes: Alan> Sending the initial INQUIRY command to LUNs larger than 0 involves Alan> a chicken-and-egg problem -- we don't know whether to fill in the Alan> LUN bits in the command until we know the SCSI level, and we don't Alan> know the SCSI level until the INQUIRY

Re: [Bug 80711] [PATCH]SG_FLAG_LUN_INHIBIT is no longer implemented and there's not way to prevent the kernel from using the 2nd cdb byte for the LUN

2014-08-22 Thread Christoph Hellwig
On Fri, Aug 22, 2014 at 10:53:42AM -0400, Alan Stern wrote: > Good idea. An enhanced patch is below. If I can get a Tested-By: from > Tiziano and one or two Acked-By: responses, I'll submit this for the > current and stable kernels. > > Sending the initial INQUIRY command to LUNs larger than 0 i

Re: [PATCH v2] drivers: usb: gadget: fusb300_udc.h: Fix typo in include guard

2014-08-22 Thread Felipe Balbi
On Fri, Aug 22, 2014 at 04:44:33PM +0200, Rasmus Villemoes wrote: > Clearly this was meant to be an include guard, but a trailing > underscore was missing. It has been this way since the file was > introduced in 0fe6f1d1 ("usb: udc: add Faraday fusb300 driver"). > right here you need to have: Fi

Re: [Bug 80711] [PATCH]SG_FLAG_LUN_INHIBIT is no longer implemented and there's not way to prevent the kernel from using the 2nd cdb byte for the LUN

2014-08-22 Thread Alan Stern
On Thu, 21 Aug 2014, Christoph Hellwig wrote: > On Thu, Aug 21, 2014 at 05:43:41PM -0400, Martin K. Petersen wrote: > > Alan> Okay, here's a patch that implements the suggestion, except that I > > Alan> put the flag in the Scsi_Host structure instead of the template. > > Alan> This was to minimize

[PATCH v2] drivers: usb: gadget: fusb300_udc.h: Fix typo in include guard

2014-08-22 Thread Rasmus Villemoes
Clearly this was meant to be an include guard, but a trailing underscore was missing. It has been this way since the file was introduced in 0fe6f1d1 ("usb: udc: add Faraday fusb300 driver"). Signed-off-by: Rasmus Villemoes --- drivers/usb/gadget/udc/fusb300_udc.h | 2 +- 1 file changed, 1 insert

Re: [RFC 1/2] USB: OTG: Hold wakeupsource when VBUS present

2014-08-22 Thread Alan Stern
On Fri, 22 Aug 2014, Kiran Kumar Raparthy wrote: > From: Todd Poynor > > USB: OTG: Hold wakeupsource when VBUS present > > Enabled by default, can disable with: >echo N > /sys/module/otg_wakeupsource/parameters/enabled > > This is one of the number of patches from the Android AOSP common.g

Re: [PATCH] drivers: usb: gadget: fusb300_udc.h: Fix typo in include guard

2014-08-22 Thread Felipe Balbi
On Fri, Aug 22, 2014 at 02:59:32PM +0200, Rasmus Villemoes wrote: you need a commit log. Has this always been there ? Which commit are you fixing ? > Signed-off-by: Rasmus Villemoes > --- > drivers/usb/gadget/udc/fusb300_udc.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --

Re: [PATCH 1/1] HID: usbhid: add usb_clear_halt determination for next hid_start_in

2014-08-22 Thread Alan Stern
On Fri, 22 Aug 2014, vichy wrote: > hi Jiri: > > 2014-08-22 15:45 GMT+08:00 Jiri Kosina : > > On Fri, 22 Aug 2014, CheChun Kuo wrote: > > > >> HID IR device will not response to any command send from host when > >> it is finishing paring and tring to reset itself. During this period of > >>

Re: [PATCH] usb: phy: twl4030-usb: Fix lost interrupts after ID pin goes down

2014-08-22 Thread Grazvydas Ignotas
Hi, On Thu, Aug 21, 2014 at 7:48 PM, Tony Lindgren wrote: > Commit 249751f22380 ("usb: phy: twl4030-usb: poll for ID disconnect") > added twl4030_id_workaround_work() to deal with lost interrupts > after ID pin goes down. However, this currently only works for the > insertion. The PHY interrupts

[PATCH] drivers: usb: gadget: fusb300_udc.h: Fix typo in include guard

2014-08-22 Thread Rasmus Villemoes
Signed-off-by: Rasmus Villemoes --- drivers/usb/gadget/udc/fusb300_udc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/udc/fusb300_udc.h b/drivers/usb/gadget/udc/fusb300_udc.h index ae811d8..ad39f89 100644 --- a/drivers/usb/gadget/udc/fusb300_udc.h +++ b/

[PATCH 1/2] leds: usb: Add LED trigger for USB gadget activity

2014-08-22 Thread Michal Sojka
With this patch, USB gadget activity can be signaled by blinking a LED. Since there is no generic code where to put the trigger for all USB controllers, each USB controller needs to call the trigger individually. This patch adds the call only for the musb controller where I can test it. Signed-of

[PATCH 2/2] leds: usb: Add LED trigger for USB host activity

2014-08-22 Thread Michal Sojka
With this patch, USB host activity can be signaled by blinking a LED. This should work with all host controllers. Tested only with musb. Signed-off-by: Michal Sojka --- drivers/leds/trigger/Kconfig | 8 ++ drivers/leds/trigger/Makefile | 1 + drivers/leds/trigger/ledtri

Re: [PATCH v2 02/16] libusbg: Add guards for libconfig version

2014-08-22 Thread Sergei Shtylyov
Hello. On 8/22/2014 3:59 PM, Krzysztof Opasiak wrote: Changes sent to libcofngi has not been merged yet, Perhaps libconfig? so add compatibility defines to make all compile and work. Signed-off-by: Krzysztof Opasiak [...] WBR, Sergei -- To unsubscribe from this list: send the line

[PATCH v2 13/16] libusbg: Add import gadget functionality

2014-08-22 Thread Krzysztof Opasiak
Whole gadget can be exported to file using usbg_export_gadget(). This commit adds complementary API function usbg_import_gadget() which allows to import whole gadget (including attrs, strings, configs, functions and bindings) from file to configfs. Signed-off-by: Krzysztof Opasiak --- include/us

[PATCH v2 10/16] libusbg: Add import function functionality

2014-08-22 Thread Krzysztof Opasiak
Functions can be exported to file using usbg_export_function(). This commit adds complementary API function usbg_import_function() which allows to import function from file to configfs. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 13 src/usbg.c | 188 +

[PATCH v2 11/16] libusbg: Add import config functionality

2014-08-22 Thread Krzysztof Opasiak
Configurations can be exported to file using usbg_export_config(). This commit adds complementary API function usbg_import_config() which allows to import configuration (with attrs, strings and bindings) from file to chosen gadget. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 11

[PATCH v2 15/16] libusbg: examples: Add gadget-import sample app

2014-08-22 Thread Krzysztof Opasiak
Signed-off-by: Krzysztof Opasiak --- examples/Makefile.am |3 +- examples/gadget-import.c | 79 ++ src/usbg.c |6 ++-- 3 files changed, 84 insertions(+), 4 deletions(-) create mode 100644 examples/gadget-import.c diff --git

[PATCH v2 12/16] libusbg: Allow to store error information in usbg_state

2014-08-22 Thread Krzysztof Opasiak
If error occurred during parsing user should have an opportunity to get details about place and type of error. Signed-off-by: Krzysztof Opasiak --- src/usbg.c |7 +++ 1 file changed, 7 insertions(+) diff --git a/src/usbg.c b/src/usbg.c index 3e4725d..3527c1b 100644 --- a/src/usbg.c +++

[PATCH v2 16/16] libusbg: doc: Add document about gadget schemes

2014-08-22 Thread Krzysztof Opasiak
Add document which clarify reasons of implementing gadget schemes and also describes syntax of such files. Signed-off-by: Krzysztof Opasiak --- doc/gadget_schemes.txt | 301 1 file changed, 301 insertions(+) create mode 100644 doc/gadget_schemes

[PATCH v2 14/16] libusbg: Add functions to get import error text and line

2014-08-22 Thread Krzysztof Opasiak
Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 43 +++ src/usbg.c | 48 2 files changed, 91 insertions(+) diff --git a/include/usbg/usbg.h b/include/usbg/usbg.h index 23783eb..a934a7

[PATCH v2 09/16] libusbg: Allow to store error information in usbg_gadget

2014-08-22 Thread Krzysztof Opasiak
If error occurred during parsing user should have an oportunity to get details about place and type of error. Signed-off-by: Krzysztof Opasiak --- src/usbg.c |8 1 file changed, 8 insertions(+) diff --git a/src/usbg.c b/src/usbg.c index 74f6bfd..929f1c7 100644 --- a/src/usbg.c +++

[PATCH v2 04/16] libusbg: Add export function functionality

2014-08-22 Thread Krzysztof Opasiak
Function settings may be complicated and their configuration may take a long while. To save time it would be convenient to allow for storing function settings in a file. Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h | 11 src/usbg.c | 156 +

[PATCH v2 07/16] libusbg: examples: Add sample application to export gadget

2014-08-22 Thread Krzysztof Opasiak
Add sample C code which shows how to use new functionality of libusbg - gadget export. This program allows to export chosen gadget from configfs to a file. Signed-off-by: Krzysztof Opasiak --- examples/Makefile.am |3 +- examples/gadget-export.c | 81 +++

[PATCH v2 01/16] libusbg: Add dependency to libconfig

2014-08-22 Thread Krzysztof Opasiak
This library is used to import and export gadget/function/config to and from file. Signed-off-by: Krzysztof Opasiak --- configure.ac|1 + libusbg.pc.in |2 +- src/Makefile.am |4 +++- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac ind

[PATCH v2 08/16] libusbg: Add errors which may happen during parsing

2014-08-22 Thread Krzysztof Opasiak
Signed-off-by: Krzysztof Opasiak --- include/usbg/usbg.h |4 src/usbg.c | 24 2 files changed, 28 insertions(+) diff --git a/include/usbg/usbg.h b/include/usbg/usbg.h index 3a66ae3..3d3cba0 100644 --- a/include/usbg/usbg.h +++ b/include/usbg/usbg.h @@

[PATCH v2 06/16] libusbg: Add export gadget functionality

2014-08-22 Thread Krzysztof Opasiak
Whole gadget setting process take a lot of simple commands (or lines of code). Those shell commands may take a while or require dedicated script and hard-coding gadget configuration. To avoid such situation add to library ability to export a whole gadget into file. Signed-off-by: Krzysztof Opasiak

  1   2   >