Re: [PATCH] [media] gp8psk: fix spelling mistake: "firmare" -> "firmware"

2016-12-29 Thread Colin Ian King
On 29/12/16 21:23, VDR User wrote: >> - err("firmare chunk size bigger than 64 bytes."); >> + err("firmware chunk size bigger than 64 bytes."); > > Yup. > >> -"HW don't support CMAC encrypiton, use software >> CMAC encrypiton\n"

Re: [RFC v2 4/5] rcu: Use for_each_leaf_node_cpu() in force_qs_rnp()

2016-12-15 Thread Colin Ian King
_possible_mask. So replace the >>> for_each_leaf_node_possible_cpu() in force_qs_rnp() with >>> for_each_leaf_node_cpu() to save several checks. >>> >>> [Note we need to use "1UL << bit" instead of "1 << bit" to generate the >>> correspond

Re: [PATCH] btrfs: fix dereference on inode->i_sb before inode null check

2016-12-16 Thread Colin Ian King
On 16/12/16 15:03, Jeff Mahoney wrote: > On 12/16/16 7:20 AM, Colin King wrote: >> From: Colin Ian King >> >> inode is being deferenced and then inode is checked to see if it >> is null, implying we potentially could have a null pointer deference >> on inode. &g

Re: [PATCH] staging: unisys: ix spelling mistake of "outstanding"

2016-11-29 Thread Colin Ian King
On 29/11/16 21:02, Greg Kroah-Hartman wrote: > On Tue, Nov 29, 2016 at 08:37:35PM +, Kershner, David A wrote: >> >> >>> -Original Message- >>> From: Colin King [mailto:colin.k...@canonical.com] >>> Sent: Tuesday, November 29, 2016 2:07 PM >>> To: Kershner, David A ; Greg Kroah-Hartman >

Re: [PATCH] tpm2: fix off-by-one comparison and out-of-bounds read error

2017-03-22 Thread Colin Ian King
On 22/03/17 11:42, Jarkko Sakkinen wrote: > On Mon, Mar 20, 2017 at 02:23:36PM +, Colin King wrote: >> From: Colin Ian King >> >> The comparison of an out of range index into space->context_tbl is >> off-by-one and should be using >= rather than >

Re: [PATCH] scsi: fcoe: sanity check string size for store_ctrl_mode option

2017-03-22 Thread Colin Ian King
On 22/03/17 19:39, Dan Carpenter wrote: > On Wed, Mar 22, 2017 at 02:01:37PM +, Colin King wrote: >> From: Colin Ian King >> >> Reading and writing to mode[count - 1] implies the count should not >> be less than 1 so add a sanity check for this. >> >>

Re: [PATCH] iio: multiplexer: fix unsigned check with less than zero

2017-03-08 Thread Colin Ian King
On 08/03/17 08:59, Peter Rosin wrote: > On 2017-03-07 16:06, Colin King wrote: >> From: Colin Ian King >> >> Comparing a size_t with less than zero is always false as size_t >> is unsigned. The intent of the comparison was to check if the size >> was -1 (that is

Re: [PATCH] [media] atmel-isc: fix off-by-one comparison and out of bounds read issue

2017-03-09 Thread Colin Ian King
like: > > *hist_count += i * (*hist_entry++); > > *hist_count += hist_entry[i]*i; As long as it gets fixed somehow, then I'm happy. Colin > > > re, > wh >>> >>> On 3/7/2017 22:30, Colin King wrote: >>>> From: Colin Ian King >&

re: rxrpc: Fix deadlock between call creation and sendmsg/recvmsg

2017-03-02 Thread Colin Ian King
I think the following part of the patch is problematic: call = rxrpc_find_call_by_user_ID(rx, user_call_ID); if (!call) { + ret = -EBADSLT; if (cmd != RXRPC_CMD_SEND_DATA) - return -EBADSLT; + goto error_rel

re: sfc: process RX event inner checksum flags

2017-02-10 Thread Colin Ian King
Hi there, not sure if this is a bug, or intentional, but CoverityScan picked up a mismatch in arguments when calling efx_ef10_handle_rx_event_error() with commit "sfc: process RX event inner checksum flags" that landed in linux-next: CID 1402067 (#1 of 1): Arguments in wrong order (SWAPPED_ARG

drivers/staging/rtl8192u

2017-02-12 Thread Colin Ian King
Hi, Static analysis via CoverityScan picked up an issue in cmpk_handle_query_config_rx where the following operation on an u8 is clearly not correct: rx_query_cfg.cfg_action = (pmsg[4] & 0x8000) >> 31; The result of this operation is always zero. I suspect this should be:

Re: [PATCH] usb: misc: usbtest: remove redundant check on retval < 0

2017-02-13 Thread Colin Ian King
On 13/02/17 10:45, Felipe Balbi wrote: > > Hi, > > Colin King writes: >> 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 wi

re: sched: check negative err value to safe one level of indent

2017-02-14 Thread Colin Ian King
Jiro, A recent static analysis run with CoverityScan identified a potential change in functionality with your recent commit "sched: check negative err value to safe one level of indent" that landed in linux-next. The original path for case RTM_DELTFILTER would always goto errout, but your commit

Re: [PATCH][V2] rtlwifi: rtl8192de: ix spelling mistake: "althougth" -> "though"

2017-02-26 Thread Colin Ian King
On 26/02/17 18:52, Colin King wrote: > From: Colin Ian King > > trivial fix to spelling mistake in RT_TRACE message > > Signed-off-by: Colin Ian King > --- > drivers/net/wireless/realtek/rtlwifi/rtl8192de/phy.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) &

Re: [PATCH] scsi: aacraid: rcode is unsigned, so can never be less than zero

2017-02-07 Thread Colin Ian King
On 07/02/17 11:37, Dan Carpenter wrote: > On Tue, Feb 07, 2017 at 11:27:38AM +, Colin King wrote: >> From: Colin Ian King >> >> The check on rcode >= 0 is always true because rcode is unsigned >> and can never be less than zero. Remove the redundant check. >&

Re: [PATCH][net-next] net: bridge: remove redundant check to see if err is set

2017-02-07 Thread Colin Ian King
;vid - v->vid) > 0 && vlan_tunnel_id_isrange(v_end, v) > 0) num_tinfos += 2; else num_tinfos += 1; } On 07/02/17 11:30, Nikolay Aleksandrov wrote: > On 07/02/17 11:56, Colin King wrote: >> From: Col

