patch-2.4.10 linux/drivers/sound/dmasound/dmasound_q40.c

Next file: linux/drivers/sound/emu10k1/audio.c
Previous file: linux/drivers/sound/dmasound/dmasound_paula.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.9/linux/drivers/sound/dmasound/dmasound_q40.c linux/drivers/sound/dmasound/dmasound_q40.c
@@ -58,7 +58,7 @@
 	ssize_t count, used;
 	u_char *p = (u_char *) &frame[*frameUsed];
 
-	used = count = min(unsigned long, userCount, frameLeft);
+	used = count = min_t(size_t, userCount, frameLeft);
 	if (copy_from_user(p,userPtr,count))
 	  return -EFAULT;
 	while (count > 0) {
@@ -84,7 +84,7 @@
 	frameLeft >>= 1;
 	if (stereo)
 		userCount >>= 1;
-	used = count = min(unsigned long, userCount, frameLeft);
+	used = count = min_t(size_t, userCount, frameLeft);
 	while (count > 0) {
 		u_char data;
 		if (get_user(data, userPtr++))
@@ -112,7 +112,7 @@
 	ssize_t count, used;
 	u_char *p = (u_char *) &frame[*frameUsed];
 
-	used = count = min(unsigned long, userCount, frameLeft);
+	used = count = min_t(size_t, userCount, frameLeft);
 	if (copy_from_user(p,userPtr,count))
 	  return -EFAULT;
 	while (count > 0) {
@@ -136,7 +136,7 @@
 	frameLeft >>= 1;
 	if (stereo)
 		userCount >>= 1;
-	used = count = min(unsigned long, userCount, frameLeft);
+	used = count = min_t(size_t, userCount, frameLeft);
 	while (count > 0) {
 		u_char data;
 		if (get_user(data, userPtr++))
@@ -164,7 +164,7 @@
 	ssize_t count, used;
 	u_char *p = (u_char *) &frame[*frameUsed];
 
-	used = count = min(unsigned long, userCount, frameLeft);
+	used = count = min_t(size_t, userCount, frameLeft);
 	if (copy_from_user(p,userPtr,count))
 	  return -EFAULT;
 	*frameUsed += used;
@@ -184,7 +184,7 @@
 	frameLeft >>= 1;
 	if (stereo)
 		userCount >>= 1;
-	used = count = min(unsigned long, userCount, frameLeft);
+	used = count = min_t(size_t, userCount, frameLeft);
 	while (count > 0) {
 		u_char data;
 		if (get_user(data, userPtr++))

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)