[PATCH v3 3/5] usb: chipidea: imx: set CI_HDRC_IMX28_WRITE_FIX for imx28

2013-10-24 Thread Peter Chen
Due to imx28 needs ARM swp instruction for writing, we set CI_HDRC_IMX28_WRITE_FIX for imx28. Signed-off-by: Peter Chen --- drivers/usb/chipidea/ci_hdrc_imx.c | 32 ++-- 1 files changed, 26 insertions(+), 6 deletions(-) diff --git a/drivers/usb/chipidea/ci_hdrc_imx

[PATCH v3 1/5] usb: ehci: add freescale imx28 special write register method

2013-10-24 Thread Peter Chen
According to Freescale imx28 Errata, "ENGR119653 USB: ARM to USB register error issue", All USB register write operations must use the ARM SWP instruction. So, we implement a special ehci_write for imx28. Discussion for it at below: http://marc.info/?l=linux-usb&m=137996395529294&w=2 Signed-off-b

[PATCH v3 5/5] ARM: dts: imx28: changing usb compatible string as only "fsl,imx28-usb"

2013-10-24 Thread Peter Chen
Due to imx28 usb has special write request, it is not compatible with other imx27 sytle usb controllers. Signed-off-by: Peter Chen --- arch/arm/boot/dts/imx28.dtsi |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/boot/dts/imx28.dtsi b/arch/arm/boot/dts/imx28.d

[PATCH v3 4/5] usb: doc: chipidea: imx: add compatiable string for imx28 SoC

2013-10-24 Thread Peter Chen
Due to imx28 usb has special write requirement compared to other imx SoCs. Signed-off-by: Peter Chen --- Changes for v3: - 4/5, 5/5 are added .../devicetree/bindings/usb/ci13xxx-imx.txt|3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/Documentation/devicetree/bi

[PATCH v3 2/5] usb: chipidea: add freescale imx28 special write register method

2013-10-24 Thread Peter Chen
According to Freescale imx28 Errata, "ENGR119653 USB: ARM to USB register error issue", All USB register write operations must use the ARM SWP instruction. So, we implement special hw_write and hw_test_and_clear for imx28. Discussion for it at below: http://marc.info/?l=linux-usb&m=137996395529294

Re: [RFC PATCH 15/15] checkpatch: allow list_for_each helper macros

2013-10-24 Thread Dan Williams
On Thu, Oct 24, 2013 at 9:48 PM, Paul Zimmerman wrote: >> From: Joe Perches [mailto:j...@perches.com] >> Sent: Thursday, October 24, 2013 9:34 PM >> >> On Fri, 2013-10-25 at 03:52 +, Paul Zimmerman wrote: >> > > From: Dan Williams >> > > Sent: Thursday, October 24, 2013 12:45 AM >> > > >> > >

RE: [RFC PATCH 15/15] checkpatch: allow list_for_each helper macros

2013-10-24 Thread Paul Zimmerman
> From: Joe Perches [mailto:j...@perches.com] > Sent: Thursday, October 24, 2013 9:34 PM > > On Fri, 2013-10-25 at 03:52 +, Paul Zimmerman wrote: > > > From: Dan Williams > > > Sent: Thursday, October 24, 2013 12:45 AM > > > > > > On Thu, Oct 24, 2013 at 12:36 AM, Dan Williams > > > wrote: >

Re: [RFC PATCH 15/15] checkpatch: allow list_for_each helper macros

2013-10-24 Thread Joe Perches
On Fri, 2013-10-25 at 03:52 +, Paul Zimmerman wrote: > > From: Dan Williams > > Sent: Thursday, October 24, 2013 12:45 AM > > > > On Thu, Oct 24, 2013 at 12:36 AM, Dan Williams > > wrote: > > > Permit list_for_each redifinitions like: > > > > > > #define for_each_connector_peer(peer, port, c

RE: [RFC PATCH 15/15] checkpatch: allow list_for_each helper macros

