Message ID | 1443692893-19905-5-git-send-email-sjoerd.simons@collabora.co.uk |
---|---|
State | Superseded |
Headers | show |
On Thu, Oct 1, 2015 at 5:48 PM, Sjoerd Simons <sjoerd.simons@collabora.co.uk> wrote: > To allow other DM drivers to subclass the designware driver various > functions and structures need to be exported. Export these. > > Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk> > --- > > drivers/net/designware.c | 6 +++--- > drivers/net/designware.h | 4 ++++ > 2 files changed, 7 insertions(+), 3 deletions(-) > > diff --git a/drivers/net/designware.c b/drivers/net/designware.c > index f9ceec2..0b7adc9 100644 > --- a/drivers/net/designware.c > +++ b/drivers/net/designware.c > @@ -621,7 +621,7 @@ static int designware_eth_bind(struct udevice *dev) > return 0; > } > > -static int designware_eth_probe(struct udevice *dev) > +int designware_eth_probe(struct udevice *dev) > { > struct eth_pdata *pdata = dev_get_platdata(dev); > struct dw_eth_dev *priv = dev_get_priv(dev); > @@ -659,7 +659,7 @@ static int designware_eth_probe(struct udevice *dev) > return ret; > } > > -static const struct eth_ops designware_eth_ops = { > +const struct eth_ops designware_eth_ops = { > .start = designware_eth_start, > .send = designware_eth_send, > .recv = designware_eth_recv, > @@ -668,7 +668,7 @@ static const struct eth_ops designware_eth_ops = { > .write_hwaddr = designware_eth_write_hwaddr, > }; > > -static int designware_eth_ofdata_to_platdata(struct udevice *dev) > +int designware_eth_ofdata_to_platdata(struct udevice *dev) > { > struct dw_eth_pdata *dw_pdata = dev_get_platdata(dev); > struct eth_pdata *pdata = &dw_pdata->eth_pdata; > diff --git a/drivers/net/designware.h b/drivers/net/designware.h > index f34263b..47e727b 100644 > --- a/drivers/net/designware.h > +++ b/drivers/net/designware.h > @@ -239,6 +239,10 @@ struct dw_eth_dev { > }; > > #ifdef CONFIG_DM_ETH > +int designware_eth_ofdata_to_platdata(struct udevice *dev); > +int designware_eth_probe(struct udevice *dev); > +extern const struct eth_ops designware_eth_ops; > + > struct dw_eth_pdata { > struct eth_pdata eth_pdata; > struct gpio_desc reset_gpio; > -- Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
On 1 October 2015 at 10:48, Sjoerd Simons <sjoerd.simons@collabora.co.uk> wrote: > To allow other DM drivers to subclass the designware driver various > functions and structures need to be exported. Export these. > > Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk> > --- > > drivers/net/designware.c | 6 +++--- > drivers/net/designware.h | 4 ++++ > 2 files changed, 7 insertions(+), 3 deletions(-) Acked-by: Simon Glass <sjg@chromium.org>
diff --git a/drivers/net/designware.c b/drivers/net/designware.c index f9ceec2..0b7adc9 100644 --- a/drivers/net/designware.c +++ b/drivers/net/designware.c @@ -621,7 +621,7 @@ static int designware_eth_bind(struct udevice *dev) return 0; } -static int designware_eth_probe(struct udevice *dev) +int designware_eth_probe(struct udevice *dev) { struct eth_pdata *pdata = dev_get_platdata(dev); struct dw_eth_dev *priv = dev_get_priv(dev); @@ -659,7 +659,7 @@ static int designware_eth_probe(struct udevice *dev) return ret; } -static const struct eth_ops designware_eth_ops = { +const struct eth_ops designware_eth_ops = { .start = designware_eth_start, .send = designware_eth_send, .recv = designware_eth_recv, @@ -668,7 +668,7 @@ static const struct eth_ops designware_eth_ops = { .write_hwaddr = designware_eth_write_hwaddr, }; -static int designware_eth_ofdata_to_platdata(struct udevice *dev) +int designware_eth_ofdata_to_platdata(struct udevice *dev) { struct dw_eth_pdata *dw_pdata = dev_get_platdata(dev); struct eth_pdata *pdata = &dw_pdata->eth_pdata; diff --git a/drivers/net/designware.h b/drivers/net/designware.h index f34263b..47e727b 100644 --- a/drivers/net/designware.h +++ b/drivers/net/designware.h @@ -239,6 +239,10 @@ struct dw_eth_dev { }; #ifdef CONFIG_DM_ETH +int designware_eth_ofdata_to_platdata(struct udevice *dev); +int designware_eth_probe(struct udevice *dev); +extern const struct eth_ops designware_eth_ops; + struct dw_eth_pdata { struct eth_pdata eth_pdata; struct gpio_desc reset_gpio;
To allow other DM drivers to subclass the designware driver various functions and structures need to be exported. Export these. Signed-off-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk> --- drivers/net/designware.c | 6 +++--- drivers/net/designware.h | 4 ++++ 2 files changed, 7 insertions(+), 3 deletions(-)