[PATCH][RFC] OCP support for MPC107 and relatives

Kumar Gala kumar.gala at freescale.com
Tue Jun 15 10:38:51 EST 2004


Matt,

We know have several systems which have the same issue of updating a
paddr based on some offset.

I'm wondering if we should add something like the following code into
ocp.c (obviously, removing the 85xx specific aspects).

Called w/in board code:

         ocp_for_each_device(mpc85xx_update_paddr_ocp,
&(binfo->bi_immr_base));

Or should we have a more explicit ocp_update_paddr(phys_addr_t x);

/*
************************************************************************
  */
/* Update the 85xx OCP tables paddr field */
void
mpc85xx_update_paddr_ocp(struct ocp_device *dev, void *arg)
{
         phys_addr_t ccsrbar;
         if (arg) {
                 ccsrbar = *(phys_addr_t *)arg;
                 dev->def->paddr += ccsrbar;
         }
}

- kumar


** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/





More information about the Linuxppc-embedded mailing list