Re: [PATCH][V2] Smack: fix a dereference before null check on sock->sk

2017-02-09 Thread Colin Ian King
On 09/02/17 18:44, Casey Schaufler wrote: > On 2/9/2017 9:11 AM, Colin King wrote: >> From: Colin Ian King >> >> The initialisation of pointer ssp is from a dereference on sock->sk >> before sock-sk is null checked, hence there is a potential for a >> null po

Re: [PATCH v1] scsi: ufs: fix arguments order some trace calls

2017-01-11 Thread Colin Ian King
On 11/01/17 00:48, Subhash Jadavani wrote: > Colin Ian King reported that with > commit 7ff5ab473633 ("scsi: ufs: add tracing support") static analysis > is reporting that we may have swapped arguments on calls to: > trace_ufshcd_runtime_resume, > tra

Re: [PATCH] ide: hpt366: fix incorrect mask when checking at cmd_high_time

2016-07-12 Thread Colin Ian King
On 12/07/16 12:09, Sergei Shtylyov wrote: > On 7/12/2016 2:04 PM, Sergei Shtylyov wrote: > >>> From: Colin Ian King >>> >>> According to the HPT366 data sheet, PCI config space dword 0x40-0x43 >>> bits 11:8 specify the primary drive cmd_high_time, howev

Re: [PATCH] ata: hpt366: fix incorrect mask when checking at cmd_high_time

2016-07-12 Thread Colin Ian King
On 12/07/16 12:27, Bartlomiej Zolnierkiewicz wrote: > > Hi, > > On Tuesday, July 12, 2016 12:16:19 PM Colin King wrote: >> From: Colin Ian King >> >> According to the HPT366 data sheet, PCI config space dword 0x40-0x43 >> bits 11:8 specify the primary drive

Re: [Nouveau] [PATCH] drm/nouveau/iccsense: fix memory leak on default sensor->type case

2016-06-03 Thread Colin Ian King
es on this. Colin > > 2016-06-02 12:28 GMT+02:00 Colin King : >> From: Colin Ian King >> >> The default sensor->type case leaks memory allocated to rail. Fix >> this by free'ing rail before we continue with the next loop iteration. >> >> Signed-

Re: powerpc/fadump: trivial fix of spelling mistake, clean up message

2016-06-27 Thread Colin Ian King
On 26/06/16 05:19, Michael Ellerman wrote: > On Fri, 2016-24-06 at 17:43:00 UTC, Colin King wrote: >> From: Colin Ian King >> >> trivial fix to spelling mistake "rgistration" and minor clean up >> of the printk error message > > Can you also: > - u

Re: powerpc/fadump: trivial fix of spelling mistake, clean up message

2016-06-27 Thread Colin Ian King
On 27/06/16 12:20, Michael Ellerman wrote: > On Mon, 2016-06-27 at 03:51 -0700, Joe Perches wrote: >> On Mon, 2016-06-27 at 11:38 +0100, Colin Ian King wrote: >>> On 26/06/16 05:19, Michael Ellerman wrote: >>>> On Fri, 2016-24-06 at 17:43:00 UTC, Colin King wrote:

Re: [PATCH] devpts: fix null pointer dereference on failed memory allocation

2016-06-27 Thread Colin Ian King
On 26/06/16 19:29, Greg Kroah-Hartman wrote: > On Mon, Jun 20, 2016 at 03:40:27PM +0100, Colin King wrote: >> From: Colin Ian King >> >> An ENOMEM when creating a pair tty in tty_ldisc_setup causes a null >> pointer dereference in devpts_kill_index because tty->link

Re: Q: why didn't GCC warn about this uninitialized variable?

