Re: [USB EHCI DRIVER] [Regression] EHCI no longer working in 5.4 series kernel

2019-10-20 Thread Ben
edikt Schemmer wrote: reverting that specific commit on top of todays linux git (d418d070057c) produces a good kernel Hi Ben, the fix is in https://lore.kernel.org/lkml/20191008143357.ga599...@rani.riverdale.lan/ Am 18.10.19 um 00:31 schrieb Alan Stern: On Thu, 17 Oct 2019, Benedikt Schemmer

Re: [PATCH] usb: cdns3: include host-export,h for cdns3_host_init

2019-10-18 Thread Ben Dooks
port.h as static. I know, this isn't being made static, that's a warning. For me It doesn't look like driver issue. Signed-off-by: Ben Dooks --- Cc: Greg Kroah-Hartman Cc: Pawel Laszczak Cc: Felipe Balbi Cc: "Ben Dooks Cc: linux-usb@vger.kernel.org --- drivers/usb/cdn

[PATCH] usb: mtu3: fix missing include of mtu3_dr.h

2019-10-17 Thread Ben Dooks (Codethink)
be static? drivers/usb/mtu3/mtu3_core.c:925:6: warning: symbol 'ssusb_gadget_exit' was not declared. Should it be static? Signed-off-by: Ben Dooks --- Cc: Chunfeng Yun Cc: Greg Kroah-Hartman Cc: linux-usb@vger.kernel.org Cc: linux-arm-ker...@lists.infradead.org Cc: linux-media...

[PATCH] usb: host: oxu210hp-hcd: fix __iomem annotations

2019-10-17 Thread Ben Dooks (Codethink)
* Signed-off-by: Ben Dooks --- Cc: Greg Kroah-Hartman Cc: linux-usb@vger.kernel.org --- drivers/usb/host/oxu210hp-hcd.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/usb/host/oxu210hp-hcd.c b/drivers/usb/host/oxu210hp-hcd.c index e67242e437ed..fe09b8626329

[PATCH] usb: cdns3: include host-export,h for cdns3_host_init

2019-10-17 Thread Ben Dooks (Codethink)
'cdns3_host_init' was not declared. Should it be static? Signed-off-by: Ben Dooks --- Cc: Greg Kroah-Hartman Cc: Pawel Laszczak Cc: Felipe Balbi Cc: "Ben Dooks Cc: linux-usb@vger.kernel.org --- drivers/usb/cdns3/host-export.h | 1 - drivers/usb/cdns3/host.c| 1 + 2 f

Re: [PATCH lora-next 3/5] net: lora: sx130x: Add PicoCell serdev driver

2019-01-05 Thread Ben Whitten
;Removed\n"); +} + +static const struct of_device_id picogw_serdev_of_match[] = { + { .compatible = "semtech,lora-picocell" }, lora-picocell or lora-picogw... picocell has mobile connotations, should we match the module name? + {} +}; +MODULE_DEVICE_TABLE(of, picogw_serdev_of_match); + +static struct serdev_device_driver picogw_serdev_driver = { + .probe = picogw_serdev_probe, + .remove = picogw_serdev_remove, + .driver = { + .name = "lora-picogw", + .of_match_table = picogw_serdev_of_match, + }, +}; + +static int __init picogw_serdev_init(void) +{ + int ret; + + ret = serdev_device_driver_register(&picogw_serdev_driver); + if (ret) { + pr_err("serdev_device_driver_register failed (%d)", ret); + return ret; + } + + return 0; +} +module_init(picogw_serdev_init); + +static void __exit picogw_serdev_exit(void) +{ + serdev_device_driver_unregister(&picogw_serdev_driver); +} +module_exit(picogw_serdev_exit); + +MODULE_LICENSE("GPL"); Thanks, Ben Whitten

Re: [PATCH] USB: host: ehci: allow tine of highspeed nak-count

2018-11-19 Thread Ben Dooks
On Fri, Nov 16, 2018 at 10:38:18AM -0500, Alan Stern wrote: > On Fri, 16 Nov 2018, Ben Dooks wrote: > > > On 14/11/18 18:47, Alan Stern wrote: > > > On Wed, 14 Nov 2018, Ben Dooks wrote: > > > > > >> From: Ben Dooks > > >> > > >

[PATCH] usbnet: use tasklet_init() for usbnet_bh handler

2018-11-16 Thread Ben Dooks
The tasklet initialisation would be better done by tasklet_init() instead of assuming all the fields are in an ok state by default. Note, this does not fix any known bug. Signed-off-by: Ben Dooks --- drivers/net/usb/usbnet.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a

Re: [PATCH] USB: host: ehci: allow tine of highspeed nak-count

2018-11-16 Thread Ben Dooks
On 14/11/18 18:47, Alan Stern wrote: On Wed, 14 Nov 2018, Ben Dooks wrote: From: Ben Dooks At least some systems benefit with less scheduling if the NAK count value is set higher than the default 4. For instance a Tegra3 with an SMSC9512 showed less interrupt load when this was changed to 14

Re: SMSC95xx driver updates (round 1)

