mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Ahmad Fatoum <a.fatoum@pengutronix.de>
Cc: Barebox List <barebox@lists.infradead.org>
Subject: Re: [PATCH 06/12] ARM: versatile: Use smc91c111 from device tree
Date: Tue, 2 May 2023 13:41:03 +0200	[thread overview]
Message-ID: <20230502114103.GE29365@pengutronix.de> (raw)
In-Reply-To: <52edeca2-edbb-0a55-c9fc-1555200102d5@pengutronix.de>

On Tue, May 02, 2023 at 11:17:43AM +0200, Ahmad Fatoum wrote:
> On 02.05.23 11:14, Sascha Hauer wrote:
> > Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> > ---
> >  arch/arm/boards/versatile/versatilepb.c |  7 -------
> >  drivers/net/smc91111.c                  | 16 +++++++++++-----
> >  include/platform_data/eth-smc91111.h    |  1 -
> >  3 files changed, 11 insertions(+), 13 deletions(-)
> > 
> > diff --git a/arch/arm/boards/versatile/versatilepb.c b/arch/arm/boards/versatile/versatilepb.c
> > index 0ea397d3cb..8079ade9a5 100644
> > --- a/arch/arm/boards/versatile/versatilepb.c
> > +++ b/arch/arm/boards/versatile/versatilepb.c
> > @@ -39,15 +39,8 @@ static int vpb_console_init(void)
> >  }
> >  console_initcall(vpb_console_init);
> >  
> > -static struct smc91c111_pdata net_pdata = {
> > -	.qemu_fixup = 1,
> > -};
> > -
> >  static int vpb_devices_init(void)
> >  {
> > -	add_generic_device("smc91c111", DEVICE_ID_DYNAMIC, NULL, VERSATILE_ETH_BASE,
> > -			64 * 1024, IORESOURCE_MEM, &net_pdata);
> > -
> >  	armlinux_set_architecture(MACH_TYPE_VERSATILE_PB);
> >  
> >  	return 0;
> > diff --git a/drivers/net/smc91111.c b/drivers/net/smc91111.c
> > index 89195fc826..46faf385f9 100644
> > --- a/drivers/net/smc91111.c
> > +++ b/drivers/net/smc91111.c
> > @@ -440,7 +440,6 @@ struct smc91c111_priv {
> >  	struct mii_bus miibus;
> >  	struct accessors a;
> >  	void __iomem *base;
> > -	int qemu_fixup;
> >  	unsigned shift;
> >  	int version;
> >  	int revision;
> > @@ -1048,7 +1047,8 @@ static int smc91c111_eth_open(struct eth_device *edev)
> >  	if (ret)
> >  		return ret;
> >  
> > -	if (priv->qemu_fixup && edev->phydev->phy_id == 0x00000000) {
> > +	if (of_machine_is_compatible("arm,versatile-pb") ||
> > +	    of_machine_is_compatible("arm,versatile-ab")) {
> >  		struct phy_device *dev = edev->phydev;
> >  
> >  		dev->speed = SPEED_100;
> > @@ -1451,7 +1451,6 @@ static int smc91c111_probe(struct device *dev)
> >  	if (dev->platform_data) {
> >  		struct smc91c111_pdata *pdata = dev->platform_data;
> >  
> > -		priv->qemu_fixup = pdata->qemu_fixup;
> >  		priv->shift = pdata->addr_shift;
> >  		if (pdata->bus_width == 16)
> >  			priv->a = access_via_16bit;
> > @@ -1489,8 +1488,15 @@ static int smc91c111_probe(struct device *dev)
> >  	return 0;
> >  }
> >  
> > +static __maybe_unused struct of_device_id imx_fec_dt_ids[] = {
> 
> smc91c111_dt_ids

Fixed, thanks

Sascha

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |



  reply	other threads:[~2023-05-02 11:42 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-02  9:14 [PATCH 00/12] ARM Versatile updates Sascha Hauer
2023-05-02  9:14 ` [PATCH 01/12] ARM: versatile: Enable CONFIG_RELOCATABLE Sascha Hauer
2023-05-02  9:14 ` [PATCH 02/12] ARM: versatile: Use common clk framework Sascha Hauer
2023-05-02  9:14 ` [PATCH 03/12] ARM: versatile: drop platform code to register UART Sascha Hauer
2023-05-02  9:14 ` [PATCH 04/12] ARM: versatile: drop platform code to register GPIOs Sascha Hauer
2023-05-02  9:14 ` [PATCH 05/12] ARM: versatile: Use flash from device tree Sascha Hauer
2023-05-02  9:14 ` [PATCH 06/12] ARM: versatile: Use smc91c111 " Sascha Hauer
2023-05-02  9:17   ` Ahmad Fatoum
2023-05-02 11:41     ` Sascha Hauer [this message]
2023-05-02  9:14 ` [PATCH 07/12] ARM: versatile: make sure to run initcalls on versatile only Sascha Hauer
2023-05-02  9:14 ` [PATCH 08/12] ARM: versatile: simplify ARM1176 support Sascha Hauer
2023-05-02  9:14 ` [PATCH 09/12] ARM: versatile: move over to multi image support Sascha Hauer
2023-05-02  9:14 ` [PATCH 10/12] ARM: versatile: move over to multi arch support Sascha Hauer
2023-05-02  9:14 ` [PATCH 11/12] ARM: versatile: Use existing clocksource driver Sascha Hauer
2023-05-02  9:14 ` [PATCH 12/12] ARM: Merge imx_defconfig and versatilepb_defconfig into multi_v5_v6_defconfig Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230502114103.GE29365@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=a.fatoum@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox