data transfer limit using ioctl()?
Arnd Bergmann
arnd at arndb.de
Thu Dec 14 04:09:02 EST 2006
On Wednesday 13 December 2006 10:24, Parav Pandit wrote:
> How much maximum data transfer should be done using ioctl() to driver?
No, there is no technical limit. Usually, it's considered good style
to transfer only a basic data type with fixed length though, like uint32_t
or loff_t, not a long buffer. You should also make sure you have a fixed
length buffer, and that it's the same size on 32 and 64 bit kernels.
For long non-structured transfers, use read/write operations if possible.
> I can also use the Netlink sockets to transfer data from user to kernel.
> Is there any limit that we should consider for choosing ioctl() to driver or using netlink sockets?
>
No, that decision does not depend on the data size mostly, but more on
what you want to do.
Arnd <><
More information about the Linuxppc-embedded
mailing list