[PATCH V2] usb: {ohci,ehci}-platform: Use new OF big-endian helper function

2014-11-27 Thread Kevin Cernekee
This handles the existing big-endian case, and in addition, it also does the right thing when native-endian is specified. Signed-off-by: Kevin Cernekee cerne...@gmail.com Acked-by: Alan Stern st...@rowland.harvard.edu --- Documentation/devicetree/bindings/usb/usb-ehci.txt | 2 ++ Documentation

Re: [PATCH 9/9] usb: {ohci,ehci}-platform: Use new OF big-endian helper function

2014-11-26 Thread Kevin Cernekee
On Wed, Nov 26, 2014 at 7:14 AM, Alan Stern st...@rowland.harvard.edu wrote: diff --git a/Documentation/devicetree/bindings/usb/usb-ehci.txt b/Documentation/devicetree/bindings/usb/usb-ehci.txt index 43c1a4e..9505c31 100644 --- a/Documentation/devicetree/bindings/usb/usb-ehci.txt +++

[PATCH 4/9] bus: brcmstb_gisb: Make the driver buildable on MIPS

2014-11-25 Thread Kevin Cernekee
BCM7xxx ARM and MIPS platforms share a similar hardware block for reporting GISB errors, so they both benefit from the use of this driver. Conditionally compile the ARM-specific bus error handler so that the GISB error IRQ handler works on other architectures. Signed-off-by: Kevin Cernekee cerne

[PATCH 2/9] power/reset: brcmstb: Use the DT compatible string to indicate bit positions

2014-11-25 Thread Kevin Cernekee
Some of the older chips used different bits to arm and trigger the reset. Add the infrastructure needed to specify this through the compatible string. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- drivers/power/reset/brcmstb-reboot.c | 35 --- 1 file

[PATCH 0/9] Extend various drivers to run on bi-endian BMIPS hosts

2014-11-25 Thread Kevin Cernekee
: Register with kernel restart handler (Guenter Roeck) of: Add helper function to check MMIO register endianness (Kevin Cernekee) These are both tentatively accepted, but might not be present in the same tree yet. As such, we might want to review now, merge later. Kevin Cernekee (9): power/reset

[PATCH 9/9] usb: {ohci,ehci}-platform: Use new OF big-endian helper function

2014-11-25 Thread Kevin Cernekee
This handles the existing big-endian case, and in addition, it also does the right thing when native-endian is specified. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- Documentation/devicetree/bindings/usb/usb-ehci.txt | 2 ++ Documentation/devicetree/bindings/usb/usb-ohci.txt | 2

[PATCH 1/9] power/reset: brcmstb: Make the driver buildable on MIPS

2014-11-25 Thread Kevin Cernekee
Now that the driver doesn't use any ARM-specific headers, it is safe to build on MIPS or with COMPILE_TEST. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- drivers/power/reset/Kconfig | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/drivers/power/reset/Kconfig b

[PATCH 6/9] bus: brcmstb_gisb: Look up register offsets in a table

2014-11-25 Thread Kevin Cernekee
There are at least 4 incompatible variations of this hardware block, so let's use the ARB_* constants as a table index instead of hardcoding specific register offsets. Also, allow for the possibility of adding old devices that are missing some of the registers. Signed-off-by: Kevin Cernekee

[PATCH 7/9] bus: brcmstb_gisb: Add register offset tables for older chips

2014-11-25 Thread Kevin Cernekee
This will select the appropriate register layout based on the DT compatible string. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- .../devicetree/bindings/bus/brcm,gisb-arb.txt | 6 ++- drivers/bus/brcmstb_gisb.c | 52 +++--- 2 files changed

[PATCH 3/9] power/reset: brcmstb: Add support for old 65nm chips

2014-11-25 Thread Kevin Cernekee
The register bit fields are a little different, so add an entry and a compatible string to accommodate them. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- Documentation/devicetree/bindings/arm/brcm-brcmstb.txt | 4 +++- drivers/power/reset/brcmstb-reboot.c | 6 ++ 2

[PATCH 5/9] bus: brcmstb_gisb: Introduce wrapper functions for MMIO accesses

2014-11-25 Thread Kevin Cernekee
These will be used to abstract out chip-to-chip differences. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- drivers/bus/brcmstb_gisb.c | 24 +--- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/drivers/bus/brcmstb_gisb.c b/drivers/bus/brcmstb_gisb.c index

[PATCH 8/9] bus: brcmstb_gisb: Honor the big-endian and native-endian DT properties

2014-11-25 Thread Kevin Cernekee
On chips strapped for BE, we'll need to use ioread32be/iowrite32be instead of ioread32/iowrite32. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- drivers/bus/brcmstb_gisb.c | 13 +++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/drivers/bus/brcmstb_gisb.c b

