Re: [PATCH] pinctrl: intel: Only restore pins that are used by the driver
From: AceLan Kao <acelan.kao@canonical.com>
Date: 2016-10-12 01:36:58
Cool, the fix works for me. I really hope these fixes could be in stable kernel from 4.1+, but if you have any concerns or troubles in doing that, please let me know, I'll submit those patches to ubuntu 4.4 and 4.8 kernels. Thanks. 2016-10-11 17:27 GMT+08:00 Mika Westerberg [off-list ref]:
quoted hunk ↗ jump to hunk
On Tue, Oct 11, 2016 at 10:38:27AM +0800, AceLan Kao wrote:quoted
Hi Mika, BTW, I failed to compile the kernel 4.4 with the patch. The patch uses gpiochip_line_is_irq() function which has been introduced since 4.6-rc1, so we need to cherry pick this commit, too. 6cee382 gpio/pinctrl: sunxi: stop poking around in private vars But the above commit uses gpiodev data member in struct gpio_chip which is introduced from this commit, and it's a big commit that can't be cherry-picked clearly. ff2b135 gpio: make the gpiochip a real device Will you provide other patch that can apply on top of old stable kernels?Hmm, So 6cee382 ("gpio/pinctrl: sunxi: stop poking around in private vars") needs the following patch. I can backport 6cee382 with the below patch and send both patches to stable@ after this gets merged to mainline but not sure if that's the correct process to follow.diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index db007a3e2af7..6240dd40e8be 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c@@ -1524,7 +1524,7 @@ bool gpiochip_line_is_irq(struct gpio_chip *chip, unsigned int offset) if (offset >= chip->ngpio) return false; - return test_bit(FLAG_USED_AS_IRQ, &chip->gpiodev->descs[offset].flags); + return test_bit(FLAG_USED_AS_IRQ, &chip->desc[offset].flags); } EXPORT_SYMBOL_GPL(gpiochip_line_is_irq);