Re: [PATCH 05/14] gpio: lpc32xx: allow building on non-lpc32xx targets

2019-08-02 Thread Bartosz Golaszewski
śr., 31 lip 2019 o 22:06 Arnd Bergmann napisał(a): > > The driver uses hardwire MMIO addresses instead of the data > that is passed in device tree. Change it over to only > hardcode the register offset values and allow compile-testing. > > Signed-off-by: Arnd Bergmann Hi Arnd, thanks for workin

Re: [PATCH v2 2/2] usbip: Implement SG support to vhci

2019-08-02 Thread Suwan Kim
On Thu, Aug 01, 2019 at 08:03:59AM -0600, shuah wrote: > On 8/1/19 12:38 AM, Suwan Kim wrote: > > On Mon, Jul 29, 2019 at 10:32:31AM -0600, shuah wrote: > > > On 7/29/19 8:52 AM, Suwan Kim wrote: > > > > Hi Shuah, > > > > > > > > On Tue, Jul 23, 2019 at 06:21:53PM -0600, shuah wrote: > > > > > Hi

Re: [PATCH] HID: usbhid: Use GFP_KERNEL instead of GFP_ATOMIC when applicable

2019-08-02 Thread Christophe JAILLET
Hi, (and sorry if you receive this email twice. I've used a web mail which sends HTML by default and it was rejected by ML) Le 01/08/2019 à 12:06, walter harms a écrit : Am 01.08.2019 09:47, schrieb Christophe JAILLET: There is no need to use GFP_ATOMIC when calling 'usb_alloc_coherent()' he

Re: [RFC PATCH] usb: typec: tcpm: Ignore unsupported/unknown alternate mode requests

2019-08-02 Thread Heikki Krogerus
On Thu, Aug 01, 2019 at 06:07:09PM +0200, Greg Kroah-Hartman wrote: > On Wed, Jul 31, 2019 at 12:55:55PM +0300, Heikki Krogerus wrote: > > On Tue, Jul 30, 2019 at 06:28:52AM -0700, Guenter Roeck wrote: > > > On 7/30/19 5:07 AM, Heikki Krogerus wrote: > > > > On Mon, Jul 29, 2019 at 10:31:04AM -0700

AW: Unhandled fault: imprecise external abort (0x1406) when loading xhci_pci.ko - uPD720202, PEX8605, iMX6Q and linux-4.19.25

2019-08-02 Thread Schmid, Carsten
> > > > Facing kernel "Unhandled fault: imprecise external abort (0x1406)" > > when trying to load xhci_pci.ko module for uPD720202. Receiving this > > fault straight-away when driver trying to setup device. > > I had "imprecise external abort" on ARM systems in the following cases: - Subsystem tha

[PATCH] usb: host: xhci-rcar: Fix timeout in xhci_suspend()

2019-08-02 Thread Yoshihiro Shimoda
When a USB device is connected to the host controller and the system enters suspend, the following error happens in xhci_suspend(): xhci-hcd ee00.usb: WARN: xHC CMD_RUN timeout Since the firmware/internal CPU control the USBSTS.STS_HALT and the process speed is down when the roothub p

Re: [PATCH 2/5] usb: chipidea: add role switch class support

2019-08-02 Thread Peter Chen
> USB role is fully controlled by usb role switch consumer(e.g. typec), > usb port either at host mode, or at device connected mode, will not > stay at USB_ROLE_NONE mode. > Then, if the Type-C cable is disconnected from PC host, the controller driver can't be notified?If that, how controller ente

Re: Unhandled fault: imprecise external abort (0x1406) when loading xhci_pci.ko - uPD720202, PEX8605, iMX6Q and linux-4.19.25

2019-08-02 Thread Fawad Lateef
Hi Bjorn, On Thu, 1 Aug 2019 at 19:17, Bjorn Helgaas wrote: > > [+cc i.MX6 folks] > > On Thu, Aug 01, 2019 at 10:18:22AM +0200, Fawad Lateef wrote: > > Hi everyone, > > > > I am trying to get Renesas uPD720202 USB3.0 hub working which is > > connected PCIe switch (PEX8605); PEX8605 is connected t

Re: Unhandled fault: imprecise external abort (0x1406) when loading xhci_pci.ko - uPD720202, PEX8605, iMX6Q and linux-4.19.25

2019-08-02 Thread Fawad Lateef
Hi Schmid, On Fri, 2 Aug 2019 at 10:24, Schmid, Carsten wrote: > > > > > > > Facing kernel "Unhandled fault: imprecise external abort (0x1406)" > > > when trying to load xhci_pci.ko module for uPD720202. Receiving this > > > fault straight-away when driver trying to setup device. > > > > I had "i

Re: [PATCH 05/14] gpio: lpc32xx: allow building on non-lpc32xx targets

2019-08-02 Thread Arnd Bergmann
On Fri, Aug 2, 2019 at 9:10 AM Bartosz Golaszewski wrote: > > -#include > > -#include > > +#define _GPREG(x) (x) > > What purpose does this macro serve? > > > > > #define LPC32XX_GPIO_P3_INP_STATE _GPREG(0x000) > > #define LPC32XX_GPIO_P3_OUTP_SET

Re: Oops in xhci_endpoint_reset

2019-08-02 Thread Mathias Nyman
On 31.7.2019 19.31, Enric Balletbo Serra wrote: Missatge de Mathias Nyman del dia dc., 31 de jul. 2019 a les 16:16: On 31.7.2019 12.18, Enric Balletbo Serra wrote: Hi Mathias, Thanks to look into this. Missatge de Mathias Nyman del dia dt., 30 de jul. 2019 a les 21:39: On 27.7.2019 23.43

Re: [RFC PATCH] usb: typec: tcpm: Ignore unsupported/unknown alternate mode requests

2019-08-02 Thread Greg Kroah-Hartman
On Wed, Jul 24, 2019 at 09:30:37PM -0700, Guenter Roeck wrote: > TCPM may receive PD messages associated with unknown or unsupported > alternate modes. If that happens, calls to typec_match_altmode() > will return NULL. The tcpm code does not currently take this into > account. This results in cras

Re: [PATCH] usb: devio: fix mmap() on non-coherent DMA architectures

2019-08-02 Thread Greg KH
On Thu, Aug 01, 2019 at 03:04:36PM -0700, gavi...@thegavinli.com wrote: > From: Gavin Li > > On architectures that are not (or are optionally) DMA coherent, > dma_alloc_coherent() returns an address into the vmalloc space, > and calling virt_to_phys() on this address returns an unusable > physica

KASAN: use-after-free Read in __pm_runtime_resume

2019-08-02 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:e96407b4 usb-fuzzer: main usb gadget fuzzer driver git tree: https://github.com/google/kasan.git usb-fuzzer console output: https://syzkaller.appspot.com/x/log.txt?x=146071b460 kernel config: https://syzkaller.appspot.com/x/.

[PATCH -next] usb: dwc3: keystone: use devm_platform_ioremap_resource() to simplify code

2019-08-02 Thread YueHaibing
Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Reported-by: Hulk Robot Signed-off-by: YueHaibing --- drivers/usb/dwc3/dwc3-keystone.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/usb/dwc3/dwc3-keystone.c b/drive

[PATCH -next] usb: dwc3: meson-g12a: use devm_platform_ioremap_resource() to simplify code

2019-08-02 Thread YueHaibing
Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Reported-by: Hulk Robot Signed-off-by: YueHaibing --- drivers/usb/dwc3/dwc3-meson-g12a.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/usb/dwc3/dwc3-meson-g12a.c b/

[PATCH -next] usb: dwc3: omap: use devm_platform_ioremap_resource() to simplify code

2019-08-02 Thread YueHaibing
Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Reported-by: Hulk Robot Signed-off-by: YueHaibing --- drivers/usb/dwc3/dwc3-omap.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/usb/dwc3/dwc3-omap.c b/drivers/usb/d

Re: KASAN: use-after-free Read in __pm_runtime_resume

2019-08-02 Thread Pavel Machek
On Fri 2019-08-02 05:58:05, syzbot wrote: > Hello, > > syzbot found the following crash on: > > HEAD commit:e96407b4 usb-fuzzer: main usb gadget fuzzer driver > git tree: https://github.com/google/kasan.git usb-fuzzer > console output: https://syzkaller.appspot.com/x/log.txt?x=146071b46

Re: [PATCH v2 2/2] usbip: Implement SG support to vhci

2019-08-02 Thread shuah
On 8/2/19 1:41 AM, Suwan Kim wrote: On Thu, Aug 01, 2019 at 08:03:59AM -0600, shuah wrote: On 8/1/19 12:38 AM, Suwan Kim wrote: On Mon, Jul 29, 2019 at 10:32:31AM -0600, shuah wrote: On 7/29/19 8:52 AM, Suwan Kim wrote: Hi Shuah, On Tue, Jul 23, 2019 at 06:21:53PM -0600, shuah wrote: Hi Suw

CHARITY WORK

2019-08-02 Thread Sir.Francois Stamm
I am Mr Francois Jean Stamm from Switzerland i am the chief delegate south Sudan red cross organisation, my objective to send this mail across to you on mere internet search of a friend from your country,i lost his contact , intent pump up your email is to extend our humanitarian aid/assistance to

Re: KASAN: use-after-free Read in __pm_runtime_resume

2019-08-02 Thread Andrey Konovalov
On Fri, Aug 2, 2019 at 3:33 PM Pavel Machek wrote: > > On Fri 2019-08-02 05:58:05, syzbot wrote: > > Hello, > > > > syzbot found the following crash on: > > > > HEAD commit:e96407b4 usb-fuzzer: main usb gadget fuzzer driver > > git tree: https://github.com/google/kasan.git usb-fuzzer > >

Re: [PATCH -next] usb: dwc3: meson-g12a: use devm_platform_ioremap_resource() to simplify code

2019-08-02 Thread Neil Armstrong
On 02/08/2019 15:04, YueHaibing wrote: > Use devm_platform_ioremap_resource() to simplify the code a bit. > This is detected by coccinelle. > > Reported-by: Hulk Robot > Signed-off-by: YueHaibing > --- > drivers/usb/dwc3/dwc3-meson-g12a.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(

[PATCH] xhci: Fix NULL pointer dereference at endpoint zero reset.

2019-08-02 Thread Mathias Nyman
Usb core will reset the default control endpoint "ep0" before resetting a device. if the endpoint has a valid pointer back to the usb device then the xhci driver reset callback will try to clear the toggle for the endpoint. ep0 didn't use to have this pointer set as ep0 was always allocated by def

Re: [RFC PATCH] usb: typec: tcpm: Ignore unsupported/unknown alternate mode requests

2019-08-02 Thread Douglas Gilbert
On 2019-07-25 6:30 a.m., Guenter Roeck wrote: TCPM may receive PD messages associated with unknown or unsupported alternate modes. If that happens, calls to typec_match_altmode() will return NULL. The tcpm code does not currently take this into account. This results in crashes. Unable to handle

Re: About usb_new_device() API

2019-08-02 Thread Mayuresh Kulkarni
On Thu, 2019-08-01 at 13:51 -0400, Alan Stern wrote: > On Thu, 1 Aug 2019, Mayuresh Kulkarni wrote: > > > > > Hi All, > > > > I am seeing a peculiar behaviour which I think *might* be  > > caused by usb_new_device(). Since usb_new_device() is one of the > > core > > APIs, I cannot explain how PM

Re: [PATCH] xhci: Fix NULL pointer dereference at endpoint zero reset.

2019-08-02 Thread Enric Balletbo Serra
Hi Mathias, Missatge de Mathias Nyman del dia dv., 2 d’ag. 2019 a les 16:59: > > Usb core will reset the default control endpoint "ep0" before resetting > a device. if the endpoint has a valid pointer back to the usb device > then the xhci driver reset callback will try to clear the toggle for >

[PATCH v2] usb: typec: tcpm: Ignore unsupported/unknown alternate mode requests

2019-08-02 Thread Guenter Roeck
TCPM may receive PD messages associated with unknown or unsupported alternate modes. If that happens, calls to typec_match_altmode() will return NULL. The tcpm code does not currently take this into account. This results in crashes. Unable to handle kernel NULL pointer dereference at virtual addre

Re: About usb_new_device() API

2019-08-02 Thread Alan Stern
On Fri, 2 Aug 2019, Mayuresh Kulkarni wrote: > Hi Alan, > > Thanks a lot for clearing out the confusion. > > Our USB device can operate in 2 mutually exclusive modes: one is normal > composite USB audio mode and other is vendor specific HID device mode. > > On the same platform (Android based):

Re: [PATCH v2 2/2] usbip: Implement SG support to vhci

2019-08-02 Thread Suwan Kim
On Fri, Aug 02, 2019 at 07:33:59AM -0600, shuah wrote: > On 8/2/19 1:41 AM, Suwan Kim wrote: > > On Thu, Aug 01, 2019 at 08:03:59AM -0600, shuah wrote: > > > On 8/1/19 12:38 AM, Suwan Kim wrote: > > > > On Mon, Jul 29, 2019 at 10:32:31AM -0600, shuah wrote: > > > > > On 7/29/19 8:52 AM, Suwan Kim w

[PATCH v3 0/2] usbip: Implement SG support

2019-08-02 Thread Suwan Kim
There are bugs on vhci with usb 3.0 storage device. Currently, vhci doesn't supported SG, so USB storage driver on vhci breaks SG list into multiple URBs and it causes error that a transfer got terminated too early because the transfer length for one of the URBs was not divisible by the maxpacket s

[PATCH v3 2/2] usbip: Implement SG support to vhci-hcd and stub driver

2019-08-02 Thread Suwan Kim
There are bugs on vhci with usb 3.0 storage device. Currently, vhci doesn't supported SG, so USB storage driver on vhci breaks SG list into multiple URBs and it causes error that a transfer got terminated too early because the transfer length for one of the URBs was not divisible by the maxpacket s

[PATCH v3 1/2] usbip: Skip DMA mapping and unmapping for urb at vhci

2019-08-02 Thread Suwan Kim
vhci doesn’t do DMA for remote device. Actually, the real DMA operation is done by network card driver. vhci just passes virtual address of the buffer to the network stack, so vhci doesn’t use and need dma address of the buffer of the URB. But HCD provides DMA mapping and unmapping function by def

Re: [PATCH] usb: devio: fix mmap() on non-coherent DMA architectures

2019-08-02 Thread Gavin Li
usbfs mmap() looks like it was introduced for 4.6 in commit f7d34b445abc, so it should probably be backported to 4.9 and onwards. This issue has been present since the introduction of the feature. One sidenote: this patch will cause the following warning on x86 due to dmap_mmap_coherent() trying t

EHSET USB testing

2019-08-02 Thread Evan Gates
I'm trying to get my device to pass the EHSET tests. I found the thread "Using EHSET module" from March. I'm having similar issues. I don't have access to the PID VID board that the lab uses. Instead I'm using another computer setup as a mass storage gadget but set the VID:PID to 1a0a:0102 (TES

Re: possible deadlock in open_rio

2019-08-02 Thread Alan Stern
On Thu, 1 Aug 2019, syzbot wrote: > Hello, > > syzbot found the following crash on: > > HEAD commit:7f7867ff usb-fuzzer: main usb gadget fuzzer driver > git tree: https://github.com/google/kasan.git usb-fuzzer > console output: https://syzkaller.appspot.com/x/log.txt?x=136b6aec60 >

Re: [PATCH v3 1/2] usbip: Skip DMA mapping and unmapping for urb at vhci

2019-08-02 Thread shuah
On 8/2/19 11:36 AM, Suwan Kim wrote: vhci doesn’t do DMA for remote device. Actually, the real DMA operation is done by network card driver. vhci just passes virtual address of the buffer to the network stack, so vhci doesn’t use and need dma address of the buffer of the URB. But HCD provides DM

Re: [PATCH v3 2/2] usbip: Implement SG support to vhci-hcd and stub driver

2019-08-02 Thread shuah
Hi Suwan, On 8/2/19 11:36 AM, Suwan Kim wrote: There are bugs on vhci with usb 3.0 storage device. This sentence doesn't make sense to me. What bugs? Ca you eloborate? Currently, vhci doesn't supported SG, so USB storage driver on vhci breaks SG list into multiple URBs and it causes error th

Re: [PATCH v3 0/2] usbip: Implement SG support

2019-08-02 Thread shuah
Hi Suwan, On 8/2/19 11:36 AM, Suwan Kim wrote: There are bugs on vhci with usb 3.0 storage device. Currently, vhci doesn't supported SG, so USB storage driver on vhci breaks SG list into multiple URBs and it causes error that a transfer got terminated too early because the transfer length for on