linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: Yoshinori Sato <ysato@users.sourceforge.jp>,
	Rich Felker <dalias@libc.org>,
	linux-sh@vger.kernel.org
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH 2/2] SolutionEngine771x: add Ether TSU resource
Date: Sat, 06 Jan 2018 09:24:32 +0000	[thread overview]
Message-ID: <405370a2-d421-be13-c051-ac972d083d95@cogentembedded.com> (raw)
In-Reply-To: <20180103201137.255228853@cogentembedded.com>

Hello!

On 1/3/2018 11:08 PM, Sergei Shtylyov wrote:

> After the  Ether platform data is fixed, the driver probe() method would
> still fail since the 'struct sh_eth_cpu_data' corresponding  to SH771x
> indicates the presence of TSU but the memory resource for it is absent.
> Add the missing TSU resource  to both Ether devices and fix the harmless
> off-by-one error in the main memory resources, while at it...
> 
> Fixes: 4986b996882d ("net: sh_eth: remove the SH_TSU_ADDR")
> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
> 
> ---
>  arch/sh/boards/mach-se/770x/setup.c |   14 ++++++++++++--
>  arch/sh/include/mach-se/mach/se.h   |    1 +
>  2 files changed, 13 insertions(+), 2 deletions(-)
> 
> Index: linux/arch/sh/boards/mach-se/770x/setup.c
> =================================> --- linux.orig/arch/sh/boards/mach-se/770x/setup.c
> +++ linux/arch/sh/boards/mach-se/770x/setup.c
> @@ -123,10 +123,15 @@ static struct sh_eth_plat_data sh_eth_pl
>  static struct resource sh_eth0_resources[] = {
>  	[0] = {
>  		.start = SH_ETH0_BASE,
> -		.end = SH_ETH0_BASE + 0x1B8,
> +		.end = SH_ETH0_BASE + 0x1B8 - 1,
>  		.flags = IORESOURCE_MEM,
>  	},
>  	[1] = {
> +		.start = SH_TSU_BASE,
> +		.end = SH_TSU_BASE + 0xA00 - 1,

     Oops, should be 0x200, not 0xA00.

> +		.flags = IORESOURCE_MEM,
> +	},
> +	[2] = {
>  		.start = SH_ETH0_IRQ,
>  		.end = SH_ETH0_IRQ,
>  		.flags = IORESOURCE_IRQ,
> @@ -146,10 +151,15 @@ static struct platform_device sh_eth0_de
>  static struct resource sh_eth1_resources[] = {
>  	[0] = {
>  		.start = SH_ETH1_BASE,
> -		.end = SH_ETH1_BASE + 0x1B8,
> +		.end = SH_ETH1_BASE + 0x1B8 - 1,
>  		.flags = IORESOURCE_MEM,
>  	},
>  	[1] = {
> +		.start = SH_TSU_BASE,
> +		.end = SH_TSU_BASE + 0xA00 - 1,

    Same here. I''ll repost...

> +		.flags = IORESOURCE_MEM,
> +	},
> +	[2] = {
>  		.start = SH_ETH1_IRQ,

MBR, Sergei


  reply	other threads:[~2018-01-06  9:24 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-03 20:08 [PATCH 2/2] SolutionEngine771x: add Ether TSU resource Sergei Shtylyov
2018-01-06  9:24 ` Sergei Shtylyov [this message]
2018-01-06 18:53 ` Sergei Shtylyov

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=405370a2-d421-be13-c051-ac972d083d95@cogentembedded.com \
    --to=sergei.shtylyov@cogentembedded.com \
    --cc=dalias@libc.org \
    --cc=linux-sh@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=ysato@users.sourceforge.jp \
    /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;
as well as URLs for NNTP newsgroup(s).