To: linux-m68k@lists.linux-m68k.org
Subject: L68K: 2.1.64
X-Yow: CHUBBY CHECKER owns my BUILDING!
From: Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
Date: 19 Nov 1997 10:34:12 +0100
Sender: owner-linux-m68k@phil.uni-sb.de

Hi!

Here are the usual patches. :-)  They are just due to the new VFS
interface.

Andreas.

----------------------------------------------------------------------
--- drivers/char/lp_m68k.c.~1~	Mon Nov 17 18:02:33 1997
+++ drivers/char/lp_m68k.c	Mon Nov 17 18:34:05 1997
@@ -345,13 +345,13 @@
 unsigned int lp_irq = 0;
 
 #if WHICH_DRIVER == PREFER_INTERRUPT
-static long lp_write(struct inode *inode, struct file *file,
-		    const char *buf, unsigned long count)
+static ssize_t lp_write(struct file *file, const char *buf, size_t count,
+			loff_t *ppos)
 {
 	if (lp_irq)
-		return lp_write_interrupt(inode, file, buf, count);
+		return lp_write_interrupt(file, buf, count, ppos);
 	else
-		return lp_write_polled(inode, file, buf, count);
+		return lp_write_polled(file, buf, count, ppos);
 }
 #endif
 
--- drivers/char/nvram.c.~1~	Mon Nov 17 18:02:34 1997
+++ drivers/char/nvram.c	Mon Nov 17 18:35:08 1997
@@ -250,8 +250,8 @@
 	return( tmp - buf );
 }
 
-static long nvram_write( struct inode * inode, struct file * file,
-						 const char * buf, unsigned long count )
+static ssize_t nvram_write(struct file * file, const char * buf,
+			   size_t count, loff_t *ppos)
 {
 	unsigned long flags;
 	unsigned i = *ppos;
--- drivers/sound/dmasound.c.~1~	Mon Nov 17 18:04:03 1997
+++ drivers/sound/dmasound.c	Fri Nov  7 22:47:52 1997
@@ -628,7 +628,7 @@
 static struct sound_queue sq;
 
 #define sq_block_address(i)	(sq.buffers[i])
-#define SIGNAL_RECEIVED	(current->signal & ~current->blocked)
+#define SIGNAL_RECEIVED	(signal_pending(current))
 #define NON_BLOCKING(open_mode)	(open_mode & O_NONBLOCK)
 #define ONE_SECOND	HZ	/* in jiffies (100ths of a second) */
 #define NO_TIME_LIMIT	0xffffffff
@@ -668,10 +668,9 @@
 
 
 static int sound_open(struct inode *inode, struct file *file);
-static int sound_fsync(struct inode *inode, struct file *filp);
+static int sound_fsync(struct file *filp, struct dentry *dentry);
 static int sound_release(struct inode *inode, struct file *file);
-static long long sound_lseek(struct inode *inode, struct file *file,
-			     long long offset, int orig);
+static long long sound_lseek(struct file *file, long long offset, int orig);
 static ssize_t sound_read(struct file *file, char *buf, size_t count,
 			  loff_t *ppos);
 static ssize_t sound_write(struct file *file, const char *buf, size_t count,
@@ -3071,9 +3070,9 @@
 }
 
 
-static int sound_fsync(struct inode *inode, struct file *filp)
+static int sound_fsync(struct file *filp, struct dentry *dentry)
 {
-    int dev = MINOR(inode->i_rdev) & 0x0f;
+    int dev = MINOR(dentry->d_inode->i_rdev) & 0x0f;
 
     switch (dev) {
 	case SND_DEV_STATUS:
@@ -3116,8 +3115,7 @@
 }
 
 
-static long long sound_lseek(struct inode *inode, struct file *file,
-			     long long offset, int orig)
+static long long sound_lseek(struct file *file, long long offset, int orig)
 {
     return -ESPIPE;
 }
@@ -3188,25 +3186,25 @@
 		    return(0);
 		case SNDCTL_DSP_POST:
 		case SNDCTL_DSP_SYNC:
-		    return(sound_fsync(inode, file));
+		    return(sound_fsync(file, file->f_dentry));
 
 		/* ++TeSche: before changing any of these it's probably wise to
 		 * wait until sound playing has settled down
 		 */
 		case SNDCTL_DSP_SPEED:
-		    sound_fsync(inode, file);
+		    sound_fsync(file, file->f_dentry);
 		    IOCTL_IN(arg, data);
 		    return(IOCTL_OUT(arg, sound_set_speed(data)));
 		case SNDCTL_DSP_STEREO:
-		    sound_fsync(inode, file);
+		    sound_fsync(file, file->f_dentry);
 		    IOCTL_IN(arg, data);
 		    return(IOCTL_OUT(arg, sound_set_stereo(data)));
 		case SOUND_PCM_WRITE_CHANNELS:
-		    sound_fsync(inode, file);
+		    sound_fsync(file, file->f_dentry);
 		    IOCTL_IN(arg, data);
 		    return(IOCTL_OUT(arg, sound_set_stereo(data-1)+1));
 		case SNDCTL_DSP_SETFMT:
-		    sound_fsync(inode, file);
+		    sound_fsync(file, file->f_dentry);
 		    IOCTL_IN(arg, data);
 		    return(IOCTL_OUT(arg, sound_set_format(data)));
 		case SNDCTL_DSP_GETFMTS:

-- 
Andreas Schwab                                      "And now for something
schwab@issan.informatik.uni-dortmund.de              completely different"
schwab@gnu.org
