/* The MPC824x has an integrated PCI controller known as the MPC107. The following are MPC107 Bridge Controller and PCI Support functions This procedure reads a 32-bit address MPC107 register, and returns a 32 bit value. It swaps the address to little endian before writing it to config address, and swaps the value to big endian before returning to the caller.  */
unsigned int mpc824x_mpc107_getreg(unsigned int regNum)
/* The MPC824x has an integrated PCI controller known as the MPC107. The following are MPC107 Bridge Controller and PCI Support functions This procedure reads a 32-bit address MPC107 register, and returns a 32 bit value. It swaps the address to little endian before writing it to config address, and swaps the value to big endian before returning to the caller.  */
unsigned int mpc824x_mpc107_getreg(unsigned int regNum)
{
	unsigned int temp;
	*(volatile unsigned int *) CHRP_REG_ADDR = PCISWAP (regNum);
	temp = *(volatile unsigned int *) CHRP_REG_DATA;
	return PCISWAP (temp);
}