From: Thierry Reding Date: Thu, 12 Apr 2012 11:26:01 +0000 (+0200) Subject: gpiolib: Use seq_file's iterator interface X-Git-Tag: omap-for-v3.7-rc1/fixes-cpufreq-signed~45^2~33 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f9c4a31f61501d25f0a45faae6a5cd701ad5694a;p=pandora-kernel.git 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 Cc: Linus Walleij Cc: Grant Likely Cc: linux-kernel@vger.kernel.org Reviewed-by: Arnd Bergmann Signed-off-by: Linus Walleij --- Reading git-diff-tree failed