summaryrefslogtreecommitdiff
path: root/bsp/env
diff options
context:
space:
mode:
authorMegan Wachs <megan@sifive.com>2017-02-02 11:40:13 -0800
committerGitHub <noreply@github.com>2017-02-02 11:40:13 -0800
commitb7c778c4e0b26e719226053a204142c0cb54dd4b (patch)
tree88405c74373d0d04da351aff5f2cf92dcf11d2a9 /bsp/env
parent55136a72df6f6f64793be7ead298434d01721dc5 (diff)
parent557c3ed0dc025b73a919f3e2a4068808092f48c1 (diff)
Merge pull request #50 from sifive/common_plic
FE-203 Move plic_driver code to a common location.
Diffstat (limited to 'bsp/env')
-rw-r--r--bsp/env/common.mk3
-rw-r--r--bsp/env/hifive1.h2
2 files changed, 4 insertions, 1 deletions
diff --git a/bsp/env/common.mk b/bsp/env/common.mk
index 420c196..74f5582 100644
--- a/bsp/env/common.mk
+++ b/bsp/env/common.mk
@@ -19,6 +19,7 @@ C_SRCS += $(PLATFORM_DIR)/init.c
LINKER_SCRIPT := $(PLATFORM_DIR)/link.lds
INCLUDES += -I$(BSP_BASE)/include
+INCLUDES += -I$(BSP_BASE)/drivers/
INCLUDES += -I$(ENV_DIR)
INCLUDES += -I$(PLATFORM_DIR)
@@ -47,7 +48,7 @@ $(ASM_OBJS): %.o: %.S $(HEADERS)
$(CC) $(CFLAGS) $(INCLUDES) -c -o $@ $<
$(C_OBJS): %.o: %.c $(HEADERS)
- $(CC) $(CFLAGS) $(INCLUDES) -c -o $@ $<
+ $(CC) $(CFLAGS) $(INCLUDES) -include sys/cdefs.h -c -o $@ $<
.PHONY: clean
clean:
diff --git a/bsp/env/hifive1.h b/bsp/env/hifive1.h
index 11b98f8..4c65f18 100644
--- a/bsp/env/hifive1.h
+++ b/bsp/env/hifive1.h
@@ -74,6 +74,8 @@
#define HAS_HFXOSC 1
#define HAS_LFROSC_BYPASS 1
+#define RTC_FREQ 32768
+
void write_hex(int fd, uint32_t hex);
#endif /* _SIFIVE_HIFIVE1_H */