[PATCH v3 3/9] arm: mach-mvebu: add source files

Arnd Bergmann arnd at arndb.de
Fri Jun 15 05:12:56 EDT 2012


On Friday 15 June 2012, Gregory Clement wrote:
> +static int __init mvebu_system_controller_init(void)
> +{
> +       struct device_node *np;
> +
> +       np = of_find_compatible_node(NULL, NULL, "marvell,system-controller");
> +       if (!np) {
> +               pr_warn("No marvell,system-controller found\n");
> +               return -ENODEV;
> +       }

Much better than before, but there are now two problems:

* You look for a generic "marvell,system-controller" node, which does not tell
  you at all which kind it is. I'm sure that inside of Marvell there has been more
  than one peripheral that can be described as a system controller, so please
  be more specific here.

* You should not issue a warning if the device is not found. The initialization
  comes from a platform independent arch_initcall, so in a future combined
  kernel, it will be executed on all machines including non-Marvell ones.

	Arnd



More information about the linux-arm-kernel mailing list