Pinctrl-amd interrupt states on boot

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I've been working on getting Linux running on the AMD variant of the Microsoft 
Surface Laptop 4, and have tracked down high power consumption and spurious 
wakes in the s2idle state to the interrupt states configured on the AMD GPIO 
chip under pinctrl-amd, in this case an AMDI0031.
I don't think pinctrl-amd has has been used as a wakeup source yet, as it 
never called enable_irq_wake until this[0] patch, which has not hit mainline 
yet.

I read the gpio state before allowing pinctrl-amd to setup, there's 183 pins,
and there are a number configured.  Pin 6 and 11 for example are configured 
with.
6: 0x00c50000: Driver Strength 2, Output enabled, Output high
11: 0x00052800: Interrupt Enabled, Wake in Si03, Driver Strength 2, Input high

My understanding is that on boot Linux expects interrupts to be disabled and 
masked on boot, and I have found that on boot, on this device, the interrupts 
are in various states of configuration.  I'm not sure if this is a quirk of the 
firmware of the Surface Laptop 4 and if I should add a quirk for this device, 
or if the pinctrl-amd driver needs to loop over the pins and disable, mask, 
and clear the wakeup flags in general.  In either case I'm assuming output pins 
should be left alone.  I'm hoping for some thoughts on this.

[0]: https://lore.kernel.org/linux-gpio/20210831120613.1514899-1-Basavaraj.Natikar@xxxxxxx/

Thanks,
Sachi





[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux