[U-Boot] [PATCH] powerpc: add support for the Freescale P1022DS reference board
Timur Tabi
timur at freescale.com
Wed May 26 20:12:09 CEST 2010
Wolfgang Denk wrote:
>>> > > Hm... looks as if you were repeating the same code 3 times. Please make
>>> > > this a function.
>> >
>> > The code isn't really the same. I would need to pass a lot of
>> > parameters to this function: the hose, the devdisr mask, the slot
>> > name, the slot number, the bus number, and so on.
> Actually it is not that many arguments.
It is. Here's the prototype I came up with;
static int configure_pci(enum srds_prtcl pci,
const char *name,
const char *target,
int endpoint,
int first_free_busno,
phys_addr_t mem_addr,
enum law_size mem_size,
phys_addr_t io_addr,
enum law_size io_size,
struct fsl_pci_info *pci_info,
struct pci_controller *hose);
Are you sure you would really rather see this as its own function?
--
Timur Tabi
Linux kernel developer at Freescale
More information about the U-Boot
mailing list