From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tolunay Orkun Date: Thu, 12 May 2005 17:13:39 -0500 Subject: [U-Boot-Users] cfi_flash.c bug regarding intel k3 devices In-Reply-To: <20050512195653.GB20585@ku-gbr.de> References: <20050512142803.GA4333@synertronixx3> <42838112.6090805@orkun.us> <20050512195653.GB20585@ku-gbr.de> Message-ID: <4283D513.9050702@orkun.us> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Konstantin Kletschke wrote: > Only after manual "protect off x:y-z" I can erase something. That is the idea. It is supposed to work this way as far as I understand. Don't change this behavior... > Before I could _nothing_ write to the chip. Well, I could but nothing > happened. Kinda hardware locked. If you have not done already, I think you should enable hardware (real) flash protection (CFG_FLASH_PROTECTION) in your board config file. Upon boot do you see all sectors reported (RO) if you use flinfo command? If not, you should look at the initialization of flash_info[].protect[] within flash_get_size() which is called from flash_init(). If this array is not initialized properly, U-Boot might attempt to erase a locked sector/block incorrectly instead of bailing out nicely. I think "saveenv" would have trouble as well. If this is the case, perhaps, FLASH_OFFSET_PROTECT and FLASH_STATUS_PROTECT is not appropriate for your type of flash and you should work on a solution for this instead. Regards, Tolunay