You want to be careful here. What you've done is modify the size and
content of a structure. If this structure is only used inside the
kernel, that's fine. However, if the structure is shared between
kernel and user space (say for an ioctl()), you're rooted. The same
goes for adding or moving structure members, of course.
In this case, a quick scan of the kernel sources doesn't reveal that
"struct lp_struct" is "exported" to user space, so your change is
fine, as far as it goes. But since the structure doesn't appear to be
exported to user space, you may as well put the #ifdef around the
whole structure declaration. That way, if any user space code is silly
enough to refer to that structure, it will refuse to compile, rather
than generating an incompatible binary.
Even better, put the #ifdef __KERNEL__ around all the stuff in lp.h
that doesn't seem to be needed in user space. That way you can make a
small contribution to cleaning up the current mess.
Regards,
Richard....
P.S. I told you it isn't worth the effort to build everything...
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/