diff options
author | Thierry Reding <thierry.reding@avionic-design.de> | 2012-04-12 13:26:01 +0200 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2012-08-17 07:35:41 +0200 |
commit | f9c4a31f61501d25f0a45faae6a5cd701ad5694a (patch) | |
tree | fc98b2e1357f7374a5384615f12fb2e9e7d25d37 /drivers/gpio/gpio-ml-ioh.c | |
parent | d9875690d9b89a866022ff49e3fcea892345ad92 (diff) | |
download | op-kernel-dev-f9c4a31f61501d25f0a45faae6a5cd701ad5694a.zip op-kernel-dev-f9c4a31f61501d25f0a45faae6a5cd701ad5694a.tar.gz |
gpiolib: Use seq_file's iterator interface
When dumping a collection of items via seq_file, it is recommended to
use the iterator interface. For the gpiolib debugfs interface this can
be done to dump each GPIO chip in turn.
Note that for gpiolib this is a little cumbersome because it does not
provide a list of registered GPIO chips and the only way to iterate is
over each GPIO individually. Once a chip is found, the number of GPIOs
it provides can be skipped as a small optimization.
This patch was requested by Arnd Bergmann here:
http://article.gmane.org/gmane.linux.ports.tegra/3535
Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Cc: Linus Walleij <linus.walleij@stericsson.com>
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: linux-kernel@vger.kernel.org
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/gpio-ml-ioh.c')
0 files changed, 0 insertions, 0 deletions