2013-10-24 Thread Paul Zimmerman
> From: Dan Williams > Sent: Thursday, October 24, 2013 12:45 AM > > On Thu, Oct 24, 2013 at 12:36 AM, Dan Williams > wrote: > > Permit list_for_each redifinitions like: > > > > #define for_each_connector_peer(peer, port, c) \ > >list_for_each_entry(peer, &(c)->ports, node) \ > >

Re: [RFC PATCH 04/15] PM / Runtime: Allow drivers to intercept pm qos flag changes

2013-10-24 Thread Dan Williams
Hi Rafael, sorry about the email mix up. On Thu, Oct 24, 2013 at 4:08 PM, Rafael J. Wysocki wrote: >> > + >> > +What: /sys/devices/.../power/pm_qos_no_notify_flags >> > +Date: October 2013 >> > +Contact: Dan Williams >> > +Description: >> > + The /sys/device

Re: [PATCH 3/7] usb-storage: Don't bind to uas devices if the uas driver is enabled

2013-10-24 Thread Hans de Goede
Hi, On 10/24/2013 06:32 PM, Alan Stern wrote: On Thu, 24 Oct 2013, Hans de Goede wrote: uas devices have 2 alternative settings on their usb-storage interface, one for usb-storage and one for uas. Using the uas driver is preferred, so if the uas driver is enabled, and the device has an uas alt

Re: [RFC PATCH 04/15] PM / Runtime: Allow drivers to intercept pm qos flag changes

2013-10-24 Thread Rafael J. Wysocki
On Thursday, October 24, 2013 12:42:36 AM Dan Williams wrote: > [ adding Rafael ] First, this is not the right address to Cc (please check MAINTAINERS in 3.12-rc6), but it still kind of works yet. Second, quite frankly, I don't like this change. > On Thu, Oct 24, 2013 at 12:35 AM, Dan Williams

RE: usb mass storage bug

2013-10-24 Thread Alan Stern
On Thu, 24 Oct 2013, Jánosi Zoli wrote: > I can confirm, that its working without usb otg config. it was the problem > since kernel version 3.10. Then you can close out the Bugzilla entry. Alan Stern > Date: Thu, 24 Oct 2013 12:09:03 -0400 > From: st...@rowland.harvard.edu > To: janosiz...@hot

Account Upgrade

2013-10-24 Thread Web Security
Dear Email User, Your mailbox has exceeded the storage limit which is 20.00 GB as set by your administrator, you are currently running on 19.99 GB, you may not be able to send or receive new mail until you re-validate your email box. Kindly click the link below to re-validate your email account

Re: [RFC PATCH 00/15] rework port power control

2013-10-24 Thread Dan Williams
Hi Alan, thanks for taking a look. On Thu, Oct 24, 2013 at 10:25 AM, Alan Stern wrote: > On Thu, 24 Oct 2013, Dan Williams wrote: > >> Summary: >> Address the following issues for port power control: >> 1/ Port power policy needs 'connector' awareness. >> 2/ Reliable port power control requires c

Account Upgrade

2013-10-24 Thread Web Security
Dear Email User, Your mailbox has exceeded the storage limit which is 20.00 GB as set by your administrator, you are currently running on 19.99 GB, you may not be able to send or receive new mail until you re-validate your email box. Kindly click the link below to re-validate your email account

Re: [PATCH 3/7] usb-storage: Don't bind to uas devices if the uas driver is enabled

2013-10-24 Thread Alan Stern
On Thu, 24 Oct 2013, Hans de Goede wrote: > uas devices have 2 alternative settings on their usb-storage interface, > one for usb-storage and one for uas. Using the uas driver is preferred, so if > the uas driver is enabled, and the device has an uas alt setting, don't bind. We need a mechanism f

Re: [RFC PATCH 00/15] rework port power control

