From: Sean Wang <sean.wang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
To: Matthias Brugger <matthias.bgg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: herbert-lOAM2aK0SrRLBo1qDEOMRrpzq4S04n8Q@public.gmane.org,
mpm-VDJrAJ4Gl5ZBDgjK7y7TUQ@public.gmane.org,
robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
mark.rutland-5wv7dgnIgG8@public.gmane.org,
clabbe.montjoie-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
prasannatsmkumar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
romain.perier-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org,
shannon.nelson-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org,
devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
keyhaede-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
linux-crypto-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
weiyongjun1-hv44wF8Li93QT0dZR+AlfA@public.gmane.org,
linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [PATCH 1/4] dt-bindings: rng: add generic bindings for MediaTek SoCs
Date: Wed, 7 Jun 2017 21:20:19 +0800 [thread overview]
Message-ID: <1496841619.30833.5.camel@mtkswgap22> (raw)
In-Reply-To: <9eb87222-ca89-0abb-4532-3887008f6e7a-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
On Tue, 2017-06-06 at 13:07 +0200, Matthias Brugger wrote:
>
> On 31/05/17 20:44, sean.wang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org wrote:
> > From: Sean Wang <sean.wang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
> >
> > Add the generic binding for allowing the support of RNG on MediaTek SoCs
> > such as MT7622.
> >
> > Signed-off-by: Sean Wang <sean.wang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
> > ---
> > Documentation/devicetree/bindings/rng/mtk-rng.txt | 3 ++-
> > 1 file changed, 2 insertions(+), 1 deletion(-)
> >
> > diff --git a/Documentation/devicetree/bindings/rng/mtk-rng.txt b/Documentation/devicetree/bindings/rng/mtk-rng.txt
> > index a6d62a2..0772913 100644
> > --- a/Documentation/devicetree/bindings/rng/mtk-rng.txt
> > +++ b/Documentation/devicetree/bindings/rng/mtk-rng.txt
> > @@ -2,7 +2,8 @@ Device-Tree bindings for Mediatek random number generator
> > found in Mediatek SoC family
> >
> > Required properties:
> > -- compatible : Should be "mediatek,mt7623-rng"
> > +- compatible : Should be "mediatek,generic-rng" or
> > + "mediatek,mt7623-rng".
>
> What does generic-rng mean. Is it for all mt7xxx, or also for mt6xxx and
> mt8xxx based SoCs? I think we should stick with SoC specific bindings,
> as we don't know if Mediatek won't publish a new IP block next year
> which is differnet.
>
Yes, what I mean is generic-rng can be applied to all
platform MediaTek provides.
> Just in case we should add a binding for the actual SoC + a fallback.
> For example.
> - compatible " Should be
> "mediatek,mt7622-rng", "mediatek,mt7623-rng" for SoC mt7622
> "mediatek,mt7623-rng" for SoC mt7623
>
> This will also eliminate the need of adding mt6722-rng to the driver, as
> it will use mt7623-rng as fallback. If in the future we realize that
> mt7622-rng has a extra feature/bug, we can still work around it, without
> breaking the bindings.
>
I knew the fallback rules you said here because I saw them being used in
many drivers such as sysirq and uart driver, such kind of basic drivers.
These drivers are basic enough, various following chipsets almost fall
back into the oldest one. So the clues let me think the hardware
interface shouldn't have too much differences among them.
If there is string used like generic-uart or generic-sysirq, it can
stop we blindly add new string into the binding document when a new
platform is introduced.
And they easily allows users unfamiliar MediaTek platform (they didn't
know what the oldest MediaTek chipset is) pick up the right compatible
string to start bring up the new platform.
The specific one can be added after new feature required is added or
critical hardware bug is found. Otherwise the generic one can fit
all generic needs for those.
Those are only opinions, if you don't like it, I still can accept the
original way as you suggest :)
> Makes sense?
>
> Regards,
> Matthias
>
> > - clocks : list of clock specifiers, corresponding to
> > entries in clock-names property;
> > - clock-names : Should contain "rng" entries;
> >
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2017-06-07 13:20 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <cover.1496255334.git.sean.wang@mediatek.com>
[not found] ` <cover.1496255334.git.sean.wang-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>
2017-05-31 18:44 ` [PATCH 1/4] dt-bindings: rng: add generic bindings for MediaTek SoCs sean.wang-NuS5LvNUpcJWk0Htik3J/w
2017-06-06 11:07 ` Matthias Brugger
[not found] ` <9eb87222-ca89-0abb-4532-3887008f6e7a-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-06-07 13:20 ` Sean Wang [this message]
2017-06-07 13:25 ` Matthias Brugger
[not found] ` <a8b797e9-db6f-7f92-2cee-72d456815310-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2017-06-07 14:48 ` Sean Wang
2017-05-31 18:44 ` [PATCH 2/4] hwrng: mtk - add support for MT7622 SoC sean.wang
2017-05-31 18:44 ` [PATCH 3/4] hwrng: mtk - add runtime PM support sean.wang
2017-05-31 18:44 ` [PATCH 4/4] MAINTAINERS: add entry for MediaTek Random Number Generator sean.wang
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=1496841619.30833.5.camel@mtkswgap22 \
--to=sean.wang-nus5lvnupcjwk0htik3j/w@public.gmane.org \
--cc=clabbe.montjoie-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=herbert-lOAM2aK0SrRLBo1qDEOMRrpzq4S04n8Q@public.gmane.org \
--cc=keyhaede-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=linux-crypto-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
--cc=matthias.bgg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=mpm-VDJrAJ4Gl5ZBDgjK7y7TUQ@public.gmane.org \
--cc=prasannatsmkumar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=romain.perier-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org \
--cc=shannon.nelson-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
--cc=weiyongjun1-hv44wF8Li93QT0dZR+AlfA@public.gmane.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 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).