Subject: Re: [PATCH v3]: Fix e500 v2 core reboot bug

From: Segher Boessenkool <[email-masked]>
Date: Wed, 13 Jun 2007 06:44:50 +0200

> +		global-utilities@e0000 {	//global utilities reg
> +			compatible = "fsl,mpc8548-guts";
> +			reg = <e0000 1000>;
> +			fsl,has-rstcr;
> +		};

Looks good.

> +	np = of_find_node_by_name(NULL, "global-utilities");
> +	if ((np && of_get_property(np, "fsl,has-rstcr", NULL))) {
> +		const u32 *prop = of_get_property(np, "reg", NULL);
> +		if (prop) {
> +		/* map reset control register
> +		 * 0xE00B0 is offset of reset control register
> +		 */
> +			rstcr = ioremap(get_immrbase() + *prop + 0xB0, 0xff);
> +			if (!rstcr)
> +				printk (KERN_EMERG "Error: reset control register not mapped, 
> spinning!\n");
> +		}
> +	else
> +		printk (KERN_INFO "rstcr compatible register does not exist!\n");
> +	}

This needs an of_node_put(np).  Oh and the indenting
is off.

Segher