2013-10-24 Thread Alan Stern
On Thu, 24 Oct 2013, Dan Williams wrote: > Summary: > Address the following issues for port power control: > 1/ Port power policy needs 'connector' awareness. > 2/ Reliable port power control requires coordination with khubd. > 3/ Userspace needs full control, but also help coordinating port >

Re: [PATCH 1/7] uas: Add a uas_find_uas_alt_setting helper function

2013-10-24 Thread Hans de Goede
Hi, I forgot one important note. This is currently only tested with qemu's emulated uas device. I'll test it with real hardware when I get back home this weekend. Regards, Hans On 10/24/2013 06:13 PM, Hans de Goede wrote: This is a preparation patch for teaching usb-storage to not bind to ua

[PATCH 6/7] uas: Use proper packet size when submitting reponse urbs

2013-10-24 Thread Hans de Goede
Signed-off-by: Hans de Goede --- drivers/usb/storage/uas.c | 19 --- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/drivers/usb/storage/uas.c b/drivers/usb/storage/uas.c index c618c01..c543bdb 100644 --- a/drivers/usb/storage/uas.c +++ b/drivers/usb/storage/uas.c @

[PATCH 1/7] uas: Add a uas_find_uas_alt_setting helper function

2013-10-24 Thread Hans de Goede
This is a preparation patch for teaching usb-storage to not bind to uas devices. Signed-off-by: Hans de Goede --- drivers/usb/storage/uas.c | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/drivers/usb/storage/uas.c b/drivers/usb/storage/uas.c index 357f1

[PATCH 4/7] uas: Pack iu struct definitions

2013-10-24 Thread Hans de Goede
The iu struct definitions are usb packet definitions, so no alignment should happen. Notice for most of the structs this does not make a difference (assuming 32 bit alignment). The only case this actually makes a difference for is the response_ui struct, which keeps all its members at the same plac

[PATCH 5/7] uas: s/response_ui/response_iu/

2013-10-24 Thread Hans de Goede
Signed-off-by: Hans de Goede --- drivers/usb/storage/uas.c | 2 +- include/linux/usb/uas.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/storage/uas.c b/drivers/usb/storage/uas.c index 9969632..c618c01 100644 --- a/drivers/usb/storage/uas.c +++ b/drivers/usb

[PATCH 3/7] usb-storage: Don't bind to uas devices if the uas driver is enabled

2013-10-24 Thread Hans de Goede
uas devices have 2 alternative settings on their usb-storage interface, one for usb-storage and one for uas. Using the uas driver is preferred, so if the uas driver is enabled, and the device has an uas alt setting, don't bind. Signed-off-by: Hans de Goede --- drivers/usb/storage/usb.c | 10

[PATCH 2/7] uas: Move uas detect code to uas-detect.h

2013-10-24 Thread Hans de Goede
This is a preparation patch for teaching usb-storage to not bind to uas devices. Signed-off-by: Hans de Goede --- drivers/usb/storage/uas-detect.h | 40 drivers/usb/storage/uas.c| 40 ++-- 2 files changed, 42 in

[PATCH 7/7] uas: Use all available stream ids

2013-10-24 Thread Hans de Goede
If we get ie 16 streams we can use stream-id 1-16, not 1-15. Signed-off-by: Hans de Goede --- drivers/usb/storage/uas.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/usb/storage/uas.c b/drivers/usb/storage/uas.c index c543bdb..d6a575b 100644 --- a/drivers/usb/

[PATCH 0/7] uas: Final set of uas fixes

2013-10-24 Thread Hans de Goede
Hi All, This is / should be my final set of uas fixes. After this set my uas to-do list is empty and uas should be in good shape to go into 3.14 . Regards, Hans -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majo

Re: Controller's wakeup setting at usb_add_hcd

2013-10-24 Thread Alan Stern
On Thu, 24 Oct 2013, Peter Chen wrote: > It is the same which the embedded world does, that is the physical wakeup > setting is controlled by software flag. Since it is the controller's wakeup, > why the controller driver does not go to control the software flag in general? > > The current proble