2016-03-03 Thread Colin Ian King
On 03/03/16 12:19, Ingo Molnar wrote: > > * Arnaldo Carvalho de Melo wrote: > >> Em Wed, Mar 02, 2016 at 02:21:27PM +0100, Peter Zijlstra escreveu: >>> On Wed, Mar 02, 2016 at 10:03:50AM -0300, Arnaldo Carvalho de Melo wrote: > Would not something like: > > sa = (struct sigaction){

Re: [PATCH] selinux: fix memory leak on node_ptr on error return path

2016-03-22 Thread Colin Ian King
On 22/03/16 21:35, Paul Moore wrote: > On Tue, Mar 22, 2016 at 4:28 PM, Serge E. Hallyn wrote: >> Quoting Colin King (colin.k...@canonical.com): >>> From: Colin Ian King >>> >>> node_ptr is not being free'd if the list allocation fails, fix >>>

Re: [PATCH] rtlwifi: pass struct rtl_stats by reference as it is more efficient

2016-02-22 Thread Colin Ian King
On 22/02/16 06:51, Alexander Stein wrote: > On Saturday 20 February 2016 22:10:27, Colin King wrote: >> From: Colin Ian King >> >> passing rtl_stats by value is inefficient; the structure is over 300 >> bytes in size and generally just one field (packet_report_type) &

rhashtable concurrent writers issue, 4.2+

2015-12-11 Thread Colin Ian King
Hi, After testing with commit 7def0f952eccdd0edb3c504f4dab35ee0d3aba1f ("lib: fix data race in rhashtable_rehash_one") on the current 4.4-rc4 kernel, I believe I am still seeing race conditions that seem to bite concurrent readers. The reproducer is found in my stress-ng system stress tool: git:

Re: [PATCH] tty/metag_da: initialize number_written to zero

2016-01-28 Thread Colin Ian King
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 On 27/01/16 11:42, James Hogan wrote: > Hi Colin, > > On Tue, Jan 26, 2016 at 11:37:25PM +, Colin King wrote: >> From: Colin Ian King >> >> number_written is not initialized, so it can be any value. In the >> c

Re: [PATCH] tty/metag_da: initialize number_written to zero

2016-02-06 Thread Colin Ian King
On 07/02/16 07:41, Greg Kroah-Hartman wrote: > On Thu, Jan 28, 2016 at 06:48:17PM +0000, Colin Ian King wrote: >> On 27/01/16 11:42, James Hogan wrote: >>> Hi Colin, >>> >>> On Tue, Jan 26, 2016 at 11:37:25PM +, Colin King wrote: >>>> From:

Re: [PATCH] drm/arm: fix unintentional integer overflow on left shift

2020-06-18 Thread Colin Ian King
On 18/06/2020 13:14, Liviu Dudau wrote: > On Thu, Jun 18, 2020 at 11:04:00AM +0100, Colin King wrote: >> From: Colin Ian King > > Hi Colin, > >> >> Shifting the integer value 1 is evaluated using 32-bit arithmetic >> and then used in an expression tha

Re: [PATCH] drm/arm: fix unintentional integer overflow on left shift

2020-06-18 Thread Colin Ian King
1 it a UL before shifting so it catches these type of bugs. use BIT_ULL when the result is assigned to a long long. Colin > > Am Do., 18. Juni 2020 um 16:23 Uhr schrieb Liviu Dudau : >> >> On Thu, Jun 18, 2020 at 01:50:34PM +0100, Colin Ian King wrote: >>> On 18/06/2020

re: fs: Expand __fd_install_received() to accept fd

2020-06-22 Thread Colin Ian King
Hi, static analysis with Coverity has detected a potential issue with the following commit: commit 8336af9ab8c5d64a309cbf72648054af61548899 Author: Kees Cook Date: Wed Jun 10 08:46:58 2020 -0700 fs: Expand __fd_install_received() to accept fd Calling __fd_install_received() with fd >= 0

Re: [PATCH][next] mm/zswap: fix a couple of memory leaks and rework kzalloc failure check

2020-06-23 Thread Colin Ian King
eck >> >> On Mon, Jun 22, 2020 at 04:35:46PM +0100, Colin King wrote: >>> From: Colin Ian King >>> >>> kzalloc failures return NULL on out of memory errors, so replace the >>> IS_ERR_OR_NULL check with the usual null pointer check. Fix two mem

re: power: supply: bq25980: Add support for the BQ259xx family

2020-10-06 Thread Colin Ian King
Hi Static analysis with Coverity has detected a potential out-of-bounds read issue in the following commit: commit 5069185fc18e810715a91d80fcd075e03add600c Author: Dan Murphy Date: Mon Aug 31 11:48:49 2020 -0500 power: supply: bq25980: Add support for the BQ259xx family Analysis is as f

Re: [PATCH] selftests/ftrace: check for do_sys_openat2 in user-memory test

2020-10-01 Thread Colin Ian King
On 01/10/2020 15:44, Steven Rostedt wrote: > On Thu, 1 Oct 2020 09:56:41 +0100 > Colin King wrote: > >> From: Colin Ian King >> >> More recent libc implementations are now using openat/openat2 system >> calls so also add do_sys_openat2 to the tracing so that th

Re: [PATCH] selftests/ftrace: check for do_sys_openat2 in user-memory test

2020-10-02 Thread Colin Ian King
On 02/10/2020 14:07, Masami Hiramatsu wrote: > On Thu, 1 Oct 2020 09:56:41 +0100 > Colin King wrote: > >> From: Colin Ian King >> >> More recent libc implementations are now using openat/openat2 system >> calls so also add do_sys_openat2 to the tracing so

re: tracing: Add support for dynamic strings to synthetic events

2020-10-07 Thread Colin Ian King
Hi, Static analysis with Coverity has detected a duplicated condition in an if statement in the following commit in source kernel/trace/trace_events_synth.c commit bd82631d7ccdc894af2738e47abcba2cb6e7dea9 Author: Tom Zanussi Date: Sun Oct 4 17:14:06 2020 -0500 tracing: Add support for dyn

Re: tracing: Add support for dynamic strings to synthetic events

2020-10-07 Thread Colin Ian King
On 07/10/2020 14:30, Steven Rostedt wrote: > On Wed, 7 Oct 2020 14:08:38 +0100 > Colin Ian King wrote: > >> Hi, >> >> Static analysis with Coverity has detected a duplicated condition in an >> if statement in the following commit in source >> kernel/

re: io_uring: process task work in io_uring_register()

2020-10-08 Thread Colin Ian King
Hi, Static analysis with Coverity has detected a "dead-code" issue with the following commit: commit af9c1a44f8dee7a958e07977f24ba40e3c770987 Author: Jens Axboe Date: Thu Sep 24 13:32:18 2020 -0600 io_uring: process task work in io_uring_register() The analysis is as follows: 9513

Re: [PATCH] scsi: qla2xxx: fix return of uninitialized value in rval

2020-10-08 Thread Colin Ian King
On 08/10/2020 19:41, Pavel Machek wrote: > On Thu 2020-10-08 19:32:39, Colin King wrote: >> From: Colin Ian King >> >> A previous change removed the initialization of rval and there is >> now an error where an uninitialized rval is being returned on an >> error r

re: RDMA/rxe: Fix skb lifetime in rxe_rcv_mcast_pkt()

2020-10-12 Thread Colin Ian King
Hi, Static analysis with Coverity has detected a potential issue with the following commit: commit e7ec96fc7932f48a6d6cdd05bf82004a1a04285b Author: Bob Pearson Date: Thu Oct 8 15:36:52 2020 -0500 RDMA/rxe: Fix skb lifetime in rxe_rcv_mcast_pkt() The analysis is as follows: 16. Condit

Re: [PATCH] ima: Fix sizeof mismatches

2020-10-12 Thread Colin Ian King
On 12/10/2020 19:06, Joe Perches wrote: > On Mon, 2020-10-12 at 13:51 -0400, Mimi Zohar wrote: >> On Wed, 2020-10-07 at 11:27 -0700, Joe Perches wrote: >>> On Wed, 2020-10-07 at 12:02 +0100, Colin King wrote: An incorrect sizeof is being used, sizeof(*fields) is not correct, it should be

Re: [PATCH] ima: Fix sizeof mismatches

2020-10-13 Thread Colin Ian King
On 13/10/2020 17:17, Mimi Zohar wrote: > On Mon, 2020-10-12 at 19:10 +0100, Colin Ian King wrote: >> On 12/10/2020 19:06, Joe Perches wrote: >>> On Mon, 2020-10-12 at 13:51 -0400, Mimi Zohar wrote: >>>> On Wed, 2020-10-07 at 11:27 -0700, Joe Perches wrote: >>&

re: net/mlx5: Refactor tc flow attributes structure

2020-09-28 Thread Colin Ian King
Hi, static analysis with Coverity has found a null pointer dereference issue with the following commit: commit c620b772152b8274031083bdb2e11c963e596c5c Author: Ariel Levkovich Date: Thu Apr 30 05:54:08 2020 +0300 net/mlx5: Refactor tc flow attributes structure The analysis is as follows:

Re: [PATCH][net-next] nexthop: fix incorrect allocation failure on nhg->spare

2020-05-28 Thread Colin Ian King
On 28/05/2020 15:55, Nikolay Aleksandrov wrote: > On 28/05/2020 17:53, Nikolay Aleksandrov wrote: >> On 28/05/2020 17:51, Colin King wrote: >>> From: Colin Ian King >>> >>> The allocation failure check for nhg->spare is currently checking >>> the p

Re: [PATCH][net-next] nexthop: fix incorrect allocation failure on nhg->spare

2020-05-28 Thread Colin Ian King
On 28/05/2020 16:55, Nikolay Aleksandrov wrote: > On 28/05/2020 18:53, Colin Ian King wrote: >> On 28/05/2020 15:55, Nikolay Aleksandrov wrote: >>> On 28/05/2020 17:53, Nikolay Aleksandrov wrote: >>>> On 28/05/2020 17:51, Colin King wrote: >>>>> Fro

re: netfilter: nfnetlink_queue: resolve clash for unconfirmed conntracks

2020-05-26 Thread Colin Ian King
Hi, Static analysis with Coverity has detected a potential issue with the commit in linux-next: commit 368982cd7d1bd41cd39049c794990aca3770db44 Author: Pablo Neira Ayuso Date: Wed May 23 09:17:24 2018 +0200 netfilter: nfnetlink_queue: resolve clash for unconfirmed conntracks Namely: 201

Re: [PATCH] net: tg3: tidy up loop, remove need to compute off with a multiply

2020-05-08 Thread Colin Ian King
On 09/05/2020 00:21, Joe Perches wrote: > On Fri, 2020-05-08 at 23:53 +0100, Colin King wrote: >> From: Colin Ian King >> >> Currently the value for 'off' is computed using a multiplication and >> a couple of statements later off is being incremented by len an

NAK: [PATCH][next] usb: xhci: fix spelling mistake in Kconfig "firwmare" -> "firmware"

2020-06-03 Thread Colin Ian King
On 03/06/2020 13:11, Colin King wrote: > From: Colin Ian King > > There are two spelling mistakes in the Kconfig text. Fix these. > > Signed-off-by: Colin Ian King > --- > drivers/usb/host/Kconfig | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >

Re: NAK: [PATCH][next] usb: xhci: fix spelling mistake in Kconfig "firwmare" -> "firmware"

2020-06-03 Thread Colin Ian King
On 03/06/2020 13:15, Colin Ian King wrote: > On 03/06/2020 13:11, Colin King wrote: >> From: Colin Ian King >> >> There are two spelling mistakes in the Kconfig text. Fix these. >> >> Signed-off-by: Colin Ian King >> --- >> drivers/usb/host/Kcon

Re: [PATCH] input: ims-pcu: remove redundant assignment to variable 'error'

2020-06-03 Thread Colin Ian King
On 03/06/2020 15:09, Dan Carpenter wrote: > On Wed, Jun 03, 2020 at 02:51:02PM +0100, Colin King wrote: >> From: Colin Ian King >> >> The variable error is being initialized with a value that is >> never read and the -ENOMEM error return is being returned anyhow >>

Re: [PATCH] input: ims-pcu: remove redundant assignment to variable 'error'

2020-06-03 Thread Colin Ian King
On 03/06/2020 15:45, Dan Carpenter wrote: > On Wed, Jun 03, 2020 at 03:18:46PM +0100, Colin Ian King wrote: >> On 03/06/2020 15:09, Dan Carpenter wrote: >>> On Wed, Jun 03, 2020 at 02:51:02PM +0100, Colin King wrote: >>>> From: Colin Ian King >>>> >>

Re: [PATCH][next] ovl: fix null pointer dereference on null stack pointer on error return

2020-06-03 Thread Colin Ian King
On 03/06/2020 17:11, Amir Goldstein wrote: > On Wed, Jun 3, 2020 at 6:46 PM Colin King wrote: >> >> From: Colin Ian King >> >> There are two error return paths where the call to path_put is >> dereferencing the null pointer 'stack'. Fix this by avoidin

Re: [PATCH][next] ovl: fix null pointer dereference on null stack pointer on error return

2020-06-04 Thread Colin Ian King
On 04/06/2020 08:25, Miklos Szeredi wrote: > On Wed, Jun 3, 2020 at 6:15 PM Colin Ian King > wrote: >> >> On 03/06/2020 17:11, Amir Goldstein wrote: >>> On Wed, Jun 3, 2020 at 6:46 PM Colin King wrote: >>>> >>>> From: Colin Ian King >>&

Re: [PATCH][next] USB: EHCI: ehci-mv: fix less than zero comparison of an unsigned int

2020-05-15 Thread Colin Ian King
On 15/05/2020 18:21, Alan Stern wrote: > On Fri, May 15, 2020 at 05:54:53PM +0100, Colin King wrote: >> From: Colin Ian King >> >> The comparison of hcd->irq to less than zero for an error check will >> never be true because hcd->irq is an unsigned int. Fix this

Re: [PATCH v2] power: supply: charger-manager: Fix info message in check_charging_duration()

2020-09-02 Thread Colin Ian King
On 02/09/2020 17:43, Gustavo A. R. Silva wrote: > On Wed, Sep 02, 2020 at 09:29:31AM -0700, Randy Dunlap wrote: >> On 9/2/20 9:23 AM, Gustavo A. R. Silva wrote: >>> A few months ago, commit e132fc6bb89b ("power: supply: charger-manager: >>> Make decisions focussed on battery status") >>> changed t

Re: [PATCH] RDMA/ucma: fix memory leak of mc on an xa_alloc failure

2020-09-02 Thread Colin Ian King
On 02/09/2020 20:03, Markus Elfring wrote: >> Currently when an xa_alloc failure occurs the error exit path leaks >> the allocated object mc. Fix this by adding an error return path >> that frees mc and rename error exit paths err3 to err4 and err2 to err3. > > I propose to choose further alterna

Re: [PATCH] ACPI: sysfs: copy ACPI data using io memory copying

2020-09-02 Thread Colin Ian King
On 14/03/2020 10:23, Rafael J. Wysocki wrote: > On Thursday, March 12, 2020 12:13:45 PM CET Colin King wrote: >> From: Colin Ian King >> >> Reading ACPI data on ARM64 at a non-aligned offset from >> /sys/firmware/acpi/tables/data/BERT will cause a splat because >&

Re: [PATCH] ACPI: sysfs: copy ACPI data using io memory copying

2020-09-02 Thread Colin Ian King
On 02/09/2020 12:13, David Laight wrote: > From: Colin Ian King >> Sent: 02 September 2020 11:27 >> >> On 14/03/2020 10:23, Rafael J. Wysocki wrote: >>> On Thursday, March 12, 2020 12:13:45 PM CET Colin King wrote: >>>> From: Colin Ian King >>>

Re: [RFC PATCH -rc] gcov: Protect from uninitialized number of functions provided by GCC

2020-08-29 Thread Colin Ian King
nabled at (326463): [] > _raw_spin_unlock_irqrestore+0x8e/0xb0 > hardirqs last disabled at (326464): [] > _raw_spin_lock_irqsave+0x34/0xa0 > hardirqs last disabled at (326464): [] > _raw_spin_lock_irqsave+0x34/0xa0 > softirqs last enabled at (320794): [] > __do_softirq+0x931/0xb

NAK: [PATCH][next] drm/amd/display: fix spelling mistake "Usupported" -> "Unsupported"

2020-08-04 Thread Colin Ian King
On 04/08/2020 18:34, Colin King wrote: > From: Colin Ian King > > There are spelling mistakes in two DRM_ERROR error messages. Fix them. > > Signed-off-by: Colin Ian King > --- > drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 4 ++-- > 1 file changed, 2 in

re: vfio/fsl-mc: trigger an interrupt via eventfd

2020-10-15 Thread Colin Ian King
Hi, Static analysis with Coverity on linux-next today has detected an issue in the following commit: commit cc0ee20bd96971c10eba9a83ecf1c0733078a083 Author: Diana Craciun Date: Mon Oct 5 20:36:52 2020 +0300 vfio/fsl-mc: trigger an interrupt via eventfd The analysis is as follows: 106 s

Re: [PATCH][next] afs: fix a dereference on pointer cell before cell is null checked

2020-10-27 Thread Colin Ian King
On 27/10/2020 11:05, David Howells wrote: > Colin King wrote: > >> @@ -606,7 +605,7 @@ void afs_unuse_cell(struct afs_net *net, struct afs_cell >> *cell, enum afs_cell_tr >> >> u = atomic_read(&cell->ref); >> a = atomic_dec_return(&cell->active); >> -trace_afs_cell(debug_id, u, a

re: ASoC: qcom: sm8250: add sound card qrb5165-rb5 support

2020-10-28 Thread Colin Ian King
Hi, Static analysis on linux-next with Coverity had detected a potential array out-of-bounds write issue in the following commit: commit aa2e2785545aab21b6cb2e23f111ae0751cbcca7 Author: Srinivas Kandagatla Date: Mon Oct 26 17:09:47 2020 + ASoC: qcom: sm8250: add sound card qrb5165-rb5

Re: PM / devfreq: map devfreq drivers to governor using name

2020-10-28 Thread Colin Ian King
On 28/10/2020 12:00, Colin Ian King wrote: > Hi, > > Static analysis of linux-next with Coverity has found a potential null > pointer dereference issue with the following commit: > > commit 1b5c1be2c88e8445a20fa1929e26c37e7ca8c926 > Author: Nishanth Menon > Date:

re: PM / devfreq: map devfreq drivers to governor using name

2020-10-28 Thread Colin Ian King
Hi, Static analysis of linux-next with Coverity has found a potential null pointer dereference issue with the following commit: commit 1b5c1be2c88e8445a20fa1929e26c37e7ca8c926 Author: Nishanth Menon Date: Mon Oct 29 15:01:45 2012 -0500 PM / devfreq: map devfreq drivers to governor using n

Re: [PATCH] ASoC: qcom: sm8250: Fix array out of bounds access

2020-10-28 Thread Colin Ian King
cro. > > Fixes: aa2e2785545a ("ASoC: qcom: sm8250: add sound card qrb5165-rb5 support") > Reported-by: Colin Ian King > Signed-off-by: Srinivas Kandagatla > --- > sound/soc/qcom/sm8250.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) > > diff --git a/sound

Re: default cpufreq gov, was: [PATCH] sched/fair: check for idle core

2020-10-22 Thread Colin Ian King
On 22/10/2020 15:52, Mel Gorman wrote: > On Thu, Oct 22, 2020 at 02:29:49PM +0200, Peter Zijlstra wrote: >> On Thu, Oct 22, 2020 at 02:19:29PM +0200, Rafael J. Wysocki wrote: However I do want to retire ondemand, conservative and also very much intel_pstate/active mode. >>> >>> I agree in

Re: [PATCH] stop_machine: Mark functions as notrace

2020-10-23 Thread Colin Ian King
relax(); > } > Apologies for taking so long to reply, I needed to test this on several devices. This not only fixes the ftrace issue I see on RISC-V but also a ftrace hang issue on ARM64 in 5.8 too. Tested-by: Colin Ian King Many thanks!

re: spi: bcm2835: fix gpio cs level inversion

2020-10-30 Thread Colin Ian King
Hi, Static analysis with coverity on today's linux-next has detected a potential issue in bcm2835_spi_setup() in the following commit: commit 5e31ba0c0543a04483b53151eb5b7413efece94c Author: Martin Hundebøll Date: Wed Oct 14 11:02:30 2020 +0200 spi: bcm2835: fix gpio cs level inversion

Re: [PATCH] vfio/fsl-mc: fix the return of the uninitialized variable ret

2020-10-16 Thread Colin Ian King
On 16/10/2020 10:26, Diana Craciun OSS wrote: > On 10/15/2020 9:52 PM, Alex Williamson wrote: >> On Thu, 15 Oct 2020 13:22:26 +0100 >> Colin King wrote: >> >>> From: Colin Ian King >>> >>> Currently the success path in function vfio_fsl_mc_reflck_a

Re: [PATCH][next] cpumask: allocate enough space for string and trailing '\0' char

2020-11-10 Thread Colin Ian King
On 10/11/2020 15:24, Paul E. McKenney wrote: > On Mon, Nov 09, 2020 at 11:57:15PM -0500, Paul Gortmaker wrote: >> >> >> On 2020-11-09 8:07 p.m., Qian Cai wrote: >>> On Mon, 2020-11-09 at 13:04 +, Colin King wrote: >>>> From: Colin Ian King >&g

Re: [PATCH v2 0/4] support for global CPU list abbreviations

2020-11-10 Thread Colin Ian King
On 10/11/2020 15:32, Paul E. McKenney wrote: > On Mon, Nov 09, 2020 at 11:07:21PM -0500, Paul Gortmaker wrote: >> RFC/v1 ---> v2: >> >> commit #1: >>leave one line stub behind for !SMP solving build failures. >>Reported by Randy Dunlap and various build bots. >> >> commit #4 >>manage to

Re: [PATCH][next] cpumask: allocate enough space for string and trailing '\0' char

2020-11-10 Thread Colin Ian King
On 10/11/2020 18:38, Paul E. McKenney wrote: > On Tue, Nov 10, 2020 at 03:34:05PM +0000, Colin Ian King wrote: >> On 10/11/2020 15:24, Paul E. McKenney wrote: >>> On Mon, Nov 09, 2020 at 11:57:15PM -0500, Paul Gortmaker wrote: >>>> >>>> >>>>

Re: [PATCH] PCI: fix a potential uninitentional integer overflow issue

2020-11-10 Thread Colin Ian King
t 12:46:15PM +0100, Colin King wrote: >>>>> From: Colin Ian King >>>>> >>>>> The shift of 1 by align_order is evaluated using 32 bit arithmetic >>>>> and the result is assigned to a resource_size_t type variable that >>>>> i

Re: [PATCH][next] mptcp: fix a dereference of pointer before msk is null checked.

2020-11-11 Thread Colin Ian King
On 11/11/2020 18:49, Mat Martineau wrote: > On Mon, 9 Nov 2020, Colin King wrote: > >> From: Colin Ian King >> >> Currently the assignment of pointer net from the sock_net(sk) call >> is potentially dereferencing a null pointer sk. sk points to the >> sam

Re: [PATCH][next] drm/kmb: fix array out-of-bounds writes to kmb->plane_status[]

2020-11-13 Thread Colin Ian King
On 13/11/2020 14:55, Sam Ravnborg wrote: > Hi Colin. > > On Fri, Nov 13, 2020 at 12:01:21PM +, Colin King wrote: >> From: Colin Ian King >> >> Writes to elements in the kmb->plane_status array in function >> kmb_plane_atomic_disable are overrunning the a

Re: [PATCH][next] drm/kmb: fix array out-of-bounds writes to kmb->plane_status[]

2020-11-16 Thread Colin Ian King
On 16/11/2020 16:53, Chrisanthus, Anitha wrote: > Hi Sam and Colin, > >> -Original Message- >> From: Sam Ravnborg >> Sent: Friday, November 13, 2020 10:02 AM >> To: Colin Ian King >> Cc: Chrisanthus, Anitha ; Dea, Edmund J >>

Re: [PATCH][V2] PCI: Fix a potential uninitentional integer overflow issue

2020-11-14 Thread Colin Ian King
On 14/11/2020 21:53, Bjorn Helgaas wrote: > [+cc Dan] > > On Tue, Nov 10, 2020 at 10:10:48PM +, Colin King wrote: >> From: Colin Ian King >> >> The shift of 1 by align_order is evaluated using 32 bit arithmetic >> and the result is assigned to a resource_siz

Re: [PATCH][next] drm/atomic: avoid null pointer dereference on pointer crtc

2020-11-16 Thread Colin Ian King
On 16/11/2020 11:08, Simon Ser wrote: > On Monday, November 16, 2020 12:03 PM, Colin King > wrote: > >> From: Colin Ian King colin.k...@canonical.com >> >> Since moving to the new debug helper functions we now have a debug message >> that dereferences crtc to

Re: [PATCH][next] hwmon: corsair-psu: fix unintentional sign extension issue

2020-11-05 Thread Colin Ian King
On 05/11/2020 12:32, Wilken Gottwalt wrote: > On Thu, 5 Nov 2020 11:50:19 + > Colin King wrote: > >> From: Colin Ian King >> >> The shifting of the u8 integer data[3] by 24 bits to the left will >> be promoted to a 32 bit signed int and then sign-extende

re: scsi: ufs: Try to save power mode change and UIC cmd completion timeout

2020-11-09 Thread Colin Ian King
Hi Static analysis with Coverity on linux-next has detected a potential null pointer deference issue with commit: commit 0f52fcb99ea2738a0a0f28e12cf4dd427069dd2a Author: Can Guo Date: Mon Nov 2 22:24:40 2020 -0800 scsi: ufs: Try to save power mode change and UIC cmd completion timeout T

re: net: dsa: hellcreek: Add support for hardware timestamping

2020-11-09 Thread Colin Ian King
Hi Static analysis on linux-next with Coverity has detected a potential null pointer dereference issue on the following commit: commit f0d4ba9eff75a79fccb7793f4d9f12303d458603 Author: Kamil Alkhouri Date: Tue Nov 3 08:10:58 2020 +0100 net: dsa: hellcreek: Add support for hardware timestam

Re: net: dsa: hellcreek: Add support for hardware timestamping

2020-11-09 Thread Colin Ian King
On 09/11/2020 13:59, Kurt Kanzenbach wrote: > Hi Colin, > > On Mon Nov 09 2020, Colin Ian King wrote: >> Hi >> >> Static analysis on linux-next with Coverity has detected a potential >> null pointer dereference issue on the following commit: >> >> co

Re: [PATCH] qed: fix assignment of n_rq_elems to incorrect params field

2020-07-27 Thread Colin Ian King
On 27/07/2020 15:36, Alexander Lobakin wrote: > Hi Colin, > > From: Colin King > Date: Mon, 27 Jul 2020 15:17:12 +0100 > >> From: Colin Ian King >> >> Currently n_rq_elems is being assigned to params.elem_size instead of the >> field params.num_elems.

re: net: phy: continue searching for C45 MMDs even if first returned ffff:ffff

2020-07-20 Thread Colin Ian King
Hi, Static analysis by Coverity has found a potential issue with the following commit in /drivers/net/phy/phy_device.c: commit bba238ed037c60242332dd1e4c5778af9eba4d9b Author: Vladimir Oltean Date: Sun Jul 12 19:48:15 2020 +0300 net: phy: continue searching for C45 MMDs even if first retu

re: xprtrdma: Prevent inline overflow

2020-07-15 Thread Colin Ian King
Hi, Static analysis with Coverity has found a potential issue with the header size calculations in source net/sunrpc/xprtrdma/rpc_rdma.c in functions rpcrdma_max_call_header_size and rpcrdma_max_reply_header_size. The commit in question is relatively old: commit 302d3deb20682a076e1ab551821cacfdc

Re: xprtrdma: Prevent inline overflow

2020-07-15 Thread Colin Ian King
On 15/07/2020 17:05, Chuck Lever wrote: > > >> On Jul 15, 2020, at 11:56 AM, Colin Ian King >> wrote: >> >> Hi, >> >> Static analysis with Coverity has found a potential issue with the >> header size calculations in sourc

Re: [PATCH] xprtrdma: fix incorrect header size calcations

2020-07-15 Thread Colin Ian King
Bah, $SUBJECT typo "calcations" -> "calculations". can that be fixed up when it's applied, or shall I send a V2? On 15/07/2020 17:26, Colin King wrote: > From: Colin Ian King > > Currently the header size calculations are using an assignment > operator in

Re: USB: PHY: JZ4770: Add support for new Ingenic SoCs - bug report

2020-07-27 Thread Colin Ian King
Hi, Static analysis with Coverity has detected an issue with the following commit: commit 2a6c0b82e65128c73b5102e00e031c5e58bb3504 Author: 周琰杰 (Zhou Yanjie) Date: Thu Jul 23 14:13:00 2020 +0800 USB: PHY: JZ4770: Add support for new Ingenic SoCs. The analysis from Coverity is as follows:

Re: [PATCH][next] bpf: fix swapped arguments in calls to check_buffer_access

2020-07-28 Thread Colin Ian King
On 28/07/2020 11:43, Daniel Borkmann wrote: > On 7/27/20 11:39 PM, Yonghong Song wrote: >> On 7/27/20 10:54 AM, Colin King wrote: >>> From: Colin Ian King >>> >>> There are a couple of arguments of the boolean flag zero_size_allowed >>> and the c

re: mvpp2: XDP TX support

2020-07-06 Thread Colin Ian King
Hi, Static analysis with Coverity has found a potential issue in the following commit: commit c2d6fe6163de80d7f7cf400ee351f56d6cdb7a5a Author: Matteo Croce Date: Thu Jul 2 16:12:43 2020 +0200 mvpp2: XDP TX support In source drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c in function mvp

Re: mvpp2: XDP TX support

2020-07-06 Thread Colin Ian King
On 06/07/2020 16:28, Matteo Croce wrote: > On Mon, 6 Jul 2020 14:59:22 +0100 > Colin Ian King wrote: > >> Hi, >> >> Static analysis with Coverity has found a potential issue in the >> following commit: >> >> commit c2d6fe6163de80d7f7cf400ee351f56d6cd

Re: [PATCH] sctp: remove redundant initialization of variable status

2020-07-24 Thread Colin Ian King
On 24/07/2020 13:55, Marcelo Ricardo Leitner wrote: > On Fri, Jul 24, 2020 at 01:17:53PM +0100, Colin King wrote: >> From: Colin Ian King >> >> The variable status is being initialized with a value that is never read >> and it is being updated later with a new va

re: Bluetooth: hci_qca: Add QCA Rome power off support to the qca_power_shutdown()

2020-07-10 Thread Colin Ian King
Hi, Static analysis with Coverity has found a potential issue in drivers/bluetooth/hci_qca.c, function qca_power_shutdown. The commit that triggered the detection of the issue was as follows: commit 5559904ccc0867a0ce796761681e40defe4a5f44 Author: Rocky Liao Date: Wed Jan 15 16:55:50 2020 +08

Re: [PATCH] crypto: xts: use memmove to avoid overlapped memory copy

2020-07-16 Thread Colin Ian King
On 16/07/2020 16:56, Ard Biesheuvel wrote: > On Thu, 16 Jul 2020 at 18:29, Colin King wrote: >> >> From: Colin Ian King >> >> There is a memcpy that performs a potential overlapped memory copy >> from source b to destination b + 1. Fix this by using the safer &g

Re: [PATCH -rc v1] gcov: Disable gcov build with GCC 10

2020-09-10 Thread Colin Ian King
gt;> As a workaround, let's disable GCOV build for broken GCC 10 version. >> >> [1] https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1891288 >> [2] https://lore.kernel.org/lkml/20200827133932.3338519-1-l...@kernel.org >> Cc: Colin Ian King >> Signed-off-by: L

Re: [PATCH][next] PCI: brcmstb: fix a missing if statement on a return error check

2020-09-21 Thread Colin Ian King
} > > Currently, our STB upstream suspend/resume is not functional yet and > this is how this omission slipped by testing. > > Thanks, > Jim Quinlan > Broadcom STB > > On Mon, Sep 21, 2020 at 3:43 PM Florian Fainelli wrote: >> >> On 9/21/20 7:40 AM, C

re: xfs: support inode btree blockcounts in online repair

2020-09-11 Thread Colin Ian King
Hi, Static analysis with Coverity has detected an issue with the following commit: commit 30deae31eab501f568aadea45cfb3258b9e522f5 Author: Darrick J. Wong Date: Wed Aug 26 10:48:50 2020 -0700 xfs: support inode btree blockcounts in online repair the analysis is as follows: 830

<    1   2   3   4   5   6   >