Re: [linux-yocto]: [kernel v5.4/standard/bcm-2xxx-rpi]: bcm-2xxx-rpi: upgrade patches for raspberrypi 4b platform

2020-11-19 Thread Bruce Ashfield
In message: [linux-yocto]: [kernel v5.4/standard/bcm-2xxx-rpi]: bcm-2xxx-rpi: 
upgrade patches for raspberrypi 4b platform
on 18/11/2020 meng...@windriver.com wrote:

> From: Limeng 
> 
> Hi Bruce,
> 
> There are some new patches merged into upstream raspberrypi sdk kernel, 
> branch rpi-5.4.y.
> So, I get the latest patches from raspberry pi git repo 
> https://github.com/raspberrypi/linux.git rpi-5.4.y,
> and intend to merge them into linux-yocto, branch v5.4/standard/bcm-2xxx-rpi.
> 
> Could you please help merge these patches into linux-ycoto kernel, branch is 
> v5.4/standard/bcm-2xxx-rpi?
> The 88 patches are in my public repo 
> https://github.com/limeng-linux/linux-yocto-5.4.git, branch 
> v5.4/standard/bcm-2xxx-rpi

Merged.

I also put this on the preempt-rt variant of the BSP. Let me know if that's a
problem!

Bruce

> 
> 
> diffstat info as below.
> 
>  /drivers/net/can/spi/mcp25xxfd/Makefile| 
>8 
>  arch/arm/boot/dts/overlays/sdtweak-overlay.dts | 
>   25 
>  b/Documentation/devicetree/bindings/net/can/microchip,mcp251xfd.yaml   | 
>8 
>  b/Documentation/devicetree/bindings/net/can/microchip,mcp25xxfd.yaml   | 
>   87 
>  b/arch/arm/boot/dts/Makefile   | 
>3 
>  b/arch/arm/boot/dts/bcm2708-rpi-zero-w.dts | 
>3 
>  b/arch/arm/boot/dts/bcm2708-rpi-zero.dts   | 
>3 
>  b/arch/arm/boot/dts/bcm270x.dtsi   | 
>2 
>  b/arch/arm/boot/dts/bcm2710-rpi-3-b-plus.dts   | 
>2 
>  b/arch/arm/boot/dts/bcm2710-rpi-3-b.dts| 
>2 
>  b/arch/arm/boot/dts/bcm2711-rpi-4-b.dts| 
>   22 
>  b/arch/arm/boot/dts/bcm2711-rpi-400.dts| 
>  587 +
>  b/arch/arm/boot/dts/bcm2711-rpi-cm4.dts| 
>3 
>  b/arch/arm/boot/dts/bcm2711-rpi.dtsi   | 
>7 
>  b/arch/arm/boot/dts/overlays/Makefile  | 
>6 
>  b/arch/arm/boot/dts/overlays/README| 
>  151 
>  b/arch/arm/boot/dts/overlays/adafruit18-overlay.dts| 
>   12 
>  b/arch/arm/boot/dts/overlays/allo-boss2-dac-audio-overlay.dts  | 
>   57 
>  b/arch/arm/boot/dts/overlays/allo-piano-dac-plus-pcm512x-audio-overlay.dts | 
>2 
>  b/arch/arm/boot/dts/overlays/audremap-overlay.dts  | 
>7 
>  b/arch/arm/boot/dts/overlays/cma-overlay.dts   | 
>4 
>  b/arch/arm/boot/dts/overlays/fsm-demo-overlay.dts  | 
>  104 
>  b/arch/arm/boot/dts/overlays/ghost-amp-overlay.dts | 
>  119 
>  b/arch/arm/boot/dts/overlays/goodix-overlay.dts| 
>2 
>  b/arch/arm/boot/dts/overlays/hy28a-overlay.dts | 
>2 
>  b/arch/arm/boot/dts/overlays/hy28b-2017-overlay.dts| 
>2 
>  b/arch/arm/boot/dts/overlays/hy28b-overlay.dts | 
>2 
>  b/arch/arm/boot/dts/overlays/i2c-rtc-overlay.dts   | 
>   16 
>  b/arch/arm/boot/dts/overlays/mcp251xfd-overlay.dts | 
>  226 
>  b/arch/arm/boot/dts/overlays/media-center-overlay.dts  | 
>6 
>  b/arch/arm/boot/dts/overlays/mz61581-overlay.dts   | 
>2 
>  b/arch/arm/boot/dts/overlays/ov9281-overlay.dts| 
>3 
>  b/arch/arm/boot/dts/overlays/overlay_map.dts   | 
>4 
>  b/arch/arm/boot/dts/overlays/pifi-40-overlay.dts   | 
>   50 
>  b/arch/arm/boot/dts/overlays/piscreen-overlay.dts  | 
>4 
>  b/arch/arm/boot/dts/overlays/piscreen2r-overlay.dts| 
>4 
>  b/arch/arm/boot/dts/overlays/sainsmart18-overlay.dts   | 
>   11 
>  b/arch/arm/boot/dts/overlays/sh1106-spi-overlay.dts| 
>2 
>  b/arch/arm/boot/dts/overlays/ssd1306-spi-overlay.dts   | 
>2 
>  b/arch/arm/boot/dts/overlays/ssd1351-spi-overlay.dts   | 
>2 
>  b/arch/arm/boot/dts/overlays/tinylcd35-overlay.dts | 
>4 
>  b/arch/arm/boot/dts/overlays/upstream-pi4-overlay.dts  | 
>   12 
>  b/arch/arm/configs/bcm2709_defconfig   | 
>   12 
>  b/arch/arm/configs/bcm2711_defconfig   | 
>   10 
>  b/arch/arm/configs/bcmrpi_defconfig| 
>   12 
>  b/arch/arm64/boot/dts/broadcom/Makefile| 
>   11 
>  

