public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Andre Przywara <andre.przywara@arm.com>
To: Peter Hoyes <peter.hoyes@arm.com>
Cc: u-boot@lists.denx.de, Joe Hershberger <joe.hershberger@ni.com>,
	Ramon Fried <rfried.dev@gmail.com>
Subject: Re: [PATCH] net: Use phys_addr_t for SMC net device addresses
Date: Sun, 11 Jul 2021 23:29:06 +0100	[thread overview]
Message-ID: <20210711232906.1745967f@slackpad.fritz.box> (raw)
In-Reply-To: <20210709095206.659825-1-peter.hoyes@arm.com>

On Fri,  9 Jul 2021 10:52:06 +0100
Peter Hoyes <peter.hoyes@arm.com> wrote:

> From: Peter Hoyes <Peter.Hoyes@arm.com>
> 
> Use same type as eth_device->iobase and support addresses greater
> than INT_MAX.

Indeed, a signed(!) int is really a poor choice for a base address.

> Signed-off-by: Peter Hoyes <Peter.Hoyes@arm.com>

Reviewed-by: Andre Przywara <andre.przywara@arm.com>

Cheers,
Andre

> ---
>  drivers/net/smc91111.c | 2 +-
>  drivers/net/smc911x.c  | 2 +-
>  include/netdev.h       | 4 ++--
>  3 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/net/smc91111.c b/drivers/net/smc91111.c
> index ec4e8e928c..61d7f3df69 100644
> --- a/drivers/net/smc91111.c
> +++ b/drivers/net/smc91111.c
> @@ -1269,7 +1269,7 @@ static void print_packet( byte * buf, int length )
>  }
>  #endif
>  
> -int smc91111_initialize(u8 dev_num, int base_addr)
> +int smc91111_initialize(u8 dev_num, phys_addr_t base_addr)
>  {
>  	struct smc91111_priv *priv;
>  	struct eth_device *dev;
> diff --git a/drivers/net/smc911x.c b/drivers/net/smc911x.c
> index 3afebee440..8f420261fa 100644
> --- a/drivers/net/smc911x.c
> +++ b/drivers/net/smc911x.c
> @@ -478,7 +478,7 @@ static int smc911x_recv(struct eth_device *dev)
>  	return ret;
>  }
>  
> -int smc911x_initialize(u8 dev_num, int base_addr)
> +int smc911x_initialize(u8 dev_num, phys_addr_t base_addr)
>  {
>  	struct smc911x_priv *priv;
>  	int ret;
> diff --git a/include/netdev.h b/include/netdev.h
> index b960c42106..00a0993a83 100644
> --- a/include/netdev.h
> +++ b/include/netdev.h
> @@ -70,8 +70,8 @@ int rtl8169_initialize(struct bd_info *bis);
>  int scc_initialize(struct bd_info *bis);
>  int sh_eth_initialize(struct bd_info *bis);
>  int skge_initialize(struct bd_info *bis);
> -int smc91111_initialize(u8 dev_num, int base_addr);
> -int smc911x_initialize(u8 dev_num, int base_addr);
> +int smc91111_initialize(u8 dev_num, phys_addr_t base_addr);
> +int smc911x_initialize(u8 dev_num, phys_addr_t base_addr);
>  int uec_standard_init(struct bd_info *bis);
>  int uli526x_initialize(struct bd_info *bis);
>  int armada100_fec_register(unsigned long base_addr);


  parent reply	other threads:[~2021-07-11 22:29 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-09  9:52 [PATCH] net: Use phys_addr_t for SMC net device addresses Peter Hoyes
2021-07-10  5:38 ` Ramon Fried
2021-07-11 22:29 ` Andre Przywara [this message]
2021-07-22 18:55   ` Ramon Fried

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=20210711232906.1745967f@slackpad.fritz.box \
    --to=andre.przywara@arm.com \
    --cc=joe.hershberger@ni.com \
    --cc=peter.hoyes@arm.com \
    --cc=rfried.dev@gmail.com \
    --cc=u-boot@lists.denx.de \
    /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