From: Colin Ian King
There appears to be a typo in the comparison of pdo_max_voltage[i]
with the previous value, currently it is checking against the
array pdo_min_voltage rather than pdo_max_voltage. I believe this
is a typo. Fix this.
Addresses-Coverity: ("Copy-paste error")
Fixes: 5007e1b5db7
From: Colin Ian King
The variable sendToTransport is being initialized with a value that is
never read and is being re-assigned a little later on. The assignment
is redundant and hence can be removed.
Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King
---
drivers/usb/storage/is
From: Colin Ian King
Variable ret is being initialized with a value that is never read
and ret is being re-assigned a little later on. The assignment is
redundant and hence can be removed.
Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King
---
drivers/usb/musb/musb_core.c | 2 +
From: Colin Ian King
The checks of a negative nval indicating an error an never be true
as nval is currently a size_t which is of course unsigned and hence
never less than zero. Fix this by making nval an int.
Detected by CoverityScan, CID#1476863 ("Unsigned compared against 0)
and CID#1476948
From: Colin Ian King
All the code paths that lead to the return statement are where
match is always true, hence the check to see if it is true is
redundant and can be removed.
Detected by CoverityScan, CID#14769672 ("Logically dead code")
Signed-off-by: Colin Ian King
---
drivers/usb/typec/mu
From: Colin Ian King
There is a spelling mistake in a dev_err message. Fix it.
Signed-off-by: Colin Ian King
---
drivers/usb/renesas_usbhs/mod_host.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/renesas_usbhs/mod_host.c
b/drivers/usb/renesas_usbhs/mod_host.c
From: Colin Ian King
A statement is indented too deeply, fix this by removing a tab.
Signed-off-by: Colin Ian King
---
drivers/usb/host/oxu210hp-hcd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/host/oxu210hp-hcd.c b/drivers/usb/host/oxu210hp-hcd.c
index c5e
From: Colin Ian King
There are a bunch of various indentation issues, clean these up.
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/function/f_uac1.c | 8 ++---
drivers/usb/gadget/legacy/inode.c| 40
drivers/usb/gadget/udc/aspeed-vhub/hub.c | 2 +-
From: Colin Ian King
A return statement is indented one level too far, fix this by removing
a tab.
Signed-off-by: Colin Ian King
---
drivers/usb/musb/musb_host.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c
inde
From: Colin Ian King
There are two statements that are indented incorrectly and need
to be moved to a new line. Fix these.
Signed-off-by: Colin Ian King
---
drivers/usb/host/u132-hcd.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/host/u132-hcd.c b/driv
From: Colin Ian King
There is a missing indentation before the return statement. Add it.
Signed-off-by: Colin Ian King
---
drivers/usb/storage/ene_ub6250.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/storage/ene_ub6250.c b/drivers/usb/storage/ene_ub6250.c
in
From: Colin Ian King
There is a hunk of code that is indented too much by one level, fix
this by removing the extraneous tabs.
Signed-off-by: Colin Ian King
---
drivers/usb/early/ehci-dbgp.c | 38 +--
1 file changed, 19 insertions(+), 19 deletions(-)
diff --git
From: Colin Ian King
Trivial fix to clean up an indentation issue, remove tab
Signed-off-by: Colin Ian King
---
drivers/uwb/i1480/dfu/usb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/uwb/i1480/dfu/usb.c b/drivers/uwb/i1480/dfu/usb.c
index c0430a41e24b..b1b466cb
From: Colin Ian King
Trivial fix to spelling mistake in comment
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/pch_udc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/gadget/udc/pch_udc.c b/drivers/usb/gadget/udc/pch_udc.c
index afaea11ec771..55c8c8a
From: Colin Ian King
Currently the call to atoi is being passed a single char string
that is not null terminated, so there is a potential read overrun
along the stack when parsing for an integer value. Fix this by
instead using a 2 char string that is initialized to all zeros
to ensure that a 1
From: Colin Ian King
Currently the allocation of port_dev_path from the call to
kobject_get_path is not being kfree'd, causing a memory leak. Fix
this by kfree'ing this at the end of the function. Add an extra
error exit path to fix one of the early leaks when envp[0] fails
to be allocated.
Dete
From: Colin Ian King
Trivial fix to spelling mistakes in debug warning messages
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/aspeed-vhub/epn.c | 2 +-
drivers/usb/gadget/udc/udc-xilinx.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/gadget/
From: Colin Ian King
Currently the allocation of a buffer is performed before a sanity check on
the required buffer size and if the buffer size is too large the error exit
return leaks the allocated buffer. Fix this by checking the size before
allocating.
Also, the same buffer is allocated agai
From: Colin Ian King
Trivial fix to spelling mistake in dev_dbg message
Signed-off-by: Colin Ian King
---
drivers/usb/serial/cypress_m8.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/serial/cypress_m8.c b/drivers/usb/serial/cypress_m8.c
index e0035c023120..31
From: Colin Ian King
Trivial fix to spelling mistake in dev_dbg message
Signed-off-by: Colin Ian King
---
drivers/usb/phy/phy-mxs-usb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/phy/phy-mxs-usb.c b/drivers/usb/phy/phy-mxs-usb.c
index e5aa24c1e4fd..1b1bb0ad
From: Colin Ian King
The removal of the use of 'flags' in commit ed194d136769
("usb: core: remove local_irq_save() around ->complete() handler")
didn't remove the unused variable. Remove it.
Cleans up warning:
warning: unused variable ‘flags’ [-Wunused-variable]
Signed-off-by: Colin Ian King
-
From: Colin Ian King
Trivial fix to spelling mistake in usbg_us_strings array
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/legacy/tcm_usb_gadget.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/gadget/legacy/tcm_usb_gadget.c
b/drivers/usb/gadget/legacy
From: Colin Ian King
Trivial fix to spelling mistake in text string
Signed-off-by: Colin Ian King
---
drivers/usb/misc/sisusbvga/sisusb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/misc/sisusbvga/sisusb.c
b/drivers/usb/misc/sisusbvga/sisusb.c
index 3e65bdc
From: Colin Ian King
Trivial fix to spelling mistake in dev_warn warning message text.
Signed-off-by: Colin Ian King
---
drivers/usb/dwc2/hcd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c
index dcfda5eb4cac..190f95964000 1
From: Colin Ian King
Use the ARRAY_SIZE macro on a couple of arrays to determine
size of the arrays. Also fix up alignment to clean up a checkpatch
warning. Improvement suggested by Coccinelle.
Signed-off-by: Colin Ian King
---
drivers/net/usb/kalmia.c | 8
1 file changed, 4 insertion
From: Colin Ian King
Currently the driver attempts to spin lock on udc->lock before a NULL
pointer check is performed on udc, hence there is a potential null
pointer dereference on udc->lock. Fix this by moving the null check
on udc before the lock occurs.
Fixes: ea6873a45a22 ("usbip: vudc: Add
From: Colin Ian King
Pointer tv_nexus is being initialized a value and this is never read
and is later being updated with the same value. Remove the redundant
initialization so that the assignment to tv_nexus is performed later
and more local to when it is being read.
Cleans up clang warning:
dr
From: Colin Ian King
Pointer dev is initialized and then re-assigned with the same value
a little later, hence the second assignment is redundant and can be
removed.
Cleans up clang warning:
drivers/usb/wusbcore/wa-nep.c:88:17: warning: Value stored to 'dev'
during its initialization is never re
From: Colin Ian King
The pointer mos_parport is being initialized to pp->private_data and
then the assignment is duplicated after a spin lock. Remove the
initialization as it occurs before the spin lock and it is a redundant
assignment.
Cleans up clang warnings:
drivers/usb/serial/mos7720.c:521
From: Colin Ian King
Trivial fix to spelling mistake in dev_dbg debug message.
Signed-off-by: Colin Ian King
---
drivers/usb/usbip/vhci_rx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/usbip/vhci_rx.c b/drivers/usb/usbip/vhci_rx.c
index 112ebb90d8c9..44cd645
From: Colin Ian King
Function xhci_dbc_free_req is local to the source and does not need to
be in global scope, so make it static.
Cleans up sparse warning:
symbol 'xhci_dbc_free_req' was not declared. Should it be static?
Signed-off-by: Colin Ian King
---
drivers/usb/host/xhci-dbgtty.c | 2 +
From: Colin Ian King
Use setup_timer function instead of initializing timer with the
function and data fields.
Signed-off-by: Colin Ian King
---
drivers/usb/atm/usbatm.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/usb/atm/usbatm.c b/drivers/usb/atm/usbatm.c
From: Colin Ian King
Trival fix to spelling mistake in ERR message
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/fsl_udc_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/gadget/udc/fsl_udc_core.c
b/drivers/usb/gadget/udc/fsl_udc_core.c
index d6
From: Colin Ian King
Trivial fix to spelling mistake in error message text
Signed-off-by: Colin Ian King
---
drivers/usb/usbip/vhci_rx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/usbip/vhci_rx.c b/drivers/usb/usbip/vhci_rx.c
index 90577e8b2282..a9813f1d507
From: Colin Ian King
The variable value is being assigned to zero but that value is never being
read. Either value is being reassigned in the following if condition, or
it is never read and the function returns. In both cases the assignment is
redundant and can be removed. Cleans up clang warnin
From: Colin Ian King
The assignment of DIV to itself is redundant and can be removed.
Signed-off-by: Colin Ian King
---
drivers/usb/serial/iuu_phoenix.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/usb/serial/iuu_phoenix.c b/drivers/usb/serial/iuu_phoenix.c
index 397a8012ffa3..62
From: Colin Ian King
Avoid dereferencing pointer g until after g has been sanity null checked;
move the assignment of cdev much later when it is required into a more
local scope.
Detected by CoverityScan, CID#1222135 ("Dereference before null check")
Fixes: b785ea7ce662 ("usb: gadget: composite
From: Colin Ian King
Variable t is assigned but never read, it is redundant and therefore
can be removed. Cleans up clang warning:
drivers/usb/host/whci/asl.c:106:3: warning: Value stored to 't' is
never read
Signed-off-by: Colin Ian King
---
drivers/usb/host/whci/asl.c | 2 --
1 file changed
From: Colin Ian King
Pointer udc is assigned but never read, hence it is redundant and
can be removed. Cleans up clang warning:
drivers/usb/gadget/udc/udc-xilinx.c:974:2: warning: Value stored
to 'udc' is never read
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/udc-xilinx.c | 2 --
From: Colin Ian King
The variable temp is incorrectly being updated, instead it should
be offset otherwise the loop just reads the same capability value
and loops forever. Thanks to Alan Stern for pointing out the
correct fix to my original fix. Fix also cleans up clang warning:
drivers/usb/ho
From: Colin Ian King
Variable is_short is set to zero but this value is never read as it is
overwritten with a new value later on, hence it is a redundant
assignment and can be removed. Pointer dev is assigned a value that
is not read and it is updated a few statements later, this too is
redunda
From: Colin Ian King
Variable is set to zero but this value is never read as it is
overwritten with a new value later on, hence it is a redundant
assignment and can be removed. Cleans up clang warning:
drivers/usb/gadget/udc/pxa27x_udc.c:1141:2: warning: Value stored
to 'dev' is never read
Sign
From: Colin Ian King
Variable index is being initialized and the value is never read,
it is being updated a few statements later, so remove the redundant
initialization. Variable total is being updated but the value is
never read, so this is also redundant and can be removed. Cleans
up two clang
From: Colin Ian King
Variable minor is being assigned but never read, hence it is redundant
and can be removed. Cleans up clang warning:
drivers/usb/misc/adutux.c:770:2: warning: Value stored to 'minor' is
never read
Signed-off-by: Colin Ian King
---
drivers/usb/misc/adutux.c | 2 --
1 file c
From: Colin Ian King
The variable temp is being set at the end of each loop iteration
but this value is never read, it is either being updated in just
the case 1 block or at the end of the loop. Thus the assignment
is redundant and can be removed. Cleans up clang warning:
drivers/usb/host/ehci
From: Colin Ian King
Don't populate the const array max_packet_array on the stack, instead make
it static. Makes the object code smaller by over 90 bytes:
Before:
textdata bss dec hex filename
343375612 128 400779c8d renesas_usb3.o
After:
textdata b
From: Colin Ian King
Pointer urbp is assigned but is never read, hence it is redundant
and can be removed. Cleans up clang warning:
drivers/usb/c67x00/c67x00-sched.c:975:2: warning: Value stored to 'urbp'
is never read
Signed-off-by: Colin Ian King
---
drivers/usb/c67x00/c67x00-sched.c | 2 --
From: Colin Ian King
The pointer dev is being assigned but is never used, hence it is
redundant and can be removed. Cleans up clang warning:
drivers/net/usb/hso.c:2280:2: warning: Value stored to 'dev' is
never read
Signed-off-by: Colin Ian King
---
drivers/net/usb/hso.c | 2 --
1 file change
From: Colin Ian King
Calls to regmap_read may fail with an -EINVAL return without setting
usbc_irq1 and usbc_irq2. The error handling clean up expects these
to have been set (or zero on a failure) and currently may try to
clear the wrong IRQs if the uninitalized garbage values in usbc_irq1
or us
From: Colin Ian King
Don't populate const arrays on the stack, instead make them
static. Makes the object code smaller by over 1070 bytes:
Before:
textdata bss dec hex filename
3505 880 043851121 drivers/usb/storage/option_ms.o
After:
textdata
From: Colin Ian King
The while loop never terminates because the loop counter i is never
decremented. Fix this by decrementing i.
Detected by CoverityScan, CID#751073 ("Infinite Loop")
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/dummy_hcd.c | 2 +-
1 file changed, 1 insertion(+),
From: Colin Ian King
When us->extra is null the driver is not initialized, however, a
later call to osd200_scsi_to_ata is made that dereferences
us->extra, causing a null pointer dereference. The code
currently detects and reports that the driver is not initialized;
add a return to avoid the sub
From: Colin Ian King
When us->extra is null the driver is not initialized, however, a
later call to osd200_scsi_to_ata is made that dereferences
us->extra, causing a null pointer dereference. The code
currently detects and reports that the driver is not initialized;
add a return to avoid the sub
From: Colin Ian King
Array type_array can be made static const rather than being
populated on the stack. Makes the object code smaller:
Before:
textdata bss dec hex filename
80871496 09583256f drivers/usb/renesas_usbhs/pipe.o
After:
textdata bs
From: Colin Ian King
Trivial fix to spelling mistake in uea_err error message
Signed-off-by: Colin Ian King
---
drivers/usb/atm/ueagle-atm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/atm/ueagle-atm.c b/drivers/usb/atm/ueagle-atm.c
index df67815f74e6..a7b69
From: Colin Ian King
Trivial fix to spelling mistake in seq_printf text
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/fsl_udc_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/gadget/udc/fsl_udc_core.c
b/drivers/usb/gadget/udc/fsl_udc_core.c
ind
From: Colin Ian King
Writing to td->next should be avoided after td has been freed using
dma_pool_free. The intent was to nullify the next pointer, but this
is potentially dangerous once it is back in the pool. Remove it.
Detected by CoverityScan, CID#1091173 ("Write tp pointer after free")
Sig
From: Colin Ian King
The initial setting of pointer s to the driver name or to the literal
string "(none)" is redundant as later it is always set to point to
a different literal string before it is printed log. Remove this
redundant code.
Detected with CoverityScan, CID#1227032, CID#1227033 ("U
From: Colin Ian King
The call to asix_write_medium_mode is not updating the return code ret
and yet ret is being checked for an error. Fix this by assigning ret to
the return code from the call asix_write_medium_mode.
Detected by CoverityScan, CID#1357148 ("Logically Dead Code")
Signed-off-by:
From: Colin Ian King
The check for retval being less than zero is always true since
retval equal to -EPIPE at that point. Replace the existing
conditional with just return retval.
Detected with CoverityScan, CID#114349 ("Logically dead code")
Signed-off-by: Colin Ian King
---
drivers/usb/mis
From: Colin Ian King
If jumpshot_get_status continues to return a failed result then the
wait loop will spin forever because the waitcount counter is never
being incremented and we don't ever timeout. Fix this by incrementing
waitcount.
Cc:
Signed-off-by: Colin Ian King
---
drivers/usb/stora
From: Colin Ian King
The 2nd check for a non-zero return from copy_to_user is redundant as
it is has already been made a few lines earlier. This check was made
redundant because of previous fix to the copy_to_user error return
check.
Detected by CoverityScan, CID#114347 ("Logically Dead Code")
From: Colin Ian King
Quirking the following AMI USB device with ALWAYS_POLL fixes an AMI
virtual keyboard and mouse from not responding and timing out when
it is attached to a ppc64el Power 8 system and when we have some
rapid open/closes on the mouse device.
usb 1-3: new high-speed USB device
From: Colin Ian King
trivial fix to typo in dev_dbg message
Signed-off-by: Colin Ian King
---
drivers/usb/renesas_usbhs/mod_host.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/renesas_usbhs/mod_host.c
b/drivers/usb/renesas_usbhs/mod_host.c
index 165e81b..dfb
From: Colin Ian King
A dev_err message spans two lines and the literal string is missing
a white space between words. Add the white space and reformat the
message to not span multiple lines.
Signed-off-by: Colin Ian King
---
drivers/usb/wusbcore/cbaf.c | 3 +--
1 file changed, 1 insertion(+),
From: Colin Ian King
A dev_err message spans two lines and the literal string is missing
a white space between words. Add the white space.
Signed-off-by: Colin Ian King
---
drivers/usb/wusbcore/cbaf.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/wusbcore/cbaf
From: Colin Ian King
the if statement in lb_modinit is unnecessary so we can totally
remove the variable ret and just return the return value from
the call to usb_function_register.
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/function/f_loopback.c | 8 ++--
1 file changed, 2 inser
From: Colin Ian King
An earlier fix partially fixed the null pointer dereference on skb->len
by moving the assignment of len after the check on skb being non-null,
however it failed to remove the erroneous dereference when assigning len.
Correctly fix this by removing the initialisation of len as
From: Colin Ian King
Trivial fix to spelling mistakes in dev_err messages.
Signed-off-by: Colin Ian King
---
drivers/usb/phy/phy-ab8500-usb.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/usb/phy/phy-ab8500-usb.c b/drivers/usb/phy/phy-ab8500-usb.c
index 0c
From: Colin Ian King
trivial typo fix in dev_err message
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/net2280.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/gadget/udc/net2280.c b/drivers/usb/gadget/udc/net2280.c
index 614ab951..d8c9ab4 100644
---
From: Colin Ian King
The assignment ret = ret is redundant and can be removed.
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/core.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/usb/gadget/udc/core.c b/drivers/usb/gadget/udc/core.c
index ff8685e..48c
From: Colin Ian King
trivial fix to spelling mistake
Signed-off-by: Colin Ian King
---
drivers/usb/gadget/udc/bdc/bdc_ep.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/gadget/udc/bdc/bdc_ep.c
b/drivers/usb/gadget/udc/bdc/bdc_ep.c
index d619950..b48b259 10064
From: Colin Ian King
The goto in create_sysfs_files is never executed, so remove it
and clean up the code.
Signed-off-by: Colin Ian King
---
drivers/usb/host/fotg210-hcd.c | 8 +---
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/drivers/usb/host/fotg210-hcd.c b/drivers/usb/ho
From: Colin Ian King
whc_init already calls whc_clean_up if an error occurs during
the initialization, so calling it again if whc_init fails at
the end of wch_probe will cause double free errors. Fix this
by bailing out on an whc_init failure to a new label that avoids
doing the duplicated whc_c
From: Colin Ian King
Used to be allocated and required freeing, but now
priv->mdio->irq is now a fixed sized array and should no longer be
free'd.
Issue detected using static analysis with CoverityScan
Fixes: e7f4dc3536a400 ("mdio: Move allocation of interrupts into core")
Signed-off-by: Colin
From: Colin Ian King
isp1760_ep_alloc_request allocates a structure with kzalloc without checking
for NULL and then returns a pointer to one of the structure fields. As the
field happens to be the first in the structure the caller can properly check
for NULL, but this is risky if the structure
From: Colin Ian King
If kzalloc returns null then isp1760_ep_alloc_request performs
a null pointer dereference on req. Check for null to avoid this.
Detected with smatch static analysis:
drivers/usb/isp1760/isp1760-udc.c:816 isp1760_ep_alloc_request()
error: potential null dereference 'req'.
From: Colin Ian King
If kzalloc returns null then isp1760_ep_alloc_request performs
a null pointer deference on req. Check for null to avoid this.
Detected with smatch static analysis:
drivers/usb/isp1760/isp1760-udc.c:816 isp1760_ep_alloc_request()
error: potential null dereference 'req'. (
From: Colin Ian King
There is old, unused code that is #defined out by the
use of NOTMOS7840 and NOTMCS7840 - these are not
defined anywhere.
If NOTMOS7840 is defined then the code will break on null
pointer dereferences on mos7840_port. So the code is
currently unused, and broken anyway, so wh
From: Colin Ian King
There is old, unused code that is #defined out by the
use of NOTMOS7840 - this is not defined anywhere. If
NOTMOS7840 is defined then the code will break on null
pointer dereferences on mos7840_port. So the code is
currently unused, and broken anyway, so why not just
remove
From: Colin Ian King
Fix warning: drivers/usb/misc/usb3503.c:195:11: warning: 'err'
may be used uninitialized in this function [-Wmaybe-uninitialized]
err is not initialized, the error return should be PTR_ERR(clk)
Signed-off-by: Colin Ian King
---
drivers/usb/misc/usb3503.c | 3 ++-
1 file
From: Colin Ian King
A failed kzalloc() is reported with a dev_err that dereferences the null
sisusb, this will cause a NULL pointer deference error.
Instead, pass dev->dev to the dev_err() rather than &sisusb->sisusb_dev->dev
Smatch analysis:
drivers/usb/misc/sisusbvga/sisusb.c:3087 sisusb_pr
82 matches
Mail list logo