[PATCH] usb: gadget: udc: s3c2410_udc.c: Remove some unused functions

2014-12-20 Thread Rickard Strandqvist
Removes some functions that are not used anywhere: s3c2410_udc_clear_ep_state() s3c2410_udc_set_ep0_sse_out() This was partially found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- drivers/usb/gadget/udc/s3c2410_udc.c | 20

[PATCH] usb: phy: phy-fsl-usb: Remove some unused functions

2015-01-01 Thread Rickard Strandqvist
Removes some functions that are not used anywhere: fsl_otg_tick_timer() view_ulpi() This was partially found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- drivers/usb/phy/phy-fsl-usb.c | 35 --- 1 file changed

[PATCH] uwb: lc-dev: Remove unused function

2015-01-11 Thread Rickard Strandqvist
Remove the function uwb_dev_addr_bcast() that is not used anywhere. This was partially found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- drivers/uwb/lc-dev.c |7 --- 1 file changed, 7 deletions(-) diff --git a/drivers/uwb/lc-dev.c b

[PATCH] Fix for possible null pointer dereference in keyspan.c

2014-05-15 Thread Rickard Strandqvist
There is otherwise a risk of a possible null pointer dereference. Was largely found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- drivers/usb/serial/keyspan.c |4 ++-- 1 fil ändrad, 2 tillägg(+), 2 borttagningar(-) diff --git a/drivers/usb

[PATCH] usb: class: usbtmc.c: Cleaning up uninitialized variables

2014-06-01 Thread Rickard Strandqvist
There is a risk that the variable will be used without being initialized. This was largely found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- drivers/usb/class/usbtmc.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a

[PATCH] usb: musb: musb_host.c: Cleaning up uninitialized variables

2014-06-01 Thread Rickard Strandqvist
There is a risk that the variable will be used without being initialized. This was largely found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- drivers/usb/musb/musb_host.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a

[PATCH] staging: usbip: stub_main.c: Cleaning up missing null-terminate after strncpy call

2014-06-04 Thread Rickard Strandqvist
Added a guaranteed null-terminate after call to strncpy. This was partly found using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- drivers/staging/usbip/stub_main.c |1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/usbip/stub_main.c

Re: [PATCH] staging: usbip: stub_main.c: Cleaning up missing null-terminate after strncpy call

2014-06-10 Thread Rickard Strandqvist
urn -EINVAL; Or should we just let it be, perhaps? Kind regards Rickard Strandqvist 2014-06-10 8:57 GMT+02:00 Dan Carpenter : > On Wed, Jun 04, 2014 at 11:39:49PM +0200, Rickard Strandqvist wrote: >> Added a guaranteed null-terminate after call to strncpy. >> >> This was par

Re: [PATCH] staging: usbip: stub_main.c: Cleaning up missing null-terminate after strncpy call

2014-06-12 Thread Rickard Strandqvist
2014-06-11 7:45 GMT+02:00 Dan Carpenter : > On Tue, Jun 10, 2014 at 10:48:35PM +0200, Rickard Strandqvist wrote: >> Hi >> >> True! >> Sorry :-( >> >> But then one would either operate strcpy outright. >> >> Or use strlcpy then the code woul

[PATCH 5/5] mmc: host: vub300.c: Cleaning up missing null-terminate by switching from strncpy to strzcpy

2014-10-18 Thread Rickard Strandqvist
Ensures that the string is null-terminate in connection with the use of strncpy, by switching from strncpy to strzcpy. Signed-off-by: Rickard Strandqvist --- drivers/mmc/host/vub300.c | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/drivers/mmc

[PATCH] arch: arm: mach-omap2: usb-tusb6010.c: Cleaning up variable is set more than once

2014-06-25 Thread Rickard Strandqvist
A struct member variable is set to the same value more than once This was found using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- arch/arm/mach-omap2/usb-tusb6010.c |1 - 1 file changed, 1 deletion(-) diff --git a/arch/arm/mach-omap2/usb-tusb6010

[PATCH] staging: usbip: stub_main.c: Cleaning up missing null-terminate in conjunction with strncpy

2014-07-26 Thread Rickard Strandqvist
Replacing strncpy with strlcpy to avoid strings that lacks null terminate. Signed-off-by: Rickard Strandqvist --- drivers/staging/usbip/stub_main.c | 10 +++--- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/drivers/staging/usbip/stub_main.c b/drivers/staging/usbip