Re: [PATCH v2 2/3] USB: ohci-platform: Expose no_big_frame_no and num_ports in DT

2014-10-14 Thread Kevin Cernekee
On Tue, Oct 14, 2014 at 6:58 AM, Alan Stern st...@rowland.harvard.edu wrote: On Sat, 11 Oct 2014, Kevin Cernekee wrote: These quirks are currently set through platform_data; allow DT-based SoCs to use them too. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- a/drivers/usb/host/ohci

Re: [PATCH 1/2] USB: OHCI: Eliminate platform-specific test in ohci.h

2014-10-11 Thread Kevin Cernekee
On Sat, Oct 11, 2014 at 7:58 AM, Alan Stern st...@rowland.harvard.edu wrote: On Fri, 10 Oct 2014, Kevin Cernekee wrote: OHCI_QUIRK_FRAME_NO is currently set under either of the following conditions: 1) If a ppc-of-ohci DT node indicates a compatible string of fsl,mpc5200-ohci or mpc5200

Re: [PATCH 2/2] USB: ohci-platform: Expose no_big_frame_no and num_ports in DT

2014-10-11 Thread Kevin Cernekee
On Sat, Oct 11, 2014 at 8:09 AM, Alan Stern st...@rowland.harvard.edu wrote: On Fri, 10 Oct 2014, Kevin Cernekee wrote: These quirks are currently set through platform_data; allow DT-based SoCs to use them too. It looks strange to have the platform_data version of the quirks set in one

[PATCH v2 1/3] USB: OHCI: Eliminate platform-specific test in ohci.h

2014-10-11 Thread Kevin Cernekee
OHCI_QUIRK_FRAME_NO and the related PSW endian swap. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- drivers/usb/host/ohci.h | 19 +-- 1 file changed, 9 insertions(+), 10 deletions(-) v1-v2: PATCH 1/3: Tweak description; no change to the code. PATCH 2/3: No changes. PATCH 3/3: New

[PATCH v2 2/3] USB: ohci-platform: Expose no_big_frame_no and num_ports in DT

2014-10-11 Thread Kevin Cernekee
These quirks are currently set through platform_data; allow DT-based SoCs to use them too. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- Documentation/devicetree/bindings/usb/usb-ohci.txt | 2 ++ drivers/usb/host/ohci-platform.c | 6 ++ 2 files changed, 8 insertions

[PATCH v2 3/3] USB: ohci-platform: Move platform_data checks into the probe function

2014-10-11 Thread Kevin Cernekee
This puts all of the platform_data checks in the same place, and removes the need for a custom drv-reset() callback. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- drivers/usb/host/ohci-platform.c | 19 --- 1 file changed, 4 insertions(+), 15 deletions(-) diff --git

[PATCH 2/2] USB: ohci-platform: Expose no_big_frame_no and num_ports in DT

2014-10-10 Thread Kevin Cernekee
These quirks are currently set through platform_data; allow DT-based SoCs to use them too. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- Documentation/devicetree/bindings/usb/usb-ohci.txt | 2 ++ drivers/usb/host/ohci-platform.c | 6 ++ 2 files changed, 8 insertions

[PATCH 1/2] USB: OHCI: Eliminate platform-specific test in ohci.h

2014-10-10 Thread Kevin Cernekee
, there are currently no in-tree users. So we can safely remove the #ifdef, and thereby allow OHCI_QUIRK_FRAME_NO to be used by other (non-PPC) platforms that have the same property. bcm63xx and bcm3384 are two such users. Signed-off-by: Kevin Cernekee cerne...@gmail.com --- drivers/usb/host/ohci.h

Re: USB 3380 using net2280 driver

2014-02-18 Thread Kevin Cernekee
On Tue, Feb 18, 2014 at 7:12 AM, Felipe Balbi ba...@ti.com wrote: On Mon, Feb 17, 2014 at 04:43:11PM -0800, Amit Uttamchandani wrote: I was looking at the changes for net2280.c and saw your name come up in a few of the more recent changes. I wanted to know, are you aware of support for PLXs

Re: [PATCH V4] usb: gadget: bcm63xx UDC driver

2012-08-27 Thread Kevin Cernekee
On Mon, Aug 27, 2012 at 1:46 PM, Sebastian Andrzej Siewior One little question: Felipe suggested to replace the workqueue by a threaded interrupt. You schedule the workqueue in interrupt context and once in ep0 enqueue. The enqueue should be fine by executing one round and waiting for the

