linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] tools: iio: lsiio: enumerate processed channels
@ 2016-08-02  2:39 Matt Ranostay
  2016-08-15 17:33 ` Jonathan Cameron
  0 siblings, 1 reply; 2+ messages in thread
From: Matt Ranostay @ 2016-08-02  2:39 UTC (permalink / raw)
  To: linux-iio; +Cc: jic23, Matt Ranostay

Enumerate the processed channels (e.g. *_input) as well the raw channels.

Signed-off-by: Matt Ranostay <mranostay@gmail.com>
---
 tools/iio/lsiio.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tools/iio/lsiio.c b/tools/iio/lsiio.c
index 3d650e668252..ab0f5cf16025 100644
--- a/tools/iio/lsiio.c
+++ b/tools/iio/lsiio.c
@@ -51,7 +51,8 @@ static int dump_channels(const char *dev_dir_name)
 
 	while (ent = readdir(dp), ent)
 		if (check_prefix(ent->d_name, "in_") &&
-		    check_postfix(ent->d_name, "_raw"))
+		   (check_postfix(ent->d_name, "_raw") ||
+		    check_postfix(ent->d_name, "_input")))
 			printf("   %-10s\n", ent->d_name);
 
 	return (closedir(dp) == -1) ? -errno : 0;
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] tools: iio: lsiio: enumerate processed channels
  2016-08-02  2:39 [PATCH] tools: iio: lsiio: enumerate processed channels Matt Ranostay
@ 2016-08-15 17:33 ` Jonathan Cameron
  0 siblings, 0 replies; 2+ messages in thread
From: Jonathan Cameron @ 2016-08-15 17:33 UTC (permalink / raw)
  To: Matt Ranostay, linux-iio

On 02/08/16 03:39, Matt Ranostay wrote:
> Enumerate the processed channels (e.g. *_input) as well the raw channels.
> 
> Signed-off-by: Matt Ranostay <mranostay@gmail.com>
Applied to the togreg branch of iio.git

Thanks,

Jonathan
> ---
>  tools/iio/lsiio.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/tools/iio/lsiio.c b/tools/iio/lsiio.c
> index 3d650e668252..ab0f5cf16025 100644
> --- a/tools/iio/lsiio.c
> +++ b/tools/iio/lsiio.c
> @@ -51,7 +51,8 @@ static int dump_channels(const char *dev_dir_name)
>  
>  	while (ent = readdir(dp), ent)
>  		if (check_prefix(ent->d_name, "in_") &&
> -		    check_postfix(ent->d_name, "_raw"))
> +		   (check_postfix(ent->d_name, "_raw") ||
> +		    check_postfix(ent->d_name, "_input")))
>  			printf("   %-10s\n", ent->d_name);
>  
>  	return (closedir(dp) == -1) ? -errno : 0;
> 


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-08-15 17:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-08-02  2:39 [PATCH] tools: iio: lsiio: enumerate processed channels Matt Ranostay
2016-08-15 17:33 ` Jonathan Cameron

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).