From 23979f13aaf24db373f89e266424e4ac177a539e Mon Sep 17 00:00:00 2001 From: Sasha Levin Date: Sat, 2 Nov 2024 07:11:44 -0400 Subject: [PATCH] Fixes for 5.4 Signed-off-by: Sasha Levin --- ...st-remove-unneeded-variable-in-st_tt.patch | 46 +++++++++++++++++++ ...i-fix-the-input-parameter-of-cpuhp_r.patch | 38 +++++++++++++++ queue-5.4/series | 2 + 3 files changed, 86 insertions(+) create mode 100644 queue-5.4/drivers-misc-ti-st-remove-unneeded-variable-in-st_tt.patch create mode 100644 queue-5.4/firmware-arm_sdei-fix-the-input-parameter-of-cpuhp_r.patch diff --git a/queue-5.4/drivers-misc-ti-st-remove-unneeded-variable-in-st_tt.patch b/queue-5.4/drivers-misc-ti-st-remove-unneeded-variable-in-st_tt.patch new file mode 100644 index 00000000000..fde1a999177 --- /dev/null +++ b/queue-5.4/drivers-misc-ti-st-remove-unneeded-variable-in-st_tt.patch @@ -0,0 +1,46 @@ +From 16e91807bed1a008e132d5456de0aba5a0387ab9 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Fri, 13 Sep 2019 00:52:27 +0800 +Subject: drivers/misc: ti-st: Remove unneeded variable in st_tty_open + +From: zhong jiang + +[ Upstream commit 8b063441b7417a79b0c27efc401479748ccf8ad1 ] + +st_tty_open do not need local variable to store different value, +Hence just remove it. + +Signed-off-by: zhong jiang +Link: https://lore.kernel.org/r/1568307147-43468-1-git-send-email-zhongjiang@huawei.com +Signed-off-by: Greg Kroah-Hartman +Stable-dep-of: c83212d79be2 ("firmware: arm_sdei: Fix the input parameter of cpuhp_remove_state()") +Signed-off-by: Sasha Levin +--- + drivers/misc/ti-st/st_core.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/drivers/misc/ti-st/st_core.c b/drivers/misc/ti-st/st_core.c +index c19460e7f0f16..7a7a1ac81ad02 100644 +--- a/drivers/misc/ti-st/st_core.c ++++ b/drivers/misc/ti-st/st_core.c +@@ -709,7 +709,6 @@ EXPORT_SYMBOL_GPL(st_unregister); + */ + static int st_tty_open(struct tty_struct *tty) + { +- int err = 0; + struct st_data_s *st_gdata; + pr_info("%s ", __func__); + +@@ -732,7 +731,8 @@ static int st_tty_open(struct tty_struct *tty) + */ + st_kim_complete(st_gdata->kim_data); + pr_debug("done %s", __func__); +- return err; ++ ++ return 0; + } + + static void st_tty_close(struct tty_struct *tty) +-- +2.43.0 + diff --git a/queue-5.4/firmware-arm_sdei-fix-the-input-parameter-of-cpuhp_r.patch b/queue-5.4/firmware-arm_sdei-fix-the-input-parameter-of-cpuhp_r.patch new file mode 100644 index 00000000000..a3a65ffe807 --- /dev/null +++ b/queue-5.4/firmware-arm_sdei-fix-the-input-parameter-of-cpuhp_r.patch @@ -0,0 +1,38 @@ +From 86e9c484caf9e9a03bb9d3df16f9daedb650e025 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Wed, 16 Oct 2024 16:47:40 +0800 +Subject: firmware: arm_sdei: Fix the input parameter of cpuhp_remove_state() + +From: Xiongfeng Wang + +[ Upstream commit c83212d79be2c9886d3e6039759ecd388fd5fed1 ] + +In sdei_device_freeze(), the input parameter of cpuhp_remove_state() is +passed as 'sdei_entry_point' by mistake. Change it to 'sdei_hp_state'. + +Fixes: d2c48b2387eb ("firmware: arm_sdei: Fix sleep from invalid context BUG") +Signed-off-by: Xiongfeng Wang +Reviewed-by: James Morse +Link: https://lore.kernel.org/r/20241016084740.183353-1-wangxiongfeng2@huawei.com +Signed-off-by: Will Deacon +Signed-off-by: Sasha Levin +--- + drivers/firmware/arm_sdei.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/firmware/arm_sdei.c b/drivers/firmware/arm_sdei.c +index b0e8752174c6f..f6627ccbc2d81 100644 +--- a/drivers/firmware/arm_sdei.c ++++ b/drivers/firmware/arm_sdei.c +@@ -802,7 +802,7 @@ static int sdei_device_freeze(struct device *dev) + int err; + + /* unregister private events */ +- cpuhp_remove_state(sdei_entry_point); ++ cpuhp_remove_state(sdei_hp_state); + + err = sdei_unregister_shared(); + if (err) +-- +2.43.0 + diff --git a/queue-5.4/series b/queue-5.4/series index 486d476b649..987941eb339 100644 --- a/queue-5.4/series +++ b/queue-5.4/series @@ -439,3 +439,5 @@ bpf-fix-out-of-bounds-write-in-trie_get_next_key.patch net-support-ip-generic-csum-processing-in-skb_csum_h.patch net-skip-offload-for-netif_f_ipv6_csum-if-ipv6-heade.patch netfilter-nft_payload-sanitize-offset-and-length-bef.patch +drivers-misc-ti-st-remove-unneeded-variable-in-st_tt.patch +firmware-arm_sdei-fix-the-input-parameter-of-cpuhp_r.patch -- 2.47.2