[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACRpkdak90H+eZXH=9tZYzQ5DCZsYRXqF7i+tdAqQ8_Y0fcjug@mail.gmail.com>
Date: Thu, 24 Dec 2015 00:29:58 +0100
From: Linus Walleij <linus.walleij@...aro.org>
To: "Andrew F. Davis" <afd@...com>
Cc: Alexandre Courbot <gnurou@...il.com>,
"linux-gpio@...r.kernel.org" <linux-gpio@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] gpio: Add driver for TI TPIC2810
On Tue, Dec 15, 2015 at 9:10 PM, Andrew F. Davis <afd@...com> wrote:
> Add driver for TI TPIC2810 8-Bit LED Driver with I2C Interface.
>
> The TPIC2810 has 8 open-drain outputs that can but used to drive
> LEDs and other low-side switched resistive loads.
>
> Signed-off-by: Andrew F. Davis <afd@...com>
This patch will have to be rebased to apply and compile after the release
of kernel v4.5-rc1, as we have too much lined up right now, I see no
big problems
with it but here are some more minor comments.
+static inline struct tpic2810 *to_tpic2810(struct gpio_chip *chip)
> +{
> + return container_of(chip, struct tpic2810, chip);
> +}
We are getting rid of this design pattern, check the gpiochip_get_data()
function that will be introduced in v4.5-rc1 and patches I merge to all
other drivers.
> +static const struct i2c_device_id tpic2810_id_table[] = {
> + { "tpic2810", },
> + { /* sentinel */ }
> +};
> +MODULE_DEVICE_TABLE(i2c, tpic2810_id_table);
> +
> +static struct i2c_driver tpic2810_driver = {
> + .driver = {
> + .name = "tpic2810",
> + },
> + .probe = tpic2810_probe,
> + .remove = tpic2810_remove,
> + .id_table = tpic2810_id_table,
> +};
> +module_i2c_driver(tpic2810_driver);
No device tree probing? Which platform uses this?
I was expecting an .of_match_table() in .driver.
Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists