Re: [PATCH 4/6] usbip: fix stub_dev usbip_sockfd_store() races leading to gpf

2021-03-09 Thread Shuah Khan
On 3/9/21 4:40 PM, Tetsuo Handa wrote: On 2021/03/10 4:50, Shuah Khan wrote: On 3/9/21 4:04 AM, Tetsuo Handa wrote: On 2021/03/09 1:27, Shuah Khan wrote: Yes. We might need synchronization between events, threads, and shutdown in usbip_host side and in connection polling and threads in vhci

Re: [PATCH 4/6] usbip: fix stub_dev usbip_sockfd_store() races leading to gpf

2021-03-09 Thread Shuah Khan
On 3/9/21 4:04 AM, Tetsuo Handa wrote: On 2021/03/09 1:27, Shuah Khan wrote: Yes. We might need synchronization between events, threads, and shutdown in usbip_host side and in connection polling and threads in vhci. I am also looking at the shutdown sequences closely as well since the local

Re: [PATCH 4/6] usbip: fix stub_dev usbip_sockfd_store() races leading to gpf

2021-03-09 Thread Shuah Khan
On 3/8/21 9:27 AM, Shuah Khan wrote: On 3/8/21 3:10 AM, Tetsuo Handa wrote: On 2021/03/08 16:35, Tetsuo Handa wrote: On 2021/03/08 12:53, Shuah Khan wrote: Fix the above problems: - Stop using kthread_get_run() macro to create/start threads. - Create threads and get task struct reference

Re: [PATCH 4/6] usbip: fix stub_dev usbip_sockfd_store() races leading to gpf

2021-03-08 Thread Shuah Khan
On 3/8/21 3:10 AM, Tetsuo Handa wrote: On 2021/03/08 16:35, Tetsuo Handa wrote: On 2021/03/08 12:53, Shuah Khan wrote: Fix the above problems: - Stop using kthread_get_run() macro to create/start threads. - Create threads and get task struct reference. - Add kthread_create() failure handling

[PATCH 3/6] usbip: fix vudc to check for stream socket

2021-03-07 Thread Shuah Khan
Fix usbip_sockfd_store() to validate the passed in file descriptor is a stream socket. If the file descriptor passed was a SOCK_DGRAM socket, sock_recvmsg() can't detect end of stream. Cc: sta...@vger.kernel.org Suggested-by: Tetsuo Handa Signed-off-by: Shuah Khan --- drivers/usb/usbip

[PATCH 4/6] usbip: fix stub_dev usbip_sockfd_store() races leading to gpf

2021-03-07 Thread Shuah Khan
-by: syzbot Reported-by: syzbot Reported-by: Tetsuo Handa Fixes: 9720b4bc76a83807 ("staging/usbip: convert to kthread") Cc: sta...@vger.kernel.org Signed-off-by: Shuah Khan --- drivers/usb/usbip/stub_dev.c | 32 +--- 1 file changed, 25 insertions(+), 7 deletion

[PATCH 5/6] usbip: fix vhci_hcd attach_store() races leading to gpf

2021-03-07 Thread Shuah Khan
;) Cc: sta...@vger.kernel.org Signed-off-by: Shuah Khan --- drivers/usb/usbip/vhci_sysfs.c | 29 + 1 file changed, 25 insertions(+), 4 deletions(-) diff --git a/drivers/usb/usbip/vhci_sysfs.c b/drivers/usb/usbip/vhci_sysfs.c index 1e1ae9bd06ab..c4b4256e5dad 100644 --- a/d

[PATCH 1/6] usbip: fix stub_dev to check for stream socket

2021-03-07 Thread Shuah Khan
Fix usbip_sockfd_store() to validate the passed in file descriptor is a stream socket. If the file descriptor passed was a SOCK_DGRAM socket, sock_recvmsg() can't detect end of stream. Cc: sta...@vger.kernel.org Suggested-by: Tetsuo Handa Signed-off-by: Shuah Khan --- drivers/usb/usbip

[PATCH 2/6] usbip: fix vhci_hcd to check for stream socket

2021-03-07 Thread Shuah Khan
Fix attach_store() to validate the passed in file descriptor is a stream socket. If the file descriptor passed was a SOCK_DGRAM socket, sock_recvmsg() can't detect end of stream. Cc: sta...@vger.kernel.org Suggested-by: Tetsuo Handa Signed-off-by: Shuah Khan --- drivers/usb/usbip/vhci_sysfs.c

[PATCH 0/6] usbip fixes to crashes found by syzbot

2021-03-07 Thread Shuah Khan
path bug and starting threads before updating the local and shared state bug in the stub-up sequence. Shuah Khan (6): usbip: fix stub_dev to check for stream socket usbip: fix vhci_hcd to check for stream socket usbip: fix vudc to check for stream socket usbip: fix stub_dev

