aboutsummaryrefslogtreecommitdiffstats
path: root/net/dsa/dsa.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/dsa/dsa.c')
-rw-r--r--net/dsa/dsa.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/dsa/dsa.c b/net/dsa/dsa.c
index 5db37cef50a9..0a49632fac47 100644
--- a/net/dsa/dsa.c
+++ b/net/dsa/dsa.c
@@ -351,8 +351,7 @@ static void dsa_of_free_platform_data(struct dsa_platform_data *pd)
351 for (i = 0; i < pd->nr_chips; i++) { 351 for (i = 0; i < pd->nr_chips; i++) {
352 port_index = 0; 352 port_index = 0;
353 while (port_index < DSA_MAX_PORTS) { 353 while (port_index < DSA_MAX_PORTS) {
354 if (pd->chip[i].port_names[port_index]) 354 kfree(pd->chip[i].port_names[port_index]);
355 kfree(pd->chip[i].port_names[port_index]);
356 port_index++; 355 port_index++;
357 } 356 }
358 kfree(pd->chip[i].rtable); 357 kfree(pd->chip[i].rtable);