Re: choice =y selection becomes lost after having multiple entries =m with depends on

2013-10-24 Thread Dirk Gouders
Sebastian Andrzej Siewior writes: > On 10/24/2013 05:30 PM, Dirk Gouders wrote: >> Hi Sebastian, > > Hi Dirk, > >> I was looking at what you described and initially had a hard time to >> reproduce the problem, probably because I tried it after `make >> mrproper'. I am only able to reproduce the

Re: choice =y selection becomes lost after having multiple entries =m with depends on

2013-10-24 Thread Sebastian Andrzej Siewior
On 10/24/2013 05:30 PM, Dirk Gouders wrote: > Hi Sebastian, Hi Dirk, > I was looking at what you described and initially had a hard time to > reproduce the problem, probably because I tried it after `make > mrproper'. I am only able to reproduce the problem with an existing > .config of my runni

Re: usb mass storage bug

2013-10-24 Thread Alan Stern
On Thu, 24 Oct 2013, [iso-8859-2] J�nosi Zoli wrote: > https://bugzilla.kernel.org/show_bug.cgi?id=63611 > � > Bug ID: 63611 > Summary: cant connect sony phones in mass storage mode Is CONFIG_USB_OTG turned on in your kernel's .config? If it is, try building a new kernel with it turned off. Fe

Re: choice =y selection becomes lost after having multiple entries =m with depends on

2013-10-24 Thread Dirk Gouders
Sebastian Andrzej Siewior writes: > On 10/23/2013 01:23 PM, Yann E. MORIN wrote: >> Sebastian, All, > > Hi Yann, > >> So, I've tried your tests here, and indeed it does not behave as >> expected. Yet, I can observe a slight deviation from your observations: >> the third time I enter the "USB Gadg

Re: [GIT PULL] USB patches

2013-10-24 Thread Felipe Balbi
On Thu, Oct 24, 2013 at 04:20:43PM +0100, Greg KH wrote: > On Mon, Oct 21, 2013 at 06:50:42AM -0500, Felipe Balbi wrote: > > Hi Greg, > > > > Here's a large set of patches for v3.13 merge window. All patches have > > been pending in linux-usb for quite a while and soaked in linux-next > > for a bi

Re: LTE vodafone K5150 (hilink) 12d1 1f16 ; 12d1 1575 mbim?

2013-10-24 Thread Thomas Schäfer
Am 24.10.2013 11:45, schrieb Bjørn Mork: Any chance you could snoop the Windows IPv6 session? I'm interesting in seeing the NS and NA messages. In particular any NA from Windows. Don't need many packets, only the part where the modem tries to discover the host "L2 address". To answering one q

Re: [GIT PULL] USB patches

2013-10-24 Thread Greg KH
On Mon, Oct 21, 2013 at 06:50:42AM -0500, Felipe Balbi wrote: > Hi Greg, > > Here's a large set of patches for v3.13 merge window. All patches have > been pending in linux-usb for quite a while and soaked in linux-next > for a bit too. > > Please consider merging on top of your usb-next branch or

[PATCH] usb: wusbcore: remove unneccessary byte-swap when assigning RPIPE wMaxPacketSize

2013-10-24 Thread Thomas Pugliese
This patch removes an unneccessary byte-swap when assigning RPIPE wMaxPacketSize. Both sides of the assignment are __le16 members of a USB descriptor so no byte swap is needed. This patch is against 3.11.6 and is intended for -stable. Signed-off-by: Thomas Pugliese Cc: --- drivers/usb/wusbcor

[PATCH] usb: wusbcore: change WA_SEGS_MAX to a legal value

