[PATCH v3 00/12] Add SiFive TMC0 and SMC0 driver
Nick Hu
nick.hu at sifive.com
Tue Jul 8 00:49:28 PDT 2025
The previous version can be found in [1].
SiFive TMC0 and SMC0 are the power controllers that controls the Tile and
CoreComplex power domain. Add the drivers to support the power
management features such as HSM STOP and System Suspend.
Some features, such as power management, may require flushing the entire
cache before entering a non-retention power state. To support this, a
simple cache framework is introduced to allow the external CMO to
perform a full cache flush.
Changes in v3:
- Add the SiFive TMC and SMC driver
Changes in v2:
- Since the platform override hooks was deprecated, use the fdt_driver
for initializing the sifive_dev_platform.
Links:
- [1] https://lore.kernel.org/opensbi/20250424034003.28522-1-nick.hu@sifive.com/
Nick Hu (10):
lib: utils: Add cache flush library
lib: utils: Add FDT cache library
lib: utils/cache: Add fdt cmo helpers
lib: sbi: Add SiFive proprietary xsfcflushdlone
lib: sbi: Add SiFive proprietary xsfcease
lib: utils/ipi: Exposing the ACLINT IPI device
lib: utils/irqchip: Add APLIC restore function
platform: sifive: Add SiFive TMC0 driver
lib: utils/timer: Expose timer update function
platform: sifive: Add SiFive SMC0 driver
Vincent Chen (2):
utils: cache: Add SiFive ccache controller
platform: generic: Add SiFive development platform
include/sbi/sbi_hart.h | 4 +
include/sbi_utils/cache/cache.h | 69 +++
include/sbi_utils/cache/fdt_cache.h | 34 ++
include/sbi_utils/cache/fdt_cmo_helper.h | 34 ++
include/sbi_utils/ipi/aclint_mswi.h | 1 +
include/sbi_utils/irqchip/aplic.h | 3 +
include/sbi_utils/timer/aclint_mtimer.h | 5 +
lib/sbi/sbi_hart.c | 2 +
lib/utils/Kconfig | 2 +
lib/utils/cache/Kconfig | 23 +
lib/utils/cache/cache.c | 46 ++
lib/utils/cache/fdt_cache.c | 87 ++++
lib/utils/cache/fdt_cache_drivers.carray | 3 +
lib/utils/cache/fdt_cmo_helper.c | 112 +++++
lib/utils/cache/fdt_sifive_ccache.c | 175 +++++++
lib/utils/cache/objects.mk | 14 +
lib/utils/ipi/aclint_mswi.c | 5 +
lib/utils/irqchip/aplic.c | 160 +++---
lib/utils/timer/aclint_mtimer.c | 28 +-
platform/generic/Kconfig | 8 +
platform/generic/configs/defconfig | 3 +
platform/generic/include/sifive/sifive_inst.h | 20 +
platform/generic/include/sifive/sifive_smc0.h | 13 +
platform/generic/include/sifive/sifive_tmc0.h | 15 +
platform/generic/sifive/Kconfig | 10 +
platform/generic/sifive/objects.mk | 7 +
.../pmdomain/fdt_pmdomain_sifive_smc0.c | 322 ++++++++++++
.../pmdomain/fdt_pmdomain_sifive_tmc0.c | 459 ++++++++++++++++++
platform/generic/sifive/sifive_dev_platform.c | 62 +++
29 files changed, 1652 insertions(+), 74 deletions(-)
create mode 100644 include/sbi_utils/cache/cache.h
create mode 100644 include/sbi_utils/cache/fdt_cache.h
create mode 100644 include/sbi_utils/cache/fdt_cmo_helper.h
create mode 100644 lib/utils/cache/Kconfig
create mode 100644 lib/utils/cache/cache.c
create mode 100644 lib/utils/cache/fdt_cache.c
create mode 100644 lib/utils/cache/fdt_cache_drivers.carray
create mode 100644 lib/utils/cache/fdt_cmo_helper.c
create mode 100644 lib/utils/cache/fdt_sifive_ccache.c
create mode 100644 lib/utils/cache/objects.mk
create mode 100644 platform/generic/include/sifive/sifive_inst.h
create mode 100644 platform/generic/include/sifive/sifive_smc0.h
create mode 100644 platform/generic/include/sifive/sifive_tmc0.h
create mode 100644 platform/generic/sifive/Kconfig
create mode 100644 platform/generic/sifive/pmdomain/fdt_pmdomain_sifive_smc0.c
create mode 100644 platform/generic/sifive/pmdomain/fdt_pmdomain_sifive_tmc0.c
create mode 100644 platform/generic/sifive/sifive_dev_platform.c
--
2.17.1
More information about the opensbi
mailing list