summaryrefslogtreecommitdiffstats
path: root/drivers/pwm/pwm-pca9685.c
diff options
context:
space:
mode:
authorDavid Jander <david@protonic.nl>2020-08-28 14:14:14 +0200
committerThierry Reding <thierry.reding@gmail.com>2020-09-24 09:18:13 +0200
commite1057a8df16503b8d08e75d9258e6026ef88a06d (patch)
tree91c0b6f7bdbaa0e8ff5ad4503967c76fc1ccbe31 /drivers/pwm/pwm-pca9685.c
parentpwm: pca9685: Make comments more consistent (diff)
downloadlinux-e1057a8df16503b8d08e75d9258e6026ef88a06d.tar.xz
linux-e1057a8df16503b8d08e75d9258e6026ef88a06d.zip
pwm: pca9685: Use BIT() macro instead of shift
Signed-off-by: David Jander <david@protonic.nl> Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
Diffstat (limited to 'drivers/pwm/pwm-pca9685.c')
-rw-r--r--drivers/pwm/pwm-pca9685.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/pwm/pwm-pca9685.c b/drivers/pwm/pwm-pca9685.c
index 0f1a3e07e501..9d1d9dece0c0 100644
--- a/drivers/pwm/pwm-pca9685.c
+++ b/drivers/pwm/pwm-pca9685.c
@@ -57,10 +57,10 @@
#define PCA9685_NUMREGS 0xFF
#define PCA9685_MAXCHAN 0x10
-#define LED_FULL (1 << 4)
-#define MODE1_SLEEP (1 << 4)
-#define MODE2_INVRT (1 << 4)
-#define MODE2_OUTDRV (1 << 2)
+#define LED_FULL BIT(4)
+#define MODE1_SLEEP BIT(4)
+#define MODE2_INVRT BIT(4)
+#define MODE2_OUTDRV BIT(2)
#define LED_N_ON_H(N) (PCA9685_LEDX_ON_H + (4 * (N)))
#define LED_N_ON_L(N) (PCA9685_LEDX_ON_L + (4 * (N)))