2018-11-16 Thread Ben Dooks
On 15/11/18 18:06, woojung@microchip.com wrote: Hi Ben, -Original Message- From: netdev-ow...@vger.kernel.org On Behalf Of Ben Dooks Sent: Wednesday, November 14, 2018 6:50 AM To: net...@vger.kernel.org Cc: oneu...@suse.com; da...@davemloft.net; linux-usb@vger.kernel.org; linux

[PATCH] USB: host: ehci: allow tine of highspeed nak-count

2018-11-14 Thread Ben Dooks
From: Ben Dooks At least some systems benefit with less scheduling if the NAK count value is set higher than the default 4. For instance a Tegra3 with an SMSC9512 showed less interrupt load when this was changed to 14. To allow the changing of this value, add a sysfs node to each of the

[PATCH 1/4] usbnet: smsc95xx: fix rx packet alignment

2018-11-14 Thread Ben Dooks
with the start on an aligned address. Tested on Raspberry Pi B3. Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c index 06b4d290784d..401ec9feb495 100644 --- a/drivers/net/usb

SMSC95xx driver updates (round 1)

2018-11-14 Thread Ben Dooks
This is a series of a few driver cleanups and some fixups of the code for the SMSC95XX driver. There have been a few reviews, and the issues have been fixed so this should be ready for merging. I will work on the tx-alignment and the other bits of usbnet changes and produce at least two more patch

[PATCH 2/4] usbnet: smsc95xx: simplify tx_fixup code

2018-11-14 Thread Ben Dooks
to LE32 conversion as well and makes the whole sequence easier to understand hopefully. Signed-off-by: Ben Dooks --- Since v1: - Add alignment changes using put_unaligned_le32() --- drivers/net/usb/smsc95xx.c | 28 +--- 1 file changed, 13 insertions(+), 15 deletions

[PATCH 3/4] usbnet: smsc95xx: fix memcpy for accessing rx-data

2018-11-14 Thread Ben Dooks
Change the RX code to use get_unaligned_le32() instead of the combo of memcpy and cpu_to_le32s(&var). Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c i

[PATCH 4/4] usbnet: smsc95xx: check for csum being in last four bytes

2018-11-14 Thread Ben Dooks
option makes it more likely to happen. Signed-off-by: Ben Dooks --- Fixes for v2: - Fix spelling of check at Sergei's suggestion - Move skb->len check into smsc95xx_can_tx_checksum() - Change name of smsc95xx_can_checksum to explicitly say it is tx-csum --- drivers/net/usb/smsc95x

Re: [PATCH 3.16] staging: usbip stub_rx fix static checker warning on unnecessary checks

2018-11-10 Thread Ben Hutchings
cmd_submit.transfer_buffer_length <= ((~0 >> > 1))) => (s32min-s32max <= s32max)' I've finally queued this up, thanks. Ben. > Reported-by: Dan Carpenter > Signed-off-by: Shuah Khan > --- > drivers/staging/usbip/stub_rx.c | 11 +-- > 1 file changed, 1

Re: [PATCH 4/7] net: qmi_wwan: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
On 12/10/18 11:44, Bjørn Mork wrote: Ben Dooks writes: +static inline struct qmi_wwan_state *usbnet_to_qmi(struct usbnet *usb) +{ + return (void *) &usb->data; +} checkpatch doesn't like this, and it is also inconsistent with the coding style elsewhere in the driver. T

[PATCH 2/7] net: asix: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
There are a number of places in the asix driver where it gets the private-data from the usbnet passed in. It would be sensible to have one inline function to convert it and change all points in the driver to use that. Signed-off-by: Ben Dooks --- drivers/net/usb/asix.h | 5

[PATCH 6/7] net: huawei_cdc_ncm: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
There are a number of places in the huawei driver where it gets the private-data from the usbnet passed in. It would be sensible to have one inline function to convert it and change all points in the driver to use that. Signed-off-by: Ben Dooks --- --- drivers/net/usb/huawei_cdc_ncm.c | 15

[PATCH 1/7] net: smsc75xx: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
There are a number of places in the smsc75xx driver where it gets the private-data from the usbnet passed in. It would be sensible to have one inline function to convert it and change all points in the driver to use that. Signed-off-by: Ben Dooks --- drivers/net/usb/smsc75xx.c | 31

usbnet private-data accessor functions

2018-10-12 Thread Ben Dooks
I have been looking at the usbnet drivers and the possibility of some code cleanups. One of the things I've found is that changing the way the drivers use the private data with the usbnet structure is often hand-coded each time is needed. An easy cleanp (and making it easier in the future to chang

[PATCH 3/7] net: usb: asix88179_178a: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
There are a number of places in the asix88179_178a driver where it gets the private-data from the usbnet passed in. It would be sensible to have one inline function to convert it and change all points in the driver to use that. Signed-off-by: Ben Dooks --- drivers/net/usb/ax88179_178a.c | 19

[PATCH 4/7] net: qmi_wwan: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
There are a number of places in the qmi_wwan driver where it gets the private-data from the usbnet passed in. It would be sensible to have one inline function to convert it and change all points in the driver to use that. Signed-off-by: Ben Dooks --- drivers/net/usb/qmi_wwan.c | 31

