* [PATCH] Input: goodix: request_irq: convert gpio to irq
@ 2019-11-27 10:29 Yannick Fertre
2019-12-01 3:05 ` Dmitry Torokhov
0 siblings, 1 reply; 6+ messages in thread
From: Yannick Fertre @ 2019-11-27 10:29 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard,
Bastien Nocera, Dmitry Torokhov, linux-input, linux-kernel
From: Yannick Fertré <yannick.fertre@st.com>
Convert gpio to irq if not already done by gpio lib.
Signed-off-by: Yannick Fertré <yannick.fertre
---
drivers/input/touchscreen/goodix.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/input/touchscreen/goodix.c b/drivers/input/touchscreen/goodix.c
index b470773..f1d9d5e 100644
--- a/drivers/input/touchscreen/goodix.c
+++ b/drivers/input/touchscreen/goodix.c
@@ -23,6 +23,7 @@
#include <linux/delay.h>
#include <linux/irq.h>
#include <linux/interrupt.h>
+#include <linux/gpio.h>
#include <linux/regulator/consumer.h>
#include <linux/slab.h>
#include <linux/acpi.h>
@@ -392,6 +393,13 @@ static void goodix_free_irq(struct goodix_ts_data *ts)
static int goodix_request_irq(struct goodix_ts_data *ts)
{
+ int gpio;
+
+ gpio = desc_to_gpio(ts->gpiod_int);
+
+ if (gpio_is_valid(gpio))
+ ts->client->irq = gpio_to_irq(gpio);
+
return devm_request_threaded_irq(&ts->client->dev, ts->client->irq,
NULL, goodix_ts_irq_handler,
ts->irq_flags, ts->client->name, ts);
--
2.7.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] Input: goodix: request_irq: convert gpio to irq
2019-11-27 10:29 [PATCH] Input: goodix: request_irq: convert gpio to irq Yannick Fertre
@ 2019-12-01 3:05 ` Dmitry Torokhov
0 siblings, 0 replies; 6+ messages in thread
From: Dmitry Torokhov @ 2019-12-01 3:05 UTC (permalink / raw)
To: Yannick Fertre
Cc: Philippe Cornu, Benjamin Gaignard, Bastien Nocera, linux-input,
linux-kernel
On Wed, Nov 27, 2019 at 11:29:01AM +0100, Yannick Fertre wrote:
> From: Yannick Fertré <yannick.fertre@st.com>
>
> Convert gpio to irq if not already done by gpio lib.
No, please make sure that dts specifies "interrupts" property. It is
marked as "required" in the binding.
Thanks.
--
Dmitry
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH] Input: goodix: request_irq: convert gpio to irq
@ 2019-11-27 10:24 ` Yannick Fertre
0 siblings, 0 replies; 6+ messages in thread
From: Yannick Fertre @ 2019-11-27 10:24 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
From: Yannick Fertré <yannick.fertre@st.com>
Convert gpio to irq if not already done by gpio lib.
Signed-off-by: Yannick Fertré <yannick.fertre
---
drivers/input/touchscreen/goodix.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/input/touchscreen/goodix.c b/drivers/input/touchscreen/goodix.c
index b470773..f1d9d5e 100644
--- a/drivers/input/touchscreen/goodix.c
+++ b/drivers/input/touchscreen/goodix.c
@@ -23,6 +23,7 @@
#include <linux/delay.h>
#include <linux/irq.h>
#include <linux/interrupt.h>
+#include <linux/gpio.h>
#include <linux/regulator/consumer.h>
#include <linux/slab.h>
#include <linux/acpi.h>
@@ -392,6 +393,13 @@ static void goodix_free_irq(struct goodix_ts_data *ts)
static int goodix_request_irq(struct goodix_ts_data *ts)
{
+ int gpio;
+
+ gpio = desc_to_gpio(ts->gpiod_int);
+
+ if (gpio_is_valid(gpio))
+ ts->client->irq = gpio_to_irq(gpio);
+
return devm_request_threaded_irq(&ts->client->dev, ts->client->irq,
NULL, goodix_ts_irq_handler,
ts->irq_flags, ts->client->name, ts);
--
2.7.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH] Input: goodix: request_irq: convert gpio to irq
@ 2019-11-27 10:24 ` Yannick Fertre
0 siblings, 0 replies; 6+ messages in thread
From: Yannick Fertre @ 2019-11-27 10:24 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
From: Yannick Fertré <yannick.fertre@st.com>
Convert gpio to irq if not already done by gpio lib.
Signed-off-by: Yannick Fertré <yannick.fertre
---
drivers/input/touchscreen/goodix.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/input/touchscreen/goodix.c b/drivers/input/touchscreen/goodix.c
index b470773..f1d9d5e 100644
--- a/drivers/input/touchscreen/goodix.c
+++ b/drivers/input/touchscreen/goodix.c
@@ -23,6 +23,7 @@
#include <linux/delay.h>
#include <linux/irq.h>
#include <linux/interrupt.h>
+#include <linux/gpio.h>
#include <linux/regulator/consumer.h>
#include <linux/slab.h>
#include <linux/acpi.h>
@@ -392,6 +393,13 @@ static void goodix_free_irq(struct goodix_ts_data *ts)
static int goodix_request_irq(struct goodix_ts_data *ts)
{
+ int gpio;
+
+ gpio = desc_to_gpio(ts->gpiod_int);
+
+ if (gpio_is_valid(gpio))
+ ts->client->irq = gpio_to_irq(gpio);
+
return devm_request_threaded_irq(&ts->client->dev, ts->client->irq,
NULL, goodix_ts_irq_handler,
ts->irq_flags, ts->client->name, ts);
--
2.7.4
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH] Input: goodix: request_irq: convert gpio to irq
@ 2019-11-27 10:24 ` Yannick Fertre
0 siblings, 0 replies; 6+ messages in thread
From: Yannick Fertre @ 2019-11-27 10:24 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
From: Yannick Fertré <yannick.fertre@st.com>
Convert gpio to irq if not already done by gpio lib.
Signed-off-by: Yannick Fertré <yannick.fertre
---
drivers/input/touchscreen/goodix.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/input/touchscreen/goodix.c b/drivers/input/touchscreen/goodix.c
index b470773..f1d9d5e 100644
--- a/drivers/input/touchscreen/goodix.c
+++ b/drivers/input/touchscreen/goodix.c
@@ -23,6 +23,7 @@
#include <linux/delay.h>
#include <linux/irq.h>
#include <linux/interrupt.h>
+#include <linux/gpio.h>
#include <linux/regulator/consumer.h>
#include <linux/slab.h>
#include <linux/acpi.h>
@@ -392,6 +393,13 @@ static void goodix_free_irq(struct goodix_ts_data *ts)
static int goodix_request_irq(struct goodix_ts_data *ts)
{
+ int gpio;
+
+ gpio = desc_to_gpio(ts->gpiod_int);
+
+ if (gpio_is_valid(gpio))
+ ts->client->irq = gpio_to_irq(gpio);
+
return devm_request_threaded_irq(&ts->client->dev, ts->client->irq,
NULL, goodix_ts_irq_handler,
ts->irq_flags, ts->client->name, ts);
--
2.7.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH] Input: goodix: request_irq: convert gpio to irq
@ 2019-11-27 10:24 ` Yannick Fertre
0 siblings, 0 replies; 6+ messages in thread
From: Yannick Fertre @ 2019-11-27 10:24 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
From: Yannick Fertré <yannick.fertre@st.com>
Convert gpio to irq if not already done by gpio lib.
Signed-off-by: Yannick Fertré <yannick.fertre
---
drivers/input/touchscreen/goodix.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/input/touchscreen/goodix.c b/drivers/input/touchscreen/goodix.c
index b470773..f1d9d5e 100644
--- a/drivers/input/touchscreen/goodix.c
+++ b/drivers/input/touchscreen/goodix.c
@@ -23,6 +23,7 @@
#include <linux/delay.h>
#include <linux/irq.h>
#include <linux/interrupt.h>
+#include <linux/gpio.h>
#include <linux/regulator/consumer.h>
#include <linux/slab.h>
#include <linux/acpi.h>
@@ -392,6 +393,13 @@ static void goodix_free_irq(struct goodix_ts_data *ts)
static int goodix_request_irq(struct goodix_ts_data *ts)
{
+ int gpio;
+
+ gpio = desc_to_gpio(ts->gpiod_int);
+
+ if (gpio_is_valid(gpio))
+ ts->client->irq = gpio_to_irq(gpio);
+
return devm_request_threaded_irq(&ts->client->dev, ts->client->irq,
NULL, goodix_ts_irq_handler,
ts->irq_flags, ts->client->name, ts);
--
2.7.4
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2019-12-01 3:05 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-27 10:29 [PATCH] Input: goodix: request_irq: convert gpio to irq Yannick Fertre
2019-12-01 3:05 ` Dmitry Torokhov
-- strict thread matches above, loose matches on Subject: below --
2019-11-27 10:24 Yannick Fertre
2019-11-27 10:24 ` Yannick Fertre
2019-11-27 10:24 ` Yannick Fertre
2019-11-27 10:24 ` Yannick Fertre
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.