[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20230528161255.216fee6f@jic23-huawei>
Date: Sun, 28 May 2023 16:12:55 +0100
From: Jonathan Cameron <jic23@...nel.org>
To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc: George Stark <gnstark@...rdevices.ru>, lars@...afoo.de,
neil.armstrong@...aro.org, khilman@...libre.com,
jbrunet@...libre.com, martin.blumenstingl@...glemail.com,
nuno.sa@...log.com, linux-iio@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
linux-amlogic@...ts.infradead.org, kernel@...rdevices.ru
Subject: Re: [PATCH v2] meson saradc: add iio device attrib to switch
channel 7 mux
On Sun, 28 May 2023 13:55:20 +0300
Andy Shevchenko <andriy.shevchenko@...ux.intel.com> wrote:
> On Sun, May 28, 2023 at 01:46:37PM +0300, Andy Shevchenko wrote:
> > On Sun, May 28, 2023 at 12:48:54AM +0300, George Stark wrote:
>
> ...
>
> > > +static const char * const chan7_vol[] = {
> > > + "gnd",
> > > + "vdd/4",
> > > + "vdd/2",
> > > + "vdd*3/4",
> > > + "vdd",
> > > + "ch7_input",
> > > +};
>
> One more thing to discuss (Jonathan, what's your opinion?) I think the
> following easier to understand and has less problematic characters in the names
> (in case of sysfs direct use from shelll):
I suspect no one would use these particulary inputs directly from the shell,
but agreed that avoiding / where not absolutely necessary is a good idea.
Jonathan
>
> static const char * const chan7_vol[] = {
> "gnd", // alternatively GND
> "0.25vdd", // alternatively 0.25_vdd, 0.25Vdd, 0.25_Vdd
> "0.5vdd",
> "0.75vdd",
> "vdd", // Vdd
> "ch7_input",
> };
>
> That said, my personal preference:
>
> static const char * const chan7_vol[] = {
> "GND",
> "0.25Vdd",
> "0.5Vdd",
> "0.75Vdd",
> "Vdd",
> "ch7_input",
> };
>
Powered by blists - more mailing lists