lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1330555428.5881.8.camel@bwh-desktop>
Date:	Wed, 29 Feb 2012 22:43:48 +0000
From:	Ben Hutchings <bhutchings@...arflare.com>
To:	David Miller <davem@...emloft.net>
CC:	<netdev@...r.kernel.org>, <linux-net-drivers@...arflare.com>
Subject: Re: [PATCH net-next] mdio: Export mdio.h to userland

On Wed, 2012-02-29 at 15:42 -0500, David Miller wrote:
> From: Ben Hutchings <bhutchings@...arflare.com>
> Date: Wed, 29 Feb 2012 19:12:34 +0000
> 
> > On Wed, 2012-02-29 at 19:02 +0000, Ben Hutchings wrote:
> >> The ID packing/unpacking functions are needed by userland and the
> >> register definitions may also be useful there.
> > 
> > Minor issue with this: mdio_phy_id_is_c45() returns bool, and that's not
> > defined by default.  Should I add #include <stdbool.h> or change the
> > return type to int for maximum compatibility?
> 
> I do not see any precedence for including stdbool.h in a kernel header
> file.  And I sure as hell am not going to compromise using a correct
> type just to make this usable by userspace.
> 
> I think this is of dubious value, and combined with the bool
> complication I'm not going to apply this, sorry.

Without this, userland doing clause 45 MDIO has to duplicate the ID
packing definitions.   I intended to export these to userland in the
first place; that's why the header already has an #ifdef __KERNEL__.
I was about to get rid of the duplicate definitions in our utilities
when I realised I hadn't exported them.

Ben.

-- 
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