Re: [linux-yocto] [yocto-kernel-cache master PATCH] meta: Add CONFIG_SERIAL_OF_PLATFORM to 8250.cfg

2020-11-19 Thread Bruce Ashfield
In message: [linux-yocto] [yocto-kernel-cache master PATCH] meta: Add 
CONFIG_SERIAL_OF_PLATFORM to 8250.cfg
on 16/11/2020 Vasyl Vavrychuk wrote:

> On some embedded systems 8250 compatible serial ports meant to be
> defined in devicetree. Config SERIAL_OF_PLATFORM enables probing of
> them.


This is a reasonable dependency/enabler to put in the fragment. It is
merged to master.

Bruce

> 
> Signed-off-by: Vasyl Vavrychuk 
> ---
>  cfg/8250.cfg | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/cfg/8250.cfg b/cfg/8250.cfg
> index fe2d270c..403c736e 100644
> --- a/cfg/8250.cfg
> +++ b/cfg/8250.cfg
> @@ -7,3 +7,4 @@ CONFIG_SERIAL_8250_NR_UARTS=4
>  CONFIG_SERIAL_8250_RUNTIME_UARTS=4
>  CONFIG_SERIAL_CORE=y
>  CONFIG_SERIAL_CORE_CONSOLE=y
> +CONFIG_SERIAL_OF_PLATFORM=y
> --
> 2.23.0
> 
> 
> Please mind our privacy 
> notice
>  pursuant to Art. 13 GDPR. // Unsere Hinweise zum Datenschutz gem. Art. 13 
> DSGVO finden Sie 
> hier.

> 
> 
> 


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9178): 
https://lists.yoctoproject.org/g/linux-yocto/message/9178
Mute This Topic: https://lists.yoctoproject.org/mt/78302000/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [linux-yocto][linux-yocto v5.4/standard/nxp-s32g2xx][PATCH] s32gen1: pcie: Remove duplicate interrupt resource request

2020-11-19 Thread Bruce Ashfield
merged.

Bruce


In message: [linux-yocto][linux-yocto v5.4/standard/nxp-s32g2xx][PATCH] 
s32gen1: pcie: Remove duplicate interrupt resource request
on 16/11/2020 Xulin Sun wrote:

