Re: [PATCH 2/2] tools/gpio: add the gpio-hammer tool

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jun 01, 2016 at 11:40:04PM +0200, Linus Walleij wrote:
> On Wed, Jun 1, 2016 at 8:09 PM, Michael Welling <mwelling@xxxxxxxx> wrote:
> 
> > Is there a way to name a group of GPIOs?
> 
> Do you mean from the producer side or the consumer side?

Producer side is what I am thinking.

> There is gpio-line-names in DT for the producer side.
> 
The gpio-line-names are naming individual GPIO on a controller.
I am looking to take a set of GPIOs and name them as a group and
be able to access them by that name. Either individually or
simultaneously.
 
> From the consumer side the same consumer name will be used
> on all lines if more than one is selected, which I think makes
> sense. (It's just a label after all.)
> 
> > It seems you are passing around a byte of data for each GPIO state.
> > Is there a reason why the bits couldn't bit masked into single variable
> > given the max number of handles is 64?
> 
> Sorry not following, I guess you need to post me some part of
> the patch or so...

+       fprintf(stdout, "] on %s, initial states: [", device_name);
+       for (i = 0; i < nlines; i++) {
+               fprintf(stdout, "%d", data.values[i]);

data.values[i];

Each bit is stored in a byte.

> 
> Yours,
> Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-gpio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux