[PATCH 2/3] 82xx: Parse SMC serial device node in DTS

Arnd Bergmann arnd at arndb.de
Tue Jul 17 11:02:07 EST 2007


On Monday 16 July 2007, Mark Zhan wrote:
> -               cpm_uart_data.uart_clk = ppc_proc_freq;
> +               if (strstr(model, "SMC")) {
> +                       cpm_uart_dev = platform_device_register_simple("fsl-cpm-smc:uart",
> +                                                       i, &r[0], 3);
> +               } else if (strstr(model, "SCC")) {
> +                       cpm_uart_dev = platform_device_register_simple("fsl-cpm-scc:uart",
> +                                                       i, &r[0], 3);
> +               }
> 

You should probably use of_device_is_compatible() to check
if a given device can be used by a particular driver.

	Arnd <><


More information about the Linuxppc-dev mailing list