[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20200405192246.3741784-2-oleksandr.suvorov@toradex.com>
Date: Sun, 5 Apr 2020 22:22:41 +0300
From: Oleksandr Suvorov <oleksandr.suvorov@...adex.com>
To: devicetree@...r.kernel.org
Cc: Paul Barker <pbarker@...sulko.com>,
Marcel Ziswiler <marcel.ziswiler@...adex.com>,
Igor Opaniuk <igor.opaniuk@...adex.com>,
Philippe Schenker <philippe.schenker@...adex.com>,
Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>,
Oleksandr Suvorov <oleksandr.suvorov@...adex.com>,
Rob Herring <robh+dt@...nel.org>, linux-kernel@...r.kernel.org
Subject: [RFC PATCH v2 1/6] dt-bindings: pwm: add PWM_NOFLAGS definition
"pwms" property has the optional 3rd cell for modification flags,
i.e. the flag for inverted polarity. Multiple pwms instances in child
nodes all have to have or haven't this flags property. Now the value
"no flags" codes with the raw constant "0".
Define the PWM_NOFLAGS to use instead of the raw "0" value.
Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@...adex.com>
---
Changes in v2:
- Rename PWM_POLARITY_NORMAL to PWM_NOFLAGS to avoid possible
conflict with enum pwm_polarity in <linux/pwm.h>. Also, this name
reflects the sense of this value more precisely.
include/dt-bindings/pwm/pwm.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/dt-bindings/pwm/pwm.h b/include/dt-bindings/pwm/pwm.h
index ab9a077e3c7d..f4cc763e159a 100644
--- a/include/dt-bindings/pwm/pwm.h
+++ b/include/dt-bindings/pwm/pwm.h
@@ -10,6 +10,7 @@
#ifndef _DT_BINDINGS_PWM_PWM_H
#define _DT_BINDINGS_PWM_PWM_H
+#define PWM_NOFLAGS 0
#define PWM_POLARITY_INVERTED (1 << 0)
#endif
--
2.24.1
Powered by blists - more mailing lists