2013-10-24 Thread Thomas Pugliese
Change WA_SEGS_MAX to a number that is legal according to the WUSB spec and correct the test for exceeding this value. This patch is against 3.11.6 and is intended for -stable. Signed-off-by: Thomas Pugliese Cc: --- drivers/usb/wusbcore/wa-xfer.c |5 +++-- 1 file changed, 3 insertions(+)

RE: transmit lockup using smsc95xx ethernet on usb3

2013-10-24 Thread David Laight
> Have you tried the latest stable kernel or the latest -rc kernel? I've built a kernel based on Linus's tree from last Friday, 3.12-rc6 ish. Commented out the trace for short reads - happens all the time. I've not seen an error on a Bo yet, the failure rate is depressingly low. I have had an err

Re: Controller's wakeup setting at usb_add_hcd

2013-10-24 Thread Peter Chen
On Thu, Oct 24, 2013 at 10:25:25AM -0400, Alan Stern wrote: > On Thu, 24 Oct 2013, Peter Chen wrote: > > > > If the HC is deleted and the UDC is added then the wakeup settings > > > should be determined by the UDC, not by the HC. The next time the > > > system goes to sleep, the UDC driver should

Re: [PATCH 4/4] usb: wusbcore: change WA_SEGS_MAX to a legal value

2013-10-24 Thread Thomas Pugliese
On Thu, 24 Oct 2013, Greg KH wrote: > On Thu, Oct 24, 2013 at 10:04:08AM +0200, Oliver Neukum wrote: > > On Wed, 2013-10-23 at 14:44 -0500, Thomas Pugliese wrote: > > > change WA_SEGS_MAX to a number that is legal according to the WUSB > > > spec. > > > > > > Signed-off-by: Thomas Pugliese >

Re: Controller's wakeup setting at usb_add_hcd

2013-10-24 Thread Alan Stern
On Thu, 24 Oct 2013, Peter Chen wrote: > > If the HC is deleted and the UDC is added then the wakeup settings > > should be determined by the UDC, not by the HC. The next time the > > system goes to sleep, the UDC driver should be responsible for enabling > > or disabling wakeup. > > > > I agre

Re: pl2303 driver regression after commit 61fa8d694b854

2013-10-24 Thread Frank Schäfer
Am 24.10.2013 14:21, schrieb Mika Westerberg: > Hi, > > Just noticed that after commit 61fa8d694b854 (usb: pl2303: also use the > divisor based baud rate encoding method for baud rates < 115200 with HX > chips) my TRENDnet TU-S9 USB-to-serial adapter started corrupting data. > > I added baud <= 115

Re: [Patch v2 09/10] usb: chipidea: host: add ehci quirk for imx controller

2013-10-24 Thread Peter Chen
On Thu, Oct 24, 2013 at 07:04:11AM -0500, Felipe Balbi wrote: > Hi, > > On Thu, Oct 24, 2013 at 09:33:26AM +0800, Peter Chen wrote: > > On Wed, Oct 23, 2013 at 02:45:39PM -0400, Alan Stern wrote: > > > On Wed, 23 Oct 2013, Felipe Balbi wrote: > > > > > > > Hi, > > > > > > > > On Wed, Oct 23, 201

pl2303 driver regression after commit 61fa8d694b854

2013-10-24 Thread Mika Westerberg
Hi, Just noticed that after commit 61fa8d694b854 (usb: pl2303: also use the divisor based baud rate encoding method for baud rates < 115200 with HX chips) my TRENDnet TU-S9 USB-to-serial adapter started corrupting data. I added baud <= 115200 check back to the comparison which makes the device wo

Re: [Patch v2 09/10] usb: chipidea: host: add ehci quirk for imx controller

2013-10-24 Thread Felipe Balbi
Hi, On Thu, Oct 24, 2013 at 09:33:26AM +0800, Peter Chen wrote: > On Wed, Oct 23, 2013 at 02:45:39PM -0400, Alan Stern wrote: > > On Wed, 23 Oct 2013, Felipe Balbi wrote: > > > > > Hi, > > > > > > On Wed, Oct 23, 2013 at 10:46:09AM -0400, Alan Stern wrote: > > > > On Tue, 22 Oct 2013, Peter Chen

