summaryrefslogtreecommitdiffstats
path: root/drivers/net/can
diff options
context:
space:
mode:
authorDan Murphy <dmurphy@ti.com>2019-08-23 12:50:57 -0500
committerMarc Kleine-Budde <mkl@pengutronix.de>2019-09-03 10:23:57 +0200
commitbe1d28424adca74d7b2a3970b8fec6c9786a6b5e (patch)
tree95d22a95010286694db9a5b3eeeaaf904645ccce /drivers/net/can
parente3b329221567ac86bd667bfb644ac04c867b71cb (diff)
downloadblackbird-op-linux-be1d28424adca74d7b2a3970b8fec6c9786a6b5e.tar.gz
blackbird-op-linux-be1d28424adca74d7b2a3970b8fec6c9786a6b5e.zip
can: tcan4x5x: Remove data-ready gpio interrupt
Remove the data-ready gpio interrupt handling and use the spi->irq that is created based on the interrupt DT property. Signed-off-by: Dan Murphy <dmurphy@ti.com> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'drivers/net/can')
-rw-r--r--drivers/net/can/m_can/tcan4x5x.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/drivers/net/can/m_can/tcan4x5x.c b/drivers/net/can/m_can/tcan4x5x.c
index a697996d81b4..bb41e8d5f3a2 100644
--- a/drivers/net/can/m_can/tcan4x5x.c
+++ b/drivers/net/can/m_can/tcan4x5x.c
@@ -117,7 +117,6 @@ struct tcan4x5x_priv {
struct m_can_classdev *mcan_dev;
struct gpio_desc *reset_gpio;
- struct gpio_desc *interrupt_gpio;
struct gpio_desc *device_wake_gpio;
struct gpio_desc *device_state_gpio;
struct regulator *power;
@@ -356,13 +355,6 @@ static int tcan4x5x_parse_config(struct m_can_classdev *cdev)
{
struct tcan4x5x_priv *tcan4x5x = cdev->device_data;
- tcan4x5x->interrupt_gpio = devm_gpiod_get(cdev->dev, "data-ready",
- GPIOD_IN);
- if (IS_ERR(tcan4x5x->interrupt_gpio)) {
- dev_err(cdev->dev, "data-ready gpio not defined\n");
- return -EINVAL;
- }
-
tcan4x5x->device_wake_gpio = devm_gpiod_get(cdev->dev, "device-wake",
GPIOD_OUT_HIGH);
if (IS_ERR(tcan4x5x->device_wake_gpio)) {
@@ -381,8 +373,6 @@ static int tcan4x5x_parse_config(struct m_can_classdev *cdev)
if (IS_ERR(tcan4x5x->device_state_gpio))
tcan4x5x->device_state_gpio = NULL;
- cdev->net->irq = gpiod_to_irq(tcan4x5x->interrupt_gpio);
-
tcan4x5x->power = devm_regulator_get_optional(cdev->dev,
"vsup");
if (PTR_ERR(tcan4x5x->power) == -EPROBE_DEFER)
@@ -447,6 +437,7 @@ static int tcan4x5x_can_probe(struct spi_device *spi)
mcan_class->is_peripheral = true;
mcan_class->bit_timing = &tcan4x5x_bittiming_const;
mcan_class->data_timing = &tcan4x5x_data_bittiming_const;
+ mcan_class->net->irq = spi->irq;
spi_set_drvdata(spi, priv);
OpenPOWER on IntegriCloud