All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefan Roese <sr@denx.de>
To: "Marek Behún" <marek.behun@nic.cz>
Cc: u-boot@lists.denx.de, pali@kernel.org
Subject: Re: [PATCH u-boot-marvell 2/9] arm: mvebu: a38x: serdes: Remove duplicate macro SOC_CTRL_REG
Date: Fri, 8 Oct 2021 08:26:52 +0200	[thread overview]
Message-ID: <830716f3-8121-478d-5d4b-77513887cd38@denx.de> (raw)
In-Reply-To: <20210924205922.25432-3-marek.behun@nic.cz>

On 24.09.21 22:59, Marek Behún wrote:
> From: Pali Rohár <pali@kernel.org>
> 
> SoC Control 1 Register (offset 0x18204) is already defined by macro
> SOC_CONTROL_REG1.
> 
> Use macro SOC_CONTROL_REG1 instead of macro SOC_CTRL_REG in ctrl_pex.c
> code and remove the other definition.
> 
> Signed-off-by: Pali Rohár <pali@kernel.org>
> Reviewed-by: Marek Behún <marek.behun@nic.cz>

Reviewed-by: Stefan Roese <sr@denx.de>

Thanks,
Stefan

> ---
>   arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.c | 4 ++--
>   arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.h | 4 ----
>   2 files changed, 2 insertions(+), 6 deletions(-)
> 
> diff --git a/arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.c b/arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.c
> index adef3331a7..717bcfb29c 100644
> --- a/arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.c
> +++ b/arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.c
> @@ -49,7 +49,7 @@ int hws_pex_config(const struct serdes_map *serdes_map, u8 count)
>   		reg_write(PEX_CAPABILITIES_REG(pex_idx), tmp);
>   	}
>   
> -	tmp = reg_read(SOC_CTRL_REG);
> +	tmp = reg_read(SOC_CONTROL_REG1);
>   	tmp &= ~0x03;
>   
>   	for (idx = 0; idx < count; idx++) {
> @@ -79,7 +79,7 @@ int hws_pex_config(const struct serdes_map *serdes_map, u8 count)
>   		}
>   	}
>   
> -	reg_write(SOC_CTRL_REG, tmp);
> +	reg_write(SOC_CONTROL_REG1, tmp);
>   
>   	/* Support gen1/gen2 */
>   	DEBUG_INIT_FULL_S("Support gen1/gen2\n");
> diff --git a/arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.h b/arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.h
> index 3f30b6bf97..a882d24208 100644
> --- a/arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.h
> +++ b/arch/arm/mach-mvebu/serdes/a38x/ctrl_pex.h
> @@ -14,10 +14,6 @@
>   /* PCI Express Control and Status Registers */
>   #define MAX_PEX_BUSSES			256
>   
> -#define MISC_REGS_OFFSET		0x18200
> -#define MV_MISC_REGS_BASE		MISC_REGS_OFFSET
> -#define SOC_CTRL_REG			(MV_MISC_REGS_BASE + 0x4)
> -
>   #define PEX_IF_REGS_OFFSET(if)		((if) > 0 ?			\
>   					 (0x40000 + ((if) - 1) * 0x4000) : \
>   					 0x80000)
> 


Viele Grüße,
Stefan

-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: sr@denx.de

  reply	other threads:[~2021-10-08  6:27 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-24 20:59 [PATCH u-boot-marvell 0/9] a38x serdes cleanup Marek Behún
2021-09-24 20:59 ` [PATCH u-boot-marvell 1/9] arm: mvebu: a38x: serdes: Add comments and use macros in PCIe code Marek Behún
2021-10-08  6:24   ` Stefan Roese
2021-09-24 20:59 ` [PATCH u-boot-marvell 2/9] arm: mvebu: a38x: serdes: Remove duplicate macro SOC_CTRL_REG Marek Behún
2021-10-08  6:26   ` Stefan Roese [this message]
2021-09-24 20:59 ` [PATCH u-boot-marvell 3/9] arm: mvebu: a38x: serdes: Add comments for hws_pex_config() code Marek Behún
2021-10-08  6:27   ` Stefan Roese
2021-09-24 20:59 ` [PATCH u-boot-marvell 4/9] arm: mvebu: a38x: serdes: Don't overwrite read-only SAR PCIe registers Marek Behún
2021-10-08  6:27   ` Stefan Roese
2021-09-24 20:59 ` [PATCH u-boot-marvell 5/9] arm: mvebu: a38x: serdes: Don't set PCIe Common Clock Configuration Marek Behún
2021-10-08  6:28   ` Stefan Roese
2021-09-24 20:59 ` [PATCH u-boot-marvell 6/9] arm: mvebu: a38x: serdes: Don't overwrite PCI device ID Marek Behún
2021-10-08  6:28   ` Stefan Roese
2021-09-24 20:59 ` [PATCH u-boot-marvell 7/9] arm: mvebu: a38x: serdes: Don't configure PCIe cards in SerDes init code Marek Behún
2021-10-08  6:29   ` Stefan Roese
2021-09-24 20:59 ` [PATCH u-boot-marvell 8/9] arm: mvebu: a38x: serdes: Remove unused PCIe macros and functions Marek Behún
2021-10-08  6:29   ` Stefan Roese
2021-09-24 20:59 ` [PATCH u-boot-marvell 9/9] arm: mvebu: a38x: serdes: Update comment about PCIE*_ENABLE_* defines Marek Behún
2021-10-08  6:30   ` Stefan Roese
2021-10-08  6:31 ` [PATCH u-boot-marvell 0/9] a38x serdes cleanup Stefan Roese
2021-10-08  9:18 ` Stefan Roese

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=830716f3-8121-478d-5d4b-77513887cd38@denx.de \
    --to=sr@denx.de \
    --cc=marek.behun@nic.cz \
    --cc=pali@kernel.org \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.