Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1431848

Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu

From Marc Zyngier <marc.zyngier@arm.com>
Newsgroups linux.kernel
Subject Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu
Date 2016-06-27 11:20 +0200
Message-ID <rOARY-6GU-15@gated-at.bofh.it> (permalink)
References <rOkNb-54u-3@gated-at.bofh.it>
Organization ARM Ltd

Show all headers | View raw


[Thanks Maxime for pointing me to this discussion, +RMK]

Hi Hans,

On 26/06/16 17:00, Hans de Goede wrote:
> Hi,
> 
> I've just spend most of my Sunday debugging a problem
> where Allwinner ARM SoC based boards will not shutdown when
> using a Fedora 24 userland, where as the exact same
> kernel works fine with Fedora 22.
> 
> It turns out that irq-balanced is to blame. In Fedora 24
> it pins the i2c controller, which talks to the pmic
> which is needed for poweroff to cpu-id 1:
> 
> [root@localhost ~]# cat /proc/irq/49/smp_affinity
> 2
> 
> Where as the reboot_cpu is cpu-id 0 and with
> cpu 1 disabled at poweroff time, the i2c transfer
> never gets past its first step leading to an i2c
> driver timeout + kernel panic due to machine_power_off()
> returning.
> 
> As a workaround I can stop irq-balanced and do:
> 
> echo 3 > /proc/irq/49/smp_affinity
> 
> Before doing poweroff and then everything works as
> expected again.
> 
> Now the question is how to fix this?

[...]

I'm wondering if that's not an effect of this patch:

https://lkml.org/lkml/2015/9/24/138

missing on the ARM side (the corresponding arm64 patch is 217d453d473c).

Otherwise, can you instrument the GIC set_affinity method and find out
if we're even trying to move this IRQ away from the CPU that is being
torn down?

Thanks,

	M.
-- 
Jazz is not dead. It just smells funny...

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Hans de Goede <hdegoede@redhat.com> - 2016-06-26 18:10 +0200
  Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Marc Zyngier <marc.zyngier@arm.com> - 2016-06-27 11:20 +0200
    Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Russell King - ARM Linux <linux@armlinux.org.uk> - 2016-06-27 11:50 +0200
      Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Hans de Goede <hdegoede@redhat.com> - 2016-06-27 13:00 +0200
        Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Russell King - ARM Linux <linux@armlinux.org.uk> - 2016-06-27 13:40 +0200
          Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Russell King - ARM Linux <linux@armlinux.org.uk> - 2016-06-27 13:50 +0200
          Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Hans de Goede <hdegoede@redhat.com> - 2016-06-27 15:00 +0200
            Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Russell King - ARM Linux <linux@armlinux.org.uk> - 2016-06-27 16:00 +0200
              Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Hans de Goede <hdegoede@redhat.com> - 2016-06-27 16:40 +0200
            Re: BUG?: kernel does not (re)set irq smp_affinity to reboot_cpu Mark Rutland <mark.rutland@arm.com> - 2016-06-27 17:00 +0200

csiph-web