diff options
Diffstat (limited to 'drivers/video/omap2/displays/panel-tpo-td043mtea1.c')
-rw-r--r-- | drivers/video/omap2/displays/panel-tpo-td043mtea1.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/video/omap2/displays/panel-tpo-td043mtea1.c b/drivers/video/omap2/displays/panel-tpo-td043mtea1.c index dbe9d43b4850..2462b9ec6662 100644 --- a/drivers/video/omap2/displays/panel-tpo-td043mtea1.c +++ b/drivers/video/omap2/displays/panel-tpo-td043mtea1.c | |||
@@ -17,7 +17,7 @@ | |||
17 | #include <linux/err.h> | 17 | #include <linux/err.h> |
18 | #include <linux/slab.h> | 18 | #include <linux/slab.h> |
19 | 19 | ||
20 | #include <plat/display.h> | 20 | #include <video/omapdss.h> |
21 | 21 | ||
22 | #define TPO_R02_MODE(x) ((x) & 7) | 22 | #define TPO_R02_MODE(x) ((x) & 7) |
23 | #define TPO_R02_MODE_800x480 7 | 23 | #define TPO_R02_MODE_800x480 7 |
@@ -144,13 +144,15 @@ static ssize_t tpo_td043_vmirror_store(struct device *dev, | |||
144 | struct device_attribute *attr, const char *buf, size_t count) | 144 | struct device_attribute *attr, const char *buf, size_t count) |
145 | { | 145 | { |
146 | struct tpo_td043_device *tpo_td043 = dev_get_drvdata(dev); | 146 | struct tpo_td043_device *tpo_td043 = dev_get_drvdata(dev); |
147 | long val; | 147 | int val; |
148 | int ret; | 148 | int ret; |
149 | 149 | ||
150 | ret = strict_strtol(buf, 0, &val); | 150 | ret = kstrtoint(buf, 0, &val); |
151 | if (ret < 0) | 151 | if (ret < 0) |
152 | return ret; | 152 | return ret; |
153 | 153 | ||
154 | val = !!val; | ||
155 | |||
154 | ret = tpo_td043_write_mirror(tpo_td043->spi, tpo_td043->hmirror, val); | 156 | ret = tpo_td043_write_mirror(tpo_td043->spi, tpo_td043->hmirror, val); |
155 | if (ret < 0) | 157 | if (ret < 0) |
156 | return ret; | 158 | return ret; |
@@ -175,7 +177,7 @@ static ssize_t tpo_td043_mode_store(struct device *dev, | |||
175 | long val; | 177 | long val; |
176 | int ret; | 178 | int ret; |
177 | 179 | ||
178 | ret = strict_strtol(buf, 0, &val); | 180 | ret = kstrtol(buf, 0, &val); |
179 | if (ret != 0 || val & ~7) | 181 | if (ret != 0 || val & ~7) |
180 | return -EINVAL; | 182 | return -EINVAL; |
181 | 183 | ||