Re: [PATCH v2] HID: hiddev: change hiddev_connect() to return bool

2015-10-19 Thread Luis de Bethencourt
On 13/10/15 02:49, Krzysztof Kozlowski wrote: > 2015-10-09 22:00 GMT+09:00 Luis de Bethencourt : >> Since hid_connect() only cares about hiddev_connect() succeeding or >> failing, there is no need for this function to return an int and it can >> return a bool instead. >

[PATCH v2] HID: hiddev: change hiddev_connect() to return bool

2015-10-09 Thread Luis de Bethencourt
Since hid_connect() only cares about hiddev_connect() succeeding or failing, there is no need for this function to return an int and it can return a bool instead. Suggested-by: Jiri Kosina Signed-off-by: Luis de Bethencourt --- Hi, No idea why my local build did not complain about the obvious

[PATCH] HID: hiddev: change hiddev_connect() to return bool

2015-10-09 Thread Luis de Bethencourt
Since hid_connect() only cares about hiddev_connect() succeeding or failing, there is no need for this function to return an int and it can return a bool instead. Suggested-by: Jiri Kosina Signed-off-by: Luis de Bethencourt --- Hi, The suggestion to change the return type of the function was

Re: [PATCH] HID: hiddev: fix returned errno code in hiddev_connect()

2015-10-06 Thread Luis de Bethencourt
On 05/10/15 15:24, Jiri Kosina wrote: > On Sat, 3 Oct 2015, Luis de Bethencourt wrote: > >>> But I am not really sure where you are seeing the bug (mapping to >>> -EPERM) in this case? I think the only caller of hiddev_connect() >>> should be hid_connect(),

Re: [PATCH] HID: hiddev: fix returned errno code in hiddev_connect()

2015-10-03 Thread Luis de Bethencourt
On 30/09/15 20:40, Jiri Kosina wrote: > On Wed, 30 Sep 2015, Luis de Bethencourt wrote: > >> The driver is using -1 instead of the -ENOMEM defined macro to specify >> that a buffer allocation failed. Since the error number is propagated, >> the caller will get a -EPERM

[PATCH] HID: hiddev: fix returned errno code in hiddev_connect()

2015-09-30 Thread Luis de Bethencourt
: returning -1 instead of -ENOMEM is sloppy Signed-off-by: Luis de Bethencourt --- drivers/hid/usbhid/hiddev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/hid/usbhid/hiddev.c b/drivers/hid/usbhid/hiddev.c index 2f1ddca..c5290ff 100644 --- a/drivers/hid/usbhid/hiddev.c +++ b

Re: [PATCH] HID: hiddev: fix returned errno code in hiddev_connect()

2015-09-30 Thread Luis de Bethencourt
On 30/09/15 11:04, Sudip Mukherjee wrote: > On Wed, Sep 30, 2015 at 10:56:26AM +0100, Luis de Bethencourt wrote: >> On 30/09/15 10:52, Luis de Bethencourt wrote: >>> The driver is using -1 instead of the -ENOMEM defined macro to specify >>> that a buffer allocation fai

Re: [PATCH] HID: hiddev: fix returned errno code in hiddev_connect()

2015-09-30 Thread Luis de Bethencourt
On 30/09/15 10:52, Luis de Bethencourt wrote: > The driver is using -1 instead of the -ENOMEM defined macro to specify > that a buffer allocation failed. Since the error number is propagated, > the caller will get a -EPERM which is the wrong error condition. > > Also, the smatch

[PATCH] usb: host: fotg210: remove unreachable code

2015-09-28 Thread Luis de Bethencourt
Before running the platform_driver_unregister() the code will either return retval or jump to clean. Removing this line that is unreachable. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/fotg210-hcd.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/usb/host/fotg210-hcd.c b

[PATCH v3 4/4] usb: host: uhci-platform: Fix module autoload for OF platform driver

2015-09-19 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/uhci-platform.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/uhci-platfor

[PATCH v3 2/4] usb: host: fsl-mph-dr-of: Fix module autoload for OF platform driver

2015-09-19 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/fsl-mph-dr-of.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/fsl-mph-dr-o

