linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Shawn Guo <shawnguo@kernel.org>
To: peng.fan@nxp.com
Cc: linux-arm-kernel@lists.infradead.org, abel.vesa@nxp.com,
	Anson.Huang@nxp.com, ard.biesheuvel@linaro.org,
	festevam@gmail.com, s.hauer@pengutronix.de,
	linux-kernel@vger.kernel.org, linux-imx@nxp.com,
	kernel@pengutronix.de, git@andred.net, leonard.crestez@nxp.com,
	info@metux.net, allison@lohutok.net
Subject: Re: [PATCH V1 2/4] ARM: imx: cpu: drop dead code
Date: Wed, 29 Apr 2020 10:32:02 +0800	[thread overview]
Message-ID: <20200429023201.GJ32592@dragon> (raw)
In-Reply-To: <1584004645-26720-3-git-send-email-peng.fan@nxp.com>

On Thu, Mar 12, 2020 at 05:17:23PM +0800, peng.fan@nxp.com wrote:
> From: Peng Fan <peng.fan@nxp.com>
> 
> imx_soc_device_init is only called by i.MX6Q/SL/SX/UL/7D/7ULP.
> So we could drop the switch case for i.MX1/2/3/5 which are dead code
> that never be executed.
> 
> Signed-off-by: Peng Fan <peng.fan@nxp.com>
> ---
>  arch/arm/mach-imx/cpu.c | 24 ------------------------
>  1 file changed, 24 deletions(-)
> 
> diff --git a/arch/arm/mach-imx/cpu.c b/arch/arm/mach-imx/cpu.c
> index 2df649a84697..0302cb66134b 100644
> --- a/arch/arm/mach-imx/cpu.c
> +++ b/arch/arm/mach-imx/cpu.c
> @@ -108,30 +108,6 @@ static int __init imx_soc_device_init(void)
>  		goto free_soc;
>  
>  	switch (__mxc_cpu_type) {
> -	case MXC_CPU_MX1:
> -		soc_id = "i.MX1";
> -		break;
> -	case MXC_CPU_MX21:
> -		soc_id = "i.MX21";
> -		break;
> -	case MXC_CPU_MX25:
> -		soc_id = "i.MX25";
> -		break;
> -	case MXC_CPU_MX27:
> -		soc_id = "i.MX27";
> -		break;
> -	case MXC_CPU_MX31:
> -		soc_id = "i.MX31";
> -		break;
> -	case MXC_CPU_MX35:
> -		soc_id = "i.MX35";
> -		break;
> -	case MXC_CPU_MX51:
> -		soc_id = "i.MX51";
> -		break;
> -	case MXC_CPU_MX53:
> -		soc_id = "i.MX53";
> -		break;

The code is here to completeness.  If it doesn't get in your way, let's
just keep it.

Shawn

>  	case MXC_CPU_IMX6SL:
>  		ocotp_compat = "fsl,imx6sl-ocotp";
>  		soc_id = "i.MX6SL";
> -- 
> 2.16.4
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2020-04-29  2:32 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-12  9:17 [PATCH V1 0/4] ARM: imx: move cpu code to drivers/soc/imx peng.fan
2020-03-12  9:17 ` [PATCH V1 1/4] ARM: imx: use device_initcall for imx_soc_device_init peng.fan
2020-04-29  2:25   ` Shawn Guo
2020-03-12  9:17 ` [PATCH V1 2/4] ARM: imx: cpu: drop dead code peng.fan
2020-04-29  2:32   ` Shawn Guo [this message]
2020-03-12  9:17 ` [PATCH V1 3/4] ARM: imx: move cpu definitions into a header peng.fan
2020-03-12  9:17 ` [PATCH V1 4/4] soc: imx: move cpu code to drivers/soc/imx peng.fan

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=20200429023201.GJ32592@dragon \
    --to=shawnguo@kernel.org \
    --cc=Anson.Huang@nxp.com \
    --cc=abel.vesa@nxp.com \
    --cc=allison@lohutok.net \
    --cc=ard.biesheuvel@linaro.org \
    --cc=festevam@gmail.com \
    --cc=git@andred.net \
    --cc=info@metux.net \
    --cc=kernel@pengutronix.de \
    --cc=leonard.crestez@nxp.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-imx@nxp.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peng.fan@nxp.com \
    --cc=s.hauer@pengutronix.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;
as well as URLs for NNTP newsgroup(s).