Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 322267
b: refs/heads/master
c: 127c6e7
h: refs/heads/master
i:
  322265: 2541bd9
  322263: 1a5fd0a
v: v3
  • Loading branch information
Tiejun Chen authored and Kumar Gala committed Aug 17, 2012
1 parent 3331af1 commit cb2f51a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 09a3017a585eb8567a7de15b426bb1dfb548bf0f
refs/heads/master: 127c6e731106a2071ee4a6c5a34c471cd3e719f0
7 changes: 3 additions & 4 deletions trunk/drivers/watchdog/booke_wdt.c
Original file line number Diff line number Diff line change
Expand Up @@ -166,18 +166,17 @@ static long booke_wdt_ioctl(struct file *file,

switch (cmd) {
case WDIOC_GETSUPPORT:
if (copy_to_user((void *)arg, &ident, sizeof(ident)))
return -EFAULT;
return copy_to_user(p, &ident, sizeof(ident)) ? -EFAULT : 0;
case WDIOC_GETSTATUS:
return put_user(0, p);
case WDIOC_GETBOOTSTATUS:
/* XXX: something is clearing TSR */
tmp = mfspr(SPRN_TSR) & TSR_WRS(3);
/* returns CARDRESET if last reset was caused by the WDT */
return (tmp ? WDIOF_CARDRESET : 0);
return put_user((tmp ? WDIOF_CARDRESET : 0), p);
case WDIOC_SETOPTIONS:
if (get_user(tmp, p))
return -EINVAL;
return -EFAULT;
if (tmp == WDIOS_ENABLECARD) {
booke_wdt_ping();
break;
Expand Down

0 comments on commit cb2f51a

Please sign in to comment.