[PATCH v3 3/4] usb: host: ohci-spear: Fix module autoload for OF platform driver

2015-09-19 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/ohci-spear.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/ohci-spear.c b/driver

[PATCH v3 1/4] usb: host: ehci-spear: Fix module autoload for OF platform driver

2015-09-19 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/ehci-spear.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/ehci-spear.c b/driver

[PATCH v3 0/4] usb: host: Fix module autoload for OF platform drivers

2015-09-19 Thread Luis de Bethencourt
d the missing MODULE_DEVICE_TABLE() for OF to export the information so modules have the correct aliases built-in and autoloading works correctly. A longer explanation by Javier Canillas can be found here: https://lkml.org/lkml/2015/7/30/519 Thanks, Luis Luis de Bethencourt (4): usb: host: ehci-

[PATCH v2 1/4] usb: host: ehci-spear: Fix module autoload for OF platform driver

2015-09-18 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/ehci-spear.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/ehci-spear.c b/driver

Re: [PATCH 1/4] usb: host: ehci-spear: Fix module autoload for OF platform driver

2015-09-18 Thread Luis de Bethencourt
On Fri, Sep 18, 2015 at 02:57:10PM -0400, Alan Stern wrote: > On Fri, 18 Sep 2015, Luis de Bethencourt wrote: > > > This platform driver has a OF device ID table but the OF module > > alias information is not created so module autoloading won't work. > > > >

[PATCH 4/4] usb: host: uhci-platform: Fix module autoload for OF platform driver

2015-09-18 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/uhci-platform.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/uhci-platfor

[PATCH 3/4] usb: host: ohci-spear: Fix module autoload for OF platform driver

2015-09-18 Thread Luis de Bethencourt
Signed-off-by: Luis de Bethencourt --- drivers/usb/host/ohci-spear.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/ohci-spear.c b/drivers/usb/host/ohci-spear.c index 707437c..56478ed 100644 --- a/drivers/usb/host/ohci-spear.c +++ b/drivers/usb/host/ohci-spear.c @@ -161,6

[PATCH 1/4] usb: host: ehci-spear: Fix module autoload for OF platform driver

2015-09-18 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/ehci-spear.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/ehci-spear.c b/driver

[PATCH 2/4] usb: host: fsl-mph-dr-of: Fix module autoload for OF platform driver

2015-09-18 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/host/fsl-mph-dr-of.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/host/fsl-mph-dr-o

[PATCH 0/4] usb: host: Fix module autoload for OF platform drivers

2015-09-18 Thread Luis de Bethencourt
Hi, These patches add the missing MODULE_DEVICE_TABLE() for OF to export the information so modules have the correct aliases built-in and autoloading works correctly. A longer explanation by Javier Canillas can be found here: https://lkml.org/lkml/2015/7/30/519 Thanks, Luis Luis de Bethencourt

Re: [PATCH] usb: musb: Fix module autoload for OF platform driver

2015-08-27 Thread Luis de Bethencourt
On Thu, Aug 27, 2015 at 10:41:42AM -0500, Bin Liu wrote: > Hi, > > On Thu, Aug 27, 2015 at 10:07 AM, Luis de Bethencourt > wrote: > > This platform driver has a OF device ID table but the OF module > > alias information is not created so module autoloading won't work

[PATCH v2] usb: musb: ux500: Fix module autoload for OF platform driver

2015-08-27 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/musb/ux500.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/usb/musb/ux500.c b/drivers/usb

[PATCH] usb: musb: Fix module autoload for OF platform driver

2015-08-27 Thread Luis de Bethencourt
This platform driver has a OF device ID table but the OF module alias information is not created so module autoloading won't work. Signed-off-by: Luis de Bethencourt --- drivers/usb/musb/ux500.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/usb/musb/ux500.c b/drivers/usb

[PATCH] usb: host: xhci: remove typo in function documentation

2015-06-30 Thread Luis de Bethencourt
Fix "though" to "through" in documentation of xhci_alloc_streams(). Signed-off-by: Luis de Bethencourt --- drivers/usb/host/xhci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c index 7da0d60..e66857f