usb mass storage bug

2013-10-24 Thread Jánosi Zoli
https://bugzilla.kernel.org/show_bug.cgi?id=63611   Bug ID: 63611 Summary: cant connect sony phones in mass storage mode -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo i

Re: [PATCH 4/4] usb: wusbcore: change WA_SEGS_MAX to a legal value

2013-10-24 Thread Greg KH
On Thu, Oct 24, 2013 at 10:04:08AM +0200, Oliver Neukum wrote: > On Wed, 2013-10-23 at 14:44 -0500, Thomas Pugliese wrote: > > change WA_SEGS_MAX to a number that is legal according to the WUSB > > spec. > > > > Signed-off-by: Thomas Pugliese > > This should go to stable. Good catch, I'll do t

[PATCH v2 3/3] usb: chipidea: imx: set CI_HDRC_IMX28_WRITE_FIX for imx28

2013-10-24 Thread Peter Chen
Due to imx28 needs ARM swp instruction for writing, we set CI_HDRC_IMX28_WRITE_FIX for imx28. Signed-off-by: Peter Chen --- Changes for v2: - Using of_device_id->data to get platform's flag drivers/usb/chipidea/ci_hdrc_imx.c | 32 ++-- 1 files changed, 26 insertio

[PATCH v2 1/3] usb: ehci: add freescale imx28 special write register method

2013-10-24 Thread Peter Chen
According to Freescale imx28 Errata, "ENGR119653 USB: ARM to USB register error issue", All USB register write operations must use the ARM SWP instruction. So, we implement a special ehci_write for imx28. Discussion for it at below: http://marc.info/?l=linux-usb&m=137996395529294&w=2 Signed-off-b

[PATCH v2 2/3] usb: chipidea: add freescale imx28 special write register method

2013-10-24 Thread Peter Chen
According to Freescale imx28 Errata, "ENGR119653 USB: ARM to USB register error issue", All USB register write operations must use the ARM SWP instruction. So, we implement special hw_write and hw_test_and_clear for imx28. Discussion for it at below: http://marc.info/?l=linux-usb&m=137996395529294

Re: LTE vodafone K5150 (hilink) 12d1 1f16 ; 12d1 1575 mbim?

2013-10-24 Thread Bjørn Mork
Thomas Schäfer writes: > Hi, > > I have some news about this device. Under Windows 8.1 (6.3)(testversion) > with these IDs: > > USB\VID_12D1&PID_1F16&REV_0102&MI_00 > USB\VID_12D1&PID_1F16&MI_00 > > USB\Class_02&SubClass_0e&Prot_00 > USB\Class_02&SubClass_0e > USB\Class_02 > > > the device works

Re: [PATCH 1/4] usb: wusbcore: set the RPIPE wMaxPacketSize value correctly

2013-10-24 Thread Oliver Neukum
On Wed, 2013-10-23 at 16:14 -0500, Thomas Pugliese wrote: > > On Thu, 24 Oct 2013, Sergei Shtylyov wrote: > > > Hello. > > > > On 10/23/2013 11:44 PM, Thomas Pugliese wrote: > > > > > For isochronous endpoints, set the RPIPE wMaxPacketSize value using > > > wOverTheAirPacketSize from the endpoi

Re: [PATCH 4/4] usb: wusbcore: change WA_SEGS_MAX to a legal value

2013-10-24 Thread Oliver Neukum
On Wed, 2013-10-23 at 14:44 -0500, Thomas Pugliese wrote: > change WA_SEGS_MAX to a number that is legal according to the WUSB > spec. > > Signed-off-by: Thomas Pugliese This should go to stable. Regards Oliver -- To unsubscribe from this list: send the line "unsubscr

Re: [RFC PATCH 15/15] checkpatch: allow list_for_each helper macros

