patch-1.3.36 linux/drivers/sound/audio.c

Next file: linux/drivers/sound/configure.c
Previous file: linux/drivers/sound/adlib_card.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.35/linux/drivers/sound/audio.c linux/drivers/sound/audio.c
@@ -154,20 +154,6 @@
   DMAbuf_release (dev, mode);
 }
 
-#ifdef NO_INLINE_ASM
-static void
-translate_bytes (const unsigned char *table, unsigned char *buff, int n)
-{
-  unsigned long   i;
-
-  if (n <= 0)
-    return;
-
-  for (i = 0; i < n; ++i)
-    buff[i] = table[buff[i]];
-}
-
-#else
 extern inline void
 translate_bytes (const void *table, void *buff, int n)
 {
@@ -183,7 +169,6 @@
     }
 }
 
-#endif
 
 int
 audio_write (int dev, struct fileinfo *file, const snd_rw_buf * buf, int count)
@@ -247,7 +232,7 @@
 	{			/*
 				 * No device specific copy routine
 				 */
-	  memcpy_fromfs ((&wr_dma_buf[dev][wr_buff_ptr[dev]]), &((buf)[p]), (l));
+	  memcpy_fromfs (&wr_dma_buf[dev][wr_buff_ptr[dev]], &((buf)[p]), l);
 	}
       else
 	audio_devs[dev]->copy_from_user (dev,
@@ -343,7 +328,7 @@
 	  translate_bytes (dsp_ulaw, (unsigned char *) dmabuf, l);
 	}
 
-      memcpy_tofs (&((buf)[p]), (dmabuf), (l));
+      memcpy_tofs (&((buf)[p]), dmabuf, l);
 
       DMAbuf_rmchars (dev, buff_no, l);
 
@@ -418,7 +403,7 @@
 	  if (err < 0)
 	    return err;
 
-	  memcpy_tofs (&(((char *) arg)[0]), ((char *) &info), (sizeof (info)));
+	  memcpy_tofs ((&((char *) arg)[0]), (char *) &info, sizeof (info));
 	  return 0;
 	}
 
@@ -437,7 +422,7 @@
 	  if (wr_buff_no[dev] != -1)
 	    info.bytes += wr_buff_size[dev] - wr_buff_ptr[dev];
 
-	  memcpy_tofs (&(((char *) arg)[0]), ((char *) &info), (sizeof (info)));
+	  memcpy_tofs ((&((char *) arg)[0]), (char *) &info, sizeof (info));
 	  return 0;
 	}
 
@@ -462,7 +447,7 @@
 	  if (audio_devs[dev]->trigger)		/* Supports SETTRIGGER */
 	    info |= DSP_CAP_TRIGGER;
 
-	  memcpy_tofs (&(((char *) arg)[0]), ((char *) &info), (sizeof (info)));
+	  memcpy_tofs ((&((char *) arg)[0]), (char *) &info, sizeof (info));
 	  return 0;
 	}
 	break;

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this