From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefan Roese Date: Wed, 1 Jun 2011 17:34:29 +0200 Subject: [U-Boot] Reg. CFI flash_init and hardware write protected devices In-Reply-To: References: <201105311637.13721.sr@denx.de> Message-ID: <201106011734.29911.sr@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Frank, On Wednesday 01 June 2011 16:33:14 Frank Svendsb?e wrote: > >> Simply because disabling write-protection is not impossible after > >> installation. Our device will be located 3000m below sea level. > > > > I see. > > Hmm.. then you read my mind :) I meant to say "is not possible" and not "is > not impossible" :) Yep. I read so fast, that I didn't catch the misspelled words. ;) > Thanks, this worked for me. Is it ok for you too? > > diff --git a/drivers/mtd/cfi_flash.c b/drivers/mtd/cfi_flash.c > index 6039e1f..99360af 100644 > --- a/drivers/mtd/cfi_flash.c > +++ b/drivers/mtd/cfi_flash.c > @@ -176,6 +176,7 @@ u64 flash_read64(void *addr)__attribute__((weak, > alias("__flash_read64"))); > #define flash_read64 __flash_read64 > #endif > > + Don't add this empty line. > /*----------------------------------------------------------------------- > */ > #if defined(CONFIG_ENV_IS_IN_FLASH) || > defined(CONFIG_ENV_ADDR_REDUND) || (CONFIG_SYS_MONITOR_BASE >= > CONFIG_SYS_FLASH_BASE) > @@ -2151,7 +2152,8 @@ void flash_protect_default(void) > #endif > } > > -unsigned long flash_init (void) > +unsigned long flash_init(void) __attribute__((weak, > alias("__flash_init"))); +unsigned long __flash_init (void) > { > unsigned long size = 0; > int i; Looks good. I have no objections. Please go ahead and send this as a "proper" patch. Best regards, Stefan -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-0 Fax: (+49)-8142-66989-80 Email: office at denx.de