mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Alexander Kurz <akurz@blala.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 1/5] ARM i.MX: move cpu_type macros in front of cpu_revision code
Date: Wed, 1 Feb 2017 09:04:22 +0100	[thread overview]
Message-ID: <20170201080422.jon2ewtezc66axbi@pengutronix.de> (raw)
In-Reply-To: <1485816659-26091-1-git-send-email-akurz@blala.de>

On Mon, Jan 30, 2017 at 11:50:55PM +0100, Alexander Kurz wrote:
> Preparational commit to enable the use of cpu_type macros in imx6_cpu_revision()
> 
> Signed-off-by: Alexander Kurz <akurz@blala.de>

Applied patches 1-4 for now.

Sascha

> ---
>  arch/arm/mach-imx/include/mach/imx6.h | 40 +++++++++++++++++------------------
>  1 file changed, 20 insertions(+), 20 deletions(-)
> 
> diff --git a/arch/arm/mach-imx/include/mach/imx6.h b/arch/arm/mach-imx/include/mach/imx6.h
> index 8c169f1..e201721 100644
> --- a/arch/arm/mach-imx/include/mach/imx6.h
> +++ b/arch/arm/mach-imx/include/mach/imx6.h
> @@ -50,6 +50,26 @@ static inline int imx6_cpu_type(void)
>  	return __imx6_cpu_type();
>  }
>  
> +#define DEFINE_MX6_CPU_TYPE(str, type)					\
> +	static inline int cpu_mx6_is_##str(void)			\
> +	{								\
> +		return __imx6_cpu_type() == type;			\
> +	}								\
> +									\
> +	static inline int cpu_is_##str(void)				\
> +	{								\
> +		if (!cpu_is_mx6())					\
> +			return 0;					\
> +		return cpu_mx6_is_##str();				\
> +	}
> +
> +DEFINE_MX6_CPU_TYPE(mx6s, IMX6_CPUTYPE_IMX6S);
> +DEFINE_MX6_CPU_TYPE(mx6dl, IMX6_CPUTYPE_IMX6DL);
> +DEFINE_MX6_CPU_TYPE(mx6q, IMX6_CPUTYPE_IMX6Q);
> +DEFINE_MX6_CPU_TYPE(mx6d, IMX6_CPUTYPE_IMX6D);
> +DEFINE_MX6_CPU_TYPE(mx6sx, IMX6_CPUTYPE_IMX6SX);
> +DEFINE_MX6_CPU_TYPE(mx6ul, IMX6_CPUTYPE_IMX6UL);
> +
>  static inline int __imx6_cpu_revision(void)
>  {
>  
> @@ -85,24 +105,4 @@ static inline int imx6_cpu_revision(void)
>  	return __imx6_cpu_revision();
>  }
>  
> -#define DEFINE_MX6_CPU_TYPE(str, type)					\
> -	static inline int cpu_mx6_is_##str(void)			\
> -	{								\
> -		return __imx6_cpu_type() == type;			\
> -	}								\
> -									\
> -	static inline int cpu_is_##str(void)				\
> -	{								\
> -		if (!cpu_is_mx6())					\
> -			return 0;					\
> -		return cpu_mx6_is_##str();				\
> -	}
> -
> -DEFINE_MX6_CPU_TYPE(mx6s, IMX6_CPUTYPE_IMX6S);
> -DEFINE_MX6_CPU_TYPE(mx6dl, IMX6_CPUTYPE_IMX6DL);
> -DEFINE_MX6_CPU_TYPE(mx6q, IMX6_CPUTYPE_IMX6Q);
> -DEFINE_MX6_CPU_TYPE(mx6d, IMX6_CPUTYPE_IMX6D);
> -DEFINE_MX6_CPU_TYPE(mx6sx, IMX6_CPUTYPE_IMX6SX);
> -DEFINE_MX6_CPU_TYPE(mx6ul, IMX6_CPUTYPE_IMX6UL);
> -
>  #endif /* __MACH_IMX6_H */
> -- 
> 2.1.4
> 
> 
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
> 

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  parent reply	other threads:[~2017-02-01  8:04 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-30 22:50 Alexander Kurz
2017-01-30 22:50 ` [PATCH 2/5] ARM i.MX: add SoC type detection for i.MX6SL Alexander Kurz
2017-01-30 22:50 ` [PATCH 3/5] ARM: i.MX6SL: import clock infrastructure from linux Alexander Kurz
2017-01-30 22:50 ` [PATCH 4/5] ARM i.MX: Add i.MX6SL support Alexander Kurz
2017-01-30 22:50 ` [PATCH 5/5] ARM i.MX6SL: Add support for the Tolino Vision, Vision2 and Vision3HD Alexander Kurz
2017-02-01  8:03   ` Sascha Hauer
2017-02-01  8:04 ` Sascha Hauer [this message]
2017-02-01 20:53   ` [PATCH 1/5] ARM i.MX: move cpu_type macros in front of cpu_revision code Alexander Kurz
2017-02-02  7:14     ` 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=20170201080422.jon2ewtezc66axbi@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=akurz@blala.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