aboutsummaryrefslogtreecommitdiff
path: root/include/drivers/arm/gic_common.h
diff options
context:
space:
mode:
authorSoby Mathew <soby.mathew@arm.com>2016-01-15 14:20:57 +0000
committerSoby Mathew <soby.mathew@arm.com>2016-02-09 16:50:36 +0000
commit38a7861450409b6b234e12f15b8b516aa71b6610 (patch)
treebbd4a119d9123ac9389372d61efd1db09f77bc64 /include/drivers/arm/gic_common.h
parenta91e12fbeac527df82b39d763a68f00d1d890cdc (diff)
downloadtrusted-firmware-a-38a7861450409b6b234e12f15b8b516aa71b6610.tar.gz
Fix GIC_IPRIORITYR setting in new drivers
The code to set the interrupt priority for secure interrupts in the new GICv2 and GICv3 drivers is incorrect. The setup code to configure interrupt priorities of secure interrupts, one interrupt at a time, used gicd_write_ipriorityr()/gicr_write_ipriority() function affecting 4 interrupts at a time. This bug did not manifest itself because all the secure interrupts were configured to the highest secure priority(0) during cold boot and the adjacent non secure interrupt priority would be configured later by the normal world. This patch introduces new accessors, gicd_set_ipriorityr() and gicr_set_ipriorityr(), for configuring priority one interrupt at a time and fixes the the setup code to use the new accessors. Fixes ARM-software/tf-issues#344 Change-Id: I470fd74d2b7fce7058b55d83f604be05a27e1341
Diffstat (limited to 'include/drivers/arm/gic_common.h')
-rw-r--r--include/drivers/arm/gic_common.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/drivers/arm/gic_common.h b/include/drivers/arm/gic_common.h
index 6a322a22a0..47d0669659 100644
--- a/include/drivers/arm/gic_common.h
+++ b/include/drivers/arm/gic_common.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2015, ARM Limited and Contributors. All rights reserved.
+ * Copyright (c) 2015-2016, ARM Limited and Contributors. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
@@ -167,6 +167,7 @@ void gicd_set_ispendr(uintptr_t base, unsigned int id);
void gicd_set_icpendr(uintptr_t base, unsigned int id);
void gicd_set_isactiver(uintptr_t base, unsigned int id);
void gicd_set_icactiver(uintptr_t base, unsigned int id);
+void gicd_set_ipriorityr(uintptr_t base, unsigned int id, unsigned int pri);
#endif /* __ASSEMBLY__ */