Arnd Bergmann wrote:
> > +struct compat_if_dqblk {
> > + compat_uint_t dqb_bhardlimit[2];
> > + compat_uint_t dqb_bsoftlimit[2];
> > + compat_uint_t dqb_curspace[2];
> > + compat_uint_t dqb_ihardlimit[2];
> > + compat_uint_t dqb_isoftlimit[2];
> > + compat_uint_t dqb_curinodes[2];
> > + compat_uint_t dqb_btime[2];
> > + compat_uint_t dqb_itime[2];
> > + compat_uint_t dqb_valid;
> > +};
> > +
> > +/* XFS structures */
> > +struct compat_fs_qfilestat {
> > + compat_uint_t dqb_bhardlimit[2];
> > + compat_uint_t qfs_nblks[2];
> > + compat_uint_t qfs_nextents;
> > +};
> > +
>
> The patch looks technically correct, but you have defined the structures
> in a somewhat unusual way. I'd have defined them with
> attribute((packed, aligned(4))) in the end.
>
> Or even better, we should probably add a
>
> typedef unsigned long long __attribute__((aligned(4))) compat_u64;
>
> for x86 compat and use that instead of compat_uint_t foo[2].
Actually I didn't use __attribute__, 'case I'v heard, that this isn't
encouraged now to use __attribute__((...)) in kernel. But if you think it
is ok, and even preferable, I will definitely redo it!
Thanks!
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]