[PATCH 6/6] usbip: fix vudc usbip_sockfd_store races leading to gpf

2021-03-07 Thread Shuah Khan
-by: Tetsuo Handa Fixes: 9720b4bc76a83807 ("staging/usbip: convert to kthread") Cc: sta...@vger.kernel.org Signed-off-by: Shuah Khan --- drivers/usb/usbip/vudc_sysfs.c | 42 +++--- 1 file changed, 34 insertions(+), 8 deletions(-) diff --git a/drivers

[tip: locking/core] lockdep: Add lockdep_assert_not_held()

2021-03-06 Thread tip-bot2 for Shuah Khan
The following commit has been merged into the locking/core branch of tip: Commit-ID: 3e31f94752e454bdd0ca4a1d046ee21f80c166c5 Gitweb: https://git.kernel.org/tip/3e31f94752e454bdd0ca4a1d046ee21f80c166c5 Author:Shuah Khan AuthorDate:Fri, 26 Feb 2021 17:06:58 -07:00

[tip: locking/core] lockdep: Add lockdep lock state defines

2021-03-06 Thread tip-bot2 for Shuah Khan
The following commit has been merged into the locking/core branch of tip: Commit-ID: f8cfa46608f8aa5ca5421ce281ab314129c15411 Gitweb: https://git.kernel.org/tip/f8cfa46608f8aa5ca5421ce281ab314129c15411 Author:Shuah Khan AuthorDate:Fri, 26 Feb 2021 17:06:59 -07:00

[tip: locking/core] ath10k: Detect conf_mutex held ath10k_drain_tx() calls

2021-03-06 Thread tip-bot2 for Shuah Khan
The following commit has been merged into the locking/core branch of tip: Commit-ID: bdb1050ee1faaec1e78c15de8b1959176f26c655 Gitweb: https://git.kernel.org/tip/bdb1050ee1faaec1e78c15de8b1959176f26c655 Author:Shuah Khan AuthorDate:Fri, 26 Feb 2021 17:07:00 -07:00

Re: [PATCH v2] kunit: fix checkpatch warning

2021-03-04 Thread Shuah Khan
On 3/3/21 9:35 PM, Lucas Stankus wrote: On Wed, Mar 03, 2021 at 12:56:05PM -0800, Brendan Higgins wrote: Did you change anything other than fixing the Signed-off-by that Shuah requested? No, I only fixed the Signed-off-by warning. Generally when you make a small change after receiving

[tip: locking/core] lockdep: Add lockdep_assert_not_held()

2021-03-03 Thread tip-bot2 for Shuah Khan
The following commit has been merged into the locking/core branch of tip: Commit-ID: ac1cce36595238680c32c3f197e5aa18db6fa7a3 Gitweb: https://git.kernel.org/tip/ac1cce36595238680c32c3f197e5aa18db6fa7a3 Author:Shuah Khan AuthorDate:Fri, 26 Feb 2021 17:06:58 -07:00

[tip: locking/core] ath10k: Detect conf_mutex held ath10k_drain_tx() calls

2021-03-03 Thread tip-bot2 for Shuah Khan
The following commit has been merged into the locking/core branch of tip: Commit-ID: de469d82991b905548b5dc6539177f7b881dce1b Gitweb: https://git.kernel.org/tip/de469d82991b905548b5dc6539177f7b881dce1b Author:Shuah Khan AuthorDate:Fri, 26 Feb 2021 17:07:00 -07:00

[tip: locking/core] lockdep: Add lockdep lock state defines

2021-03-03 Thread tip-bot2 for Shuah Khan
The following commit has been merged into the locking/core branch of tip: Commit-ID: 298df9652725502bedf3593203721c03b75271f3 Gitweb: https://git.kernel.org/tip/298df9652725502bedf3593203721c03b75271f3 Author:Shuah Khan AuthorDate:Fri, 26 Feb 2021 17:06:59 -07:00

Re: [PATCH] selftests: gpio: update .gitignore

2021-03-02 Thread Shuah Khan
On 3/2/21 9:07 AM, Bartosz Golaszewski wrote: On Tue, Mar 2, 2021 at 4:27 PM Shuah Khan wrote: On 3/2/21 7:44 AM, Linus Walleij wrote: On Wed, Feb 24, 2021 at 7:53 PM Bartosz Golaszewski wrote: From: Bartosz Golaszewski The executable that we build for GPIO selftests was renamed to gpio

Re: [PATCH] selftests: gpio: update .gitignore

