[PATCHv3 1/2] ppc64: perform proper max_bus_speed detection
Michael Ellerman
michael at ellerman.id.au
Sun Apr 14 22:00:02 PDT 2013
On Thu, Apr 11, 2013 at 10:13:13AM -0300, Lucas Kannebley Tavares wrote:
> On pseries machines the detection for max_bus_speed should be done
> through an OpenFirmware property. This patch adds a function to perform this
> detection and a hook to perform dynamic adding of the function only for
> pseries.
The crucial detail you didn't mention is that pcibios_root_bridge_prepare()
already exists as a weak function in the PCI code and is called from
pci_create_root_bus().
> diff --git a/arch/powerpc/platforms/pseries/setup.c b/arch/powerpc/platforms/pseries/setup.c
> index 8bcc9ca..15796b5 100644
> --- a/arch/powerpc/platforms/pseries/setup.c
> +++ b/arch/powerpc/platforms/pseries/setup.c
> @@ -430,6 +430,8 @@ static void pSeries_machine_kexec(struct kimage *image)
> }
> #endif
>
> +int pseries_root_bridge_prepare(struct pci_host_bridge *bridge);
> +
Don't do that, put it in a header where it belongs.
cheers
More information about the dri-devel
mailing list