From: Alexandre Belloni <alexandre.belloni@bootlin.com>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: Alessandro Zummo <a.zummo@towertech.it>, linux-rtc@vger.kernel.org
Subject: Re: [PATCH 2/2] rtc: x1205: Add DT probing support
Date: Thu, 31 Jan 2019 16:30:12 +0100 [thread overview]
Message-ID: <20190131153012.GA15115@piout.net> (raw)
In-Reply-To: <20190131150642.26289-2-linus.walleij@linaro.org>
Hi Linus,
On 31/01/2019 16:06:42+0100, Linus Walleij wrote:
> This makes it possible to probe the X1205 RTC from the
> device tree. This is needed when adding device tree boot
> support for the IXP4xx-based NSLU2 which has this RTC.
>
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> drivers/rtc/rtc-x1205.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/rtc/rtc-x1205.c b/drivers/rtc/rtc-x1205.c
> index f08f18e4fcdf..c2b64c9363da 100644
> --- a/drivers/rtc/rtc-x1205.c
> +++ b/drivers/rtc/rtc-x1205.c
> @@ -673,9 +673,15 @@ static const struct i2c_device_id x1205_id[] = {
> };
> MODULE_DEVICE_TABLE(i2c, x1205_id);
>
> +static const struct of_device_id x1205_dt_ids[] = {
> + { .compatible = "xircom,x1205", },
> +};
> +MODULE_DEVICE_TABLE(of, x1205_dt_ids);
> +
I think this is not necessary and this will probe without the
of_match_table but it doesn't hurt either.
> static struct i2c_driver x1205_driver = {
> .driver = {
> .name = "rtc-x1205",
> + .of_match_table = x1205_dt_ids,
> },
> .probe = x1205_probe,
> .remove = x1205_remove,
> --
> 2.20.1
>
--
Alexandre Belloni, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
next prev parent reply other threads:[~2019-01-31 15:30 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-31 15:06 [PATCH 1/2] rtx: x1205: Add DT bindings Linus Walleij
2019-01-31 15:06 ` [PATCH 2/2] rtc: x1205: Add DT probing support Linus Walleij
2019-01-31 15:30 ` Alexandre Belloni [this message]
2019-02-01 12:22 ` Linus Walleij
2019-02-01 14:13 ` Alexandre Belloni
2019-02-01 21:29 ` Linus Walleij
2019-02-07 20:42 ` Alexandre Belloni
2019-02-07 20:42 ` [PATCH 1/2] rtx: x1205: Add DT bindings Alexandre Belloni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190131153012.GA15115@piout.net \
--to=alexandre.belloni@bootlin.com \
--cc=a.zummo@towertech.it \
--cc=linus.walleij@linaro.org \
--cc=linux-rtc@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.