[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ADE657CA350FB648AAC2C43247A983F001F3820B8699@AUSP01VMBX24.collaborationhost.net>
Date: Thu, 9 Jun 2011 18:40:21 -0500
From: H Hartley Sweeten <hartleys@...ionengravers.com>
To: Mika Westerberg <mika.westerberg@....fi>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>
CC: "linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"kernel@...tstofly.org" <kernel@...tstofly.org>,
"ryan@...ewatersys.com" <ryan@...ewatersys.com>
Subject: RE: [PATCH v2 2/5] net: ep93xx_eth: pass struct device to DMA API
functions
On Thursday, June 02, 2011 12:00 PM, Mika Westerberg wrote:
>
> We shouldn't use NULL for any DMA API functions, unless we are dealing with
> ISA or EISA device. So pass correct struct dev pointer to these functions.
>
> Signed-off-by: Mika Westerberg <mika.westerberg@....fi>
> Acked-by: Russell King <rmk+kernel@....linux.org.uk>
> ---
> drivers/net/arm/ep93xx_eth.c | 26 ++++++++++++++++----------
> 1 files changed, 16 insertions(+), 10 deletions(-)
>
> diff --git a/drivers/net/arm/ep93xx_eth.c b/drivers/net/arm/ep93xx_eth.c
> index 5a77001..8779d3b 100644
> --- a/drivers/net/arm/ep93xx_eth.c
> +++ b/drivers/net/arm/ep93xx_eth.c
> @@ -159,6 +159,8 @@ struct ep93xx_priv
> void __iomem *base_addr;
> int irq;
>
> + struct device *dma_dev;
Mika,
I just noticed this macro in include/linux/netdevice.h
/* Set the sysfs physical device reference for the network logical device
* if set prior to registration will cause a symlink during initialization.
*/
#define SET_NETDEV_DEV(net, pdev) ((net)->dev.parent = (pdev))
Is there anyway you could use that macro in the probe to save the platform_device
(with it's associated device) instead of introducing a new struct device * in the
private data?
Regards,
Hartley--
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