Commit graph

2451 commits

Author SHA1 Message Date
simbit18
eec97064d7 fix nxstyle
Removed extra spaces from .h and .c files
2024-12-10 21:57:22 +08:00
hujun5
16b63ed837 armv7/8m: fix regresion from https://github.com/apache/nuttx/pull/14881
reason:
svc call may trigger hardfault

Background
    The origin of this issue is our desire to eliminate the function of storing
"regs" in g_current_regs and instead utilize (*running_task)->xcp.regs for storage.
The benefits of this approach include faster storage speed and
avoiding multiple accesses to g_current_regs during context switching,
thus ensuring that whether returning from an interrupt or an exception,
we consistently use this_task()->xcp.regs

Issue Encountered
    However, when storing registers, we must ensure that (running_task)->xcp.regs is invalid
so that it can be safely overwritten.
According to the existing logic, the only scenario where (running_task)->xcp.regs
is valid is during restore_context. We must accurately identify this scenario.
Initially, we used the condition (running_task)==NULL for this purpose, but we deemed
this approach unsatisfactory as it did not align well with the actual logic.
(running_task) should not be NULL. Consequently, we adopted other arch-specific methods for judgment,
but due to special logic in some arch, the judgment was not accurate, leading to this issue.

Solution:
    For armv6-m, we haven't found a more suitable solution, so we are sticking with (*running_task)==NULL.
    For armv7-m/armv8-m, by removing support for primask, we can achieve accurate judgment.

    PRIMASK is a design in armv6-m, that's why arm introduce BASEPRI from armv7-m.
It's wrong to provide this option for armv7-m/armv8-m arch.

Signed-off-by: hujun5 <hujun5@xiaomi.com>
2024-12-09 21:20:06 +08:00
wangjianyu3
0481533833 boards: Update configs about system/usbmsc
The Kconfig of system/usbmsc has updated to support setting paths that bind to LUN at runtime.
More details: https://github.com/apache/nuttx-apps/pull/2876

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2024-12-06 13:38:23 +08:00
Xiang Xiao
60fb917eda Remove FAR from 32/64bit arch
since these arch doesn't distinguish between near and far pointers

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-12-05 22:55:39 +08:00
stbenn
9b52710691 board/nucleo-h563zi: Add HSE option
Add an option to use HSE on the Nucleo-H563ZI with board modification. This is enabled through board Kconfig.
It supplies the same PLL output frequencies using the HSE instead of HSI, for significantly more precise clocks.
2024-12-03 09:39:13 +08:00
simbit18
9c9b945876 fix nxstyle
Removed extra spaces from .h and .c files
2024-11-28 20:40:13 +08:00
wangmingrong1
4daafd0781 Fix path error
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2024-11-28 15:04:59 +08:00
YAMAMOTO Takashi
6ebfe8c51f linum-stm32h753bi/littlefs: use littlefs 2.9.3
I chose this config just because it seems to support cmake-based build.
2024-11-27 02:56:52 +08:00
hujun5
610efc8f1a arm: remove up_set_current_regs/up_current_regs
reason:
up_set_current_regs initially had two functions:

1: To mark the entry into an interrupt state.
2: To record the context before an interrupt/exception. If we switch to
   a new task, we need to store the upcoming context regs by calling up_set_current_regs(regs).

Currently, we record the context in other ways, so the second function is obsolete.
Therefore, we need to rename up_set_current_regs to better reflect its actual meaning,
which is solely to mark an interrupt.

Signed-off-by: hujun5 <hujun5@xiaomi.com>
2024-11-26 20:04:54 +08:00
wangjianyu3
27f278af90 lm3s6965-ek/qemu: Using default max command line length
The large max command line length may cause stack overflow.

Test
  ./tools/configure.sh lm3s6965-ek:qemu-flat
  make -j16
  qemu-system-arm -semihosting \
  		-M lm3s6965evb \
  		-device loader,file=nuttx.bin,addr=0x00000000 \
  		-netdev user,id=user0 \
  		-serial mon:stdio -nographic

