From mboxrd@z Thu Jan 1 00:00:00 1970 From: Felix Radensky Date: Wed, 15 Jul 2009 12:24:07 +0300 Subject: [U-Boot] [PATCH v2] ppc4xx: Add GDsys CompactCenter board support. In-Reply-To: <200907151116.33700.sr@denx.de> References: <200907131057.43061.sr@denx.de> <48D3D52125C49B43AE880038E2E5314B025D10@SRV101.gdsys.de> <200907151116.33700.sr@denx.de> Message-ID: <4A5DA037.9010304@embedded-sol.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi, Stefan Roese wrote: > On Wednesday 15 July 2009 09:28:58 Eibach, Dirk wrote: > >>> Please check the latest version of this code in >>> canyonlands.c. It's now using the 4xx common >>> __ft_board_setup() function. Please move to this version as well. >>> >> This code in canyonlands.c does not work for me: >> >> void ft_board_setup(void *blob, bd_t *bd) >> { >> u32 val[4]; >> int rc; >> >> __ft_board_setup(blob, bd); >> >> /* Fixup NOR mapping */ >> val[0] = CONFIG_SYS_NOR_CS; /* chip select number */ >> val[1] = 0; /* always 0 */ >> val[2] = CONFIG_SYS_FLASH_BASE_PHYS_L; /* we fixed up >> this address */ >> val[3] = gd->bd->bi_flashsize; >> rc = fdt_find_and_setprop(blob, "/plb/opb/ebc", "ranges", >> val, sizeof(val), 1); >> >> __ft_board_setup() sets the property "ranges", with an entry for every >> member of EBC_NUM_BANKS. >> Then the so called "fixup" happens and the property "ranges" is set >> again, this time with only one entry (for the nor flash). All other >> entries are lost. >> > > I see. I didn't spot this problem in the original patch. Thanks for catching. > > It shouldn't be too hard to fix this problem by reading the complete ranges > array back and patching only the first entry and re-writing ranges again. > > I think my first patch that open-coded part of ft_board_setup() related to EBC ranges was correct and tested on real hardware. I admit that I didn't test the second version of the patch, as I didn't have the hardware at hand. I'll submit a fix soon, but I still don't have hardware for testing, so I'd appreciate your help with that. Felix.