summaryrefslogtreecommitdiffstats
path: root/drivers/video/bfin_adv7393fb.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-06-16 16:59:05 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2012-06-16 16:59:05 -0700
commit88c144b12a943d35500dbfc141c9b33955d2a88a (patch)
tree5dd943ac3dd80d2c8e7f1af468314468dba541cd /drivers/video/bfin_adv7393fb.c
parent9b15b817f3d62409290fd56fe3cbb076a931bb0a (diff)
parentb67989515defba7412acff01162e5bb1f0f5923a (diff)
Merge tag 'fbdev-fixes-for-3.5-1' of git://github.com/schandinat/linux-2.6
Pull fbdev fixes from Florian Tobias Schandinat: - two fixes for s3c-fb by Jingoo Han (including a fix for a potential division by zero) - a couple of randconfig fixes by Arnd Bergmann - a cleanup for bfin_adv7393fb by Emil Goode * tag 'fbdev-fixes-for-3.5-1' of git://github.com/schandinat/linux-2.6: video: s3c-fb: fix possible division by zero in s3c_fb_calc_pixclk video: s3c-fb: clear SHADOWCON register when clearing hardware window registers drivers/tosa: driver needs I2C and SPI to compile drivers/savagefb: use mdelay instead of udelay video/console: automatically select a font video/ili9320: do not mark exported functions __devexit drivers/video: use correct __devexit_p annotation video: bfin_adv7393fb: Convert to kstrtouint_from_user
Diffstat (limited to 'drivers/video/bfin_adv7393fb.c')
-rw-r--r--drivers/video/bfin_adv7393fb.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/video/bfin_adv7393fb.c b/drivers/video/bfin_adv7393fb.c
index 33ea874c87d..9bdd4b0c18c 100644
--- a/drivers/video/bfin_adv7393fb.c
+++ b/drivers/video/bfin_adv7393fb.c
@@ -353,18 +353,16 @@ adv7393_read_proc(char *page, char **start, off_t off,
static int
adv7393_write_proc(struct file *file, const char __user * buffer,
- unsigned long count, void *data)
+ size_t count, void *data)
{
struct adv7393fb_device *fbdev = data;
- char line[8];
unsigned int val;
int ret;
- ret = copy_from_user(line, buffer, count);
+ ret = kstrtouint_from_user(buffer, count, 0, &val);
if (ret)
return -EFAULT;
- val = simple_strtoul(line, NULL, 0);
adv7393_write(fbdev->client, val >> 8, val & 0xff);
return count;