From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Wolfram Sang <wsa@the-dreams.de>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>,
Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>,
"linux-input@vger.kernel.org" <linux-input@vger.kernel.org>,
Linux I2C <linux-i2c@vger.kernel.org>,
Linux-sh list <linux-sh@vger.kernel.org>
Subject: Re: [PATCH v2 1/2] DT: i2c: Deprecate adi,adxl34x compatible string
Date: Thu, 15 Jan 2015 22:51:43 +0200 [thread overview]
Message-ID: <16733840.6Wupp0rKhe@avalon> (raw)
In-Reply-To: <20150115174333.GC6342@katana>
Hi Wolfram,
On Thursday 15 January 2015 18:43:33 Wolfram Sang wrote:
> On Thu, Jan 15, 2015 at 06:32:31PM +0100, Geert Uytterhoeven wrote:
> > On Thu, Jan 15, 2015 at 6:02 PM, Wolfram Sang <wsa@the-dreams.de> wrote:
> >>> --- a/Documentation/devicetree/bindings/i2c/trivial-devices.txt
> >>> +++ b/Documentation/devicetree/bindings/i2c/trivial-devices.txt
> >>> @@ -18,8 +18,7 @@ adi,adt7475 +/-1C TDM Extended Temp Range I.C
> >>>
> >>> adi,adt7476 +/-1C TDM Extended Temp Range I.C
> >>> adi,adt7490 +/-1C TDM Extended Temp Range I.C
> >>> adi,adxl345 Three-Axis Digital Accelerometer
> >>>
> >>> -adi,adxl346 Three-Axis Digital Accelerometer
> >>> -adi,adxl34x Three-Axis Digital Accelerometer
> >>> +adi,adxl346 Three-Axis Digital Accelerometer
> >>> (backward-compatibility value "adi,adxl345" must be listed too)
> >>
> >> I'd rather drop 346 because there is no compatible for that one
> >> anywhere. No need to resend, I can fix it here...
> >
> > If you drop adi,adxl346, checkpatch will start complaining if it
> > encounters it in a .dts.
>
> Boah, this is annoying. That means we need an 346 entry even if it is
> not different from 345 (which is fine by me).
>
> If checkpatch does it this way, that means the rule of thumb is to
> *always* have a dedicated compatible entry? Can someone confirm this?
I believe we should register a new compatible entry for a device when the
device isn't identical, from a compatibility point of view, to an already
registered device. In this specific case the adxl346 offers addition features
compared to the adxl345. It thus qualify for its own compatible string. Its DT
nodes should list both the adi,adxl346 and adi,adxl345 compatible strings in
that order, as the chip is compatible with the adxl345. On the driver side,
given that we don't need to differentiate between the devices based on the
compatible string (as runtime model detection is possible) we don't need to
add a match entry for adi,adxl346.
> Why did we discuss then? Now, I am confused as well...
--
Regards,
Laurent Pinchart
next prev parent reply other threads:[~2015-01-15 20:51 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-15 14:54 [PATCH v2 0/2] Fix OF match for adxl34x driver Laurent Pinchart
2015-01-15 14:54 ` [PATCH v2 1/2] DT: i2c: Deprecate adi,adxl34x compatible string Laurent Pinchart
2015-01-15 17:49 ` Geert Uytterhoeven
[not found] ` <1421333655-31029-2-git-send-email-laurent.pinchart+renesas-ryLnwIuWjnjg/C1BVhZhaw@public.gmane.org>
2015-01-15 17:02 ` Wolfram Sang
2015-01-15 17:27 ` Dmitry Torokhov
2015-01-15 17:32 ` Geert Uytterhoeven
[not found] ` <CAMuHMdW7ETcFGSPiE9BWA2dAE93477fzoyF-+_EaiPSDT9WMWA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-01-15 17:43 ` Wolfram Sang
2015-01-15 17:51 ` Geert Uytterhoeven
2015-01-26 12:09 ` Wolfram Sang
2015-02-26 14:27 ` Laurent Pinchart
2015-03-02 6:40 ` Wolfram Sang
2015-03-02 22:52 ` Laurent Pinchart
2015-01-15 20:51 ` Laurent Pinchart [this message]
2015-01-26 12:12 ` Wolfram Sang
2015-01-15 14:54 ` [PATCH v2 2/2] input: adxl34x: Add OF match support Laurent Pinchart
2015-01-15 16:55 ` Wolfram Sang
[not found] ` <1421333655-31029-3-git-send-email-laurent.pinchart+renesas-ryLnwIuWjnjg/C1BVhZhaw@public.gmane.org>
2015-01-15 17:45 ` Geert Uytterhoeven
[not found] ` <CAMuHMdWmGi6qKKt5YJm1i7FqDceqKosxsSRJRd8zqXO9jMzyoQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-01-15 18:54 ` Dmitry Torokhov
2015-01-15 20:00 ` Geert Uytterhoeven
[not found] ` <CAMuHMdXrRtgAahaEUh8x61E-koE25VL-6LOJrkjx4_fohKQtwQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-01-15 20:34 ` Laurent Pinchart
2015-01-15 21:06 ` Dmitry Torokhov
2015-01-15 21:34 ` Laurent Pinchart
2015-01-15 21:50 ` Dmitry Torokhov
2015-01-15 22:09 ` Laurent Pinchart
2015-01-15 22:05 ` Sergei Shtylyov
-- strict thread matches above, loose matches on Subject: below --
2015-05-21 11:42 [PATCH v2 0/2] Fix OF match for adxl34x driver Geert Uytterhoeven
2015-05-21 11:42 ` [PATCH v2 1/2] DT: i2c: Deprecate adi,adxl34x compatible string Geert Uytterhoeven
2015-05-22 1:32 ` Simon Horman
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=16733840.6Wupp0rKhe@avalon \
--to=laurent.pinchart@ideasonboard.com \
--cc=geert@linux-m68k.org \
--cc=laurent.pinchart+renesas@ideasonboard.com \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-sh@vger.kernel.org \
--cc=wsa@the-dreams.de \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).