]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
[WATCHDOG] Return value of nonseekable_open
authorWim Van Sebroeck <wim@iguana.be>
Tue, 24 Jul 2007 21:38:37 +0000 (21:38 +0000)
committerWim Van Sebroeck <wim@iguana.be>
Tue, 24 Jul 2007 21:39:52 +0000 (21:39 +0000)
Return the value of the nonseekable_open function and not 0.

Signed-off-by: Wim Van Sebroeck <wim@iguana.be>
drivers/char/watchdog/sa1100_wdt.c
drivers/char/watchdog/sbc60xxwdt.c
drivers/char/watchdog/sc1200wdt.c
drivers/char/watchdog/sc520_wdt.c

index 33c1137f17d6d3e8be5cbbc3abb2bf3099721cc1..3475f47aaa45766cc48f3cf7361683ddfede5aee 100644 (file)
@@ -45,7 +45,6 @@ static int boot_status;
  */
 static int sa1100dog_open(struct inode *inode, struct file *file)
 {
-       nonseekable_open(inode, file);
        if (test_and_set_bit(1,&sa1100wdt_users))
                return -EBUSY;
 
@@ -54,7 +53,7 @@ static int sa1100dog_open(struct inode *inode, struct file *file)
        OSSR = OSSR_M3;
        OWER = OWER_WME;
        OIER |= OIER_E3;
-       return 0;
+       return nonseekable_open(inode, file);
 }
 
 /*
index b6282039198c6cdcef656098d31a4570125c721e..e4f3cb6090bc7d0db295bacfdc8dcf88a787f031 100644 (file)
@@ -191,8 +191,6 @@ static ssize_t fop_write(struct file * file, const char __user * buf, size_t cou
 
 static int fop_open(struct inode * inode, struct file * file)
 {
-       nonseekable_open(inode, file);
-
        /* Just in case we're already talking to someone... */
        if(test_and_set_bit(0, &wdt_is_open))
                return -EBUSY;
@@ -202,7 +200,7 @@ static int fop_open(struct inode * inode, struct file * file)
 
        /* Good, fire up the show */
        wdt_startup();
-       return 0;
+       return nonseekable_open(inode, file);
 }
 
 static int fop_close(struct inode * inode, struct file * file)
index 2f7ba7a514fe08616e71fc85a7eebb04a7523510..9670d47190d0875a41a23b81d0dc568ab3e0cb4e 100644 (file)
@@ -150,8 +150,6 @@ static inline int sc1200wdt_status(void)
 
 static int sc1200wdt_open(struct inode *inode, struct file *file)
 {
-       nonseekable_open(inode, file);
-
        /* allow one at a time */
        if (down_trylock(&open_sem))
                return -EBUSY;
@@ -162,7 +160,7 @@ static int sc1200wdt_open(struct inode *inode, struct file *file)
        sc1200wdt_start();
        printk(KERN_INFO PFX "Watchdog enabled, timeout = %d min(s)", timeout);
 
-       return 0;
+       return nonseekable_open(inode, file);
 }
 
 
index 2676a43895a71f640c19f5120a0d8ff7f2523dbb..e8594c64d1e64fd9a07606ba75878007ab523578 100644 (file)
@@ -248,8 +248,6 @@ static ssize_t fop_write(struct file * file, const char __user * buf, size_t cou
 
 static int fop_open(struct inode * inode, struct file * file)
 {
-       nonseekable_open(inode, file);
-
        /* Just in case we're already talking to someone... */
        if(test_and_set_bit(0, &wdt_is_open))
                return -EBUSY;
@@ -258,7 +256,7 @@ static int fop_open(struct inode * inode, struct file * file)
 
        /* Good, fire up the show */
        wdt_startup();
-       return 0;
+       return nonseekable_open(inode, file);
 }
 
 static int fop_close(struct inode * inode, struct file * file)