Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp2566420imm; Sun, 1 Jul 2018 00:19:51 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfnydBJZei4XWjBAGmAvN0XhpJK863dnFzvWgeNPIPIGA+aykuq8eT+TbKaXjNu7iGJnM6x X-Received: by 2002:a62:8d84:: with SMTP id p4-v6mr7854597pfk.251.1530429591517; Sun, 01 Jul 2018 00:19:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530429591; cv=none; d=google.com; s=arc-20160816; b=aO5ojR76O9LAok5g0Szvp/U6C6+oYlSpETQsHQOour6UOjQjUJYcIszEW6r9mcRo9a j31iPdHUCFJg4xn/RdUSLE68TwwN6RwR2Ycx1kLdRJUpB2T2iGzZh0t6lQQnjZBo0Xe2 aCzxaV4GmqFDQUo0XMEXhPk+bornsrkgAjcr11/CI9vEqPLwyB7zeFmp5XlSy8vIN/+s uc+UIlcs6eUKE7YI+exmHSpN906+QJDDCjhGgPtSu4qlXv+M9tM5SvNBTzvg/3q8PPUq LvZyjK3r60vEuvFBzAsHQ8omkD7mJDvsIpb91xpfJxUGCOHd1lc6wf1bevC/hgCamkWw cqmg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:arc-authentication-results; bh=vhxDa4VoTa9QBc175hD8Ovo7gM1ENxBhqb1wBCky7H4=; b=pDpnXfU7RLy5R75IGDmdmgnlez7wH3Y69C/oMYGXkp1tyzIjmHHzWy7sJUsGTLCcGx SRCztHgBYz/5H9xD8hv36UyIo8Es4IDKZgvYxaxsrjr6UDDouPluvKmhLYFteZThLOiS SiOC3j1fdIahZwB8xgm5pvZXiFZK1yWPgs1humlp+ZcBW908tTcOI+Z6+PJX7bo7gdvB 3rXkhrArBSMEfLoU4rX3RhAyXYGxtr+g9rMOuFhUQWXZuGOfMZ8SNSch9L0QH8YbKzGG c2yiyrAy6OF25+OX9A+ng8PETFsqpNnbHpyznvc/48qwwlWkIQ2PsMoJNMJ5XkLNpoAl M8Kg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r63-v6si12972942plb.366.2018.07.01.00.19.36; Sun, 01 Jul 2018 00:19:51 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752033AbeGAHS1 (ORCPT + 99 others); Sun, 1 Jul 2018 03:18:27 -0400 Received: from www381.your-server.de ([78.46.137.84]:60080 "EHLO www381.your-server.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751450AbeGAHSZ (ORCPT ); Sun, 1 Jul 2018 03:18:25 -0400 Received: from [88.198.220.132] (helo=sslproxy03.your-server.de) by www381.your-server.de with esmtpsa (TLSv1.2:DHE-RSA-AES256-GCM-SHA384:256) (Exim 4.85_2) (envelope-from ) id 1fZWcq-000598-4J; Sun, 01 Jul 2018 09:18:24 +0200 Received: from [188.174.116.212] (helo=[192.168.178.33]) by sslproxy03.your-server.de with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89) (envelope-from ) id 1fZWcp-00013z-RT; Sun, 01 Jul 2018 09:18:23 +0200 Subject: Re: [PATCH] iio: add channel type for frequency To: David Lechner , linux-iio@vger.kernel.org Cc: Jonathan Cameron , Hartmut Knaack , Peter Meerwald-Stadler , linux-kernel@vger.kernel.org References: <20180701025953.3561-1-david@lechnology.com> From: Lars-Peter Clausen Message-ID: <308015e8-d203-c4d1-ba80-3c2adf4b377a@metafoo.de> Date: Sun, 1 Jul 2018 09:18:22 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <20180701025953.3561-1-david@lechnology.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Authenticated-Sender: lars@metafoo.de X-Virus-Scanned: Clear (ClamAV 0.100.0/24712/Sun Jul 1 06:40:19 2018) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 07/01/2018 04:59 AM, David Lechner wrote: > This adds a new type for frequency to the IIO channel type enumeration. > > Units are in Hz. > Documentation? We already have the altvoltage channel type with the frequency attribute. Difficult to say if there are any overlaps without documentation on how this new attribute is supposed to be used. > Signed-off-by: David Lechner > --- > drivers/iio/industrialio-core.c | 1 + > include/uapi/linux/iio/types.h | 1 + > tools/iio/iio_event_monitor.c | 1 + > 3 files changed, 3 insertions(+) > > diff --git a/drivers/iio/industrialio-core.c b/drivers/iio/industrialio-core.c > index 19bdf3d2962a..f3c2c9e4b997 100644 > --- a/drivers/iio/industrialio-core.c > +++ b/drivers/iio/industrialio-core.c > @@ -85,6 +85,7 @@ static const char * const iio_chan_type_name_spec[] = { > [IIO_COUNT] = "count", > [IIO_INDEX] = "index", > [IIO_GRAVITY] = "gravity", > + [IIO_FREQUENCY] = "frequency", > }; > > static const char * const iio_modifier_names[] = { > diff --git a/include/uapi/linux/iio/types.h b/include/uapi/linux/iio/types.h > index 4213cdf88e3c..9fee86e2046f 100644 > --- a/include/uapi/linux/iio/types.h > +++ b/include/uapi/linux/iio/types.h > @@ -44,6 +44,7 @@ enum iio_chan_type { > IIO_COUNT, > IIO_INDEX, > IIO_GRAVITY, > + IIO_FREQUENCY, > }; > > enum iio_modifier { > diff --git a/tools/iio/iio_event_monitor.c b/tools/iio/iio_event_monitor.c > index b61245e1181d..c3ef20057d52 100644 > --- a/tools/iio/iio_event_monitor.c > +++ b/tools/iio/iio_event_monitor.c > @@ -58,6 +58,7 @@ static const char * const iio_chan_type_name_spec[] = { > [IIO_PH] = "ph", > [IIO_UVINDEX] = "uvindex", > [IIO_GRAVITY] = "gravity", > + [IIO_FREQUENCY] = "frequency", > }; > > static const char * const iio_ev_type_text[] = { >