[PATCH] powerpc: consolidate mpc83xx platform files
Kumar Gala
galak at kernel.crashing.org
Tue Dec 19 04:04:55 EST 2006
On Dec 17, 2006, at 11:17 PM, Paul Mackerras wrote:
> Kim Phillips writes:
>
>> so the contents of 83xx/fsl.c would look like:
>> #ifdef CONFIG_MPC834x_SYS
>> define_machine(mpc834x_sys) {
>> .name = "MPC834x SYS",
>> .probe = mpc83xx_probe,
>> .setup_arch = mpc83xx_setup_arch,
>> .init_IRQ = mpc83xx_init_IRQ,
>> .get_irq = ipic_get_irq,
>> .restart = mpc83xx_restart,
>> .time_init = mpc83xx_time_init,
>> .calibrate_decr = generic_calibrate_decr,
>> .progress = udbg_progress,
>> };
>> #else
>
> Why do you have this #else here? Doesn't it just restrict you for no
> gain?
I think you're looking at an old version of the patch.
>> #ifdef CONFIG_MPC834x_ITX
>> define_machine(mpc83xx) {
>> .name = "MPC834x ITX",
>> <rest is the same>
>
> Your probe function can set ppc_md.name to whatever it wants. So you
> could have a define_machine(fsl_83xx_eval_board) whose probe function
> would pick up the actual board name from the device tree (e.g. the
> root node's model property), put that in ppc_md and return 1 (assuming
> of course that the device tree looks like one of your boards).
>
> Paul.
More information about the Linuxppc-dev
mailing list