Re: [patch 11/12] sound/oss/emu10k1/* - compile warning cleanup

2005-03-06 Thread Andrew Morton
[EMAIL PROTECTED] wrote: > > @@ -316,7 +320,10 @@ static void copy_block(u8 __user *dst, u > > for (i = 0; i < len; i++) { > byte = src[2 * i] ^ 0x80; > - __copy_to_user(dst + i, &byte, 1); > + if (__copy_to_user(dst + i,

Re: [patch 11/12] sound/oss/emu10k1/* - compile warning cleanup

2005-03-06 Thread Andrew Morton
[EMAIL PROTECTED] wrote: > > > compile warning cleanup - handle copy_to/from_user error > returns If a write() gets a fault it's supposed to return the number of bytes which it actually wrote, which may be zero. Still, returning -EFAULT is better than appearing to have succeeded. > +

[patch 11/12] sound/oss/emu10k1/* - compile warning cleanup

2005-03-05 Thread domen
compile warning cleanup - handle copy_to/from_user error returns Signed-off-by: Stephen Biggs <[EMAIL PROTECTED]> Signed-off-by: Domen Puncer <[EMAIL PROTECTED]> --- kj-domen/sound/oss/emu10k1/cardwi.c | 13 ++--- kj-domen/sound/oss/emu10k1/passthrough.c | 12 2