![]() | |||||||||||||
Messages in this thread |
Rusty Russell <rusty@rustcorp.com.au> writes: > In message <Pine.LNX.4.44.0205191951460.22433-100000@home.transmeta.com> you wr > ite: > > ret = copy_from_user(xxx); > > if (ret) > > return ret; > > > > which is apparently your suggestion. > > Not quite: > copy_from_user(xxx); > > Is my suggestion. No error return. I don't think it is a good idea. Consider a driver that does lots of small copy_from_user() from user space for a longer write (e.g. TCP to a small MSS) If xxx was faulting it would eat a lot of cycles with faulting again and again. -Andi - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ | ||||||||||||
| Last update: 2005-03-22 12:26 [W:0.194 / U:0.070 seconds] ©2003-2008 Jasper Spaans | |||||||||||||