[POWERPC] micro optimise pSeries_probe
We find the OF root the line before, we may as well use it. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
This commit is contained in:
committed by
Paul Mackerras
parent
f050982a9b
commit
5773bbcdec
@@ -433,8 +433,8 @@ static int __init pSeries_probe_hypertas(unsigned long node,
|
|||||||
static int __init pSeries_probe(void)
|
static int __init pSeries_probe(void)
|
||||||
{
|
{
|
||||||
unsigned long root = of_get_flat_dt_root();
|
unsigned long root = of_get_flat_dt_root();
|
||||||
char *dtype = of_get_flat_dt_prop(of_get_flat_dt_root(),
|
char *dtype = of_get_flat_dt_prop(root, "device_type", NULL);
|
||||||
"device_type", NULL);
|
|
||||||
if (dtype == NULL)
|
if (dtype == NULL)
|
||||||
return 0;
|
return 0;
|
||||||
if (strcmp(dtype, "chrp"))
|
if (strcmp(dtype, "chrp"))
|
||||||
|
Reference in New Issue
Block a user