2021-03-02 Thread Shuah Khan
: 8bc395a6a2e2 ("selftests: gpio: rework and simplify test implementation") Signed-off-by: Bartosz Golaszewski Reviewed-by: Linus Walleij Yours, Linus Walleij Thank you. I will queue this up. thanks, -- Shuah

Re: [PATCH] kunit: fix checkpatch warning

2021-03-01 Thread Shuah Khan
-by: Brendan Higgins Thanks! Hi Lucas, Please fix your Signed-off-by and resend this patch: WARNING: From:/Signed-off-by: email name mismatch: 'From: Lucas Pires Stankus ' != 'Signed-off-by: Lucas Stankus ' thanks, -- Shuah

Re: [PATCH 4.4 00/93] 4.4.259-rc1 review

2021-03-01 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.4.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 4.19 000/247] 4.19.178-rc1 review

2021-03-01 Thread Shuah Khan
/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.19.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 4.9 000/134] 4.9.259-rc1 review

2021-03-01 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.9.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.10 000/661] 5.10.20-rc2 review

2021-03-01 Thread Shuah Khan
/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.10.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.11 000/774] 5.11.3-rc2 review

2021-03-01 Thread Shuah Khan
On 3/1/21 2:23 PM, Shuah Khan wrote: On 3/1/21 12:38 PM, Greg Kroah-Hartman wrote: This is the start of the stable review cycle for the 5.11.3 release. There are 774 patches in this series, all will be posted as a response to this one.  If anyone has any issues with these being applied, please

Re: [PATCH 5.11 000/774] 5.11.3-rc2 review

2021-03-01 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.11.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. thanks, -- Shuah

Re: [PATCH v3 0/3] Add lockdep_assert_not_held()

2021-03-01 Thread Shuah Khan
On 3/1/21 4:02 AM, Kalle Valo wrote: Peter Zijlstra writes: On Mon, Mar 01, 2021 at 10:45:32AM +0200, Kalle Valo wrote: Peter Zijlstra writes: On Fri, Feb 26, 2021 at 05:06:57PM -0700, Shuah Khan wrote: Shuah Khan (3): lockdep: add lockdep_assert_not_held() lockdep: add lockdep

[PATCH v3 1/3] lockdep: add lockdep_assert_not_held()

2021-02-26 Thread Shuah Khan
lockdep_assert_not_held(). Link: https://lore.kernel.org/lkml/37a29c383bff2fb1605241ee6c7c9be3784fb3c6.1613171185.git.sk...@linuxfoundation.org/ Link: https://lore.kernel.org/linux-wireless/871rdmu9z9@codeaurora.org/ Signed-off-by: Shuah Khan --- include/linux/lockdep.h | 11 --- kernel

[PATCH v3 3/3] ath10k: detect conf_mutex held ath10k_drain_tx() calls

2021-02-26 Thread Shuah Khan
://lore.kernel.org/lkml/37a29c383bff2fb1605241ee6c7c9be3784fb3c6.1613171185.git.sk...@linuxfoundation.org/ Link: https://lore.kernel.org/linux-wireless/871rdmu9z9@codeaurora.org/ Acked-by: Kalle Valo Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath10k/mac.c | 2 ++ 1 file changed, 2 insertions

[PATCH v3 2/3] lockdep: add lockdep lock state defines

2021-02-26 Thread Shuah Khan
() and __lock_is_held() to use the new defines. Link: https://lore.kernel.org/lkml/37a29c383bff2fb1605241ee6c7c9be3784fb3c6.1613171185.git.sk...@linuxfoundation.org/ Link: https://lore.kernel.org/linux-wireless/871rdmu9z9@codeaurora.org/ Signed-off-by: Shuah Khan --- include/linux/lockdep.h | 11

[PATCH v3 0/3] Add lockdep_assert_not_held()

2021-02-26 Thread Shuah Khan
new interface in ath10k_drain_tx() function. Added Kalle Valo's Ack from v1 for this change. Tested on the mainline from yesterday. Shuah Khan (3): lockdep: add lockdep_assert_not_held() lockdep: add lockdep lock state defines ath10k: detect conf_mutex held ath10k_drain_tx() calls drivers

Re: [PATCH] iommu/amd: Fix event counter availability check

2021-02-26 Thread Shuah Khan
On 2/26/21 2:44 PM, Paul Menzel wrote: [cc: +suravee, +jörg] Dear Alex, dear Shuah, dear Suravee, dear Jörg, Am 03.06.20 um 08:54 schrieb Alexander Monakov: On Tue, 2 Jun 2020, Shuah Khan wrote: I changed the logic to read config to get max banks and counters before checking if counters

Re: [PATCH v2 1/3] lockdep: add lockdep_assert_not_held()

