Skip to content

Commit

Permalink
Staging: olpc_dcon.c: obsolete use of strict_stroul
Browse files Browse the repository at this point in the history
As Dan mentioned, dcon_write() will only write u16 values. The
appropriate parts have been changed. As a result of module_param()
not accepting u16 as a valid data type, ushort is used.

Signed-off-by: Valentin Rothberg <valentinrothberg@googlemail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Valentin Rothberg authored and Greg Kroah-Hartman committed Dec 8, 2011
1 parent 88e09a5 commit c542341
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions drivers/staging/olpc_dcon/olpc_dcon.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@

/* Module definitions */

static int resumeline = 898;
module_param(resumeline, int, 0444);
static ushort resumeline = 898;
module_param(resumeline, ushort, 0444);

/* Default off since it doesn't work on DCON ASIC in B-test OLPC board */
static int useaa = 1;
Expand Down Expand Up @@ -498,10 +498,10 @@ static ssize_t dcon_freeze_store(struct device *dev,
static ssize_t dcon_resumeline_store(struct device *dev,
struct device_attribute *attr, const char *buf, size_t count)
{
unsigned long rl;
unsigned short rl;
int rc;

rc = strict_strtoul(buf, 10, &rl);
rc = kstrtou16(buf, 10, &rl);
if (rc)
return rc;

Expand Down

0 comments on commit c542341

Please sign in to comment.