[patch] miih: don't leak kernel types

From: Robert Love
Date: Tue Jan 03 2006 - 16:03:01 EST


On Tue, 2006-01-03 at 15:50 -0500, Robert Love wrote:

> The header <linux/ethtool.h> leaks the kernel types u32, et al types to
> user-space. These types are defined in <asm/types.h> but only under
> __KERNEL__.
>
> Attached patch switches to the __u32, et al types.

Same deal for <linux/mii.h>.

Robert Love


don't leak the kernel uX types to user-space, use __uX in lieu

Signed-off-by: Robert Love <rml@xxxxxxxxxx>

include/linux/mii.h | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)

diff -urN linux-2.6.15/include/linux/mii.h linux/include/linux/mii.h
--- linux-2.6.15/include/linux/mii.h 2006-01-02 22:21:10.000000000 -0500
+++ linux/include/linux/mii.h 2006-01-03 15:59:39.000000000 -0500
@@ -171,10 +171,10 @@

/* This structure is used in all SIOCxMIIxxx ioctl calls */
struct mii_ioctl_data {
- u16 phy_id;
- u16 reg_num;
- u16 val_in;
- u16 val_out;
+ __u16 phy_id;
+ __u16 reg_num;
+ __u16 val_in;
+ __u16 val_out;
};




-
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/