2021-02-26 Thread Shuah Khan
On 2/26/21 2:07 PM, Peter Zijlstra wrote: On Fri, Feb 26, 2021 at 10:52:13AM -0700, Shuah Khan wrote: + /* avoid false negative lockdep_assert_not_held() +* and lockdep_assert_held() +*/ That's a coding style fail. Checkpatch didn't complain

Re: [PATCH v2 2/3] lockdep: add lockdep lock state defines

2021-02-26 Thread Shuah Khan
. thanks, -- Shuah

Re: [PATCH 5/5] ath10k: reduce invalid ht params rate message noise

2021-02-26 Thread Shuah Khan
On 2/11/21 4:24 AM, Kalle Valo wrote: Shuah Khan writes: On 2/10/21 1:28 AM, Kalle Valo wrote: Wen Gong writes: On 2021-02-10 08:42, Shuah Khan wrote: ath10k_mac_get_rate_flags_ht() floods dmesg with the following messages, when it fails to find a match for mcs=7 and rate=1440

[PATCH v2 2/3] lockdep: add lockdep lock state defines

2021-02-26 Thread Shuah Khan
/37a29c383bff2fb1605241ee6c7c9be3784fb3c6.1613171185.git.sk...@linuxfoundation.org/ Link: https://lore.kernel.org/linux-wireless/871rdmu9z9@codeaurora.org/ Signed-off-by: Shuah Khan --- include/linux/lockdep.h | 11 +-- kernel/locking/lockdep.c | 3 ++- 2 files changed, 11 insertions

[PATCH v2 3/3] ath10k: detect conf_mutex held ath10k_drain_tx() calls

2021-02-26 Thread Shuah Khan
://lore.kernel.org/lkml/37a29c383bff2fb1605241ee6c7c9be3784fb3c6.1613171185.git.sk...@linuxfoundation.org/ Link: https://lore.kernel.org/linux-wireless/871rdmu9z9@codeaurora.org/ Acked-by: Kalle Valo Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath10k/mac.c | 2 ++ 1 file changed, 2 insertions

[PATCH v2 1/3] lockdep: add lockdep_assert_not_held()

2021-02-26 Thread Shuah Khan
lockdep_assert_not_held(). Link: https://lore.kernel.org/lkml/37a29c383bff2fb1605241ee6c7c9be3784fb3c6.1613171185.git.sk...@linuxfoundation.org/ Link: https://lore.kernel.org/linux-wireless/871rdmu9z9@codeaurora.org/ Signed-off-by: Shuah Khan --- include/linux/lockdep.h | 11 --- kernel

[PATCH v2 0/3] Add lockdep_assert_not_held()

2021-02-26 Thread Shuah Khan
rday. Shuah Khan (3): lockdep: add lockdep_assert_not_held() lockdep: add lockdep lock state defines ath10k: detect conf_mutex held ath10k_drain_tx() calls drivers/net/wireless/ath/ath10k/mac.c | 2 ++ include/linux/lockdep.h | 18 +++--- kernel/locking/lockd

Re: [PATCH 5.4 00/17] 5.4.101-rc1 review

2021-02-25 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.4.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.11 00/12] 5.11.2-rc1 review

2021-02-25 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.11.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.10 00/23] 5.10.19-rc1 review

2021-02-25 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.10.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.11 00/12] 5.11.1-rc1 review

2021-02-23 Thread Shuah Khan
On 2/23/21 2:05 PM, Shuah Khan wrote: On 2/22/21 5:12 AM, Greg Kroah-Hartman wrote: This is the start of the stable review cycle for the 5.11.1 release. There are 12 patches in this series, all will be posted as a response to this one.  If anyone has any issues with these being applied, please

Re: [PATCH 4.4 00/35] 4.4.258-rc1 review

2021-02-23 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.4.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 4.9 00/49] 4.9.258-rc1 review

2021-02-23 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.9.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 4.19 00/50] 4.19.177-rc1 review

2021-02-23 Thread Shuah Khan
/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.19.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.4 00/13] 5.4.100-rc1 review

2021-02-23 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.4.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.10 00/29] 5.10.18-rc1 review

2021-02-23 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.10.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.11 00/12] 5.11.1-rc1 review

2021-02-23 Thread Shuah Khan
I narrowed it down to the following as a possible lead to start looking: amdgpu :0b:00.0: [drm] Cannot find any crtc or sizes Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 1/2] lockdep: add lockdep_assert_not_held()

2021-02-22 Thread Shuah Khan
k you both. Picking this back up. Will send v2 incorporating your comments and suggestions. thanks, -- Shuah

Re: [PATCH 00/20] Manual replacement of all strlcpy in favor of strscpy

