[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 12 Dec 2013 11:27:15 +0000
From: Russell King - ARM Linux <linux@....linux.org.uk>
To: Matt Porter <mporter@...aro.org>
Cc: Felipe Balbi <balbi@...com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Kishon Vijay Abraham I <kishon@...com>,
Rob Herring <rob.herring@...xeda.com>,
Pawel Moll <pawel.moll@....com>,
Mark Rutland <mark.rutland@....com>,
Kumar Gala <galak@...eaurora.org>,
Ian Campbell <ijc+devicetree@...lion.org.uk>,
Christian Daudt <bcm@...thebug.org>,
Paul Zimmerman <paulz@...opsys.com>,
Devicetree List <devicetree@...r.kernel.org>,
Kamil Debski <k.debski@...sung.com>,
Linaro Patches <patches@...aro.org>,
Tomasz Figa <t.figa@...sung.com>,
Linux USB List <linux-usb@...r.kernel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Kyungmin Park <kyungmin.park@...sung.com>,
Linux ARM Kernel List <linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH v4 1/9] phy: add
phy_get_bus_width()/phy_set_bus_width() calls
On Thu, Dec 12, 2013 at 06:18:29AM -0500, Matt Porter wrote:
> /**
> + * struct phy_attrs - represents phy attributes
> + * @bus_width: Data path width implemented by PHY
> + */
> +struct phy_attrs {
> + u32 bus_width;
Why u32?
> int phy_power_off(struct phy *phy);
> +static inline u32 phy_get_bus_width(struct phy *phy)
> +{
> + return phy->attrs.bus_width;
...
>
> +static inline u32 phy_get_bus_width(struct phy *phy)
> +{
> + return -ENOSYS;
Why u32, especially as you're returning a negative number here.
If the bus width is a small integer (I'm assuming you don't have up to
2^30 bus signals) then what's wrong with it being an 'int' ?
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists