summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPavel Pisa <ppisa@pikron.com>2016-05-21 23:50:31 +0200
committerPavel Pisa <pisa@cmp.felk.cvut.cz>2016-10-02 10:40:35 +0200
commitb5501ba492535a9868d182d77dd7c62529fc1c19 (patch)
tree5a952a88f37bb1a886a3ca4d7433583f07ec1246
parentarm/raspberrypi: reorder and update MMU config table to nor force RW section ... (diff)
downloadrtems-b5501ba492535a9868d182d77dd7c62529fc1c19.tar.bz2
arm/raspberrypi: ensure that correct RPI_PERIPHERAL_BASE is provided by raspberrypi.h
If the raspberrypi.h has been included without preceding inclussion of bsp.h then BSP_IS_RPI2 has not been set for Raspberry Pi 2 BSP variant and bad things happen later. The patch includes bspopts.h by raspberrypi.h and even includes bsp.h in critical peripherals support. Updates #2783
-rw-r--r--c/src/lib/libbsp/arm/raspberrypi/include/raspberrypi.h1
-rw-r--r--c/src/lib/libbsp/arm/raspberrypi/misc/timer.c1
2 files changed, 2 insertions, 0 deletions
diff --git a/c/src/lib/libbsp/arm/raspberrypi/include/raspberrypi.h b/c/src/lib/libbsp/arm/raspberrypi/include/raspberrypi.h
index c33e22ab8e..e7bcd984d2 100644
--- a/c/src/lib/libbsp/arm/raspberrypi/include/raspberrypi.h
+++ b/c/src/lib/libbsp/arm/raspberrypi/include/raspberrypi.h
@@ -20,6 +20,7 @@
#ifndef LIBBSP_ARM_RASPBERRYPI_RASPBERRYPI_H
#define LIBBSP_ARM_RASPBERRYPI_RASPBERRYPI_H
+#include <bspopts.h>
#include <stdint.h>
#include <bsp/utility.h>
diff --git a/c/src/lib/libbsp/arm/raspberrypi/misc/timer.c b/c/src/lib/libbsp/arm/raspberrypi/misc/timer.c
index e90af08290..1047b3e417 100644
--- a/c/src/lib/libbsp/arm/raspberrypi/misc/timer.c
+++ b/c/src/lib/libbsp/arm/raspberrypi/misc/timer.c
@@ -16,6 +16,7 @@
*
*/
+#include <bsp.h>
#include <rtems.h>
#include <rtems/btimer.h>
#include <bsp/raspberrypi.h>