2021-02-22 Thread Shuah Khan
that is in the plan to address as part of this work? thanks, -- Shuah

Re: [PATCH 19/20] usbip: usbip_host: Manual replacement of the deprecated strlcpy() with return values

2021-02-22 Thread Shuah Khan
-E2BIG) return -EINVAL; if (!strncmp(buf, "add ", 4)) { Looks good to me. Thank you. Acked-by: Shuah Khan thanks, -- Shuah

Re: [PATCH] Revert "ath9k: fix ath_tx_process_buffer() potential null ptr dereference"

2021-02-18 Thread Shuah Khan
On 2/17/21 11:23 PM, Kalle Valo wrote: Shuah Khan wrote: This reverts commit a56c14bb21b296fb6d395164ab62ef2e419e5069. ath_tx_process_buffer() doesn't dereference or check sta and passes it to ath_tx_complete_aggr() and ath_tx_complete_buf(). ath_tx_complete_aggr() checks the pointer before

[GIT PULL] KUnit update for Linux 5.12-rc1

2021-02-17 Thread Shuah Khan
el Latypov. diff is attached. thanks, -- Shuah The following changes since commit 92bf22614b21a2706f4993b278017e437f7785b3: Linux 5.11-rc7 (2021-02-07 13:57:38 -0800) are available in the Git repository at: git://git.kernel.o

[GIT PULL] Kselftest update for Linux 5.12-rc1

2021-02-17 Thread Shuah Khan
tests. - Minor code cleanups to ipc and x86 tests. diff is attached. thanks, -- Shuah The following changes since commit 92bf22614b21a2706f4993b278017e437f7785b3: Linux 5.11-rc7 (2021-02-07 13:57:38 -0800) are available in the Git

Re: [PATCH 5.10 00/54] 5.10.16-rc1 review

2021-02-17 Thread Shuah Khan
On 2/13/21 5:58 AM, Greg Kroah-Hartman wrote: On Fri, Feb 12, 2021 at 09:17:13AM -0700, Shuah Khan wrote: On 2/11/21 8:01 AM, Greg Kroah-Hartman wrote: This is the start of the stable review cycle for the 5.10.16 release. There are 54 patches in this series, all will be posted as a response

[PATCH] Revert "ath9k: fix ath_tx_process_buffer() potential null ptr dereference"

2021-02-17 Thread Shuah Khan
letion if the pointer (sta) is NULL. Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath9k/xmit.c | 28 --- 1 file changed, 12 insertions(+), 16 deletions(-) diff --git a/drivers/net/wireless/ath/ath9k/xmit.c b/drivers/net/wireless/ath/ath9k/xmit.c index 735858

Re: [PATCH 2/2] ath9k: fix ath_tx_process_buffer() potential null ptr dereference

2021-02-17 Thread Shuah Khan
On 2/17/21 7:56 AM, Shuah Khan wrote: On 2/17/21 12:30 AM, Kalle Valo wrote: Shuah Khan writes: On 2/16/21 12:53 AM, Felix Fietkau wrote: On 2021-02-16 08:03, Kalle Valo wrote: Shuah Khan wrote: ath_tx_process_buffer() references ieee80211_find_sta_by_ifaddr() return pointer (sta

Re: [PATCH 2/2] ath9k: fix ath_tx_process_buffer() potential null ptr dereference

2021-02-17 Thread Shuah Khan
On 2/17/21 12:30 AM, Kalle Valo wrote: Shuah Khan writes: On 2/16/21 12:53 AM, Felix Fietkau wrote: On 2021-02-16 08:03, Kalle Valo wrote: Shuah Khan wrote: ath_tx_process_buffer() references ieee80211_find_sta_by_ifaddr() return pointer (sta) outside null check. Fix it by moving

Re: [PATCH 5.4 00/60] 5.4.99-rc1 review

2021-02-16 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.4.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.10 000/104] 5.10.17-rc1 review

2021-02-16 Thread Shuah Khan
/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.10.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 2/2] ath9k: fix ath_tx_process_buffer() potential null ptr dereference

2021-02-16 Thread Shuah Khan
On 2/16/21 12:53 AM, Felix Fietkau wrote: On 2021-02-16 08:03, Kalle Valo wrote: Shuah Khan wrote: ath_tx_process_buffer() references ieee80211_find_sta_by_ifaddr() return pointer (sta) outside null check. Fix it by moving the code block under the null check. This problem was found while

[PATCH 2/2] ath10k: detect conf_mutex held ath10k_drain_tx() calls

2021-02-12 Thread Shuah Khan
://lore.kernel.org/linux-wireless/871rdmu9z9@codeaurora.org/ Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath10k/mac.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c index c202b167d8c6..7de05b679ad2 100644