2013-10-24 Thread Dan Williams
[ adding Andy and Joe ] On Thu, Oct 24, 2013 at 12:36 AM, Dan Williams wrote: > Permit list_for_each redifinitions like: > > #define for_each_connector_peer(peer, port, c) \ >list_for_each_entry(peer, &(c)->ports, node) \ >if (port != peer) > > ...which triggers: > ERROR:

Re: [PATCH 1/4] usb: usbtest: support bos descriptor test for usb 3.0

2013-10-24 Thread Huang Rui
On Mon, Oct 21, 2013 at 11:50:39AM -0400, Alan Stern wrote: > On Mon, 21 Oct 2013, Huang Rui wrote: > > > In Test 9 of usbtest module, it is used for performing chapter 9 tests N > > times. This patch adds to support getting bos descriptor test scenario for > > USB 3.0. > > > > Signed-off-by: Hua

Re: [RFC PATCH 04/15] PM / Runtime: Allow drivers to intercept pm qos flag changes

2013-10-24 Thread Dan Williams
[ adding Rafael ] On Thu, Oct 24, 2013 at 12:35 AM, Dan Williams wrote: > ...because struct dev_pm_ops is too clean and uniform. > > USB port power management needs to manage ports that are colocated in a > given connector. If we power down a connector we need to arrange for > the peer port in t

[RFC PATCH 14/15] usbcore: add usbcore.noacpi

2013-10-24 Thread Dan Williams
Port power management places a lot of trust in the firmware api tables. Set this flag if it turns out that trust was misplaced. Signed-off-by: Dan Williams --- Documentation/kernel-parameters.txt |4 drivers/usb/core/usb-acpi.c |7 +++ 2 files changed, 11 insertions(+),

[RFC PATCH 08/15] usbcore: kill ->is_power_on and ->did_runtime_put

2013-10-24 Thread Dan Williams
->is_power_on can now be reliably determined by looking at the power policy and the runtime status. ->did_runtime_put is handled automatically by the pm_runtime parent-child relationship. A few other cleanups fall out: 1/ No longer any need for usb_hub_set_port_power 2/ hub_power_on() only ever

[RFC PATCH 10/15] usbcore: cleanup hub_port_connect_change and hub_power_on

2013-10-24 Thread Dan Williams
Before adding another hub->ports[port1 - 1] invocation just convert to local port_dev. Signed-off-by: Dan Williams --- drivers/usb/core/hub.c |9 + 1 files changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c index 3324cf5fd253..d1a08

[RFC PATCH 06/15] usbcore: make usb_port a proper parent of a usb_device

2013-10-24 Thread Dan Williams
We jump through a few hoops to support maintaining a usb_port as a sibling of a usb_device. Namely ->power_is_on and ->did_runtime_put are artifacts of pm_ignore_children and the organization of the device tree. Re-organize the hierarchy to enable using the runtime_status as the indicator of wheth

[RFC PATCH 12/15] usbcore: allow the connect_type of ports to be changed

2013-10-24 Thread Dan Williams
hotplug ports maintain power awaiting hotplug events. Allow userspace to override this disctinction on a per port basis. Signed-off-by: Dan Williams --- drivers/usb/core/port.c | 32 +- drivers/usb/core/usb-platform.c | 42

[RFC PATCH 15/15] checkpatch: allow list_for_each helper macros

2013-10-24 Thread Dan Williams
Permit list_for_each redifinitions like: #define for_each_connector_peer(peer, port, c) \ list_for_each_entry(peer, &(c)->ports, node) \ if (port != peer) ...which triggers: ERROR: Macros with complex values should be enclosed in parenthesis Cc: Andrew Morton Cc: Joe Perch

[RFC PATCH 11/15] usbcore: power down peer port on endpoint connect

