public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Peng Fan <b51431@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 2/8] imx: mx6: Add MX6DQP CPU rev type
Date: Wed, 10 Jun 2015 18:01:47 +0800	[thread overview]
Message-ID: <20150610100146.GB26860@shlinux2> (raw)
In-Reply-To: <5578010B.7030603@denx.de>

Hi Stefano,

On Wed, Jun 10, 2015 at 11:19:07AM +0200, Stefano Babic wrote:
>Hi Peng,
>
>On 10/06/2015 10:06, Peng Fan wrote:
>> Add new cpu type for i.MX6DQP and providing a dynamical
>> detecting function.
>> 
>> Signed-off-by: Peng Fan <Peng.Fan@freescale.com>
>> Signed-off-by: Ye.Li <B37916@freescale.com>
>> ---
>>  arch/arm/cpu/armv7/mx6/soc.c              | 4 +++-
>>  arch/arm/include/asm/arch-mx6/imx-regs.h  | 1 +
>>  arch/arm/include/asm/arch-mx6/sys_proto.h | 6 ++++++
>>  3 files changed, 10 insertions(+), 1 deletion(-)
>> 
>> diff --git a/arch/arm/cpu/armv7/mx6/soc.c b/arch/arm/cpu/armv7/mx6/soc.c
>> index b21bd03..29de624 100644
>> --- a/arch/arm/cpu/armv7/mx6/soc.c
>> +++ b/arch/arm/cpu/armv7/mx6/soc.c
>> @@ -62,6 +62,7 @@ u32 get_cpu_rev(void)
>>  	struct anatop_regs *anatop = (struct anatop_regs *)ANATOP_BASE_ADDR;
>>  	u32 reg = readl(&anatop->digprog_sololite);
>>  	u32 type = ((reg >> 16) & 0xff);
>> +	u32 major;
>>  
>>  	if (type != MXC_CPU_MX6SL) {
>>  		reg = readl(&anatop->digprog);
>> @@ -79,8 +80,9 @@ u32 get_cpu_rev(void)
>>  		}
>>  
>>  	}
>> +	major = ((reg >> 8) & 0xff);
>>  	reg &= 0xff;		/* mx6 silicon revision */
>> -	return (type << 12) | (reg + 0x10);
>> +	return (type << 12) | (reg + (0x10 * (major + 1)));
>>  }
>>  
>>  /*
>> diff --git a/arch/arm/include/asm/arch-mx6/imx-regs.h b/arch/arm/include/asm/arch-mx6/imx-regs.h
>> index 0d38d45..35a324c 100644
>> --- a/arch/arm/include/asm/arch-mx6/imx-regs.h
>> +++ b/arch/arm/include/asm/arch-mx6/imx-regs.h
>> @@ -312,6 +312,7 @@
>>  #define CHIP_REV_1_0                 0x10
>>  #define CHIP_REV_1_2                 0x12
>>  #define CHIP_REV_1_5                 0x15
>> +#define CHIP_REV_2_0                 0x20
>>  #ifndef CONFIG_MX6SX
>>  #define IRAM_SIZE                    0x00040000
>>  #else
>> diff --git a/arch/arm/include/asm/arch-mx6/sys_proto.h b/arch/arm/include/asm/arch-mx6/sys_proto.h
>> index 9c827c9..c1d9c6d 100644
>> --- a/arch/arm/include/asm/arch-mx6/sys_proto.h
>> +++ b/arch/arm/include/asm/arch-mx6/sys_proto.h
>> @@ -2,6 +2,8 @@
>>   * (C) Copyright 2009
>>   * Stefano Babic, DENX Software Engineering, sbabic at denx.de.
>>   *
>> + * (C) Copyright 2009-2015 Freescale Semiconductor, Inc.
>> + *
>>   * SPDX-License-Identifier:	GPL-2.0+
>>   */
>>  
>
>mmhhh..we have already discussed this topic, Copyright should not be
>changed by small changes in a file.
oh. I missed to remove this. Thanks for correcting me.
>
>> @@ -30,6 +32,10 @@ const char *get_imx_type(u32 imxtype);
>>  unsigned imx_ddr_size(void);
>>  void set_chipselect_size(int const);
>>  
>> +#define is_mx6dqp() ((is_cpu_type(MXC_CPU_MX6Q) || \
>> +		     is_cpu_type(MXC_CPU_MX6D)) && \
>> +		     (is_soc_rev(CHIP_REV_2_0) >= 0))
>> +
>
>As "insider" you could better explain me: it looks like there will be
>not a Quad/Dual with an increased chip revision. The new chip revision
>for i.MX6 is really the QP  (P=perfect, as I see some workaround can be
>removed !)
>
>Is it correct ? Else this conflicts if a 6Q with a revision > 2 will be
>released.
P mean plus. It is from 6Q, since ic did not give new chip id for id, we use
revision.
>
>Best regards,
>Stefano Babic
>
Regards,
Peng.
>-- 
>=====================================================================
>DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
>HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
>Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
>=====================================================================

-- 

  reply	other threads:[~2015-06-10 10:01 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-10  8:06 [U-Boot] [PATCH 1/8] imx: mx6 cast return type of is_soc_rev to int Peng Fan
2015-06-10  8:06 ` [U-Boot] [PATCH 2/8] imx: mx6: Add MX6DQP CPU rev type Peng Fan
2015-06-10  9:19   ` Stefano Babic
2015-06-10 10:01     ` Peng Fan [this message]
2015-06-10 10:09       ` Stefano Babic
2015-06-10  8:06 ` [U-Boot] [PATCH 3/8] imx: mx6: L2cache: Enable the double line fill for i.MX6DQP Peng Fan
2015-06-10  8:06 ` [U-Boot] [PATCH 4/8] imx: mx6: ccm: Change the clock settings for i.MX6QP Peng Fan
2015-06-10  9:23   ` Stefano Babic
2015-06-10 10:03     ` Peng Fan
2015-06-10  8:06 ` [U-Boot] [PATCH 5/8] imx: mx6: hab : Remove the cache issue workaroud in hab " Peng Fan
2015-06-10  8:06 ` [U-Boot] [PATCH 6/8] imx: mx6qp: Enable PRG clock for IPU Peng Fan
2015-06-10  9:24   ` Stefano Babic
2015-06-10 10:04     ` Peng Fan
2015-06-10  8:06 ` [U-Boot] [PATCH 7/8] imx: mx6qpsabreauto: Add MX6QP SABREAUTO CPU3 board support Peng Fan
2015-06-10  9:40   ` Stefano Babic
2015-06-10 10:17     ` Peng Fan
2015-06-10  8:06 ` [U-Boot] [PATCH 8/8] imx: mx6qp: Adjust AQos settings for peripherals Peng Fan
2015-06-10  9:44   ` Stefano Babic
2015-06-10 10:18     ` Peng Fan
2015-06-10  8:20 ` [U-Boot] [PATCH 1/8] imx: mx6 cast return type of is_soc_rev to int Stefano Babic
2015-06-10  8:42   ` 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=20150610100146.GB26860@shlinux2 \
    --to=b51431@freescale.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