Date: Tue, 18 Nov 1997 10:18:05 +0100 (CET)
From: Geert Uytterhoeven <Geert.Uytterhoeven@cs.kuleuven.ac.be>
To: Jes Sorensen <Jes.Sorensen@cern.ch>
Cc: linux-m68k@lists.linux-m68k.org
Subject: Re: L68K: 2.1.64
In-Reply-To: <199711161610.RAA27878@valhall.cern.ch>
Sender: owner-linux-m68k@phil.uni-sb.de

On Sun, 16 Nov 1997, Jes Sorensen wrote:
> I have released 2.1.64 and of course James already pointed out that

You forgot this patch:

[ I'm not quite sure about the first chunk (signal_pending). What's the current
  convention here? ]

--- m68k-2.1.64/drivers/sound/dmasound.c.orig	Mon Nov 17 22:15:37 1997
+++ m68k-2.1.64/drivers/sound/dmasound.c	Mon Nov 17 22:55:02 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,
@@ -3070,9 +3069,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:
@@ -3115,8 +3114,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;
 }
@@ -3187,25 +3185,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:

Greetings,

						Geert

--
Geert Uytterhoeven                     Geert.Uytterhoeven@cs.kuleuven.ac.be
Wavelets, Linux/{m68k~Amiga,PPC~CHRP}  http://www.cs.kuleuven.ac.be/~geert/
Department of Computer Science -- Katholieke Universiteit Leuven -- Belgium

