
On Wednesday 24 August 2005 7:12 pm, Wolfgang Denk wrote:
Dear Tolunay,
in message 430CEC01.1070800@orkun.us you wrote:
I think Wolfgang votes against this as he expects u-boot to provide him with a common view over many boards - thus seeing the hardware protection by default rather as a design decision to be abstracted by u-boot.
But, he is making an assumption on the usage of portions of flash which is not defined by U-Boot.
I am not. As I wrote before I am aware that specific requirements may exist, and that these shallbe handled where they belong to: in the board specific sections of the code.
Ok I surrender the point that common code shall unprotect all FLASH at boot. Can I ask you to consider a method of allowing the board maintainers to easily override this feature, either through a conditional compile or through a function pointer to be overridden by the board maintainer if desired? Here is my issue, I have been porting ppcboot and u-boot to boards for nearly 4 years now. In all this time I have happend to have used Inelstrata FLASH with hardware protection, the protection was deigned into the product. That said, to forward port these boards to newer version of u-boot I will have to either patch common code, or copy cfi_flash.c to my board directoy remove the unprotect in flash_init() and maintain the copy on common code in each board set. This does not seem to make for the most modular design of u-boot. Can we have a hook such as initflash() that will by default call the common flash_init() if not overridden by the board. At least then I only have to maintain a copy of a single function.