patch-2.1.72 linux/drivers/char/wdt.c
Next file: linux/drivers/isdn/avmb1/capi.c
Previous file: linux/drivers/char/vga.c
Back to the patch index
Back to the overall index
- Lines: 31
- Date:
Tue Dec 9 09:49:58 1997
- Orig file:
v2.1.71/linux/drivers/char/wdt.c
- Orig date:
Sat Nov 29 11:25:09 1997
diff -u --recursive --new-file v2.1.71/linux/drivers/char/wdt.c linux/drivers/char/wdt.c
@@ -53,7 +53,7 @@
*/
static int io=0x240;
-static int irq=14;
+static int irq=11;
#define WD_TIMO (100*60) /* 1 minute */
@@ -171,6 +171,10 @@
static ssize_t wdt_write(struct file *file, const char *buf, size_t count, loff_t *ppos)
{
+ /* Can't seek (pwrite) on this device */
+ if (ppos != &file->f_pos)
+ return -ESPIPE;
+
if(count)
{
wdt_ping();
@@ -189,6 +193,10 @@
unsigned char cp;
int err;
+ /* Can't seek (pread) on this device */
+ if (ptr != &file->f_pos)
+ return -ESPIPE;
+
switch(MINOR(file->f_dentry->d_inode->i_rdev))
{
case TEMP_MINOR:
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov