openwrt / packages

Community maintained packages for OpenWrt. Documentation for submitting pull requests is in CONTRIBUTING.md
GNU General Public License v2.0
3.9k stars 3.41k forks source link

`irqbalance:` segfaults for `aarch64_cortex-a53` #18741

Closed aidvu closed 2 years ago

aidvu commented 2 years ago

Maintainer: @hnyman Environment: aarch64_cortex-a53, Xiaomi AX6S, OpenWrt 22.*

Description:

It seems the recent irqbalance bump to 1.9.0 made it segfault on above architecture. Judging by a recent patch https://github.com/Irqbalance/irqbalance/pull/210, it's probably broken for any AARCH64 CPU.

I can confirm it was working previously on both Belkin RT3200 and Xiaomi AX6S.

aidvu commented 2 years ago

Some debug info:

Belkin RT3200, irqbalance 1.8.0

root@Banshee:~# cat /tmp/sysinfo/model
Linksys E8450 (UBI)
root@Banshee:~# irqbalance --version
irqbalance version 1.8.0
root@Banshee:~# service irqbalance info
{
    "irqbalance": {
        "instances": {
            "irqbalance": {
                "running": true,
                "pid": 1871,
                "command": [
                    "/usr/sbin/irqbalance",
                    "-f",
                    "-t",
                    "10",
                    ""
                ],
                "term_timeout": 5,
                "respawn": {
                    "threshold": 3600,
                    "timeout": 5,
                    "retry": 5
                }
            }
        },
        "triggers": [
            [
                "config.change",
                [
                    "if",
                    [
                        "eq",
                        "package",
                        "irqbalance"
                    ],
                    [
                        "run_script",
                        "/etc/init.d/irqbalance",
                        "reload"
                    ]
                ],
                1000
            ]
        ]
    }
}

Xiaomi AX6S

root@Wendigo:~# cat /tmp/sysinfo/model 
Xiaomi Redmi Router AX6S
root@Wendigo:~# irqbalance --version
irqbalance version 1.9.0
root@Wendigo:~# service irqbalance info
{
    "irqbalance": {
        "triggers": [
            [
                "config.change",
                [
                    "if",
                    [
                        "eq",
                        "package",
                        "irqbalance"
                    ],
                    [
                        "run_script",
                        "/etc/init.d/irqbalance",
                        "reload"
                    ]
                ],
                1000
            ]
        ]
    }
}
hnyman commented 2 years ago

Thanks for spotting the bug and also the upstream fix.

aidvu commented 2 years ago

Had a plan to make a patch and try to build it, since I haven't built OpenWRT myself yet, but that sure was quick. Thank you. :)