[U-Boot] [PATCH v2 3/5] Add support for TQM-specific chip select logic to FSL-UPM
Scott Wood
scottwood at freescale.com
Fri Feb 13 22:35:23 CET 2009
Wolfgang Grandegger wrote:
> Scott Wood wrote:
>> On Wed, Feb 11, 2009 at 06:38:22PM +0100, Wolfgang Grandegger wrote:
>>> Index: u-boot/drivers/mtd/nand/fsl_upm.c
>>> ===================================================================
>>> --- u-boot.orig/drivers/mtd/nand/fsl_upm.c
>>> +++ u-boot/drivers/mtd/nand/fsl_upm.c
>>> @@ -90,8 +90,11 @@ static void fun_cmd_ctrl(struct mtd_info
>>> mar = cmd << (32 - fun->width);
>>> io_addr = fun->upm.io_addr;
>>> #if CONFIG_SYS_NAND_MAX_CHIPS > 1
>>> - if (fun->chip_nr > 0)
>>> + if (fun->chip_nr > 0) {
>>> io_addr += fun->chip_offset * fun->chip_nr;
>>> + if (fun->upm_mar_chip_offset)
>>> + mar |= fun->upm_mar_chip_offset * fun->chip_nr;
>>> + }
>> Any particular reason not to drop the > 0 conditional?
>
> No, apart from saving some space. Should I send an updated patch?
BTW, it seems to me that the conditional adds to the image size, rather
than reducing it...
-Scott
More information about the U-Boot
mailing list