> This fixes the below kmemleak call trace:
> 
> unreferenced object 0xff88784d5980 (size 128):
> comm "swapper/0", pid 1, jiffies 4294902557 (age 818.400s)
> hex dump (first 32 bytes):
> 30 5b 93 10 c0 ff ff ff b0 a8 1f 6d 88 ff ff ff 0[.m
> 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 
> backtrace:
> [<74293536>] kmem_cache_alloc_trace+0x210/0x40c
> [<093fdcf7>] request_threaded_irq+0xac/0x190
> [<7f996a2c>] devm_request_threaded_irq+0x88/0x100
> [<3d0d78cc>] s32gen1_add_pcie_port+0xb8/0x140
> [] s32gen1_pcie_probe+0x2d8/0x530
> [<03a11c47>] platform_drv_probe+0x5c/0xb0
> [<9e95fb7f>] really_probe+0x2c8/0x4c0
> [] driver_probe_device+0xa8/0x140
> [<51d2c2b2>] device_driver_attach+0xc8/0xd0
> [<95c059b0>] __driver_attach+0x100/0x180
> [<4ab82003>] bus_for_each_dev+0x84/0xe0
> [<16820dbb>] driver_attach+0x34/0x40
> [] bus_add_driver+0x138/0x224
> [] driver_register+0x7c/0x124
> [<2c21c5fe>] __platform_driver_probe+0x88/0x150
> [] s32gen1_pcie_init+0x30/0x38
> 
> That showed the allocated "action" of the function "request_threaded_irq" is 
> not
> freed.
> The reason is that the "action" of msi irq is overwrote by below calling path,
> and caused the allocated memory becoming an island and reported the kmemleak 
> call
> trace.
> 
> dw_pcie_host_init
>   irq_set_chained_handler_and_data
>   __irq_do_set_handler
>   desc->action = _action;
> 
> So remove duplicate interrupt resource request, just do it in
> dw_pcie_host_init().
> 
> Signed-off-by: Xulin Sun 
> ---
>  drivers/pci/controller/dwc/pci-s32gen1.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/pci/controller/dwc/pci-s32gen1.c 
> b/drivers/pci/controller/dwc/pci-s32gen1.c
> index e76b001354bb..748adb4015e8 100644
> --- a/drivers/pci/controller/dwc/pci-s32gen1.c
> +++ b/drivers/pci/controller/dwc/pci-s32gen1.c
> @@ -870,9 +870,8 @@ static int __init s32gen1_add_pcie_port(struct pcie_port 
> *pp,
>   DEBUG_FUNC;
>  
>  #ifdef CONFIG_PCI_MSI
> - ret = s32gen1_pcie_config_irq(>msi_irq, "msi", pdev,
> -   s32gen1_pcie_msi_handler, pp);
> - if (ret) {
> + pp->msi_irq = platform_get_irq_byname(pdev, "msi");
> + if (pp->msi_irq <= 0) {
>   dev_err(>dev, "failed to request msi irq\n");
>   return ret;
>   }
> -- 
> 2.26.2
> 

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9177): 
https://lists.yoctoproject.org/g/linux-yocto/message/9177
Mute This Topic: https://lists.yoctoproject.org/mt/78286528/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [linux-yocto][linux-yocto][v5.4/standard/xlnx-soc][PATCH] net: axienet: Remove static from __axienet_device_reset

2020-11-19 Thread Bruce Ashfield
merged.

Bruce

In message: [linux-yocto][linux-yocto][v5.4/standard/xlnx-soc][PATCH] net: 
axienet: Remove static from __axienet_device_reset
on 16/11/2020 He Zhe wrote:

> __axienet_device_reset is referenced from different source files.
> 
> Fixes: 59b0ea17cf64 ("net: axienet: Add missing return value type for 
> __axienet_device_reset")
> Signed-off-by: He Zhe 
> ---
>  drivers/net/ethernet/xilinx/xilinx_axienet.h  | 2 +-
>  drivers/net/ethernet/xilinx/xilinx_axienet_main.c | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/ethernet/xilinx/xilinx_axienet.h 
> b/drivers/net/ethernet/xilinx/xilinx_axienet.h
> index b8d94f7ae9af..f9746e3eca95 100644
> --- a/drivers/net/ethernet/xilinx/xilinx_axienet.h
> +++ b/drivers/net/ethernet/xilinx/xilinx_axienet.h
> @@ -1065,7 +1065,7 @@ irqreturn_t __maybe_unused axienet_tx_irq(int irq, void 
> *_ndev);
>  irqreturn_t __maybe_unused axienet_rx_irq(int irq, void *_ndev);
>  void axienet_start_xmit_done(struct net_device *ndev, struct axienet_dma_q 
> *q);
>  void axienet_dma_bd_release(struct net_device *ndev);
> -void __axienet_device_reset(struct axienet_dma_q *q);
> +int __axienet_device_reset(struct axienet_dma_q *q);
>  void axienet_set_mac_address(struct net_device *ndev, const void *address);
>  void axienet_set_multicast_list(struct net_device *ndev);
>  int xaxienet_rx_poll(struct napi_struct *napi, int quota);
> diff --git a/drivers/net/ethernet/xilinx/xilinx_axienet_main.c 
> b/drivers/net/ethernet/xilinx/xilinx_axienet_main.c
> index 4f2a853d34b6..af98135aa1b2 100644
> --- a/drivers/net/ethernet/xilinx/xilinx_axienet_main.c
> +++ b/drivers/net/ethernet/xilinx/xilinx_axienet_main.c
> @@ -387,7 +387,7 @@ static void xxvenet_setoptions(struct net_device *ndev, 
> u32 options)
>  }
>  
>  
> -static int __axienet_device_reset(struct axienet_dma_q *q)
> +int __axienet_device_reset(struct axienet_dma_q *q)
>  {
>   u32 timeout;
>  
> -- 
> 2.17.1
> 

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9176): 
https://lists.yoctoproject.org/g/linux-yocto/message/9176
Mute This Topic: https://lists.yoctoproject.org/mt/78285501/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [linux-yocto] [PATCH 1/2] ext4: fix -Wstringop-truncation warnings

2020-11-19 Thread Bruce Ashfield
I forgot to ask with the v5.2 versions of these changes, what is the upstream
status of these patches ?

If they are cherry-picks/backports, we should be logging the commit ID in
the patches themselves.

If they are custom patches, a note indicating if they've been submitted
upstream should be added .. so I can track them and drop them as appropriate
when I update kernels.

Regardless, these are now merged to v5.8/*

Bruce


In message: [linux-yocto] [PATCH 1/2] ext4: fix -Wstringop-truncation warnings
on 15/11/2020 wenlin.k...@windriver.com wrote:

> From: Wenlin Kang 
> 
> The strncpy() function may create a unterminated string,
> use strscpy_pad() instead.
> 
> This fixes the following warning:
> 
> fs/ext4/super.c: In function '__save_error_info':
> fs/ext4/super.c:368:2: warning: 'strncpy' specified bound 32 equals 
> destination size [-Wstringop-truncation]
>   strncpy(es->s_last_error_func, func, sizeof(es->s_last_error_func));
>   ^~~
> fs/ext4/super.c:373:3: warning: 'strncpy' specified bound 32 equals 
> destination size [-Wstringop-truncation]
>strncpy(es->s_first_error_func, func,
>^
> sizeof(es->s_first_error_func));
> ~~~
> 
> Signed-off-by: Wenlin Kang 
> ---
>  fs/ext4/super.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/fs/ext4/super.c b/fs/ext4/super.c
> index 0b38bf29c07e..9cf88162ab66 100644
> --- a/fs/ext4/super.c
> +++ b/fs/ext4/super.c
> @@ -347,7 +347,7 @@ static void __save_error_info(struct super_block *sb, int 
> error,
>   return;
>   es->s_state |= cpu_to_le16(EXT4_ERROR_FS);
>   ext4_update_tstamp(es, s_last_error_time);
> - strncpy(es->s_last_error_func, func, sizeof(es->s_last_error_func));
> + strscpy_pad(es->s_last_error_func, func, sizeof(es->s_last_error_func));
>   es->s_last_error_line = cpu_to_le32(line);
>   es->s_last_error_ino = cpu_to_le32(ino);
>   es->s_last_error_block = cpu_to_le64(block);
> @@ -408,7 +408,7 @@ static void __save_error_info(struct super_block *sb, int 
> error,
>   if (!es->s_first_error_time) {
>   es->s_first_error_time = es->s_last_error_time;
>   es->s_first_error_time_hi = es->s_last_error_time_hi;
> - strncpy(es->s_first_error_func, func,
> + strscpy_pad(es->s_first_error_func, func,
>   sizeof(es->s_first_error_func));
>   es->s_first_error_line = cpu_to_le32(line);
>   es->s_first_error_ino = es->s_last_error_ino;
> -- 
> 2.17.1
> 

> 
> 
> 



-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9175): 
https://lists.yoctoproject.org/g/linux-yocto/message/9175
Mute This Topic: https://lists.yoctoproject.org/mt/78367182/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [linux-yocto] [v5.2/standard/base][PATCH 1/3] kdb: Eliminate strncpy() warnings by replacing with strscpy()

2020-11-19 Thread Bruce Ashfield
These are now merged to v5.2/*

Bruce

In message: [linux-yocto] [v5.2/standard/base][PATCH 1/3] kdb: Eliminate 
strncpy() warnings by replacing with strscpy()
on 15/11/2020 wenlin.k...@windriver.com wrote:

> From: Daniel Thompson 
> 
> commit d228bee8201a7ea77c414f1298b2f572f42c6113 upstream
> 
> Currently the code to manage the kdb history buffer uses strncpy() to
> copy strings to/and from the history and exhibits the classic "but
> nobody ever told me that strncpy() doesn't always terminate strings"
> bug. Modern gcc compilers recognise this bug and issue a warning.
> 
> In reality these calls will only abridge the copied string if kdb_read()
> has *already* overflowed the command buffer. Thus the use of counted
> copies here is only used to reduce the secondary effects of a bug
> elsewhere in the code.
> 
> Therefore transitioning these calls into strscpy() (without checking
> the return code) is appropriate.
> 
> Signed-off-by: Daniel Thompson 
> Reviewed-by: Douglas Anderson 
> Signed-off-by: Wenlin Kang 
> ---
>  kernel/debug/kdb/kdb_main.c | 8 
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/kernel/debug/kdb/kdb_main.c b/kernel/debug/kdb/kdb_main.c
> index 9ecfa37c7fbf..bb5dec762b69 100644
> --- a/kernel/debug/kdb/kdb_main.c
> +++ b/kernel/debug/kdb/kdb_main.c
> @@ -1103,12 +1103,12 @@ static int handle_ctrl_cmd(char *cmd)
>   case CTRL_P:
>   if (cmdptr != cmd_tail)
>   cmdptr = (cmdptr-1) % KDB_CMD_HISTORY_COUNT;
> - strncpy(cmd_cur, cmd_hist[cmdptr], CMD_BUFLEN);
> + strscpy(cmd_cur, cmd_hist[cmdptr], CMD_BUFLEN);
>   return 1;
>   case CTRL_N:
>   if (cmdptr != cmd_head)
>   cmdptr = (cmdptr+1) % KDB_CMD_HISTORY_COUNT;
> - strncpy(cmd_cur, cmd_hist[cmdptr], CMD_BUFLEN);
> + strscpy(cmd_cur, cmd_hist[cmdptr], CMD_BUFLEN);
>   return 1;
>   }
>   return 0;
> @@ -1315,7 +1315,7 @@ static int kdb_local(kdb_reason_t reason, int error, 
> struct pt_regs *regs,
>   if (*cmdbuf != '\n') {
>   if (*cmdbuf < 32) {
>   if (cmdptr == cmd_head) {
> - strncpy(cmd_hist[cmd_head], cmd_cur,
> + strscpy(cmd_hist[cmd_head], cmd_cur,
>   CMD_BUFLEN);
>   *(cmd_hist[cmd_head] +
> strlen(cmd_hist[cmd_head])-1) = '\0';
> @@ -1325,7 +1325,7 @@ static int kdb_local(kdb_reason_t reason, int error, 
> struct pt_regs *regs,
>   cmdbuf = cmd_cur;
>   goto do_full_getstr;
>   } else {
> - strncpy(cmd_hist[cmd_head], cmd_cur,
> + strscpy(cmd_hist[cmd_head], cmd_cur,
>   CMD_BUFLEN);
>   }
>  
> -- 
> 2.17.1
> 

> 
> 
> 



-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9174): 
https://lists.yoctoproject.org/g/linux-yocto/message/9174
Mute This Topic: https://lists.yoctoproject.org/mt/78367079/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [linux-yocto][v4.19/standard/preempt-rt/base][PATCH] sched/core: Fix CPU offline/online process

2020-11-19 Thread Bruce Ashfield
Thanks for the fixups!

These are now merged.

Bruce

In message: [linux-yocto][v4.19/standard/preempt-rt/base][PATCH] sched/core: 
Fix CPU offline/online process
on 16/11/2020 Daniel Dragomir wrote:

> From: Daniel Dragomir 
> 
> This error was introduced in commit d02636e8d3 ("Merge branch
> 'v4.19/standard/base' into v4.19/standard/preempt-rt/base")
> when a merge conflict has overwrited the changes from commit
> 373491f1f4 ("sched/core: Fix illegal RCU from offline CPUs").
> 
> This BUG occurs when running cpu_hotplug_stress testcase from
> KTS or when stressing one CPU by switching it online/offline
> (echo 0 and 1 in /sys/devices/system/cpu/cpu0/online).
> 
> kernel BUG at kernel/fork.c:633!
> Internal error: Oops - BUG: 0 [#1] PREEMPT SMP
> Modules linked in:
> Process sh (pid: 2016, stack limit = 0xca5ad524)
> CPU: 10 PID: 2016 Comm: sh Not tainted 4.19.131-rt30 axxia_gen2
> Hardware name: AXM56xx Victoria (DT)
> pstate: 6005 (nZCv daif -PAN -UAO)
> pc : __mmdrop+0x120/0x138
> lr : finish_cpu+0x68/0x70
> sp : ff8012153a40
> x29: ff8012153a40 x28: ffc07b389e00
> x27:  x26: 00407610f000
> x25: ffc07ee62ee0 x24: 
> x23: ff80080dfc20 x22: ff8008d9a9d8
> x21: ff8008d53ee0 x20: 0055
> x19: ff8008dc1b58 x18: 0001
> x17:  x16: 
> x15:  x14: ff8008d89688
> x13: ff8088d918d7 x12: ff8008d918e0
> x11: ff8008da4000 x10: ff8012153a00
> x9 : ffd0 x8 : ff80121539d0
> x7 :  x6 : 0001
> x5 : fffb x4 : 0030
> x3 : 0030 x2 : ff8008dc1b58
> x1 : ff8008dc1ba4 x0 : ff8008dc1b58
> Call trace:
>  __mmdrop+0x120/0x138
>  finish_cpu+0x68/0x70
>  cpuhp_invoke_callback+0xa8/0x800
>  _cpu_down+0x100/0x220
>  do_cpu_down+0x48/0x70
>  cpu_down+0x24/0x30
>  cpu_subsys_offline+0x20/0x30
>  device_offline+0xa4/0xd0
>  online_store+0x60/0xc0
>  dev_attr_store+0x44/0x60
>  sysfs_kf_write+0x5c/0x78
>  kernfs_fop_write+0xd8/0x1d0
>  __vfs_write+0x60/0x178
>  vfs_write+0xac/0x1b0
>  ksys_write+0x74/0xe8
>  __arm64_sys_write+0x24/0x30
>  el0_svc_common+0xa4/0x1a0
>  el0_svc_compat_handler+0x30/0x40
>  el0_svc_compat+0x8/0x18
>  Code: a94153f3 a9425bf5 a8c37bfd d65f03c0 (d421)
> ---[ end trace 0002 ]---
> BUG: Bad rss-counter state mm:1136ddcb idx:0 val:1012
> BUG: Bad rss-counter state mm:1136ddcb idx:1 val:5902
> BUG: non-zero pgtables_bytes on freeing mm: 180224
> 
> Signed-off-by: Daniel Dragomir 
> ---
>  kernel/sched/core.c | 7 ++-
>  1 file changed, 2 insertions(+), 5 deletions(-)
> 
> diff --git a/kernel/sched/core.c b/kernel/sched/core.c
> index 218b93a..c62dbf9 100644
> --- a/kernel/sched/core.c
> +++ b/kernel/sched/core.c
> @@ -5702,11 +5702,8 @@ void idle_task_exit(void)
>   switch_mm(mm, _mm, current);
>   finish_arch_post_lock_switch();
>   }
> - /*
> -  * Defer the cleanup to an alive cpu. On RT we can neither
> -  * call mmdrop() nor mmdrop_delayed() from here.
> -  */
> - per_cpu(idle_last_mm, smp_processor_id()) = mm;
> +
> + /* finish_cpu(), as ran on the BP, will clean up the active_mm state */
>  }
>  
>  /*
> -- 
> 2.7.4
> 

> 
> 
> 



-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#9173): 
https://lists.yoctoproject.org/g/linux-yocto/message/9173
Mute This Topic: https://lists.yoctoproject.org/mt/78366960/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-