Re: IIO comments
From: Arnd Bergmann
Date: Wed Mar 16 2011 - 14:52:20 EST
On Wednesday 16 March 2011 17:54:55 Jonathan Cameron wrote:
> >> * iio_allocate_device() could get a size argument and
> >> allocate the dev_data together with the iio_dev in
> >> a single allocation, like netdev_alloc does. In addition,
> >> you can pass a structure with all constant data, such
> >> as THIS_MODULE, and the operations and/or attribute groups,
> >> instead of having to set them individually for each dev.
> > Good idea.
> There is an issue here I'd forgotten. Some of our structures have a
> elements which are cacheline aligned. For first version of this I'll
> set our alignment requirements as L1_CACHE_BYTES. Would be nice to be
> able to relax that down the line though as it means we use at least two
> cachelines even if we don't care about that alignment requirement.
I think the data used by a device structure is not really an issue,
especially extending it by just another cache line.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/