[PATCH 1/2] lockdep: add lockdep_assert_not_held()

2021-02-12 Thread Shuah Khan
for lockdep_assert_not_held() came up in a discussion on ath10k patch. ath10k_drain_tx() and i915_vma_pin_ww() are examples of functions that can use lockdep_assert_not_held(). Link: https://lore.kernel.org/linux-wireless/871rdmu9z9@codeaurora.org/ Signed-off-by: Shuah Khan --- include/linux/lockdep.h | 7

[PATCH 0/2] Add lockdep_assert_not_held()

2021-02-12 Thread Shuah Khan
it in the second patch in ath10k_drain_tx() function. Shuah Khan (2): lockdep: add lockdep_assert_not_held() ath10k: detect conf_mutex held ath10k_drain_tx() calls drivers/net/wireless/ath/ath10k/mac.c | 2 ++ include/linux/lockdep.h | 7 ++- 2 files changed, 8 insertions(+), 1

Re: general protection fault in tomoyo_socket_sendmsg_permission

2021-02-12 Thread Shuah Khan
On 2/11/21 9:58 PM, Tetsuo Handa wrote: On 2021/02/12 11:22, Tetsuo Handa wrote: On 2021/02/12 10:34, Shuah Khan wrote: On 2/10/21 6:14 PM, Tetsuo Handa wrote: (Dropping LSM ML because this is not a TOMOYO's bug.) On 2021/02/11 4:29, Shuah Khan wrote: This is a good find. I already replied

Re: [PATCH 4.19 00/27] 4.19.176-rc2 review

2021-02-12 Thread Shuah Khan
/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.19.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH] mt76: hold RCU lock when calling ieee80211_find_sta_by_ifaddr()

2021-02-12 Thread Shuah Khan
On 2/11/21 10:36 PM, Felix Fietkau wrote: On 2021-02-12 03:13, Shuah Khan wrote: ieee80211_find_sta_by_ifaddr() must be called under the RCU lock and the resulting pointer is only valid under RCU lock as well. Fix mt76_check_sta() to hold RCU read lock before it calls

Re: [PATCH 4.19 00/24] 4.19.176-rc1 review

2021-02-12 Thread Shuah Khan
/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.19.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.4 00/24] 5.4.98-rc1 review

2021-02-12 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.4.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 5.10 00/54] 5.10.16-rc1 review

2021-02-12 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.10.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan Note: gdm doesn't start and no response to keyboard and mouse. I can ssh in and use

[PATCH 2/2] ath9k: fix ath_tx_process_buffer() potential null ptr dereference

2021-02-11 Thread Shuah Khan
of other callers of ieee80211_find_sta_by_ifaddr() that don't hold RCU read lock. Signed-off-by: Shuah Khan --- - Note: This patch is compile tested. I don't have access to hardware. drivers/net/wireless/ath/ath9k/xmit.c | 28 +++ 1 file changed, 16 insertions(+), 12

[PATCH] rtw88: hold RCU lock when calling ieee80211_find_sta_by_ifaddr()

2021-02-11 Thread Shuah Khan
. This problem was found while reviewing code to debug RCU warn from ath10k_wmi_tlv_parse_peer_stats_info() and a subsequent manual audit of other callers of ieee80211_find_sta_by_ifaddr() that don't hold RCU read lock. Signed-off-by: Shuah Khan --- - Note: This patch is compile tested. I don't have

[PATCH 1/2] ath9k: hold RCU lock when calling ieee80211_find_sta_by_ifaddr()

2021-02-11 Thread Shuah Khan
. This problem was found while reviewing code to debug RCU warn from ath10k_wmi_tlv_parse_peer_stats_info() and a subsequent manual audit of other callers of ieee80211_find_sta_by_ifaddr() that don't hold RCU read lock. Signed-off-by: Shuah Khan --- - Note: This patch is compile tested. I don't have access

[PATCH] mt76: hold RCU lock when calling ieee80211_find_sta_by_ifaddr()

2021-02-11 Thread Shuah Khan
was found while reviewing code to debug RCU warn from ath10k_wmi_tlv_parse_peer_stats_info() and a subsequent manual audit of other callers of ieee80211_find_sta_by_ifaddr() that don't hold RCU read lock. Signed-off-by: Shuah Khan --- - Note: This patch is compile tested. I don't have access

Re: general protection fault in tomoyo_socket_sendmsg_permission

2021-02-11 Thread Shuah Khan
On 2/10/21 6:14 PM, Tetsuo Handa wrote: (Dropping LSM ML because this is not a TOMOYO's bug.) On 2021/02/11 4:29, Shuah Khan wrote: This is a good find. I already replied to the thread to send a complete fix. As I said at https://lkml.kernel.org/r/f8cae6b1-8f84-0e6a-7d9c-fc4aec68f...@i

Re: [PATCH 4/5] ath10k: detect conf_mutex held ath10k_drain_tx() calls

2021-02-11 Thread Shuah Khan
On 2/11/21 4:20 AM, Kalle Valo wrote: Shuah Khan writes: On 2/10/21 1:25 AM, Kalle Valo wrote: Shuah Khan writes: ath10k_drain_tx() must not be called with conf_mutex held as workers can use that also. Add check to detect conf_mutex held calls. Signed-off-by: Shuah Khan The commit log

[PATCH v2] ath10k: hold RCU lock when calling ieee80211_find_sta_by_ifaddr()

2021-02-10 Thread Shuah Khan
needed. This problem was found while reviewing code to debug RCU warn from ath10k_wmi_tlv_parse_peer_stats_info(). Link: https://lore.kernel.org/linux-wireless/7230c9e5-2632-b77e-c4f9-10eca557a...@linuxfoundation.org/ Signed-off-by: Shuah Khan --- Changes since v1: - v1 also included fix

Re: general protection fault in tomoyo_socket_sendmsg_permission

2021-02-10 Thread Shuah Khan
On 2/10/21 12:07 PM, Tetsuo Handa wrote: On 2021/02/11 3:17, Shuah Khan wrote: I am looking to understand the syzbot configuration and a reproducer to be able to debug and fix the problem. How is syzbot triggering the vhci_hcd attach and detach sequence? I don't know. I'm waiting for syzbot

Re: general protection fault in tomoyo_socket_sendmsg_permission

2021-02-10 Thread Shuah Khan
On 1/29/21 7:25 PM, Tetsuo Handa wrote: On 2021/01/30 6:18, Shuah Khan wrote: In this console log: It seems "this console log" refers to https://syzkaller.appspot.com/x/log.txt?x=1045303450 . 06:57:50 executing program 1: socketpair$tipc(0x1e, 0x2, 0x0, &(

Re: [PATCH 2/5] ath10k: fix WARNING: suspicious RCU usage

2021-02-10 Thread Shuah Khan
On 2/10/21 1:13 AM, Kalle Valo wrote: Shuah Khan wrote: ieee80211_find_sta_by_ifaddr() must be called under the RCU lock and the resulting pointer is only valid under RCU lock as well. Fix ath10k_wmi_tlv_parse_peer_stats_info() to hold RCU lock before it calls ieee80211_find_sta_by_ifaddr

Re: [PATCH 1/5] ath10k: fix conf_mutex lock assert in ath10k_debug_fw_stats_request()

2021-02-10 Thread Shuah Khan
On 2/10/21 1:09 AM, Kalle Valo wrote: Shuah Khan wrote: ath10k_debug_fw_stats_request() is called ath10k_sta_statistics() without holding conf_mutex. ath10k_debug_fw_stats_request() simply returns when CONFIG_ATH10K_DEBUGFS is disabled. When CONFIG_ATH10K_DEBUGFS is enabled

Re: [PATCH 5/5] ath10k: reduce invalid ht params rate message noise

2021-02-10 Thread Shuah Khan
On 2/10/21 1:28 AM, Kalle Valo wrote: Wen Gong writes: On 2021-02-10 08:42, Shuah Khan wrote: ath10k_mac_get_rate_flags_ht() floods dmesg with the following messages, when it fails to find a match for mcs=7 and rate=1440. supported_ht_mcs_rate_nss2: {7, {1300, 2700, 1444, 3000

Re: [PATCH 4/5] ath10k: detect conf_mutex held ath10k_drain_tx() calls

2021-02-10 Thread Shuah Khan
On 2/10/21 1:25 AM, Kalle Valo wrote: Shuah Khan writes: ath10k_drain_tx() must not be called with conf_mutex held as workers can use that also. Add check to detect conf_mutex held calls. Signed-off-by: Shuah Khan The commit log does not answer to "Why?". How did you find

[PATCH 5/5] ath10k: reduce invalid ht params rate message noise

2021-02-09 Thread Shuah Khan
helping the noise. Use dev_warn_once() instead. Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath10k/mac.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/ath/ath10k/mac.c b/drivers/net/wireless/ath/ath10k/mac.c index 3545ce7dce0a..276321f0cfdd

[PATCH 4/5] ath10k: detect conf_mutex held ath10k_drain_tx() calls

2021-02-09 Thread Shuah Khan
ath10k_drain_tx() must not be called with conf_mutex held as workers can use that also. Add check to detect conf_mutex held calls. Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath10k/mac.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/wireless/ath/ath10k/mac.c b

[PATCH 3/5] ath10k: change ath10k_offchan_tx_work() peer present msg to a warn

2021-02-09 Thread Shuah Khan
Based on the comment block in this function and the FIXME for this, peer being present for the offchannel tx is unlikely. Peer is deleted once tx is complete. Change peer present msg to a warn to detect this condition. Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath10k/mac.c | 5

[PATCH 2/5] ath10k: fix WARNING: suspicious RCU usage

2021-02-09 Thread Shuah Khan
+0x22/0x30 Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath10k/wmi-tlv.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/drivers/net/wireless/ath/ath10k/wmi-tlv.c b/drivers/net/wireless/ath/ath10k/wmi-tlv.c index 7b5834157fe5..615157dd6866 100644

[PATCH 1/5] ath10k: fix conf_mutex lock assert in ath10k_debug_fw_stats_request()

2021-02-09 Thread Shuah Khan
d at (520903): [] console_unlock+0x4e5/0x5d0 hardirqs last disabled at (520908): [] console_unlock+0x458/0x5d0 softirqs last enabled at (520722): [] asm_call_irq_on_stack+0x12/0x20 softirqs last disabled at (520717): [] asm_call_irq_on_stack+0x12/0x20 Signed-off-by: Shuah Khan --- drivers/net/wireless/ath/ath1

[PATCH 0/5] ath10k fixes for warns

2021-02-09 Thread Shuah Khan
and RCU usage bugs. The last patch (5/5) is a fix to reduce invalid ht params rate message noise. Patch 3/4 changes a message from debug to warn. Patch 4 adds detect to assert not calling ath10k_drain_tx() holding conf_mutex. Shuah Khan (5): ath10k: fix conf_mutex lock assert

Re: [PATCH] selftests/timens: add futex binary to .gitignore

2021-02-08 Thread Shuah Khan
_nanosleep exec +futex gettime_perf gettime_perf_cold procfs Thank you. Applied to linux-kselftest next for 5.12-rc1 thanks, -- Shuah

Re: [PATCH v4 1/5] selftests/x86: Use getauxval() to simplify the code in sgx

2021-02-08 Thread Shuah Khan
Sakkinen This needs also ack from Shuah. Looks good to me. Thank you. Acked-by: Shuah Khan thanks, -- Shuah

Re: [PATCH] selftests: breakpoints: Use correct error messages in breakpoint_test_arm64.c

2021-02-08 Thread Shuah Khan
ksft_print_msg("child exited prematurely\n"); return false; } if (!WIFSTOPPED(status)) { Thank you. Applied to linux-kselftest next for 5.12-rc1 thanks, -- Shuah

Re: [PATCH] selftests/vDSO: fix ABI selftest on riscv

2021-02-08 Thread Shuah Khan
tree, so I'm leaving it out for now and assuming it'll go through a kselftest tree. Either way is fine for me. Thank you. Applied to linux-kselftest next for 5.12-rc1 thanks, -- Shuah

Re: [PATCH] selftests/x86/ldt_gdt: remove unneeded semicolon

2021-02-08 Thread Shuah Khan
++; asm volatile ("mov %0, %%ss" : : "rm" (orig_ss)); - }; + } ftx = 100; /* Kill the thread. */ syscall(SYS_futex, , FUTEX_WAKE, 0, NULL, NULL, 0); Thank you. Now applied to linux-kselftest next for 5.12-rc1 thanks, -- Shuah

Re: [PATCH] selftests/ipc: remove unneeded semicolon

2021-02-08 Thread Shuah Khan
return 0; } Thank you. Now applied to linux-kselftest next for 5.12-rc1 thanks, -- Shuah

Re: [PATCH 1/5] kselftests: dmabuf-heaps: Fix Makefile's inclusion of the kernel's usr/include dir

2021-02-08 Thread Shuah Khan
then causes the _IOCW macros to give the wrong ioctl numbers, specifically for DMA_BUF_IOCTL_SYNC. This patch simply removes the extra include from the Makefile Cc: Shuah Khan Cc: Brian Starkey Cc: Sumit Semwal Cc: Laura Abbott Cc: Hridya Valsaraju Cc: Suren Baghdasaryan Cc: Sandeep Patil

Re: [PATCH 4.4 00/38] 4.4.257-rc1 review

2021-02-08 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.4.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

Re: [PATCH 4.9 00/43] 4.9.257-rc1 review

2021-02-08 Thread Shuah Khan
/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.9.y and the diffstat can be found below. thanks, greg k-h Compiled and booted on my test system. No dmesg regressions. Tested-by: Shuah Khan thanks, -- Shuah

<    1   2   3   4   5   6   7   8   9   10   >