aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/mips/cavium-octeon/octeon-platform.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/mips/cavium-octeon/octeon-platform.c b/arch/mips/cavium-octeon/octeon-platform.c
index 7b746e7bf7a1..1830874ff1e2 100644
--- a/arch/mips/cavium-octeon/octeon-platform.c
+++ b/arch/mips/cavium-octeon/octeon-platform.c
@@ -334,9 +334,10 @@ static void __init octeon_fdt_pip_iface(int pip, int idx, u64 *pmac)
334 char name_buffer[20]; 334 char name_buffer[20];
335 int iface; 335 int iface;
336 int p; 336 int p;
337 int count; 337 int count = 0;
338 338
339 count = cvmx_helper_interface_enumerate(idx); 339 if (cvmx_helper_interface_enumerate(idx) == 0)
340 count = cvmx_helper_ports_on_interface(idx);
340 341
341 snprintf(name_buffer, sizeof(name_buffer), "interface@%d", idx); 342 snprintf(name_buffer, sizeof(name_buffer), "interface@%d", idx);
342 iface = fdt_subnode_offset(initial_boot_params, pip, name_buffer); 343 iface = fdt_subnode_offset(initial_boot_params, pip, name_buffer);