Hi Peter, On Wed, 4 Jun 2008, Peter Korsgaard wrote:Oops, I've just returned from holidays, and realize I never actually responded to this question. So here is the gist of it: | I had a closer look at the structures and bitfields, and I still think it's | possible to stay compatible with the current little endian layout: | 1. About half of the bitfields are actually bytes or 16-bit words. Hence | these can easily be converted to __u8 or __le16. | 2. Most of the remaining bitfields sit in an 8, 16, or 32 bit integer. | Hence these can be converted to such an integer (or an array of bytes, | cfr. 3 below), and accessed using get_unaligned_le{16,32}() and a | shift/mask operation. | 3. There are a few bitfields that sit in an `odd' number of bytes. These | can be converted to an array of bytes, and accessed using | get_unaligned_le{16,32}() and a shift/mask operation. | 4. The integral fields in the structs should be accessed using | get_unaligned_le{8,16,32}(), too. I noticed the squashfs CVS repository is getting a new (incompatible) 4.0 layout now? What do people think? With kind regards, Geert Uytterhoeven Software Architect Sony Techsoft Centre Europe The Corporate Village
| Greg Kroah-Hartman | [PATCH 001/196] Chinese: Add the known_regression URI to the HOWTO |
| Linus Torvalds | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| Andrew Morton | 2.6.25-mm1 |
| Vladislav Bolkhovitin | Re: Integration of SCST in the mainstream Linux kernel |
git: | |
| David Miller | [GIT]: Networking |
| David Miller | Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| Gerrit Renker | [PATCH 0/37] dccp: Feature negotiation - last call for comments |
| Natalie Protasevich | [BUG] New Kernel Bugs |
