From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_PASS,URIBL_BLOCKED,USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1A7D1C10F13 for ; Mon, 8 Apr 2019 21:55:46 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id DC4AE20880 for ; Mon, 8 Apr 2019 21:55:45 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="J5wqmpDv" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DC4AE20880 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ucw.cz Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender:Content-Type:Cc: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=psDv9ueM3Q1yx49V1gXWcLSUyd/3/V5Va7sYAXeowiI=; b=J5wqmpDvtSOtZkdxzSaPhN9/6 A3U2TrCxP15blTAaTevgo2mwwWpX4nLKxOhq0vwZxGSol3m/yxtNlAHzBu5wf3LFyK1pUY9t+GsgN YvnC+6JzZNO9823f+TO8fGwL0aqHTz+rDozATgKjI9NG5NjN3hXAUMxsqhVYUCg2gdxYFg0NfOdSI wqHekpS1qJTKqKeORMNfgycJeyB63YksV8zr6d/oQ8TmdbRBQFeJbC4bCl88q4Xb7tgysGfSqL0Mf EScuGydbKWDVAJb9tkmyymbGgrAoFZzND87Qfmy9xnWDg5IHLIiTqnANaXsHa4SWD8UW3xcd+eqj4 LUjQBpusA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hDcEw-00043A-CR; Mon, 08 Apr 2019 21:55:42 +0000 Received: from atrey.karlin.mff.cuni.cz ([195.113.26.193]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hDcEn-0003tm-Rf for linux-arm-kernel@lists.infradead.org; Mon, 08 Apr 2019 21:55:37 +0000 Received: by atrey.karlin.mff.cuni.cz (Postfix, from userid 512) id 41158806A6; Mon, 8 Apr 2019 23:55:24 +0200 (CEST) Date: Mon, 8 Apr 2019 23:55:31 +0200 From: Pavel Machek To: William Breathitt Gray Subject: Re: [PATCH v10 02/18] counter: Documentation: Add Generic Counter sysfs documentation Message-ID: <20190408215531.GB27592@amd> References: MIME-Version: 1.0 In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190408_145534_317210_7E1E4BEC X-CRM114-Status: GOOD ( 22.00 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: mark.rutland@arm.com, benjamin.gaignard@st.com, linux-pwm@vger.kernel.org, linux-iio@vger.kernel.org, patrick.havelange@essensium.com, thierry.reding@gmail.com, pmeerw@pmeerw.net, lars@metafoo.de, daniel.lezcano@linaro.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, david@lechnology.com, linuxppc-dev@lists.ozlabs.org, robh+dt@kernel.org, Jonathan Cameron , tglx@linutronix.de, fabrice.gasnier@st.com, esben@haabendal.dk, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, leoyang.li@nxp.com, knaack.h@gmx.de, akpm@linux-foundation.org, shawnguo@kernel.org, jic23@kernel.org Content-Type: multipart/mixed; boundary="===============0197562935868251863==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============0197562935868251863== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="JP+T4n/bALQSJXh8" Content-Disposition: inline --JP+T4n/bALQSJXh8 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue 2019-04-02 15:30:37, William Breathitt Gray wrote: > This patch adds standard documentation for the userspace sysfs > attributes of the Generic Counter interface. >=20 > Reviewed-by: Jonathan Cameron > Signed-off-by: William Breathitt Gray > --- > Documentation/ABI/testing/sysfs-bus-counter | 230 ++++++++++++++++++++ > MAINTAINERS | 1 + > 2 files changed, 231 insertions(+) > create mode 100644 Documentation/ABI/testing/sysfs-bus-counter >=20 > diff --git a/Documentation/ABI/testing/sysfs-bus-counter b/Documentation/= ABI/testing/sysfs-bus-counter > new file mode 100644 > index 000000000000..566bd99fe0a5 > --- /dev/null > +++ b/Documentation/ABI/testing/sysfs-bus-counter > @@ -0,0 +1,230 @@ > +What: /sys/bus/counter/devices/counterX/countY/count > +KernelVersion: 5.2 > +Contact: linux-iio@vger.kernel.org > +Description: > + Count data of Count Y represented as a string. > + > +What: /sys/bus/counter/devices/counterX/countY/ceiling > +KernelVersion: 5.2 > +Contact: linux-iio@vger.kernel.org > +Description: > + Count value ceiling for Count Y. This is the upper limit for the > + respective counter. > + > +What: /sys/bus/counter/devices/counterX/countY/floor > +KernelVersion: 5.2 > +Contact: linux-iio@vger.kernel.org > +Description: > + Count value floor for Count Y. This is the lower limit for the > + respective counter. > + > +What: /sys/bus/counter/devices/counterX/countY/count_mode > +KernelVersion: 5.2 > +Contact: linux-iio@vger.kernel.org > +Description: > + Count mode for channel Y. The ceiling and floor values for > + Count Y are used by the count mode where required. The following > + count modes are available: > + > + normal: > + Counting is continuous in either direction. > + > + range limit: > + An upper or lower limit is set, mimicking limit switches > + in the mechanical counterpart. The upper limit is set to > + the Count Y ceiling value, while the lower limit is set > + to the Count Y floor value. The counter freezes at > + count =3D ceiling when counting up, and at count =3D floor > + when counting down. At either of these limits, the > + counting is resumed only when the count direction is > + reversed. > + > + non-recycle: > + The counter is disabled whenever a counter overflow or > + underflow takes place. The counter is re-enabled when a > + new count value is loaded to the counter via a preset > + operation or direct write. > + > + modulo-n: > + A count value boundary is set between the Count Y floor > + value and the Count Y ceiling value. The counter is > + reset to the Count Y floor value at count =3D ceiling when > + counting up, while the counter is set to the Count Y > + ceiling value at count =3D floor when counting down; the > + counter does not freeze at the boundary points, but > + counts continuously throughout. > + > +What: /sys/bus/counter/devices/counterX/countY/count_mode_available > +What: /sys/bus/counter/devices/counterX/countY/error_noise_available > +What: /sys/bus/counter/devices/counterX/countY/function_available > +What: /sys/bus/counter/devices/counterX/countY/signalZ_action_available > +KernelVersion: 5.2 > +Contact: linux-iio@vger.kernel.org > +Description: > + Discrete set of available values for the respective Count Y > + configuration are listed in this file. Values are delimited by > + newline characters. Elsewhere in sysfs we do space-separated: pavel@amd:~$ cat /sys/power/state freeze mem disk And we use [] to mark current selection: pavel@amd:~$ cat /sys/class/leds/tpacpi\:\:thinkvantage/trigger [none] bluetooth-power rfkill-any rfkill-none kbd-scrolllock kbd-numlock kbd-capslock kbd-kanalock kbd-shiftlock kbd-altgrlock kbd-ctrllock kbd-altlock kbd-shiftllock kbd-shiftrlock kbd-ctrlllock kbd-ctrlrlock AC-online BAT0-charging-or-full BAT0-charging BAT0-full BAT0-charging-blink-full-solid rfkill0 phy0rx phy0tx phy0assoc phy0radio phy0tpt mmc0 timer heartbeat audio-mute audio-micmute rfkill1 Note this only works if you have less than PAGE_SIZE of entries... and will never have more. Pavel --=20 (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blo= g.html --JP+T4n/bALQSJXh8 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iEYEARECAAYFAlyrw1MACgkQMOfwapXb+vIrJACdGzny2kYErlj2vHsj5g0+nisf vFUAn2r0eo4ejc8ifXJmGFrOjikVszOA =36BY -----END PGP SIGNATURE----- --JP+T4n/bALQSJXh8-- --===============0197562935868251863== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============0197562935868251863==--