[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190225172519.GD13898@sirena.org.uk>
Date: Mon, 25 Feb 2019 17:25:19 +0000
From: Mark Brown <broonie@...nel.org>
To: Olliver Schinagl <oliver@...inagl.nl>
Cc: Axel Lin <axel.lin@...ics.com>, Chen-Yu Tsai <wens@...e.org>,
Priit Laes <plaes@...es.org>,
Liam Girdwood <lgirdwood@...il.com>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] regulator: axp20x: Get rid of AXP20X_xxx_START/END/STEPS
defines
On Sat, Feb 23, 2019 at 09:37:01PM +0100, Olliver Schinagl wrote:
> In any case, you seem like a smart person that reads and writes hex and
> bits often enough. This is not true for everyone. I can just as easily
> reverse your arguments of course, for example, 'each field has a well
> known meaning' ... to whom? People that use these things daily, sure.
> People who just need to double check something or modify something, not
> so much. They have to look up the MACRO, the struct its in, compare it
> to others, so as you can see, what is natural for you, is not true for
> everyone. :)
> Also, the general consensus is still to avoid magic values, and to stay
> consistent with the rest and not make expceptions, it makes sense to
> have defines instead of magic values.
If you find you need to describe what the fields are it would be much
more constructive to add a comment at the top of the table saying what
they are. As things are this isn't helping anyone - as a big pile of
defines it's hard to read the values without context for how they're
used and if you're looking at the table you can't tell what the
regulator actually supports without going and decoding the defines.
Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)
Powered by blists - more mailing lists