Link: https://github.com/apache/nuttx-apps/pull/2850
Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2024-11-21 14:08:17 -03:00
Peter Bee
c0f776dbc3 follow upstream change & fix minor things
Signed-off-by: Peter Bee <pbjd97@gmail.com>
2024-11-20 16:32:05 -03:00
Peter Bee
48ded21e30 refine driver
Signed-off-by: Peter Bee <pbjd97@gmail.com>
2024-11-20 16:32:05 -03:00
Marco Casaroli
dac3f315a1 uf2 2024-11-20 16:32:05 -03:00
Marco Casaroli
18ee2d9130 board(rp23xx): add Pimoroni Pico 2 Plus 2024-11-20 16:32:05 -03:00
Marco Casaroli
566f31f14c board(rp23xx): add Raspberry Pi Pico 2 2024-11-20 16:32:05 -03:00
stbenn
8def1764a4 arch/stm32h5: add basic ADC support
Adds ADC support with minimal feature set (no DMA or Timers etc). A new nucleo-h563zi configuration was added to
provide easy testing with the adc example NSH addon.

Fix Kconfig spacing to tabs
2024-11-20 08:51:27 +08:00
chao an
8ffe5bdc1e arm/efm32: fix build break caused by undeclared error
Old upstream from @acassis:
d97227eddd/nuttx/configs/efm32gg-pnbfano/include/board.h

