Commit Graph

17 Commits

Author SHA1 Message Date
Ryan McClelland eabd530a64 fix-double-promotion in fsl_xcvr_trim
Double promotion warnings are generated with the flag -Wdouble-promotion

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
2023-10-10 21:18:56 +03:00
Keith Packard d1e61c0c65 vega_sdk_riscv: Ignore GCC warning about potential uninitialized variable
When -ffreestanding is not enabled, and GCC is able to use it's
knowledge of memset semantics, it sometimes gets it wrong, as in this
case. I'm not quite sure what is confusing it here, but the code sure
looks correct.

Signed-off-by: Keith Packard <keithp@keithp.com>
2023-04-18 23:40:37 +09:00
Maureen Helm 40d049f69c openisa: Make openisa hal a zephyr_library
Stops leaking long source paths in build directories and makes them
deterministic.

When building samples/hello_world for rv32m1_vega_ri5cy, this changes
the build directories from:

build/
└── zephyr
    └── CMakeFiles
        └── zephyr.dir
            └── home
                └── maureen
                    └── zephyrproject
                        └── modules
                            └── hal
                                └── openisa
                                    └── vega_sdk_riscv
                                        └── devices
                                            └── RV32M1
                                                └── drivers
                                                    ├── fsl_clock.c.obj
                                                    └── fsl_lpuart.c.obj
to:

build/
└── modules
    └── openisa
        └── lib..__modules__hal__openisa.a

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2020-06-10 12:42:14 -05:00
Maureen Helm 742d0383aa drivers: Sort drivers in CMakeLists.txt
Sorts hal drivers alphabetically in the CMakeLists.txt file. Fixes
whitespace issues while we're here.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2020-06-10 12:42:14 -05:00
Cristi Caciuloiu 3b54187649 hal: openisa: pass MIC status from CAUv3 on stack
Pass the status of the MIC validation to the caller

Signed-off-by: Cristi Caciuloiu <cristian.caciuloiu@nxp.com>
2020-02-12 17:35:17 -06:00
Henrik Brix Andersen 9bfbe35aad hal: openisa: pull in Timer/PWM module source if enabled
Include the source file for the Timer/PWM (TPM) module if
PWM_RV32M1_TPM is selected.

Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
2020-01-03 10:13:46 -06:00
Virgil Cervicescu 6416140c00 hal: openisa: Add openisa/RV32M1 CAUv3 BLE specific driver
Add BLE specific CAUv3 firmware d_ip_ahb_cau3_syn.02.00.07.21.ver05
and the corresponding driver.

This driver implements functions for AES-CCM encrypt/decrypt and
Resolvable Private Address (RPA) handling.

Signed-off-by: Virgil Cervicescu <virgil.cervicescu@nxp.com>
2019-11-06 09:23:49 -06:00
Radu Alexe e09503a0da hal: openisa: add files/config to enable vega radio config
Add the necessary files to enable the configuration of the
GenFSK LL, as it's present in the Vega RISCV platform.

The memory map for the RV32M1 ri5cy core has been updated
with the XCVR registers and additional defines, as they
were included in the SDK for the zero-riscy core. The
location of file that includes the added defines is here:

   vega_sdk_riscv/devices/RV32M1/RV32M1_zero_riscy.h

The baseline for the updates done in this commit are
based on SDK Release Version 2.2.0.

Signed-off-by: Radu Alexe <radu.alexe@nxp.com>
Signed-off-by: David Leach <david.leach@nxp.com>
Signed-off-by: Ionut Ursescu <ionut.ursescu@nxp.com>
2019-11-06 09:23:49 -06:00
George Stefan 909f6766cc hal: openisa: add openisa/RV32M1 entropy driver
Wrapper for openisa/RV32M1 TRNG driver

Signed-off-by: George Stefan <george.stefan@nxp.com>
2019-11-06 09:23:49 -06:00
Karsten Koenig 0cbbf29f15 hal: openisa: Pull in LPSPI if enabled
Add fsl_lpspi.c to the sources if SPI_RV32M1_LPSPI is selected.

Signed-off-by: Karsten Koenig <karsten.koenig.030@gmail.com>
2019-10-22 10:50:36 -05:00
Anas Nashif be5c01f86c modules: make openisa HAL a zephyr module
Make this extract from ext/ a west module.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-08-21 09:41:54 -07:00
Lyle Zhu 681698ec89 driver: flash: add flash driver for the RV32M1 SOC
Add driver and device tree for the flash controller for the RV32M1 SOC

Signed-off-by: Lyle Zhu <lyle.zhu@nxp.com>
2019-06-03 10:43:47 -05:00
Henrik Brix Andersen 3e58ac76e9 drivers: i2c: rv32m1: add I2C driver for the RV32M1 RI5CY SoC
Add driver and device tree binding for the Low Power Inter-Integrated
Circuit (LPI2C) controllers found in the RV32M1 RI5CY SoC.

Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
2019-04-18 16:04:23 -05:00
Patrik Flykt 8987064922 drivers: Rename reserved function names
Rename reserved function names in drivers/ subdirectory. Update
function macros concatenatenating function names with '##'. As
there is a conflict between the existing gpio_sch_manage_callback()
and _gpio_sch_manage_callback() names, leave the latter unmodified.

Signed-off-by: Patrik Flykt <patrik.flykt@intel.com>
2019-04-03 17:31:00 -04:00
Michael Scott a1978e7fe1 serial: RV32M1: introduce lpuart driver / DT bindings
Add a UART driver.

Signed-off-by: Michael Scott <mike@foundries.io>
Signed-off-by: Marti Bolivar <marti@foundries.io>
2019-01-25 11:59:46 -05:00
Marti Bolivar 35efa78dc8 soc: riscv32: add RV32M1 SoC as openisa_rv32m1
The OpenISA RV32M1 SoC has four CPU cores. Two of these are RISC-V
32-bit cores, which are named "RI5CY" and "ZERO-RISCY". (The other two
cores are ARM Cortex-M0+ and -M4.) This patch adds basic SoC
enablement for the RISC-V cores:

- basic dtsi, to be extended as additional drivers are added
- SoC definition in soc/riscv32/openisa_rv32m1 for RI5CY / ZERO-RISCY
- system timer driver for RI5CY, based on LPTMR0 peripheral

The timer driver will be generalized a bit soon once proper
multi-level interrupt support is available.

Emphasis is on supporting the RI5CY core as the more capable of the
two; the ZERO-RISCY SoC definitions are a good starting point, but
additional work setting up a dtsi and initial drivers is needed to
support that core.

Signed-off-by: Marti Bolivar <marti@foundries.io>
Signed-off-by: Michael Scott <mike@foundries.io>
2019-01-25 11:59:46 -05:00
Marti Bolivar 7566cca599 ext: hal: add openisa/vega_sdk_riscv
This provides a HAL for the OpenISA RV32M1 SoC.

Origin: open-isa-rv32m1 GitHub organization
URL: https://github.com/open-isa-rv32m1/rv32m1_sdk_riscv
Revision: 365b1060f0947d5250c07b3eebdbc9e54cd0246e
Maintained-by: External
License: BSD-3-Clause

Signed-off-by: Marti Bolivar <marti@foundries.io>
2019-01-25 11:59:46 -05:00