From 634ec6c23b4037ec6efc2a594fd6b666339171e9 Mon Sep 17 00:00:00 2001 From: Andrew Thoelke Date: Mon, 9 Jun 2014 12:54:15 +0100 Subject: Remove calling CPU mpidr from bakery lock API The bakery lock code currently expects the calling code to pass the MPIDR_EL1 of the current CPU. This is not always done correctly. Also the change to provide inline access to system registers makes it more efficient for the bakery lock code to obtain the MPIDR_EL1 directly. This change removes the mpidr parameter from the bakery lock interface, and results in a code reduction of 160 bytes for the ARM FVP port. Fixes ARM-software/tf-issues#213 Change-Id: I7ec7bd117bcc9794a0d948990fcf3336a367d543 --- services/std_svc/psci/psci_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'services/std_svc') diff --git a/services/std_svc/psci/psci_common.c b/services/std_svc/psci/psci_common.c index 3cbacd7..7da04fb 100644 --- a/services/std_svc/psci/psci_common.c +++ b/services/std_svc/psci/psci_common.c @@ -173,7 +173,7 @@ void psci_acquire_afflvl_locks(unsigned long mpidr, for (level = start_afflvl; level <= end_afflvl; level++) { if (mpidr_nodes[level] == NULL) continue; - bakery_lock_get(mpidr, &mpidr_nodes[level]->lock); + bakery_lock_get(&mpidr_nodes[level]->lock); } } @@ -192,7 +192,7 @@ void psci_release_afflvl_locks(unsigned long mpidr, for (level = end_afflvl; level >= start_afflvl; level--) { if (mpidr_nodes[level] == NULL) continue; - bakery_lock_release(mpidr, &mpidr_nodes[level]->lock); + bakery_lock_release(&mpidr_nodes[level]->lock); } } -- cgit v1.2.3