chip/efm32_clockconfig.c:860:24: error: 'BOARD_SWOPORT_LOCATION' undeclared (first use in this function);
                                 did you mean 'BOARD_UART0_ROUTE_LOCATION'?
  860 |   regval |= ((uint32_t)BOARD_SWOPORT_LOCATION <<
      |                        ^~~~~~~~~~~~~~~~~~~~~~
      |                        BOARD_UART0_ROUTE_LOCATION
chip/efm32_clockconfig.c:860:24: note: each undeclared identifier is reported only once for each function it appears in
chip/efm32_clockconfig.c:866:20: error: 'BOARD_GPIO_SWOPORT' undeclared (first use in this function)
  866 |   efm32_configgpio(BOARD_GPIO_SWOPORT);
      |                    ^~~~~~~~~~~~~~~~~~

Signed-off-by: chao an <anchao@lixiang.com>
2024-11-19 20:50:33 +08:00
raiden00pl
7e42ca2538 boards/stm32: split nucleo-f4x1re into separate boards
Split nucleo-f4x1re into nucleo-f401re and nucleo-f411re.
These are separate boards and should be in separate directories as it's
done for all other nucleo boards in NuttX
2024-11-19 13:28:42 +01:00
raiden00pl
af5252c8f9 boards/arm/stm32/nucleo-f4x1re/stm32_adc.c: remove dependency on AJOYSTICK
remove dependency on AJOYSTICK, ADC can be used without analog joystick,
so there is no reason to depends on it
2024-11-18 16:56:43 -03:00
raiden00pl
f04b7137c6 boards/arm/stm32/nucleo-f4x1re/src/stm32_adc.c: fix typo
fix typo, should include ADC file, not PWM file
2024-11-19 00:55:35 +08:00
Xiang Xiao
34cc7e8100 boards/arm/qemu/qemu-armv7a: Fix the typo error in dramboot.ld
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2024-11-16 17:42:09 +01:00
stbenn
caaee545b1 arch/stm32h5: Simplify PLL configuration.
The PLL clock configuration was simplified on the assumption the clocks are correctly set in the board.h file. Instead of seperate conditions
for register components, assume the relevant PLL registers are fully defined in board.h. This should result in easier to understand defines in board.h
and simpler code flow in the standard clock configuration function.

Changes were mad in the board file alongside changing the arch files. Changes to board/stm32h5:
  - PLL1 has been configured to use integer instead of fractional mode to reach the 250 MHz target. PLL2 and PLL3 configurations were
    removed since they are currently unused in the H5 configuration.
  - PLL1 output was verified by testing for changes in serial baud rate.
2024-11-16 01:55:32 +08:00
buxiasen
f53f0ecf0e sama5/at25_main: fix direct use of nput, convert to int
Signed-off-by: buxiasen <buxiasen@xiaomi.com>
2024-11-15 01:05:04 +08:00
xuxin19
d2a7e454bb build(qemu):add a qemu compilation configuration with application
enable various types of common applications and libraries, and enable CMake CI checks.
To avoid regression issues in the build system

Signed-off-by: xuxin19 <xuxin19@xiaomi.com>
2024-11-14 22:50:49 +08:00
wangjianyu3
85eed31443 mps3-an547:ap: Disable cmd_wait() as it depends on procfs currently
More details please see https://github.com/apache/nuttx-apps/pull/2848

Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
2024-11-14 13:42:34 +08:00
Federico Braghiroli
3d90079f50 boards/stm32f103-minimum: fix unaligned pointer to .data section in ld.script
This patch fix _eronly value which is used during boot process to initialize
.data section to sram.

Since .data section is 4 byte aligned in flash, also _eronly must follow this
alignment to stay coherent with the start address of .data.

If one of the sections preceeding .data has a size which is not 4 byte aligned,
the _eronly value does not match with .data physical address resulting in wrong
copy of data section to sram and thus an almost immediate hardfault.

Signed-off-by: Federico Braghiroli <federico.braghiroli@gmail.com>
2024-11-13 21:59:24 +08:00
Henry Rovner
f22685fb69 arm/rp2040: Add support for Waveshare RP2040 Zero board
This change adds a few simple configurations for the Waveshare RP2040 Zero board, along with accompanying documentation.
2024-11-13 09:53:36 +08:00
wangmingrong1
1d1ef52d1a arm/mps: Add a gcov functional testing configuration for mps-clang
Signed-off-by: wangmingrong1 <wangmingrong1@xiaomi.com>
2024-11-13 05:33:00 +08:00
Alan Carvalho de Assis
cd2633ddcc arm/olimex-stm32-p407: Fix kmodule board profile
Just increase the ksram and usram to avoid compilation issue.

Signed-off-by: Alan C. Assis <acassis@gmail.com>
2024-11-13 02:47:37 +08:00
YAMAMOTO Takashi
7ebe59022c Remove "dumprun" functions from various LCD drivers
* It seems that they assume up_putc() and syslog() outputs to the
  same device. Depending on the system and configurations, it's wrong.

* They are wrapped with "#if 0" and unused.

Fixes https://github.com/apache/nuttx/issues/14694
2024-11-12 17:25:31 +08:00
78aa26331b arm/phy6222: Fix the garbled Linker Script
The Linker Script for phy6222 was garbled due to the SPDX Update. This PR removes the garbled text.
- https://github.com/apache/nuttx/pull/14704
2024-11-10 14:19:33 -03:00
Alin Jerpelea
09b299d377 boards/arm/xmc4: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
5a90a565c1 boards/arm/tms570: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
203bfbc826 boards/arm/tlsr82: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
58b665b296 boards/arm/tiva: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
05d531dc82 boards/arm/str71x: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
2529200b38 boards/arm/stm32wl5: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
47c237a72a boards/arm/stm32wb: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
a6f1605107 boards/arm/stm32u5: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
e316bdf9ba boards/arm/stm32l5: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
290948e4a9 boards/arm/stm32l4: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
4465640587 boards/arm/stm32h7: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
b719df375e boards/arm/stm32h5: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
bfa4be9088 boards/arm/stm32f7: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
56b71deadc boards/arm/stm32f0l0g0: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
8345e5626e boards/arm/stm32: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
8592df0c22 boards/arm/samv7: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
985d7458f3 boards/arm/samd5e5: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
c217233a08 boards/arm/samd2l2: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00
Alin Jerpelea
b1abd04da9 boards/arm/sama5: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-11-10 01:12:34 +08:00