All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aneesh V <aneesh@ti.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 7/8] armv7: adapt omap3 to the new cache maintenance framework
Date: Mon, 10 Jan 2011 20:11:20 +0530	[thread overview]
Message-ID: <4D2B1A90.9030109@ti.com> (raw)
In-Reply-To: <20110109225729.4695B127@gemini.denx.de>

Dear Wolfgang,

On Monday 10 January 2011 04:27 AM, Wolfgang Denk wrote:
> Dear Aneesh V,
>
> In message<1293018898-13253-8-git-send-email-aneesh@ti.com>  you wrote:
>> adapt omap3 to the new layered cache maintenance framework
> ...
>
>> +/* Declarations */
>
> Please drop this comment.  Everybody sees what this is.

ok.

>
>> +#ifndef CONFIG_L2_OFF
>>   	/*
>> -	 * Writing to AuxCR in U-boot using SMI for GP DEV
>> -	 * Currently SMI in Kernel on ES2 devices seems to have an issue
>> -	 * Once that is resolved, we can postpone this config to kernel
>> +	 * Invalidate L2-cache from secure mode
>>   	 */
>
> Why not change this into simple
>
> 	/* Invalidate L2-cache from secure mode */
>
> ?

ok.

>
> ...
>> +static void omap3_emu_romcode_call(u32 service_id, u32 *parameters)
>> +{
>> +	u32 i, num_params = *parameters;
>> +	u32 *sram_scratch_space = (u32 *)OMAP3_PUBLIC_SRAM_SCRATCH_AREA;
>> +	/*
>> +	 * copy the parameters to an un-cached area to avoid coherency
>> +	 * issues
>> +	 */
>> +	for (i = 0; i<  num_params; i++) {
>> +		__raw_writel(*parameters, sram_scratch_space);
>> +		parameters++;
>> +		sram_scratch_space++;
>> +	}
>
> Do you have unlimited storage there?  Or should you add some check not
> to exceed some maximum size?

Number of params is typically 1 or 2. We should have enough space
unless the usage is wrong.

>
>> +	} else {
>> +		struct emu_hal_params emu_romcode_params;
>> +		emu_romcode_params.num_params = 1;
>> +		emu_romcode_params.param1 = acr;
>> +		omap3_emu_romcode_call(OMAP3_EMU_HAL_API_WRITE_ACR,
>> +				       (u32 *)&emu_romcode_params);
>
> Please add a blank line between declarations and code (fix globally).

ok.

>
>> +static void omap3_setup_aux_cr(void)
>> +{
>> +	/* Workaround for Cortex-A8 errata: #454179 #430973
>> +	 *	Set "IBE" bit
> ...
> Incorrect multiline comment style.

Will correct it.

>
> ...
>> diff --git a/arch/arm/include/asm/arch-omap3/sys_proto.h b/arch/arm/include/asm/arch-omap3/sys_proto.h
>> index 4a28ba1..25f54ea 100644
>> --- a/arch/arm/include/asm/arch-omap3/sys_proto.h
>> +++ b/arch/arm/include/asm/arch-omap3/sys_proto.h
>> @@ -27,6 +27,11 @@ typedef struct {
>>   	char *nand_string;
>>   } omap3_sysinfo;
>>
>> +struct __attribute__ ((__packed__)) emu_hal_params {
>> +	u32 num_params;
>> +	u32 param1;
>> +};
>
> Why exactly do we need the "__attribute__ ((__packed__))" here?

Because a pointer to it has to be passed to ROM code and ROM code
wouldn't expect any padding.

>
>
> Best regards,
>
> Wolfgang Denk
>

Best regards,
Aneesh

  reply	other threads:[~2011-01-10 14:41 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-22 11:54 [U-Boot] [PATCH 0/8] armv7: cache maintenance operations Aneesh V
2010-12-22 11:54 ` [U-Boot] [PATCH 1/8] arm: make default implementation of cache_flush() weakly linked Aneesh V
2011-01-08  6:40   ` Albert ARIBAUD
2010-12-22 11:54 ` [U-Boot] [PATCH 2/8] armv7: cache maintenance operations for armv7 Aneesh V
2011-01-08  6:36   ` Albert ARIBAUD
2011-01-08  8:40     ` Albert ARIBAUD
2011-01-08 10:06     ` Aneesh V
2011-01-12 19:18       ` Albert ARIBAUD
2011-01-13 11:10         ` Aneesh V
2011-01-13 12:14         ` Aneesh V
2011-01-13 17:12           ` Albert ARIBAUD
2011-01-08 13:17     ` Aneesh V
2011-01-08 14:06       ` Albert ARIBAUD
2011-01-09 22:41         ` Wolfgang Denk
2011-01-10  4:56           ` Aneesh V
2011-01-17 21:47             ` Wolfgang Denk
2011-01-12  9:08         ` Aneesh V
2011-01-12 19:23           ` Albert ARIBAUD
2011-01-13 12:05             ` Aneesh V
2011-01-13 13:14               ` Albert ARIBAUD
2011-01-13 14:30                 ` Aneesh V
2011-01-13 17:06                   ` Albert ARIBAUD
2011-03-01 11:54     ` Aneesh V
2011-03-01 13:36       ` Albert ARIBAUD
2010-12-22 11:54 ` [U-Boot] [PATCH 3/8] armv7: integrate cache maintenance support Aneesh V
2011-01-08  6:54   ` Albert ARIBAUD
2011-01-08  8:15     ` Aneesh V
2010-12-22 11:54 ` [U-Boot] [PATCH 4/8] arm: minor fixes for cache and mmu handling Aneesh V
2011-01-08  7:04   ` Albert ARIBAUD
2011-01-08  9:13     ` Aneesh V
2010-12-22 11:54 ` [U-Boot] [PATCH 5/8] armv7: add PL310 support to u-boot Aneesh V
2011-01-09 22:48   ` Wolfgang Denk
2011-01-10 13:41     ` Aneesh V
2010-12-22 11:54 ` [U-Boot] [PATCH 6/8] armv7: adapt omap4 to the new cache maintenance framework Aneesh V
2011-01-09 22:52   ` Wolfgang Denk
2011-01-10 14:33     ` Aneesh V
2011-01-17 21:52       ` Wolfgang Denk
2010-12-22 11:54 ` [U-Boot] [PATCH 7/8] armv7: adapt omap3 " Aneesh V
2011-01-09 22:57   ` Wolfgang Denk
2011-01-10 14:41     ` Aneesh V [this message]
2011-01-17 21:55       ` Wolfgang Denk
2011-01-18  5:31         ` Aneesh V
2011-01-18  9:23           ` Wolfgang Denk
2010-12-22 11:54 ` [U-Boot] [PATCH 8/8] armv7: adapt s5pc1xx " Aneesh V
2010-12-27  7:25   ` Minkyu Kang
2010-12-27 11:22     ` Aneesh V
2011-01-07  5:27       ` Minkyu Kang
2010-12-23  4:53 ` [U-Boot] [PATCH 0/8] armv7: cache maintenance operations Steve Sakoman
2010-12-28 19:51 ` Paulraj, Sandeep
2011-01-08  7:07   ` Albert ARIBAUD

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=4D2B1A90.9030109@ti.com \
    --to=aneesh@ti.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 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.