Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1379224 > unrolled thread
| Started by | Boris Brezillon <boris.brezillon@free-electrons.com> |
|---|---|
| First post | 2016-04-14 21:20 +0200 |
| Last post | 2016-04-14 21:20 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH v5 24/24] pwm: add information about polarity, duty cycle and period to debugfs Boris Brezillon <boris.brezillon@free-electrons.com> - 2016-04-14 21:20 +0200
| From | Boris Brezillon <boris.brezillon@free-electrons.com> |
|---|---|
| Date | 2016-04-14 21:20 +0200 |
| Subject | [PATCH v5 24/24] pwm: add information about polarity, duty cycle and period to debugfs |
| Message-ID | <rnUY1-71M-17@gated-at.bofh.it> |
From: Heiko Stübner <heiko@sntech.de> The pwm-states make it possible to also output the polarity, duty cycle and period information in the debugfs pwm summary-outout. This makes it easier to gather overview information about pwms without needing to walk through the sysfs attributes of every pwm. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> --- drivers/pwm/core.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/pwm/core.c b/drivers/pwm/core.c index aefffcf..9f4e97e 100644 --- a/drivers/pwm/core.c +++ b/drivers/pwm/core.c @@ -959,6 +959,11 @@ static void pwm_dbg_show(struct pwm_chip *chip, struct seq_file *s) if (state.enabled) seq_puts(s, " enabled"); + seq_printf(s, " period:%uns", state.period); + seq_printf(s, " duty:%uns", state.duty_cycle); + seq_printf(s, " polarity:%s", + state.polarity ? "inverse" : "normal"); + seq_puts(s, "\n"); } } -- 2.5.0
Back to top | Article view | linux.kernel
csiph-web