2013-10-24 Thread Dan Williams
Once a port connects to a non-hub device disable its peer until disconnect. This enables safe power cycling of the port that is to remain connected. Otherwise, if a connected port is powered off while the peer remains powered the device may attempt to change speeds and connect to the secondary po

[RFC PATCH 07/15] usbcore: pm_runtime honor children

2013-10-24 Thread Dan Williams
Now that ports are in the hierarchy above endpoints we can take advantage of the automatic power management of the device tree. There is now no need to power manage the hub in usb_port_runtime_{suspend|resume} Signed-off-by: Dan Williams --- drivers/usb/core/hub.c |2 -- drivers/usb/core/p

[RFC PATCH 13/15] usbcore: show port power policy

2013-10-24 Thread Dan Williams
Let userspace determine the effective power policy of the port. Reading the power policy returns the effective idle state for the port. If the power policy is set to off this file effectively becomes the power/runtime_status of an attached child device, otherwise it reflects the state of pm_qos_n

[RFC PATCH 09/15] usbcore: convert khubd to a workqueue and flush khubd on port power off

2013-10-24 Thread Dan Williams
For reliable port power management we want to be sure that khubd is only taking actions on active ports. Towards that end we need to mark the ports us undergoing a power transition and stop khubd actions on the port. The existing hub->busy_bits attempt this notification, but it is not synchronize

[RFC PATCH 01/15] usb: xhci: fix memleak on module removal

2013-10-24 Thread Dan Williams
We currently leak the ->shared_hcd because ->stop() clears the pointer thus preventing xhci_pci_remove() from doing its cleanup of the USB3 hcd. Regarding the cases mentioned in the comment the code is prepared to either abort initialization and continue the startup, or relies on ->shared_hcd bei

[RFC PATCH 04/15] PM / Runtime: Allow drivers to intercept pm qos flag changes

2013-10-24 Thread Dan Williams
...because struct dev_pm_ops is too clean and uniform. USB port power management needs to manage ports that are colocated in a given connector. If we power down a connector we need to arrange for the peer port in the connector to also be suspended. If the peer connector stays active it may cause

[RFC PATCH 05/15] usbcore: port power policy / prep for usb_port as usb_device parent

2013-10-24 Thread Dan Williams
To simplify and harden port power management the port needs to be a proper parent of a connected child, and the hub needs to check whether a port has power before performing actions on it. However, we also want the capability to suspend hubs and connected devices while port power is enabled. So,

[RFC PATCH 03/15] usbcore: add sysfs linkage for connector peers

2013-10-24 Thread Dan Williams
Use the "connector" association information provided by platform firmware to create links between peer ports in a connector. Signed-off-by: Dan Williams --- drivers/usb/core/usb-platform.c | 51 +-- 1 files changed, 49 insertions(+), 2 deletions(-) diff --g

[RFC PATCH 02/15] usbcore: introduce usb_domain for tracking port-connector relationships

2013-10-24 Thread Dan Williams
Platform firmware identifies ports that share a connector. This information is relevant for port power control since we do not want a device to reconnect on its peer port in a connector when pm has decided to power-off its currently connected port. In the case of xhci, peer ports are attached thr

[RFC PATCH 00/15] rework port power control

2013-10-24 Thread Dan Williams
Summary: Address the following issues for port power control: 1/ Port power policy needs 'connector' awareness. 2/ Reliable port power control requires coordination with khubd. 3/ Userspace needs full control, but also help coordinating port power policy. Even with these changes port power cont

[PATCH 1/1] ax88179_178a: Remove AX_MEDIUM_ALWAYS_ONE bit in AX_MEDIUM_STATUS_MODE register to avoid TX throttling

2013-10-24 Thread freddy
From: Freddy Xin Remove AX_MEDIUM_ALWAYS_ONE in AX_MEDIUM_STATUS_MODE register. Setting this bit may cause TX throttling in Half-Duplex mode. Signed-off-by: Freddy Xin --- drivers/net/usb/ax88179_178a.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/n