pinctrl: baytrail: Add back Baytrail-T ACPI ID
Subsystems (2)
PATCH 2/2 pinctrl: baytrail: Register GPIO chip after chip->to_irq is set
In reply to Mika WesterbergFrom: Jin Yao <[email protected]>
If chip->to_irq is NULL ACPI GPIO helpers don't register GPIO event handlers thus preventing any ACPI GPIO triggered events. Solve this by calling gpiochip_add() after we have set up drivers chip->to_irq hook.
--- drivers/pinctrl/pinctrl-baytrail.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-)
drivers/pinctrl/pinctrl-baytrail.c +6 -6
@@ -527,12 +527,6 @@ static int byt_gpio_probe(struct platform_device *pdev) gc->can_sleep = false; gc->dev = dev; - ret =gpiochip_add (gc); -if (ret) { -dev_err (&pdev->dev,"failed adding byt-gpio chip\n" ); -return ret; - } -/* set up interrupts */ irq_rc =platform_get_resource (pdev,IORESOURCE_IRQ ,0 );if (irq_rc && irq_rc->start) {
@@ -550,6 +544,12 @@ static int byt_gpio_probe(struct platform_device *pdev)irq_set_chained_handler (hwirq, byt_gpio_irq_handler); } + ret =gpiochip_add (gc); +if (ret) { +dev_err (&pdev->dev,"failed adding byt-gpio chip\n" ); +return ret; + } +pm_runtime_enable (dev);return 0 ;
Signature · 1 line
2.0.0.rc2
PATCH 1/2 pinctrl: baytrail: Add back Baytrail-T ACPI ID
From: Jin Yao <[email protected]>
Now that the x86 dynamic IRQ allocation problem has been resolved with commmit 62a08ae2a576 (genirq: x86: Ensure that dynamic irq allocation does not conflict), we can add back Baytrail-T ACPI ID to the pinctrl driver.
This makes the driver to work on Asus T100 where it is needed for several things like ACPI GPIO events and SD card detection.
References: https://bugzilla.kernel.org/show_bug.cgi?id=68291
--- drivers/acpi/acpi_lpss.c | 1 + drivers/pinctrl/pinctrl-baytrail.c | 1 + 2 files changed, 2 insertions(+)
drivers/acpi/acpi_lpss.c +1 -0
@@ -189,6 +189,7 @@ static const struct acpi_device_id acpi_lpss_device_ids[] = { { "80860F14", (unsigned long)&byt_sdio_dev_desc }, { "80860F41", (unsigned long)&byt_i2c_dev_desc }, { "INT33B2", }, + { "INT33FC", }, { "INT3430", (unsigned long)&lpt_dev_desc }, { "INT3431", (unsigned long)&lpt_dev_desc },
drivers/pinctrl/pinctrl-baytrail.c +1 -0
@@ -572,6 +572,7 @@ static const struct dev_pm_ops byt_gpio_pm_ops = {static const struct acpi_device_id byt_gpio_acpi_match[] = { {"INT33B2" ,0 }, + {"INT33FC" ,0 }, { } };MODULE_DEVICE_TABLE (acpi, byt_gpio_acpi_match);
Signature · 1 line
2.0.0.rc2
Quoted 6 lines · Mika Westerberg
From: Jin Yao <[email protected]>
Now that the x86 dynamic IRQ allocation problem has been resolved with commmit
62a08ae2a576(genirq: x86: Ensure that dynamic irq allocation does not conflict), we can add back Baytrail-T ACPI ID to the pinctrl driver.
Quoted 6 lines
This makes the driver to work on Asus T100 where it is needed for several things like ACPI GPIO events and SD card detection.
References: https://bugzilla.kernel.org/show_bug.cgi?id=68291
Signed-off-by Jin Yao <[email protected]>Signed-off-by Mika Westerberg <[email protected]>
And I think this is pinctrl material really.
Quoted 30 lines
--- drivers/acpi/acpi_lpss.c | 1 + drivers/pinctrl/pinctrl-baytrail.c | 1 + 2 files changed, 2 insertions(+)drivers/acpi/acpi_lpss.c +1
-0@@ -189,6 +189,7 @@ static const struct acpi_device_id acpi_lpss_device_ids[] = { { "80860F14", (unsigned long)&byt_sdio_dev_desc }, { "80860F41", (unsigned long)&byt_i2c_dev_desc }, { "INT33B2", }, + { "INT33FC", }, { "INT3430", (unsigned long)&lpt_dev_desc }, { "INT3431", (unsigned long)&lpt_dev_desc },drivers/pinctrl/pinctrl-baytrail.c +1
-0@@ -572,6 +572,7 @@ static const struct dev_pm_ops byt_gpio_pm_ops = {static const struct acpi_device_id byt_gpio_acpi_match[] = { {"INT33B2" ,0 }, + {"INT33FC" ,0 }, { } };MODULE_DEVICE_TABLE (acpi, byt_gpio_acpi_match);
Signature · 2 lines
I speak only for myself. Rafael J. Wysocki, Intel Open Source Technology Center.
Quoted 7 lines · Rafael J. Wysocki
Quoted 6 lines · Mika Westerberg
From: Jin Yao <[email protected]>
Now that the x86 dynamic IRQ allocation problem has been resolved with commmit
62a08ae2a576(genirq: x86: Ensure that dynamic irq allocation does not conflict), we can add back Baytrail-T ACPI ID to the pinctrl driver.
Quoted 8 lines
Quoted 6 lines
This makes the driver to work on Asus T100 where it is needed for several things like ACPI GPIO events and SD card detection.
References: https://bugzilla.kernel.org/show_bug.cgi?id=68291
Signed-off-by Jin Yao <[email protected]>Signed-off-by Mika Westerberg <[email protected]>
Thanks!
Quoted 1 line
And I think this is pinctrl material really.
Indeed, only one change touches drivers/acpi/ but wanted to keep you in the loop. I'm hoping that Linus W. takes these.
Re: [PATCH 2/2] pinctrl: baytrail: Register GPIO chip after chip->to_irq is set
In reply to Mika WesterbergQuoted 8 lines · Mika Westerberg
From: Jin Yao <[email protected]>
If
chip->to_irqis NULL ACPI GPIO helpers don't register GPIO event handlers thus preventing any ACPI GPIO triggered events. Solve this by callinggpiochip_add()after we have set up driverschip->to_irqhook.Signed-off-by Jin Yao <[email protected]>Signed-off-by Mika Westerberg <[email protected]>
Patch applied for fixes, sorry for running a bit late, we are late.
Yours,
Linus Walleij
Quoted 6 lines · Mika Westerberg
From: Jin Yao <[email protected]>
Now that the x86 dynamic IRQ allocation problem has been resolved with commmit
62a08ae2a576(genirq: x86: Ensure that dynamic irq allocation does not conflict), we can add back Baytrail-T ACPI ID to the pinctrl driver.
Quoted 6 lines
This makes the driver to work on Asus T100 where it is needed for several things like ACPI GPIO events and SD card detection.
References: https://bugzilla.kernel.org/show_bug.cgi?id=68291
Signed-off-by Jin Yao <[email protected]>Signed-off-by Mika Westerberg <[email protected]>
Patch applied with Rafael's ACK.
Applying this and 2/2 to v3.16 though, protest if there is a problem with this.
Yours,
Linus Walleij
Quoted 12 lines · Linus Walleij
Quoted 9 lines · Mika Westerberg
From: Jin Yao <[email protected]>
Now that the x86 dynamic IRQ allocation problem has been resolved with commmit
62a08ae2a576(genirq: x86: Ensure that dynamic irq allocation does not conflict), we can add back Baytrail-T ACPI ID to the pinctrl driver.This makes the driver to work on Asus T100 where it is needed for several things like ACPI GPIO events and SD card detection.
Quoted 7 lines
Quoted 3 lines
References: https://bugzilla.kernel.org/show_bug.cgi?id=68291
Signed-off-by Jin Yao <[email protected]>Signed-off-by Mika Westerberg <[email protected]>Patch applied with Rafael's ACK.
Applying this and 2/2 to v3.16 though, protest if there is a problem with this.
v3.16 is fine. Thanks!