[PATCH 7/7] net: usb: sr9800: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
There are a number of places in the sr8900 driver where it gets the private-data from the usbnet passed in. It would be sensible to have one inline function to convert it and change all points in the driver to use that. Signed-off-by: Ben Dooks --- drivers/net/usb/sr9800.c | 15

[PATCH 5/7] net: cdc_ether: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
There are a number of places in the cdc drivers where it gets the private-data from the usbnet passed in. It would be sensible to have one inline function to convert it and change all points in the driver to use that. Signed-off-by: Ben Dooks --- drivers/net/usb/cdc_ether.c | 8 ++--- drivers

SMSC95XX updates for packet alignment and turbo mode (V2)

2018-10-12 Thread Ben Dooks
This is the new seris of SMSC95XX patches to deal with the issues we found when working on this driver for a client. The new series has been tested on an Raspberry Pi3 B. Changes since v1: - Change memcpy to use {get,put}_unaligned_le32() calls - Merge tx fixups - Added rx_turbo attribute

[PATCH 3/8] usbnet: smsc95xx: simplify tx_fixup code

2018-10-12 Thread Ben Dooks
to LE32 conversion as well and makes the whole sequence easier to understand hopefully. Signed-off-by: Ben Dooks --- Since v1: - Add alignment changes using put_unaligned_le32() --- drivers/net/usb/smsc95xx.c | 28 +--- 1 file changed, 13 insertions(+), 15 deletions

[PATCH 5/8] usbnet: smsc95xx: align tx-buffer to word

2018-10-12 Thread Ben Dooks
The tegra EHCI driver requires alignment of the buffer, so try and make this better by pushing the buffer start back to an word aligned address. At the worst this makes memcpy() easier as it is word aligned, at best it makes sure the usb can directly map the buffer. Signed-off-by: Ben Dooks

[PATCH 6/8] usbnet: smsc95xx: fix memcpy for accessing rx-data

2018-10-12 Thread Ben Dooks
Change the RX code to use get_unaligned_le32() instead of the combo of memcpy and cpu_to_le32s(&var). Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c i

[PATCH 8/8] usbnet: smsc95xx: add rx_turbo attribute

2018-10-12 Thread Ben Dooks
Add attribute for the rx_turbo mode to allow run-time configuration of this feature. Note, this requires a restart of the device to take effect. Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 41 +- 1 file changed, 40 insertions(+), 1 deletion

[PATCH 2/8] usbnet: smsc95xx: add kconfig for turbo mode

2018-10-12 Thread Ben Dooks
Add a configuration option for the default state of turbo mode on the smsc95xx networking driver. Some systems it is better to default this to off as it causes significant increases in soft-irq load. Signed-off-by: Ben Dooks --- drivers/net/usb/Kconfig| 13 + drivers/net/usb

[PATCH 1/8] usbnet: smsc95xx: fix rx packet alignment

2018-10-12 Thread Ben Dooks
with the start on an aligned address. Tested on Raspberry Pi B3. Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c index 06b4d290784d..401ec9feb495 100644 --- a/drivers/net/usb

[PATCH 4/8] usbnet: smsc95xx: check for csum being in last four bytes

2018-10-12 Thread Ben Dooks
option makes it more likely to happen. Signed-off-by: Ben Dooks --- Fixes for v2: - Fix spelling of check at Sergei's suggestion - Move skb->len check into smsc95xx_can_tx_checksum() - Change name of smsc95xx_can_checksum to explicitly say it is tx-csum --- drivers/net/usb/smsc95x

[PATCH 7/8] usbnet: smsc95xx: add usbnet -> priv function

2018-10-12 Thread Ben Dooks
There are a number of places in the smsc95xx driver where it gets the private-data from the usbnet passed in. It would be sensible to have one inline function to convert it and change all points in the driver to use that. Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 47

[PATCH] net: cdc_ncm: use tasklet_init() for tasklet_struct init

2018-10-11 Thread Ben Dooks
The tasklet initialisation would be better done by tasklet_init() instead of assuming all the fields are in an ok state by default. This does not fix any actual know bug. Signed-off-by: Ben Dooks --- drivers/net/usb/cdc_ncm.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git

[PATCH] usbip: vhci_hcd: Check rhport everywhere in vhci_hub_control()

2018-10-10 Thread Ben Hutchings
nge check. Fixes: 5b22f676118f ("usbip: vhci_hcd: check rhport before using in ...") Cc: sta...@vger.kernel.org Signed-off-by: Ben Hutchings --- drivers/usb/usbip/vhci_hcd.c | 17 ++--- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/drivers/usb/usbip/vhci_h

Re: [PATCH] usbnet: smsc95xx: simplify tx_fixup code

2018-10-06 Thread Ben Dooks
On 2018-10-05 22:24, David Miller wrote: From: Ben Dooks Date: Tue, 2 Oct 2018 17:56:02 +0100 - memcpy(skb->data, &tx_cmd_a, 4); + ptr = skb_push(skb, 8); + tx_cmd_a = cpu_to_le32(tx_cmd_a); + tx_cmd_b = cpu_to_le32(tx_cmd_b); + memcpy(ptr, &

Re: [Linux-kernel] [PATCH 3/4] usbnet: smsc95xx: check for csum being in last four bytes

2018-10-04 Thread Ben Hutchings
On Tue, 2018-10-02 at 10:26 +0100, Ben Dooks wrote: [...] > @@ -2031,7 +2045,8 @@ static struct sk_buff *smsc95xx_tx_fixup(struct usbnet > *dev, > >   } >   >   if (csum) { > - if (skb->len <= 45) { > + /* note, csum does not work i

Re: [Linux-kernel] [PATCH 2/4] usbnet: smsc95xx: align tx-buffer to word

2018-10-04 Thread Ben Hutchings
On Tue, 2018-10-02 at 10:26 +0100, Ben Dooks wrote: > The tegra driver requires alignment of the buffer, so try and > make this better by pushing the buffer start back to an word > aligned address. At the worst this makes memcpy() easier as > it is word aligned, at best it makes sure

RE: [PATCH] usbnet: smsc95xx: simplify tx_fixup code

2018-10-03 Thread Ben Dooks
On 2018-10-03 14:36, David Laight wrote: From: Ben Dooks Sent: 02 October 2018 17:56 The smsc95xx_tx_fixup is doing multiple calls to skb_push() to put an 8-byte command header onto the packet. It would be easier to do one skb_push() and then copy the data in once the push is done. Signed-off

[PATCH] usbnet: smsc95xx: simplify tx_fixup code

2018-10-02 Thread Ben Dooks
The smsc95xx_tx_fixup is doing multiple calls to skb_push() to put an 8-byte command header onto the packet. It would be easier to do one skb_push() and then copy the data in once the push is done. Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 25 + 1 file

Re: [PATCH 2/4] usbnet: smsc95xx: align tx-buffer to word

2018-10-02 Thread Ben Dooks
On 02/10/18 14:19, David Laight wrote: From: Ben Dooks Sent: 02 October 2018 10:27 The tegra driver requires alignment of the buffer, so try and make this better by pushing the buffer start back to an word aligned address. At the worst this makes memcpy() easier as it is word aligned, at best

SMSC95XX driver updates

2018-10-02 Thread Ben Dooks
I have been doing some work with tegra3 systems which have a smsc9512 USB network device on them. A couple of issues we found with alignment of the data (both receive and transmit) and an issue where the automatic transmit checksum failed.

[PATCH 2/4] usbnet: smsc95xx: align tx-buffer to word

2018-10-02 Thread Ben Dooks
The tegra driver requires alignment of the buffer, so try and make this better by pushing the buffer start back to an word aligned address. At the worst this makes memcpy() easier as it is word aligned, at best it makes sure the usb can directly map the buffer. Signed-off-by: Ben Dooks [todo

[PATCH 1/4] usbnet: smsc95xx: add kconfig for turbo mode

2018-10-02 Thread Ben Dooks
Add a configuration option for the default state of turbo mode on the smsc95xx networking driver. Some systems it is better to default this to off as it causes significant increases in soft-irq load. Signed-off-by: Ben Dooks --- drivers/net/usb/Kconfig| 9 + drivers/net/usb

[PATCH 3/4] usbnet: smsc95xx: check for csum being in last four bytes

2018-10-02 Thread Ben Dooks
option makes it more likely to happen. Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 17 - 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c index d244357bf1ad..46385a4b8b98 100644 --- a/drivers/net/usb

[PATCH 4/4] usbnet: smsc95xx: fix rx packet alignment

2018-10-02 Thread Ben Dooks
with the start on an aligned address. Tested on Raspberry Pi B3. Signed-off-by: Ben Dooks --- drivers/net/usb/smsc95xx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c index 46385a4b8b98..2b867523cd53 100644 --- a/drivers/net/usb

[PATCH] net: usbnet: make driver_info const

2018-10-01 Thread Ben Dooks
From: Ben Dooks The driver_info field that is used for describing each of the usb-net drivers using the usbnet.c core all declare their information as const and the usbnet.c itself does not try and modify the struct. It is therefore a good idea to make this const in the usbnet.c structure in

Re: [PATCH 4.4 18/31] r8152: napi hangup fix after disconnect

2018-09-12 Thread Ben Hutchings
On Sat, 2018-08-25 at 09:43 +0200, Jiri Slaby wrote: > On 08/24/2018, 06:38 PM, Ben Hutchings wrote: > > On Fri, 2018-07-20 at 14:13 +0200, Greg Kroah-Hartman wrote: > > > 4.4-stable review patch.  If anyone has any objections, please

Re: [PATCH 1/2] USB: yurex: Fix buffer over-read in yurex_write()

2018-08-16 Thread Ben Hutchings
On Thu, 2018-08-16 at 04:15 +0200, Jann Horn wrote: > On Wed, Aug 15, 2018 at 10:44 PM Ben Hutchings > wrote: [...] > > @@ -446,6 +446,7 @@ static ssize_t yurex_write(struct file *file, const > > char __user *user_buffer, > > retval = -EFAULT; > &

[PATCH 2/2] USB: yurex: Check for truncation in yurex_read()

2018-08-15 Thread Ben Hutchings
ly possible for this to happen, but in case truncation occurs, WARN and return -EIO. Signed-off-by: Ben Hutchings --- drivers/usb/misc/yurex.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/usb/misc/yurex.c b/drivers/usb/misc/yurex.c index 1232dd49556d..6d9fd5f64903 100644 --- a/d

[PATCH 1/2] USB: yurex: Fix buffer over-read in yurex_write()

2018-08-15 Thread Ben Hutchings
ample/yurex_clock.pl writes an integer without a null terminator. It seems like it must have worked by chance!) Always add a null byte after the written data. Enlarge the buffer to allow for this. Cc: sta...@vger.kernel.org Signed-off-by: Ben Hutchings --- drivers/usb/misc/yurex.c | 5 +++-- 1

Re: [PATCH] usbip: Fix misuse of strncpy()

2018-07-26 Thread Ben Hutchings
On Tue, 2018-07-24 at 11:04 -0600, Shuah Khan wrote: > On 07/20/2018 08:12 PM, Ben Hutchings wrote: > > gcc 8 reports: > > > > usbip_device_driver.c: In function ‘read_usb_vudc_device’: > > usbip_device_driver.c:106:2: error: ‘strncpy’ specified bound 256 equals &g

[PATCH] usbip: Fix misuse of strncpy()

2018-07-20 Thread Ben Hutchings
re already doing so let's ensure they're still null- terminated. We can't easily use strlcpy() here, so use snprintf(). usbip_common.c has the same problem. Signed-off-by: Ben Hutchings Cc: sta...@vger.kernel.org --- tools/usb/usbip/libsrc/usbip_common.c|

Re: [PATCH 4.4 068/134] usb: dwc2: Make sure we disconnect the gadget state

2018-04-01 Thread Ben Hutchings
hould also have: commit d2471d4a24dfbff5e463d382e2c6fec7d7e25a09 Author: John Stultz Date:   Mon Oct 23 14:32:48 2017 -0700 usb: dwc2: Improve gadget state disconnection handling Ben. > I had seen some odd behavior with HiKey's usb-gadget interface > that I finally seemed to have chased

[PATCH] usbip: Correct maximum value of CONFIG_USBIP_VHCI_HC_PORTS

2018-01-28 Thread Ben Hutchings
pport") Signed-off-by: Ben Hutchings --- drivers/usb/usbip/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/usbip/Kconfig b/drivers/usb/usbip/Kconfig index eeefa29f8aa2..a20b65cb6678 100644 --- a/drivers/usb/usbip/Kconfig +++ b/drivers/usb/usbip/Kconfig @@ -

[PATCH stable 3.18-4.9] xhci: Fix ring leak in failure path of xhci_alloc_virt_device()

2018-01-11 Thread Ben Hutchings
xhci_alloc_virt_device() where ring cache allocation fails, in which case we need to free the ring allocated for endpoint 0. Signed-off-by: Ben Hutchings --- This is build-tested only. Ben. drivers/usb/host/xhci-mem.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers

Re: [PATCH 4.4 13/49] usb: dwc2: Fix UDC state tracking

2017-12-07 Thread Ben Hutchings
dds a call so that we report to the UDC layer when > the gadget device is disconnected. > > This patch does depend on the previous patch ("usb: dwc2: > Improve gadget state disconnection handling") in this patch set > in order to properly work. Then you should add that (commi

Re: [PATCH 4.4 27/56] cdc_ncm: Set NTB format again after altsetting switch for Huawei devices

2017-11-14 Thread Ben Hutchings
32_FORMAT) { [...] usbnet_read_cmd() doesn't do any byte-swapping, so it looks like curr_ntb_format will have little-endian byte order (__le16 not u16). The comparison will then need to be done using le16_to_cpu(curr_ntb_format). Ben. -- Ben Hutchings Software Developer, Codethink Ltd. -- To

[PATCH] usbip: tools: Install all headers needed for libusbip development

2017-09-30 Thread Ben Hutchings
usbip_host_driver.h now depends on several additional headers, which need to be installed along with it. Fixes: 021aed845303 ("staging: usbip: userspace: migrate usbip_host_driver ...") Fixes: 3391ba0e2792 ("usbip: tools: Extract generic code to be shared with ...") Signed-o

[PATCH] Partially revert "usb: Kconfig: using select for USB_COMMON dependency"

2017-04-17 Thread Ben Hutchings
t for USB_COMMON dependency") Signed-off-by: Ben Hutchings --- drivers/usb/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/usb/Kconfig b/drivers/usb/Kconfig index fbe493d44e81..8270abe6c677 100644 --- a/drivers/usb/Kconfig +++ b/drivers/usb/Kconfig @@ -15

Re: [PATCH net 2/4] rtl8150: Use heap buffers for all register access

2017-02-06 Thread Ben Hutchings
On Mon, Feb 06, 2017 at 04:09:18PM +, David Laight wrote: > From: Ben Hutchings [...] > > + ret = usb_control_msg(dev->udev, usb_rcvctrlpipe(dev->udev, 0), > > + RTL8150_REQ_GET_REGS, RTL8150_REQT_READ, > > +

[PATCH net 4/4] catc: Use heap buffer for memory size test

2017-02-04 Thread Ben Hutchings
Allocating USB buffers on the stack is not portable, and no longer works on x86_64 (with VMAP_STACK enabled as per default). Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2") Signed-off-by: Ben Hutchings --- drivers/net/usb/catc.c | 25 ++--- 1 file changed, 18 insert

[PATCH net 2/4] rtl8150: Use heap buffers for all register access

2017-02-04 Thread Ben Hutchings
Allocating USB buffers on the stack is not portable, and no longer works on x86_64 (with VMAP_STACK enabled as per default). Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2") Signed-off-by: Ben Hutchings --- drivers/net/usb/rtl8150.c | 34 +++--- 1 file changed, 27

[PATCH net 3/4] catc: Combine failure cleanup code in catc_probe()

2017-02-04 Thread Ben Hutchings
Signed-off-by: Ben Hutchings --- drivers/net/usb/catc.c | 33 + 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/drivers/net/usb/catc.c b/drivers/net/usb/catc.c index 3daa41bdd4ea..985909eab72c 100644 --- a/drivers/net/usb/catc.c +++ b/drivers/net

[PATCH net 1/4] pegasus: Use heap buffers for all register access

2017-02-04 Thread Ben Hutchings
án Nicanor Pérez Meyer Signed-off-by: Ben Hutchings --- drivers/net/usb/pegasus.c | 29 + 1 file changed, 25 insertions(+), 4 deletions(-) diff --git a/drivers/net/usb/pegasus.c b/drivers/net/usb/pegasus.c index 24e803fe9a53..36674484c6fb 100644 --- a/drivers/net/usb

[PATCH net 0/4] Fix on-stack USB buffers

2017-02-04 Thread Ben Hutchings
Allocating USB buffers on the stack is not portable, and no longer works on x86_64 (with VMAP_STACK enabled as per default). This series fixes all the instances I could find where USB networking drivers do that. Ben. Ben Hutchings (4): pegasus: Use heap buffers for all register access

New ID for Juniper router built in usb-serial 0x10c4 0x8470 cp210x

2016-10-19 Thread Ben White
6.442379] usb 1-1.3.4: cp210x converter now attached to ttyUSB0 Many thanks! Ben White -- Ben -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: XHCI: USB 2.0 device unresponsive on 3.0 controller

2016-09-21 Thread Ben
also bring home a few other keyboards and test them too. Regarding the logs: After the keyboard stops working or receiving power (it seems) I manually disconnect and reconnect it. > On Sep 21, 2016, at 08:19, Ben wrote: > > Good afternoon everyone, > > My coolermaster Quickfire

Re: [PATCH 4/7] phy: meson: add USB2 PHY support for Meson8b and GXBB

2016-09-09 Thread Ben Dooks
http://lxr.free-electrons.com/source/drivers/reset/core.c#L102 If we didn't have the shared reset, we'd have one of node per phy and not have to have two sub-nodes... I don't think any other bits of the PHY framework are shared. -- Ben Dooks http://www.co

Re: [PATCH 4/7] phy: meson: add USB2 PHY support for Meson8b and GXBB

2016-09-08 Thread Ben Dooks
On 08/09/16 21:42, Kevin Hilman wrote: Ben Dooks writes: On 08/09/16 20:52, Martin Blumenstingl wrote: On Thu, Sep 8, 2016 at 9:35 PM, Kevin Hilman wrote: + phy = devm_phy_create(&pdev->dev, NULL, &phy_meson_usb2_ops); + if (IS_ERR(phy)) { + dev_err(&pde

Re: [PATCH 4/7] phy: meson: add USB2 PHY support for Meson8b and GXBB

2016-09-08 Thread Ben Dooks
eep. So, in phy_meson_usb2_power_on() you could do: pm_runtime_get_sync(pdev); and in phy_meson_usb2_power_off pm_runtime_put(pdev); https://www.kernel.org/doc/Documentation/power/runtime_pm.txt -- Ben Dooks http://www.codethink.co.uk/ Senior Engineer

Re: [PATCH 4/7] phy: meson: add USB2 PHY support for Meson8b and GXBB

2016-09-08 Thread Ben Dooks
efcounting, and only calls ->runtime_resume() on the 0 -> 1 transition. This isn't a big deal for now, so I'll let Kishon decide, but using runtime PM from the start will help enabling other PM features later. I agree, pm_runtime would probably be the best place to handle &

Re: [PATCH] usb: ohci-at91: make at91_dt_syscon_sfr static

2016-06-27 Thread Ben Dooks
On 26/06/16 19:48, Greg Kroah-Hartman wrote: > On Fri, Jun 17, 2016 at 04:11:55PM +0100, Ben Dooks wrote: >> Make at91_dt_syscon_sfr() static as it is not used or declared >> outside the drivers/usb/host/ohci-at91.c file. >> >> drivers/usb/host/ohci-at9

[PATCH] usb: renesas_usbhs: make usbhs_write32() static

2016-06-21 Thread Ben Dooks
The usbhs_write32 function is not used outside of the rcar3.c file, so fix the following sparse warning by making it static: drivers/usb/renesas_usbhs/rcar3.c:26:6: warning: symbol 'usbhs_write32' was not declared. Should it be static? Signed-off-by: Ben Dooks --- Cc: Yoshihiro S

[PATCH] usb: ohci-at91: make at91_dt_syscon_sfr static

2016-06-17 Thread Ben Dooks
Make at91_dt_syscon_sfr() static as it is not used or declared outside the drivers/usb/host/ohci-at91.c file. drivers/usb/host/ohci-at91.c:144:15: warning: symbol 'at91_dt_syscon_sfr' was not declared. Should it be static? Signed-off-by: Ben Dooks --- Cc: Alan Stern Cc: Greg Kroah-H

Re: [PATCH] USB: core: fix missing include

2016-06-16 Thread Ben Dooks
69bec725 Peter Chen 2016-02-19 34 { >> 69bec725 Peter Chen 2016-02-19 35 struct device_node *node; >> >> > > I think what we want here is to make the compilation of of.o conditional on > CONFIG_OF, so we get only one of the two definitions. Ah, so make the of.

Re: [PATCH] USB: core: fix missing include

2016-06-16 Thread Ben Dooks
e_node *node; >>> >>> >> >> I think what we want here is to make the compilation of of.o conditional on >> CONFIG_OF, so we get only one of the two definitions. >> >> Arnd > > Thanks, Arnd. It is the correct solution, I will send patch soo

[PATCH] USB: core: fix missing include

2016-06-07 Thread Ben Dooks
Should it be static? Signed-off-by: Ben Dooks --- Cc: Greg Kroah-Hartman Cc: Arnd Bergmann Cc: Philipp Zabel Cc: Alan Stern Cc: Peter Chen Cc: linux-usb@vger.kernel.org Cc: linux-ker...@vger.kernel.org --- drivers/usb/core/of.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/c

Re: [PATCH 3/3] dm9601: add support ethtool style utility

2016-03-11 Thread Ben Hutchings
On Fri, 2016-03-11 at 11:33 +, Ben Hutchings wrote: > On Fri, 2016-03-11 at 19:08 +0800, Joseph Chang wrote: > > > > I tested by > >  ./ethtool -E eth0 magic 0x9620 offset 0 length 3 value 0xf1 value 0xf2 > > value 0xf3 > > > > I think ethtool need [

Re: [PATCH 3/3] dm9601: add support ethtool style utility

2016-03-11 Thread Ben Hutchings
I right? > > Oh, I can see it goes wrong~ Thanks~ [...] You can only pass one byte on the command line and that forces the length to be 1.  To set multiple bytes, you need to provide them on stdin instead. Ben. -- Ben Hutchings 73.46% of all statistics are made up. signature.asc De

Re: [PATCH 3/3] dm9601: add support ethtool style utility

2016-03-10 Thread Ben Hutchings
te1) >    ./ethtool -E eth0 magic 0x9620 offset 2 value 0xf3  (write 0xf3 to eeprom > byte2) [...] So you only tested writing 1 byte at a time.  Try again with 3 bytes and you'll see how it goes wrong. Ben. -- Ben Hutchings To err is human; to really foul things up requires a comput

Re: [PATCH 3/3] dm9601: add support ethtool style utility

2016-03-10 Thread Ben Hutchings
dm_write_eeprom_word(dev, offset / 2, > +      data[0] | data[1] << 8); > + done = 2; > + } > + data += done; > + offset += done; > + len -= done; > + } > + return 0; > +} [...] Ben. -- Ben Hutchings To err is human; to really foul things up requires a computer. signature.asc Description: This is a digitally signed message part

Re: [PATCH] cdc_ncm: do not call usbnet_link_change from cdc_ncm_bind

2016-03-08 Thread Ben Hutchings
all, and don't have that FLAG_LINK_INTR flag. > > Would they break? > Yes.  Drivers without carrier detection will be "down" forever. > > > > > Why is it called "FLAG_LINK_INTR" anyway? There doesn't seem to be > > anything "INTR"

[PATCH] usb: Use the USB_SS_MULT() macro to decode burst multiplier for log message

2015-11-17 Thread Ben Hutchings
usb_parse_ss_endpoint_companion() now decodes the burst multiplier correctly in order to check that it's <= 3, but still uses the wrong expression if warning that it's > 3. Fixes: ff30cbc8da42 ("usb: Use the USB_SS_MULT() macro to get the ...") Signed-off-by: Ben Hutchi

RE: [PATCH v2] USB: DCW3: GADGET: Set Correct Max Speed

2015-11-12 Thread McCauley, Ben
connecting through a 3.0 port. A follow on patch will be needed to add USB_SPEED_HIGH_LPM to support High Speed devices which also support LPM. Signed-off-by: McCauley, Ben --- drivers/usb/dwc3/gadget.c | 10 +- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/drivers/usb/dwc3

RE: [PATCH] USB: DCW3: GADGET: Set Correct Max Speed

2015-11-10 Thread McCauley, Ben
> -Original Message- > From: Felipe Balbi [mailto:ba...@ti.com] > Sent: Tuesday, November 10, 2015 9:10 AM > To: John Youn ; McCauley, Ben > ; John Youn ; > gre...@linuxfoundation.org > Cc: linux-usb@vger.kernel.org; Schroeder, Jay > Subject: Re: [PATCH] USB: DCW3:

RE: [PATCH] USB: DCW3: GADGET: Set Correct Max Speed

2015-11-09 Thread McCauley, Ben
> -Original Message- > From: Felipe Balbi [mailto:ba...@ti.com] > Sent: Monday, November 09, 2015 3:09 PM > To: McCauley, Ben ; John Youn > ; gre...@linuxfoundation.org > Cc: linux-usb@vger.kernel.org; Schroeder, Jay > Subject: RE: [PATCH] USB: DCW3: GADGET:

RE: [PATCH] USB: DCW3: GADGET: Set Correct Max Speed

2015-11-09 Thread McCauley, Ben
> -Original Message- > From: Felipe Balbi [mailto:ba...@ti.com] > Sent: Monday, November 09, 2015 12:33 PM > To: McCauley, Ben ; John Youn > ; gre...@linuxfoundation.org > Cc: linux-usb@vger.kernel.org; Schroeder, Jay > Subject: RE: [PATCH] USB: DCW3: GADGET:

RE: [PATCH] USB: DCW3: GADGET: Set Correct Max Speed

2015-11-09 Thread McCauley, Ben
Hi, > -Original Message- > From: Felipe Balbi [mailto:ba...@ti.com] > Sent: Monday, November 09, 2015 8:20 AM > To: John Youn ; McCauley, Ben > ; gre...@linuxfoundation.org > Cc: linux-usb@vger.kernel.org; Schroeder, Jay > Subject: Re: [PATCH] USB: DCW3: GADGET:

RE: [PATCH] USB: DCW3: GADGET: Set Correct Max Speed

2015-11-06 Thread McCauley, Ben
Felipe, -Original Message- From: Felipe Balbi [mailto:ba...@ti.com] Sent: Friday, November 06, 2015 10:06 AM To: McCauley, Ben Cc: linux-usb@vger.kernel.org; Schroeder, Jay Subject: Re: [PATCH] USB: DCW3: GADGET: Set Correct Max Speed > > > Hi, > > "McCauley, B

[PATCH] USB: DCW3: GADGET: Set Correct Max Speed

2015-11-06 Thread McCauley, Ben
connecting through a 3.0 port. Signed-off-by: McCauley, Ben --- diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c index 1eaf31c..0a388e3 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -2899,7 +2899,7 @@ } dwc->gadget.

Re: AM3517 usb host issue

2015-09-24 Thread Ben Dooks
On 22/05/15 14:50, Felipe Balbi wrote: > Hi, > > On Fri, May 22, 2015 at 11:04:33AM +0300, Ben Dooks wrote: >> I am trying to get the full-speed USB host working on an custom >> AM3517 device with the 3.18.12 kernel. The hardware works (a >> 2.6.37 kernel has been use

Re: [PATCH 1/1] cdc-acm: Add support of ATOL FPrint fiscal printers

2015-06-02 Thread Ben Dooks
); > + } > + Given quirks looks like a bitfield, it would be better if this is if (quirks & CLEAR_HALT_CONDITIONS) { -- Ben Dooks http://www.codethink.co.uk/ Senior Engineer Codethink - Providing Genius -- To unsubscribe

Re: AM3517 usb host issue

2015-05-26 Thread Ben Dooks
On 22/05/15 23:13, Ben Dooks wrote: > On 22/05/15 16:50, Felipe Balbi wrote: >> Hi, > >> On Fri, May 22, 2015 at 11:04:33AM +0300, Ben Dooks wrote: >>> I am trying to get the full-speed USB host working on an custom >>> AM3517 device with the 3.18.12 kern

[PATCH] USB: musb: Fix order of conditions for assigning end point operations

2015-05-23 Thread Ben Hutchings
Currently we always assign one of the two common implementations of ep_offset and ep_select operations, overwriting any platform-specific implementations. Fixes: d026e9c76aac ("usb: musb: Change end point selection to use ...") Signed-off-by: Ben Hutchings --- This is untested; I ju

Re: AM3517 usb host issue

2015-05-22 Thread Ben Dooks
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 On 22/05/15 16:50, Felipe Balbi wrote: > Hi, > > On Fri, May 22, 2015 at 11:04:33AM +0300, Ben Dooks wrote: >> I am trying to get the full-speed USB host working on an custom >> AM3517 device with the 3.18.12 kernel. The hardwa

Re: [PATCH net,stable-4.0] cdc_ncm: Fix tx_bytes statistics

2015-05-22 Thread Ben Hutchings
mitted frame. > > Fix by calculating the delta as a signed long. Told you I hadn't tested it. Ben. > Cc: Ben Hutchings > Reported-by: Florian Bruhin > Fixes: 7a1e890e2168 ("usbnet: Fix tx_bytes statistic running backward in > cdc_ncm") > Signed-off-by: Bj

AM3517 usb host issue

2015-05-22 Thread Ben Dooks
.usbhstll: omap_tll_enable() > > [ 77.802694] usb usb1: New USB device found, idVendor=1d6b, idProduct=0001 > > [ 77.816003] usb usb1: New USB device strings: Mfr=3, Product=2, > SerialNumber1 > [ 77.827391] usb usb1: Product: OHCI Host Controller &g

  1   2   3   >