Skip to contentSkip to conversation

bcma: add new cores at the end of list

PATCH New Rafał Miłecki 1 participant 1 message Jul 11, 2012 Broadcom specific amba driver (bcma)

lore
Share & tools
lore

Rafał Miłecki

author maintainer
#0 lore raw

PATCH v2 1/1 bcma: add new cores at the end of list

This makes order in list more natural and fixes core->core_unit for more than 2 cores.

---
V2: fix bcma_bus_scan_early as well

---
 drivers/bcma/scan.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/bcma/scan.c +2 -2
index 3bc3ec2..5672b13 100644
@@ -491,7 +491,7 @@ int bcma_bus_scan(struct bcma_bus *bus)
 			  core->id.manuf, core->id.id, core->id.rev,
 			  core->id.class);
 
-		list_add(&core->list, &bus->cores);
+		list_add_tail(&core->list, &bus->cores);
 	}
 
 	if (bus->hosttype == BCMA_HOSTTYPE_SOC)
@@ -546,7 +546,7 @@ int __init bcma_bus_scan_early(struct bcma_bus *bus,
 			  core->id.manuf, core->id.id, core->id.rev,
 			  core->id.class);
 
-		list_add(&core->list, &bus->cores);
+		list_add_tail(&core->list, &bus->cores);
 		err = 0;
 		break;
 	}
Signature · 1 line
1.7.7