patch-2.1.87 linux/arch/m68k/atari/joystick.c

Next file: linux/arch/m68k/atari/stdma.c
Previous file: linux/arch/m68k/atari/debug.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.86/linux/arch/m68k/atari/joystick.c linux/arch/m68k/atari/joystick.c
@@ -82,15 +82,16 @@
     return 0;
 }
 
-static long write_joystick(struct inode *inode, struct file *file,
-			   const char *buffer, unsigned long count)
+static ssize_t write_joystick(struct file *file, const char *buffer,
+			      size_t count, loff_t *ppos)
 {
     return -EINVAL;
 }
 
-static long read_joystick(struct inode *inode, struct file *file,
-			  char *buffer, unsigned long count)
+static ssize_t read_joystick(struct file *file, char *buffer, size_t count,
+			     loff_t *ppos)
 {
+    struct inode *inode = file->f_dentry->d_inode;
     int minor = DEVICE_NR(inode->i_rdev);
 
     if (count < 2)
@@ -109,7 +110,7 @@
 
 static unsigned int joystick_poll(struct file *file, poll_table *wait)
 {
-    int minor = DEVICE_NR(file->f_inode->i_rdev);
+    int minor = DEVICE_NR(file->f_dentry->d_inode->i_rdev);
 
     poll_wait(&joystick[minor].wait, wait);
     if (joystick[minor].ready)

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov