From: Anup Patel <apatel@ventanamicro.com>
To: opensbi@lists.infradead.org
Subject: [PATCH 00/11] OpenSBI compile-time C arrays
Date: Tue, 3 May 2022 09:07:48 +0530 [thread overview]
Message-ID: <20220503033759.544156-1-apatel@ventanamicro.com> (raw)
This series aims at removing hard-coded C arrays for drivers and modules
in OpenSBI sources and replace it with dynamically generated arrays at
compile-time. External firmwares which use OpenSBI as library will have
to create these arrays separately because they typically don't use OpenSBI
build system.
These patches can also be found in generated_carray_v1 branch at:
https://github.com/avpatel/opensbi.git
Anup Patel (11):
Makefile: Allow generated C source to be anywhere in build directory
Makefile: Add support for generating C array at compile time
lib: utils/reset: Generate FDT reset driver list at compile-time
lib: utils/serial: Generate FDT serial driver list at compile-time
lib: utils/timer: Generate FDT timer driver list at compile-time
lib: utils/irqchip: Generate FDT irqchip driver list at compile-time
lib: utils/ipi: Generate FDT ipi driver list at compile-time
lib: utils/i2c: Generate FDT i2c adapter driver list at compile-time
lib: utils/gpio: Generate FDT gpio driver list at compile-time
platform: generic: Generate platform override module list at
compile-time
platform: generic: Move Sifive platform overrides into own directory
Makefile | 17 +++-
include/sbi_utils/gpio/fdt_gpio.h | 2 +
lib/utils/gpio/fdt_gpio.c | 18 ++---
lib/utils/gpio/fdt_gpio_drivers.carray | 3 +
lib/utils/gpio/objects.mk | 4 +
lib/utils/i2c/fdt_i2c.c | 14 ++--
lib/utils/i2c/fdt_i2c_adapter_drivers.carray | 3 +
lib/utils/i2c/objects.mk | 4 +
lib/utils/ipi/fdt_ipi.c | 12 ++-
lib/utils/ipi/fdt_ipi_drivers.carray | 3 +
lib/utils/ipi/objects.mk | 4 +
lib/utils/irqchip/fdt_irqchip.c | 16 ++--
lib/utils/irqchip/fdt_irqchip_drivers.carray | 3 +
lib/utils/irqchip/objects.mk | 8 ++
lib/utils/reset/fdt_reset.c | 22 ++----
lib/utils/reset/fdt_reset_drivers.carray | 3 +
lib/utils/reset/objects.mk | 12 +++
lib/utils/serial/fdt_serial.c | 28 ++-----
lib/utils/serial/fdt_serial_drivers.carray | 3 +
lib/utils/serial/objects.mk | 16 ++++
lib/utils/timer/fdt_timer.c | 12 ++-
lib/utils/timer/fdt_timer_drivers.carray | 3 +
lib/utils/timer/objects.mk | 4 +
platform/generic/objects.mk | 3 +-
platform/generic/platform.c | 14 ++--
.../generic/platform_override_modules.carray | 3 +
.../{sifive_fu540.c => sifive/fu540.c} | 0
.../{sifive_fu740.c => sifive/fu740.c} | 0
platform/generic/sifive/objects.mk | 9 +++
scripts/carray.sh | 77 +++++++++++++++++++
30 files changed, 224 insertions(+), 96 deletions(-)
create mode 100644 lib/utils/gpio/fdt_gpio_drivers.carray
create mode 100644 lib/utils/i2c/fdt_i2c_adapter_drivers.carray
create mode 100644 lib/utils/ipi/fdt_ipi_drivers.carray
create mode 100644 lib/utils/irqchip/fdt_irqchip_drivers.carray
create mode 100644 lib/utils/reset/fdt_reset_drivers.carray
create mode 100644 lib/utils/serial/fdt_serial_drivers.carray
create mode 100644 lib/utils/timer/fdt_timer_drivers.carray
create mode 100644 platform/generic/platform_override_modules.carray
rename platform/generic/{sifive_fu540.c => sifive/fu540.c} (100%)
rename platform/generic/{sifive_fu740.c => sifive/fu740.c} (100%)
create mode 100644 platform/generic/sifive/objects.mk
create mode 100755 scripts/carray.sh
--
2.34.1
next reply other threads:[~2022-05-03 3:37 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-03 3:37 Anup Patel [this message]
2022-05-03 3:37 ` [PATCH 01/11] Makefile: Allow generated C source to be anywhere in build directory Anup Patel
2022-05-09 17:24 ` Atish Patra
2022-05-03 3:37 ` [PATCH 02/11] Makefile: Add support for generating C array at compile time Anup Patel
2022-05-09 17:26 ` Atish Patra
2022-05-03 3:37 ` [PATCH 03/11] lib: utils/reset: Generate FDT reset driver list at compile-time Anup Patel
2022-05-03 3:37 ` [PATCH 04/11] lib: utils/serial: Generate FDT serial " Anup Patel
2022-05-03 3:37 ` [PATCH 05/11] lib: utils/timer: Generate FDT timer " Anup Patel
2022-05-03 3:37 ` [PATCH 06/11] lib: utils/irqchip: Generate FDT irqchip " Anup Patel
2022-05-03 3:37 ` [PATCH 07/11] lib: utils/ipi: Generate FDT ipi " Anup Patel
2022-05-03 3:37 ` [PATCH 08/11] lib: utils/i2c: Generate FDT i2c adapter " Anup Patel
2022-05-03 3:37 ` [PATCH 09/11] lib: utils/gpio: Generate FDT gpio " Anup Patel
2022-05-03 3:37 ` [PATCH 10/11] platform: generic: Generate platform override module " Anup Patel
2022-05-03 3:37 ` [PATCH 11/11] platform: generic: Move Sifive platform overrides into own directory Anup Patel
2022-05-09 17:28 ` Atish Patra
2022-05-03 3:42 ` [PATCH 00/11] OpenSBI compile-time C arrays Jessica Clarke
2022-05-03 3:52 ` Anup Patel
2022-05-03 3:54 ` Jessica Clarke
2022-05-03 4:04 ` Anup Patel
2022-05-03 4:13 ` Jessica Clarke
2022-05-03 4:17 ` Anup Patel
2022-05-03 4:23 ` Jessica Clarke
2022-05-03 4:30 ` Anup Patel
2022-05-03 4:45 ` Jessica Clarke
2022-05-03 4:47 ` Anup Patel
2022-05-03 15:35 ` Xiang W
2022-05-03 16:24 ` Anup Patel
2022-05-09 17:29 ` Atish Patra
2022-05-13 4:03 ` Anup Patel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220503033759.544156-1-apatel@ventanamicro.com \
--to=apatel@ventanamicro.com \
--cc=opensbi@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox