From 92d0f3e15ddfeb3d3a640d9bdd3471553e14ed7e Mon Sep 17 00:00:00 2001 From: Nathaniel Graff Date: Wed, 6 Mar 2019 15:05:37 -0800 Subject: Update BSPs Signed-off-by: Nathaniel Graff --- bsp/coreip-e20-arty/metal.h | 7 +++++++ bsp/coreip-e20-arty/metal.lds | 2 +- bsp/coreip-e20/metal.h | 5 +++++ bsp/coreip-e21-arty/metal.h | 7 +++++++ bsp/coreip-e21-arty/metal.lds | 2 +- bsp/coreip-e21/metal.h | 5 +++++ bsp/coreip-e24-arty/metal.h | 7 +++++++ bsp/coreip-e24-arty/metal.lds | 2 +- bsp/coreip-e24/metal.h | 5 +++++ bsp/coreip-e31-arty/metal.h | 7 +++++++ bsp/coreip-e31-arty/metal.lds | 2 +- bsp/coreip-e31/metal.h | 5 +++++ bsp/coreip-e34-arty/metal.h | 7 +++++++ bsp/coreip-e34-arty/metal.lds | 2 +- bsp/coreip-e34/metal.h | 5 +++++ bsp/coreip-e76-arty/metal.h | 9 +++++++++ bsp/coreip-e76-arty/metal.lds | 2 +- bsp/coreip-e76/metal.h | 5 +++++ bsp/coreip-s51-arty/metal.h | 7 +++++++ bsp/coreip-s51-arty/metal.lds | 2 +- bsp/coreip-s51/metal.h | 5 +++++ bsp/coreip-s54-arty/metal.h | 7 +++++++ bsp/coreip-s54-arty/metal.lds | 2 +- bsp/coreip-s54/metal.h | 5 +++++ bsp/coreip-s76-arty/metal.h | 9 +++++++++ bsp/coreip-s76-arty/metal.lds | 2 +- bsp/coreip-s76/metal.h | 5 +++++ bsp/freedom-e310-arty/metal.h | 7 +++++++ bsp/freedom-e310-arty/metal.lds | 2 +- bsp/sifive-hifive1-revb/metal.h | 7 +++++++ bsp/sifive-hifive1/metal.h | 7 +++++++ bsp/sifive-hifive1/metal.lds | 2 +- 32 files changed, 144 insertions(+), 11 deletions(-) (limited to 'bsp') diff --git a/bsp/coreip-e20-arty/metal.h b/bsp/coreip-e20-arty/metal.h index a301667..27baf68 100644 --- a/bsp/coreip-e20-arty/metal.h +++ b/bsp/coreip-e20-arty/metal.h @@ -239,6 +239,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@2000000 */ @@ -464,6 +465,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e20-arty/metal.lds b/bsp/coreip-e20-arty/metal.lds index ea41b72..4c81b1b 100644 --- a/bsp/coreip-e20-arty/metal.lds +++ b/bsp/coreip-e20-arty/metal.lds @@ -5,7 +5,7 @@ ENTRY(_enter) MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-e20/metal.h b/bsp/coreip-e20/metal.h index 5693e03..f2441c6 100644 --- a/bsp/coreip-e20/metal.h +++ b/bsp/coreip-e20/metal.h @@ -173,6 +173,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_LOCAL_EXTERNAL_INTERRUPTS_0_HANDLE (&__metal_dt_local_external_interrupts_0.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e21-arty/metal.h b/bsp/coreip-e21-arty/metal.h index 49b4c73..5a9459b 100644 --- a/bsp/coreip-e21-arty/metal.h +++ b/bsp/coreip-e21-arty/metal.h @@ -334,6 +334,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@2000000 */ @@ -559,6 +560,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e21-arty/metal.lds b/bsp/coreip-e21-arty/metal.lds index ea41b72..4c81b1b 100644 --- a/bsp/coreip-e21-arty/metal.lds +++ b/bsp/coreip-e21-arty/metal.lds @@ -5,7 +5,7 @@ ENTRY(_enter) MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-e21/metal.h b/bsp/coreip-e21/metal.h index 20efb49..b901bfb 100644 --- a/bsp/coreip-e21/metal.h +++ b/bsp/coreip-e21/metal.h @@ -279,6 +279,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_LOCAL_EXTERNAL_INTERRUPTS_0_HANDLE (&__metal_dt_local_external_interrupts_0.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e24-arty/metal.h b/bsp/coreip-e24-arty/metal.h index f160783..129eeee 100644 --- a/bsp/coreip-e24-arty/metal.h +++ b/bsp/coreip-e24-arty/metal.h @@ -334,6 +334,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@2000000 */ @@ -559,6 +560,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e24-arty/metal.lds b/bsp/coreip-e24-arty/metal.lds index ea41b72..4c81b1b 100644 --- a/bsp/coreip-e24-arty/metal.lds +++ b/bsp/coreip-e24-arty/metal.lds @@ -5,7 +5,7 @@ ENTRY(_enter) MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-e24/metal.h b/bsp/coreip-e24/metal.h index 1d23799..23ed8d2 100644 --- a/bsp/coreip-e24/metal.h +++ b/bsp/coreip-e24/metal.h @@ -279,6 +279,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_LOCAL_EXTERNAL_INTERRUPTS_0_HANDLE (&__metal_dt_local_external_interrupts_0.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e31-arty/metal.h b/bsp/coreip-e31-arty/metal.h index 62dac06..9b087b9 100644 --- a/bsp/coreip-e31-arty/metal.h +++ b/bsp/coreip-e31-arty/metal.h @@ -244,6 +244,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -477,6 +478,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e31-arty/metal.lds b/bsp/coreip-e31-arty/metal.lds index 28a7849..ae57468 100644 --- a/bsp/coreip-e31-arty/metal.lds +++ b/bsp/coreip-e31-arty/metal.lds @@ -6,7 +6,7 @@ MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000 itim (wx!rai) : ORIGIN = 0x8000000, LENGTH = 0x4000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-e31/metal.h b/bsp/coreip-e31/metal.h index d2c696b..d6b0a52 100644 --- a/bsp/coreip-e31/metal.h +++ b/bsp/coreip-e31/metal.h @@ -335,6 +335,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e34-arty/metal.h b/bsp/coreip-e34-arty/metal.h index 768fd66..6de1b7c 100644 --- a/bsp/coreip-e34-arty/metal.h +++ b/bsp/coreip-e34-arty/metal.h @@ -244,6 +244,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -477,6 +478,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e34-arty/metal.lds b/bsp/coreip-e34-arty/metal.lds index 28a7849..ae57468 100644 --- a/bsp/coreip-e34-arty/metal.lds +++ b/bsp/coreip-e34-arty/metal.lds @@ -6,7 +6,7 @@ MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000 itim (wx!rai) : ORIGIN = 0x8000000, LENGTH = 0x4000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-e34/metal.h b/bsp/coreip-e34/metal.h index dfccf6e..197e59d 100644 --- a/bsp/coreip-e34/metal.h +++ b/bsp/coreip-e34/metal.h @@ -335,6 +335,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e76-arty/metal.h b/bsp/coreip-e76-arty/metal.h index 469dea8..b35bce6 100644 --- a/bsp/coreip-e76-arty/metal.h +++ b/bsp/coreip-e76-arty/metal.h @@ -209,6 +209,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@10060000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_10060000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 268828672UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -223,6 +224,7 @@ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_10060000 = { /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -449,6 +451,13 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 2 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_10060000, + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-e76-arty/metal.lds b/bsp/coreip-e76-arty/metal.lds index 8a30906..3875c94 100644 --- a/bsp/coreip-e76-arty/metal.lds +++ b/bsp/coreip-e76-arty/metal.lds @@ -5,7 +5,7 @@ ENTRY(_enter) MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-e76/metal.h b/bsp/coreip-e76/metal.h index 22f8073..99ffef7 100644 --- a/bsp/coreip-e76/metal.h +++ b/bsp/coreip-e76/metal.h @@ -286,6 +286,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-s51-arty/metal.h b/bsp/coreip-s51-arty/metal.h index 89f5d76..304f5b0 100644 --- a/bsp/coreip-s51-arty/metal.h +++ b/bsp/coreip-s51-arty/metal.h @@ -244,6 +244,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -477,6 +478,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-s51-arty/metal.lds b/bsp/coreip-s51-arty/metal.lds index 28a7849..ae57468 100644 --- a/bsp/coreip-s51-arty/metal.lds +++ b/bsp/coreip-s51-arty/metal.lds @@ -6,7 +6,7 @@ MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000 itim (wx!rai) : ORIGIN = 0x8000000, LENGTH = 0x4000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-s51/metal.h b/bsp/coreip-s51/metal.h index 62512f2..fb8ae89 100644 --- a/bsp/coreip-s51/metal.h +++ b/bsp/coreip-s51/metal.h @@ -335,6 +335,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-s54-arty/metal.h b/bsp/coreip-s54-arty/metal.h index 7381117..98b535b 100644 --- a/bsp/coreip-s54-arty/metal.h +++ b/bsp/coreip-s54-arty/metal.h @@ -244,6 +244,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -477,6 +478,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-s54-arty/metal.lds b/bsp/coreip-s54-arty/metal.lds index 28a7849..ae57468 100644 --- a/bsp/coreip-s54-arty/metal.lds +++ b/bsp/coreip-s54-arty/metal.lds @@ -6,7 +6,7 @@ MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000 itim (wx!rai) : ORIGIN = 0x8000000, LENGTH = 0x4000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-s54/metal.h b/bsp/coreip-s54/metal.h index 86db562..ece862b 100644 --- a/bsp/coreip-s54/metal.h +++ b/bsp/coreip-s54/metal.h @@ -335,6 +335,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-s76-arty/metal.h b/bsp/coreip-s76-arty/metal.h index aa261fc..eacfb1e 100644 --- a/bsp/coreip-s76-arty/metal.h +++ b/bsp/coreip-s76-arty/metal.h @@ -209,6 +209,7 @@ struct __metal_driver_sifive_global_external_interrupts0 __metal_dt_global_exter /* From gpio@10060000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_10060000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 268828672UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -223,6 +224,7 @@ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_10060000 = { /* From gpio@20002000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_20002000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 536879104UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -449,6 +451,13 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 2 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_10060000, + &__metal_dt_gpio_20002000}; + #define __METAL_DT_MAX_BUTTONS 4 asm (".weak __metal_button_table"); diff --git a/bsp/coreip-s76-arty/metal.lds b/bsp/coreip-s76-arty/metal.lds index 8a30906..3875c94 100644 --- a/bsp/coreip-s76-arty/metal.lds +++ b/bsp/coreip-s76-arty/metal.lds @@ -5,7 +5,7 @@ ENTRY(_enter) MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x10000000 - flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x40400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/coreip-s76/metal.h b/bsp/coreip-s76/metal.h index c4a874b..9a0623e 100644 --- a/bsp/coreip-s76/metal.h +++ b/bsp/coreip-s76/metal.h @@ -286,6 +286,11 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_GLOBAL_EXTERNAL_INTERRUPTS_HANDLE (&__metal_dt_global_external_interrupts.irc) +#define __MEE_DT_MAX_GPIOS 0 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + NULL }; #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/freedom-e310-arty/metal.h b/bsp/freedom-e310-arty/metal.h index d0a59b0..f2086b5 100644 --- a/bsp/freedom-e310-arty/metal.h +++ b/bsp/freedom-e310-arty/metal.h @@ -163,6 +163,7 @@ struct __metal_driver_sifive_local_external_interrupts0 __metal_dt_local_externa /* From gpio@10012000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_10012000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 268509184UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -253,6 +254,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_LOCAL_EXTERNAL_INTERRUPTS_0_HANDLE (&__metal_dt_local_external_interrupts_0.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_10012000}; + #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/freedom-e310-arty/metal.lds b/bsp/freedom-e310-arty/metal.lds index c0556ee..1a1801b 100644 --- a/bsp/freedom-e310-arty/metal.lds +++ b/bsp/freedom-e310-arty/metal.lds @@ -6,7 +6,7 @@ MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x4000 itim (wx!rai) : ORIGIN = 0x8000000, LENGTH = 0x4000 - flash (rxai!w) : ORIGIN = 0x20400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x20400000, LENGTH = 0x1fc00000 } PHDRS diff --git a/bsp/sifive-hifive1-revb/metal.h b/bsp/sifive-hifive1-revb/metal.h index 4d74b17..8f8c976 100644 --- a/bsp/sifive-hifive1-revb/metal.h +++ b/bsp/sifive-hifive1-revb/metal.h @@ -213,6 +213,7 @@ struct __metal_driver_sifive_local_external_interrupts0 __metal_dt_local_externa /* From gpio@10012000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_10012000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 268509184UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -356,6 +357,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_LOCAL_EXTERNAL_INTERRUPTS_0_HANDLE (&__metal_dt_local_external_interrupts_0.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_10012000}; + #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/sifive-hifive1/metal.h b/bsp/sifive-hifive1/metal.h index 6fdbb23..0f30503 100644 --- a/bsp/sifive-hifive1/metal.h +++ b/bsp/sifive-hifive1/metal.h @@ -205,6 +205,7 @@ struct __metal_driver_sifive_local_external_interrupts0 __metal_dt_local_externa /* From gpio@10012000 */ struct __metal_driver_sifive_gpio0 __metal_dt_gpio_10012000 = { .vtable = &__metal_driver_vtable_sifive_gpio0, + .gpio.vtable = &__metal_driver_vtable_sifive_gpio0.gpio, .base = 268509184UL, .size = 4096UL, /* From interrupt_controller@c000000 */ @@ -345,6 +346,12 @@ struct __metal_driver_cpu *__metal_cpu_table[] = { #define __METAL_DT_LOCAL_EXTERNAL_INTERRUPTS_0_HANDLE (&__metal_dt_local_external_interrupts_0.irc) +#define __MEE_DT_MAX_GPIOS 1 + +asm (".weak __metal_gpio_table"); +struct __metal_driver_sifive_gpio0 *__metal_gpio_table[] = { + &__metal_dt_gpio_10012000}; + #define __METAL_DT_MAX_BUTTONS 0 asm (".weak __metal_button_table"); diff --git a/bsp/sifive-hifive1/metal.lds b/bsp/sifive-hifive1/metal.lds index fdd23c7..32455d8 100644 --- a/bsp/sifive-hifive1/metal.lds +++ b/bsp/sifive-hifive1/metal.lds @@ -5,7 +5,7 @@ ENTRY(_enter) MEMORY { ram (wxa!ri) : ORIGIN = 0x80000000, LENGTH = 0x4000 - flash (rxai!w) : ORIGIN = 0x20400000, LENGTH = 0x20000000 + flash (rxai!w) : ORIGIN = 0x20400000, LENGTH = 0x1fc00000 } PHDRS -- cgit v1.2.1-18-gbd029