Re: [PATCH V3] usb: gadget: bcm63xx UDC driver

2012-08-25 Thread Kevin Cernekee
On Wed, Aug 22, 2012 at 12:48 AM, Sebastian Andrzej Siewior sebast...@breakpoint.cc wrote: Just one thing that bit while I was sleeping: The HW acks SetConfig on its own. Once you notice this, you set -ep0_req_set_cfg and set state in bcm63xx_ep0_do_idle() to EP0_IN_FAKE_STATUS_PHASE. This is

Re: [PATCH] usb: gadget: bcm63xx UDC driver

2012-08-21 Thread Kevin Cernekee
On Tue, Aug 21, 2012 at 5:04 AM, Felipe Balbi ba...@ti.com wrote: On Mon, Aug 20, 2012 at 08:48:11PM -0700, Kevin Cernekee wrote: On Mon, Aug 20, 2012 at 12:40 AM, Felipe Balbi ba...@ti.com wrote: no workqueues, please either handle the IRQ here or use threaded_irqs. again, no workqueues

Re: [PATCH] usb: gadget: bcm63xx UDC driver

2012-08-21 Thread Kevin Cernekee
On Tue, Aug 21, 2012 at 1:34 PM, Alan Stern st...@rowland.harvard.edu wrote: It is a silicon feature: the core will intercept SET_CONFIGURATION / SET_INTERFACE requests, store wValue/wIndex in the appropriate USBD_STATUS_REG field (cfg/intf/altintf), send an acknowledgement to the host, and

Re: [PATCH] usb: gadget: bcm63xx UDC driver

2012-08-21 Thread Kevin Cernekee
On Tue, Aug 21, 2012 at 2:34 PM, Alan Stern st...@rowland.harvard.edu wrote: But some requests are handled entirely in hardware, including the status phase: SET_ADDRESS SET_CONFIGURATION SET_INTERFACE SET_FEATURE CLEAR_FEATURE GET_FEATURE I assume the features in question are

Re: [PATCH V2] usb: gadget: bcm63xx UDC driver

2012-08-21 Thread Kevin Cernekee
On Tue, Aug 21, 2012 at 2:13 PM, Sebastian Andrzej Siewior sebast...@breakpoint.cc wrote: please drop the force all gadget drivers to also be dynamically linked part. We may want to change this one day :) Done in V3 + if (!pd-use_fullspeed !use_fullspeed) so it is a good advice to have

Re: [PATCH] usb: gadget: bcm63xx UDC driver

2012-08-20 Thread Kevin Cernekee
On Mon, Aug 20, 2012 at 12:40 AM, Felipe Balbi ba...@ti.com wrote: no workqueues, please either handle the IRQ here or use threaded_irqs. again, no workqueues. Felipe, I am seeing all sorts of deadlocks now, after removing the workqueue (patch V2). Some have easy fixes, but for others it is

Re: [PATCH/RFC 2/2] usb: gadget: u_ether: Don't change endpoint status in eth_stop()

2012-08-09 Thread Kevin Cernekee
that it solves the simple up/down/up kworker hang, which was the only problem I actually saw on my board. So for that problem: Tested-by: Kevin Cernekee cerne...@gmail.com I'm not sure if it solves the various other (hypothetical?) races in u_ether between up/down and connect/disconnect. It might

[PATCH] usb: gadget: udc-core: Race between disconnect/unbind and setup

2012-07-09 Thread Kevin Cernekee
too. Here is the change: -- 8 -- From: Kevin Cernekee cerne...@gmail.com usb_gadget_remove_driver() runs through a four-step sequence to shut down the gadget driver. For the case of a composite gadget + at91 UDC, this would look like: udc-driver-disconnect(udc-gadget

[PATCH/RFC 2/2] usb: gadget: u_ether: Don't change endpoint status in eth_stop()

2012-07-08 Thread Kevin Cernekee
() entirely, and let the connect/disconnect functions worry about the endpoint state. -- 8 -- From: Kevin Cernekee cerne...@gmail.com eth_stop() calls usb_ep_disable() then usb_ep_enable(), to flush out any I/O in progress. There are a couple of issues with this: 1) UDC drivers can clear ep-desc on EP

Re: [PATCH 1/2] usb: gadget: composite: Race between disconnect/unbind and setup

2012-07-08 Thread Kevin Cernekee
On Sun, Jul 8, 2012 at 5:33 PM, Alan Stern st...@rowland.harvard.edu wrote: On Sun, 8 Jul 2012, Kevin Cernekee wrote: usb_gadget_remove_driver() runs through a four-step sequence to shut down the gadget driver.  For the case of a composite gadget + at91 UDC, this would look like:     udc