projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f233dbc
)
pinctrl: sunxi: Use macros from bindings header file for DT parsing
author
Maxime Ripard
<
[email protected]
>
Tue, 11 Oct 2016 15:46:00 +0000
(17:46 +0200)
committer
Linus Walleij
<
[email protected]
>
Mon, 24 Oct 2016 14:30:14 +0000
(16:30 +0200)
Since we have some bindings header for our hardcoded flags, let's use them
when we can.
Acked-by: Chen-Yu Tsai <
[email protected]
>
Signed-off-by: Maxime Ripard <
[email protected]
>
Signed-off-by: Linus Walleij <
[email protected]
>
drivers/pinctrl/sunxi/pinctrl-sunxi.c
patch
|
blob
|
history
diff --git
a/drivers/pinctrl/sunxi/pinctrl-sunxi.c
b/drivers/pinctrl/sunxi/pinctrl-sunxi.c
index cf7eb799c6deefa43837f6a2a8b19333656efd40..62a9d012b35f5990e149691021f0536444c47cf3 100644
(file)
--- a/
drivers/pinctrl/sunxi/pinctrl-sunxi.c
+++ b/
drivers/pinctrl/sunxi/pinctrl-sunxi.c
@@
-28,6
+28,8
@@
#include <linux/platform_device.h>
#include <linux/slab.h>
+#include <dt-bindings/pinctrl/sun4i-a10.h>
+
#include "../core.h"
#include "pinctrl-sunxi.h"
@@
-163,9
+165,9
@@
static int sunxi_pctrl_parse_bias_prop(struct device_node *node)
return -EINVAL;
switch (val) {
- case
1
:
+ case
SUN4I_PINCTRL_PULL_UP
:
return PIN_CONFIG_BIAS_PULL_UP;
- case
2
:
+ case
SUN4I_PINCTRL_PULL_DOWN
:
return PIN_CONFIG_BIAS_PULL_DOWN;
}