[GitHub] [nuttx] davids5 commented on pull request #6787: imxrt: Ethernet Cleanup and extend support for ETH1 or ETH2 and LAN8742A

2023-02-09 Thread via GitHub


davids5 commented on PR #6787:
URL: https://github.com/apache/nuttx/pull/6787#issuecomment-1425319361

   @
   
   > @davids5 Sorry for adding my comments to this old PR. In this PR, it seems 
that you fixed write-back cache issues in imxrt_enet.c. So I removed the 
write-through configuration from imxrt1060-evk:netnsh like
   > 
   > ```
   > --- a/boards/arm/imxrt/imxrt1060-evk/configs/netnsh/defconfig
   > +++ b/boards/arm/imxrt/imxrt1060-evk/configs/netnsh/defconfig
   > @@ -14,7 +14,6 @@ CONFIG_ARCH_CHIP_IMXRT=y
   >  CONFIG_ARCH_CHIP_MIMXRT1062DVL6A=y
   >  CONFIG_ARCH_STACKDUMP=y
   >  CONFIG_ARMV7M_DCACHE=y
   > -CONFIG_ARMV7M_DCACHE_WRITETHROUGH=y
   >  CONFIG_ARMV7M_ICACHE=y
   >  CONFIG_ARMV7M_USEBASEPRI=y
   >  CONFIG_BOARD_LOOPSPERMSEC=104926
   > ```
   > 
   > And tried to see how the networking with imxrt1060-evk is stable. However, 
it stopped after several minutes. Do you think d-cache write-back mode works 
with imxrt1060-evk?
   
   Yes. I have not tested on current master but it was working here 
https://github.com/PX4/PX4-Autopilot/tree/pr-fmu1062/boards/nxp/fmurt1062-v2 
with NuttX 10.3+


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] 01/03: arch: imxrt: Fix imxrt for CONFIG_BUILD_PROTECTED=y

2023-02-09 Thread davids5
This is an automated email from the ASF dual-hosted git repository.

davids5 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 777c6c4aadfe88ae22be216fe40d84190f709b4c
Author: Masayuki Ishikawa 
AuthorDate: Thu Feb 9 11:53:42 2023 +0900

arch: imxrt: Fix imxrt for CONFIG_BUILD_PROTECTED=y

Summary:
- Fix imxrt_allocateheap.c for CONFIG_BUILD_PROTECTED=y
- Call mpu_reset() in imxrt_mpuinit.c

Impact:
- CONFIG_BUILD_PROTECTED=y only

Testing:
- Tested with imxrt1060-evk:knsh (will be updated later)

Signed-off-by: Masayuki Ishikawa 
---
 arch/arm/src/imxrt/imxrt_allocateheap.c | 30 ++
 arch/arm/src/imxrt/imxrt_mpuinit.c  |  4 
 2 files changed, 34 insertions(+)

diff --git a/arch/arm/src/imxrt/imxrt_allocateheap.c 
b/arch/arm/src/imxrt/imxrt_allocateheap.c
index b4fa3e6ad7..333804c863 100644
--- a/arch/arm/src/imxrt/imxrt_allocateheap.c
+++ b/arch/arm/src/imxrt/imxrt_allocateheap.c
@@ -36,6 +36,7 @@
 
 #include 
 
+#include "mpu.h"
 #include "arm_internal.h"
 #include "hardware/imxrt_memorymap.h"
 #include "imxrt_mpuinit.h"
@@ -309,14 +310,30 @@ void up_allocate_heap(void **heap_start, size_t 
*heap_size)
   uintptr_t ubase = (uintptr_t)USERSPACE->us_bssend +
  CONFIG_MM_KERNEL_HEAPSIZE;
   size_tusize = PRIMARY_RAM_END - ubase;
+  int   log2;
 
   DEBUGASSERT(ubase < (uintptr_t)PRIMARY_RAM_END);
 
+  /* Adjust that size to account for MPU alignment requirements.
+   * NOTE that there is an implicit assumption that the PRIMARY_RAM_END
+   * is aligned to the MPU requirement.
+   */
+
+  log2  = (int)mpu_log2regionfloor(usize);
+  DEBUGASSERT((PRIMARY_RAM_END & ((1 << log2) - 1)) == 0);
+
+  usize = (1 << log2);
+  ubase = PRIMARY_RAM_END - usize;
+
   /* Return the user-space heap settings */
 
   board_autoled_on(LED_HEAPALLOCATE);
   *heap_start = (void *)ubase;
   *heap_size  = usize;
+
+  /* Allow user-mode access to the user heap memory */
+
+  imxrt_mpu_uheap((uintptr_t)ubase, usize);
 #else
 
   /* Return the heap settings */
@@ -348,8 +365,21 @@ void up_allocate_kheap(void **heap_start, size_t 
*heap_size)
 
   uintptr_t ubase = (uintptr_t)USERSPACE->us_bssend +
 CONFIG_MM_KERNEL_HEAPSIZE;
+  size_tusize = PRIMARY_RAM_END - ubase;
+  int   log2;
   DEBUGASSERT(ubase < (uintptr_t)PRIMARY_RAM_END);
 
+  /* Adjust that size to account for MPU alignment requirements.
+   * NOTE that there is an implicit assumption that the CONFIG_RAM_END
+   * is aligned to the MPU requirement.
+   */
+
+  log2  = (int)mpu_log2regionfloor(usize);
+  DEBUGASSERT((PRIMARY_RAM_END & ((1 << log2) - 1)) == 0);
+
+  usize = (1 << log2);
+  ubase = PRIMARY_RAM_END - usize;
+
   /* Return the kernel heap settings (i.e., the part of the heap region
* that was not dedicated to the user heap).
*/
diff --git a/arch/arm/src/imxrt/imxrt_mpuinit.c 
b/arch/arm/src/imxrt/imxrt_mpuinit.c
index dc03caabe6..5f8db353ca 100644
--- a/arch/arm/src/imxrt/imxrt_mpuinit.c
+++ b/arch/arm/src/imxrt/imxrt_mpuinit.c
@@ -91,6 +91,10 @@ void imxrt_mpu_initialize(void)
 
   mpu_showtype();
 
+  /* Reset MPU if enabled */
+
+  mpu_reset();
+
 #ifdef CONFIG_ARMV7M_DCACHE
   /* Memory barrier */
 



[nuttx] 02/03: boards: imxrt1060-evk: Fix knsh and related linker script files

2023-02-09 Thread davids5
This is an automated email from the ASF dual-hosted git repository.

davids5 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit e95b032c7480bffdc2931d3e09e22f687c897764
Author: Masayuki Ishikawa 
AuthorDate: Thu Feb 9 11:58:57 2023 +0900

boards: imxrt1060-evk: Fix knsh and related linker script files

Summary:
- Fix knsh/defconfig to work with pyOCD
- Fix kernel-space.ld to boot
- Fix memory.ld for CONFIG_BUILD_PROTECTED=y

Impact:
- CONFIB_BUILD_PROTECTED=y only

Testing:
- Tested with imxrt1060-evk

Signed-off-by: Masayuki Ishikawa 
---
 .../arm/imxrt/imxrt1060-evk/configs/knsh/defconfig  |  2 ++
 .../arm/imxrt/imxrt1060-evk/scripts/kernel-space.ld | 21 +
 boards/arm/imxrt/imxrt1060-evk/scripts/memory.ld|  7 ---
 3 files changed, 27 insertions(+), 3 deletions(-)

diff --git a/boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig 
b/boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig
index ba97882d44..c92e9294ca 100644
--- a/boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig
+++ b/boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig
@@ -15,7 +15,9 @@ CONFIG_ARCH_CHIP_MIMXRT1062DVL6A=y
 CONFIG_ARCH_STACKDUMP=y
 CONFIG_ARMV7M_DCACHE=y
 CONFIG_ARMV7M_DCACHE_WRITETHROUGH=y
+CONFIG_ARMV7M_DTCM=y
 CONFIG_ARMV7M_ICACHE=y
+CONFIG_ARMV7M_ITCM=y
 CONFIG_ARMV7M_USEBASEPRI=y
 CONFIG_ARM_MPU=y
 CONFIG_BOARD_LOOPSPERMSEC=104926
diff --git a/boards/arm/imxrt/imxrt1060-evk/scripts/kernel-space.ld 
b/boards/arm/imxrt/imxrt1060-evk/scripts/kernel-space.ld
index 172f194495..3aa0e1a15a 100644
--- a/boards/arm/imxrt/imxrt1060-evk/scripts/kernel-space.ld
+++ b/boards/arm/imxrt/imxrt1060-evk/scripts/kernel-space.ld
@@ -24,10 +24,31 @@
 
 OUTPUT_ARCH(arm)
 EXTERN(_vectors)
+EXTERN(g_flash_config)
+EXTERN(g_image_vector_table)
+EXTERN(g_boot_data)
+
 ENTRY(_stext)
 
 SECTIONS
 {
+/* Image Vector Table and Boot Data for booting from external flash */
+
+.boot_hdr : ALIGN(4)
+{
+FILL(0xff)
+__boot_hdr_start__ = ABSOLUTE(.) ;
+KEEP(*(.boot_hdr.conf))
+. = 0x1000 ;
+KEEP(*(.boot_hdr.ivt))
+. = 0x1020 ;
+KEEP(*(.boot_hdr.boot_data))
+. = 0x1030 ;
+KEEP(*(.boot_hdr.dcd_data))
+__boot_hdr_end__ = ABSOLUTE(.) ;
+. = 0x2000 ;
+} > kflash
+
   .text :
   {
 _stext = ABSOLUTE(.);
diff --git a/boards/arm/imxrt/imxrt1060-evk/scripts/memory.ld 
b/boards/arm/imxrt/imxrt1060-evk/scripts/memory.ld
index 38982bc19c..48f8cc471c 100644
--- a/boards/arm/imxrt/imxrt1060-evk/scripts/memory.ld
+++ b/boards/arm/imxrt/imxrt1060-evk/scripts/memory.ld
@@ -61,7 +61,8 @@ MEMORY
 
   /* 1MiB of OCRAM */
 
-  dtcm   (rwx) : ORIGIN = 0x2000, LENGTH = 512K
-  kocram (rwx) : ORIGIN = 0x2020, LENGTH = 512K
-  uocram (rwx) : ORIGIN = 0x2024, LENGTH = 512K
+  itcm   (rwx) : ORIGIN = 0x, LENGTH = 128K
+  dtcm   (rwx) : ORIGIN = 0x2000, LENGTH = 128K
+  kocram (rwx) : ORIGIN = 0x2020, LENGTH = 256K
+  uocram (rwx) : ORIGIN = 0x2024, LENGTH = 256K
 }



[nuttx] 03/03: boards: imxrt1060-evk: Update knsh

2023-02-09 Thread davids5
This is an automated email from the ASF dual-hosted git repository.

davids5 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 80ebff90d51b992e892b6990cb20bd948acbb4ae
Author: Masayuki Ishikawa 
AuthorDate: Fri Feb 10 10:18:20 2023 +0900

boards: imxrt1060-evk: Update knsh

Summary:
- Add built-in apps such as ostest, getprime, hello
- Enable some debug configurations
- Enable interrupt stack and stack coloring

Impact:
- None

Testing:
- Tested with imxrt1060-evk

Signed-off-by: Masayuki Ishikawa 
---
 boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig | 17 +
 1 file changed, 17 insertions(+)

diff --git a/boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig 
b/boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig
index c92e9294ca..3b8988def6 100644
--- a/boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig
+++ b/boards/arm/imxrt/imxrt1060-evk/configs/knsh/defconfig
@@ -6,12 +6,14 @@
 # modifications.
 #
 # CONFIG_ARCH_RAMFUNCS is not set
+# CONFIG_NSH_DISABLE_MW is not set
 CONFIG_ARCH="arm"
 CONFIG_ARCH_BOARD="imxrt1060-evk"
 CONFIG_ARCH_BOARD_IMXRT1060_EVK=y
 CONFIG_ARCH_CHIP="imxrt"
 CONFIG_ARCH_CHIP_IMXRT=y
 CONFIG_ARCH_CHIP_MIMXRT1062DVL6A=y
+CONFIG_ARCH_INTERRUPTSTACK=2048
 CONFIG_ARCH_STACKDUMP=y
 CONFIG_ARMV7M_DCACHE=y
 CONFIG_ARMV7M_DCACHE_WRITETHROUGH=y
@@ -22,6 +24,14 @@ CONFIG_ARMV7M_USEBASEPRI=y
 CONFIG_ARM_MPU=y
 CONFIG_BOARD_LOOPSPERMSEC=104926
 CONFIG_BUILD_PROTECTED=y
+CONFIG_BUILTIN=y
+CONFIG_DEBUG_BUSFAULT=y
+CONFIG_DEBUG_FULLOPT=y
+CONFIG_DEBUG_HARDFAULT_ALERT=y
+CONFIG_DEBUG_MEMFAULT=y
+CONFIG_DEBUG_SYMBOLS=y
+CONFIG_DEBUG_USAGEFAULT=y
+CONFIG_EXAMPLES_HELLO=y
 CONFIG_FS_PROCFS=y
 CONFIG_IDLETHREAD_STACKSIZE=2048
 CONFIG_IMXRT_LPUART1=y
@@ -29,6 +39,7 @@ CONFIG_INIT_ENTRYPOINT="nsh_main"
 CONFIG_INTELHEX_BINARY=y
 CONFIG_LPUART1_SERIAL_CONSOLE=y
 CONFIG_NSH_ARCHINIT=y
+CONFIG_NSH_BUILTIN_APPS=y
 CONFIG_NSH_DISABLE_MKRD=y
 CONFIG_NSH_FILEIOSIZE=512
 CONFIG_NSH_LINELEN=64
@@ -38,6 +49,12 @@ CONFIG_PASS1_BUILDIR="boards/arm/imxrt/imxrt1060-evk/kernel"
 CONFIG_RAM_SIZE=1048576
 CONFIG_RAM_START=0x2020
 CONFIG_SCHED_WAITPID=y
+CONFIG_STACK_COLORATION=y
 CONFIG_START_DAY=8
 CONFIG_START_MONTH=6
 CONFIG_SYSTEM_NSH=y
+CONFIG_TESTING_GETPRIME=y
+CONFIG_TESTING_OSTEST=y
+CONFIG_TESTING_OSTEST_FPUTESTDISABLE=y
+CONFIG_TESTING_OSTEST_NBARRIER_THREADS=3
+CONFIG_TESTING_OSTEST_STACKSIZE=2048



[nuttx] branch master updated (1cc6e4b1fa -> 80ebff90d5)

2023-02-09 Thread davids5
This is an automated email from the ASF dual-hosted git repository.

davids5 pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 1cc6e4b1fa sim: add uart dma mode & use work instead of loop.
 new 777c6c4aad arch: imxrt: Fix imxrt for CONFIG_BUILD_PROTECTED=y
 new e95b032c74 boards: imxrt1060-evk: Fix knsh and related linker script 
files
 new 80ebff90d5 boards: imxrt1060-evk: Update knsh

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 arch/arm/src/imxrt/imxrt_allocateheap.c| 30 ++
 arch/arm/src/imxrt/imxrt_mpuinit.c |  4 +++
 .../arm/imxrt/imxrt1060-evk/configs/knsh/defconfig | 19 ++
 .../imxrt/imxrt1060-evk/scripts/kernel-space.ld| 21 +++
 boards/arm/imxrt/imxrt1060-evk/scripts/memory.ld   |  7 ++---
 5 files changed, 78 insertions(+), 3 deletions(-)



[GitHub] [nuttx] davids5 merged pull request #8492: Fix imxrt1060-evk:knsh

2023-02-09 Thread via GitHub


davids5 merged PR #8492:
URL: https://github.com/apache/nuttx/pull/8492


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #8489: sim: remove the critical_section in IRQ handler

2023-02-09 Thread via GitHub


masayuki2009 commented on PR #8489:
URL: https://github.com/apache/nuttx/pull/8489#issuecomment-1425273120

   @GUIDINGLI 
   By the way, I noticed that the nuttx consumes much CPU time compared to 
nuttx-12.0.0-RC1.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx-apps] branch master updated (9ee3640b6 -> 8e77b79f7)

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git


from 9ee3640b6 testing/drivertest: add block driver test
 add 8e77b79f7 Kconfig: Make indent consistent with TABS

No new revisions were added by this update.

Summary of changes:
 canutils/candump/Kconfig  |  2 +-
 canutils/cansend/Kconfig  |  2 +-
 examples/nrf24l01_btle/Kconfig|  2 +-
 examples/pty_test/Kconfig | 12 ++---
 games/shift/Kconfig   |  2 +-
 math/libtommath/Kconfig   | 96 +++
 mlearning/cmsis/Kconfig   | 10 ++--
 mlearning/darknet/Kconfig |  2 +-
 netutils/codecs/Kconfig   |  2 +-
 netutils/dhcp6c/Kconfig   | 12 ++---
 netutils/thttpd/Kconfig   |  2 +-
 nshlib/Kconfig| 48 ++--
 system/uniqueid/Kconfig   | 10 ++--
 wireless/bluetooth/nimble/Kconfig | 20 
 14 files changed, 111 insertions(+), 111 deletions(-)



[GitHub] [nuttx-apps] xiaoxiang781216 merged pull request #1556: Kconfig: Make indent consistent with TABS

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #1556:
URL: https://github.com/apache/nuttx-apps/pull/1556


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated: sim: add uart dma mode & use work instead of loop.

2023-02-09 Thread archer
This is an automated email from the ASF dual-hosted git repository.

archer pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
 new 1cc6e4b1fa sim: add uart dma mode & use work instead of loop.
1cc6e4b1fa is described below

commit 1cc6e4b1faee2c60c72ba5ba32ebdad28e08548b
Author: ligd 
AuthorDate: Fri Feb 3 18:44:03 2023 +0800

sim: add uart dma mode & use work instead of loop.

Signed-off-by: ligd 
---
 arch/Kconfig   |   1 +
 arch/sim/Kconfig   |   8 +
 arch/sim/src/sim/posix/sim_hostuart.c  |  30 ++-
 arch/sim/src/sim/sim_initialize.c  |   4 -
 arch/sim/src/sim/sim_internal.h|  19 +-
 arch/sim/src/sim/sim_uart.c| 247 -
 arch/sim/src/sim/win/sim_hostuart.c|  21 +-
 boards/sim/sim/sim/configs/citest/defconfig|   1 -
 boards/sim/sim/sim/configs/crypto/defconfig|   1 -
 boards/sim/sim/sim/configs/foc/defconfig   |   1 -
 boards/sim/sim/sim/configs/lua/defconfig   |   1 -
 boards/sim/sim/sim/configs/minmea/defconfig|   1 -
 boards/sim/sim/sim/configs/mtdrwb/defconfig|   2 -
 boards/sim/sim/sim/configs/nsh/defconfig   |   1 -
 boards/sim/sim/sim/configs/nxcamera/defconfig  |   1 -
 boards/sim/sim/sim/configs/nxscope/defconfig   |   1 -
 boards/sim/sim/sim/configs/nxwm/defconfig  |   2 -
 boards/sim/sim/sim/configs/pf_ieee802154/defconfig |   1 -
 boards/sim/sim/sim/configs/pktradio/defconfig  |   1 -
 boards/sim/sim/sim/configs/rpproxy/defconfig   |   1 -
 boards/sim/sim/sim/configs/rpserver/defconfig  |   1 -
 boards/sim/sim/sim/configs/rust/defconfig  |   1 -
 boards/sim/sim/sim/configs/segger/defconfig|   1 -
 boards/sim/sim/sim/configs/sixlowpan/defconfig |   1 -
 boards/sim/sim/sim/configs/tcpblaster/defconfig|   1 -
 boards/sim/sim/sim/configs/usrsocktest/defconfig   |   1 -
 boards/sim/sim/sim/configs/windows/defconfig   |   1 -
 27 files changed, 233 insertions(+), 119 deletions(-)

diff --git a/arch/Kconfig b/arch/Kconfig
index 7ad4673c4e..5f0cea0731 100644
--- a/arch/Kconfig
+++ b/arch/Kconfig
@@ -106,6 +106,7 @@ config ARCH_SIM
select ONESHOT
select SERIAL_CONSOLE
select SERIAL_IFLOWCONTROL
+   select SCHED_HPWORK
---help---
Linux/Cygwin user-mode simulation.
 
diff --git a/arch/sim/Kconfig b/arch/sim/Kconfig
index d221f2ba0e..875085660d 100644
--- a/arch/sim/Kconfig
+++ b/arch/sim/Kconfig
@@ -504,6 +504,14 @@ endif
 
 menu "Simulated UART"
 
+config SIM_UART_DMA
+   bool "SIM UART use DMA mode"
+   default y
+   select SERIAL_TXDMA
+   select SERIAL_RXDMA
+   ---help---
+   console use DMA mode or single char mode
+
 config SIM_UART_NUMBER
int "Number of simulated UART ports"
default 0
diff --git a/arch/sim/src/sim/posix/sim_hostuart.c 
b/arch/sim/src/sim/posix/sim_hostuart.c
index b464301f75..8be67f086d 100644
--- a/arch/sim/src/sim/posix/sim_hostuart.c
+++ b/arch/sim/src/sim/posix/sim_hostuart.c
@@ -131,25 +131,37 @@ void host_uart_close(int fd)
 }
 
 /
- * Name: host_uart_putc
+ * Name: host_uart_puts
  /
 
-int host_uart_putc(int fd, int ch)
+ssize_t host_uart_puts(int fd, const char *buf, size_t size)
 {
-  return write(fd, , 1) == 1 ? ch : -1;
+  ssize_t ret;
+
+  do
+{
+  ret = write(fd, buf, size);
+}
+  while (ret < 0 && errno == EINTR);
+
+  return ret < 0 ? -errno : ret;
 }
 
 /
- * Name: host_uart_getc
+ * Name: host_uart_gets
  /
 
-int host_uart_getc(int fd)
+ssize_t host_uart_gets(int fd, char *buf, size_t size)
 {
-  int ret;
-  unsigned char ch;
+  ssize_t ret;
+
+  do
+{
+  ret = read(fd, buf, size);
+}
+  while (ret < 0 && errno == EINTR);
 
-  ret = read(fd, , 1);
-  return ret < 0 ? ret : ch;
+  return ret < 0 ? -errno : ret;
 }
 
 /
diff --git a/arch/sim/src/sim/sim_initialize.c 
b/arch/sim/src/sim/sim_initialize.c
index 9ae9df4e58..ab65e77690 100644
--- a/arch/sim/src/sim/sim_initialize.c
+++ b/arch/sim/src/sim/sim_initialize.c
@@ -166,10 +166,6 @@ static int sim_loop_task(int argc, char **argv)
 
   sched_lock();
 
-  /* Handle UART data availability */
-
-  sim_uartloop();
-
 #if defined(CONFIG_SIM_TOUCHSCREEN) || defined(CONFIG_SIM_AJOYSTICK) || \
 defined(CONFIG_SIM_BUTTONS)
   /* Drive the X11 event loop */
diff --git 

[GitHub] [nuttx] anchao merged pull request #8470: sim: add uart dma mode & use work instead of loop

2023-02-09 Thread via GitHub


anchao merged PR #8470:
URL: https://github.com/apache/nuttx/pull/8470


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] GUIDINGLI commented on pull request #8489: sim: remove the critical_section in IRQ handler

2023-02-09 Thread via GitHub


GUIDINGLI commented on PR #8489:
URL: https://github.com/apache/nuttx/pull/8489#issuecomment-1425202319

   @masayuki2009 
   
   Thanks for the reply.
   
   I have tried the CONFIG_SMP_NCPUS=1.
   
   ```
   ligd@Opt:~/platform/mainline/nuttx$ 
   ligd@Opt:~/platform/mainline/nuttx$ uname -a
   Linux Opt 5.15.0-58-generic #64~20.04.1-Ubuntu SMP Fri Jan 6 16:42:31 UTC 
2023 x86_64 x86_64 x86_64 GNU/Linux
   ligd@Opt:~/platform/mainline/nuttx$ 
   ligd@Opt:~/platform/mainline/nuttx$ 
   ligd@Opt:~/platform/mainline/nuttx$ vim .config
   ligd@Opt:~/platform/mainline/nuttx$ 
   ligd@Opt:~/platform/mainline/nuttx$ 
   ligd@Opt:~/platform/mainline/nuttx$ cat .config |grep NCPUS
   CONFIG_SMP_NCPUS=1
   ligd@Opt:~/platform/mainline/nuttx$ 
   ligd@Opt:~/platform/mainline/nuttx$ ./nuttx 
   
   NuttShell (NSH) NuttX-10.4.0
   nsh> ps
 PID GROUP CPU PRI POLICY   TYPENPX STATEEVENT SIGMASK   STACK  
 USED  FILLED COMMAND
   0 0   0   0 FIFO Kthread N-- Assigned    066512 
004760   7.1%  CPU0 IDLE
   1 1 --- 255 FIFO Kthread --- Waiting  Signal 067504 
004728   7.0%  loop_task
   2 2   0 100 FIFO Task--- Running 067504 
007000  10.3%  nsh_main
   nsh> 
   ```
   
   
   I will find a 18.04 Ubuntu to try this.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #8486: sched/nxtask_sigchild: Set process exit code to group exit code

2023-02-09 Thread via GitHub


masayuki2009 commented on PR #8486:
URL: https://github.com/apache/nuttx/pull/8486#issuecomment-1425192882

   @pussuw 
   We can reproduce the same issue if we add some configs like
   
   ```
   --- a/boards/risc-v/qemu-rv/rv-virt/configs/nsh/defconfig
   +++ b/boards/risc-v/qemu-rv/rv-virt/configs/nsh/defconfig
   @@ -55,6 +55,8 @@ CONFIG_RAM_START=0x8000
CONFIG_READLINE_CMD_HISTORY=y
CONFIG_RISCV_SEMIHOSTING_HOSTFS=y
CONFIG_RR_INTERVAL=200
   +CONFIG_SCHED_CHILD_STATUS=y
   +CONFIG_SCHED_HAVE_PARENT=y
CONFIG_SCHED_WAITPID=y
CONFIG_SERIAL_UART_ARCH_MMIO=y
CONFIG_STACK_COLORATION=y
   ```
   
   And run ostest
   
   ```
   + /home/ishikawa/opensource/QEMU/qemu-7.1/build/qemu-system-riscv32 
-semihosting -nographic -cpu rv32 -smp 8 -M virt,aclint=on -bios none -kernel 
nuttx
   NuttShell (NSH) NuttX-12.0.0
   nsh> ps
 PID GROUP PRI POLICY   TYPENPX STATEEVENT SIGMASK   STACK   
USED  FILLED COMMAND
   0 0   0 FIFO Kthread N-- Ready   002016 
000552  27.3%  Idle Task
   1 1 100 RR   Task--- Running 001984 
001228  61.8%  nsh_main
   nsh> help
   help usage:  help [-v] []
   
 . cddmesg free  mkrd  rmtime  
uptime
 [ cpecho  help  mount rmdir true  
usleep
 ? cmp   env   hexdump   mvset   truncate  xd
 basename  dirname   exec  kill  printfsleep uname
 break ddexit  lspssourceumount
 cat   dffalse mkdir pwd   test  unset
   
   Builtin Apps:
 ostest  sh  nsh
   nsh> ostest
   ...
   user_main: waitpid test
   
   Test waitpid()
   waitpid_start_child: Started waitpid_main at PID=5
   waitpid_start_child: Started waitpid_main at PID=6
   waitpid_start_child: Started waitpid_main at PID=7
   waitpid_test: Waiting for PID=5 with waitpid()
   waitpid_main: PID 5 Started
   waitpid_main: PID 6 Started
   waitpid_main: PID 7 Started
   waitpid_main: PID 5 exitting with result=14
   waitpid_main: PID 6 exitting with result=14
   waitpid_main: PID 7 exitting with result=14
   waitpid_test: ERROR: PID 5 return status is 0, expected 14
   _assert: Current Version: NuttX  12.0.0 739688f6c6-dirty Feb 10 2023 
14:23:10 risc-v
   _assert: Assertion failed : at file: waitpid.c:220 task: ostest 0x80014988
   up_dump_register: EPC: 80014552
   up_dump_register: A0:  A1: 80028274 A2: 1000 A3: 0001
   up_dump_register: A4: 000a A5:  A6: 8000 A7: 8000
   up_dump_register: T0: 0030 T1: 4000 T2: 0020 T3: 002a
   up_dump_register: T4: 002e T5: 01ff T6: 002d
   up_dump_register: S0: 8002bb00 S1:  S2: 8001e1d4 S3: 800288f0
   up_dump_register: S4: 80021c04 S5: 00dc S6:  S7: 
   up_dump_register: S8:  S9:  S10:  S11: 
   up_dump_register: SP: 8002dda0 FP: 8002bb00 TP:  RA: 80010a48
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #8486: sched/nxtask_sigchild: Set process exit code to group exit code

2023-02-09 Thread via GitHub


masayuki2009 commented on PR #8486:
URL: https://github.com/apache/nuttx/pull/8486#issuecomment-1425187600

   >Is this testing the child return code ? I'm very confused. The original 
test seems to be a bit incomplete, as it sets #define >RETURN_STATUS 14 for 
every one and then tests if all return this.
   
   Yes, all child tasks execute `waitpid_main()` which return the maginal 
number (i.e. RETURN_STATUS (14)).
   
   ```
   static int waitpid_main(int argc, char *argv[])
   {
 pid_t me = getpid();
   
 printf("waitpid_main: PID %d Started\n", me);
 sleep(3);
 printf("waitpid_main: PID %d exitting with result=%d\n",
 me, RETURN_STATUS);
 return RETURN_STATUS;
   }
   ```
   
   Actually, we can see them in the log.
   
   ```
   waitpid_main: PID 7 Started
   waitpid_main: PID 11 Started
   waitpid_main: PID 12 Started
   waitpid_main: PID 7 exitting with result=14
   waitpid_main: PID 11 exitting with result=14
   waitpid_main: PID 12 exitting with result=14
   ```
   
   >It seems to me that all the return codes just bucketed into this magical 
number 14 before, and this no longer happens.
   
   However, it seems that waitpid() for the last child task obtains a different 
status code (i.e. 0).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #8489: sim: remove the critical_section in IRQ handler

2023-02-09 Thread via GitHub


masayuki2009 commented on PR #8489:
URL: https://github.com/apache/nuttx/pull/8489#issuecomment-1425153858

   @GUIDINGLI 
   I tried this PR with sim:smp (CONFIG_SMP_NCPUS=1) on ubuntu 18.04 x86_64.
   However, the deadlock still happens.
   
   ```
   --- a/boards/sim/sim/sim/configs/smp/defconfig
   +++ b/boards/sim/sim/sim/configs/smp/defconfig
   @@ -27,6 +27,7 @@ CONFIG_READLINE_CMD_HISTORY=y
CONFIG_SCHED_HAVE_PARENT=y
CONFIG_SIM_WALLTIME_SIGNAL=y
CONFIG_SMP=y
   +CONFIG_SMP_NCPUS=1
CONFIG_STACK_COLORATION=y
CONFIG_SYSTEM_NSH=y
CONFIG_SYSTEM_SYSTEM=y
   ```
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #6787: imxrt: Ethernet Cleanup and extend support for ETH1 or ETH2 and LAN8742A

2023-02-09 Thread via GitHub


masayuki2009 commented on PR #6787:
URL: https://github.com/apache/nuttx/pull/6787#issuecomment-1425134435

   @davids5 
   Sorry for adding my comments to this old PR.
   In this PR, it seems that you fixed write-back cache issues in imxrt_enet.c. 
   So I removed the write-through configuration from imxrt1060-evk:netnsh like
   
   ```
   --- a/boards/arm/imxrt/imxrt1060-evk/configs/netnsh/defconfig
   +++ b/boards/arm/imxrt/imxrt1060-evk/configs/netnsh/defconfig
   @@ -14,7 +14,6 @@ CONFIG_ARCH_CHIP_IMXRT=y
CONFIG_ARCH_CHIP_MIMXRT1062DVL6A=y
CONFIG_ARCH_STACKDUMP=y
CONFIG_ARMV7M_DCACHE=y
   -CONFIG_ARMV7M_DCACHE_WRITETHROUGH=y
CONFIG_ARMV7M_ICACHE=y
CONFIG_ARMV7M_USEBASEPRI=y
CONFIG_BOARD_LOOPSPERMSEC=104926
   ```
   
   And tried to see how the networking with imxrt1060-evk is stable.
   However, it stopped after several minutes.
   Do you think d-cache write-back mode works with imxrt1060-evk?
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] anchao opened a new pull request, #8494: tools/kconfig: add kconfiglib support

2023-02-09 Thread via GitHub


anchao opened a new pull request, #8494:
URL: https://github.com/apache/nuttx/pull/8494

   ## Summary
   
   tools/kconfig: add kconfiglib support
   
   Reference:
   https://github.com/ulfalizer/Kconfiglib
   
   Setup:
   pip install kconfiglib
   
   Signed-off-by: chao an 
   
   ## Impact
   
   N/A
   
   ## Testing
   
   Install kconfiglib and try 
menuconfig/savedefconfig/qconfig/oldconfig/olddefconfig


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] wengzhe opened a new pull request, #8493: net/udp: Support binding to same addr/port if SO_REUSEADDR is specified.

2023-02-09 Thread via GitHub


wengzhe opened a new pull request, #8493:
URL: https://github.com/apache/nuttx/pull/8493

   ## Summary
   UDP: Support binding to same addr/port if SO_REUSEADDR is specified.
   
   Ref: On Linux, if SO_REUSEADDR(sk_reuse) is set for both sockets, port will 
not be regarded as inuse and can be bound again. 
https://github.com/torvalds/linux/blob/v6.1/net/ipv4/udp.c#L146
   
   ## Impact
   UDP bind logic will change if SO_REUSEADDR is set.
   
   ## Testing
   CI, iperf3's server mode with UDP client
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated: sama5/twi: add support for flexcom twi

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
 new 739688f6c6 sama5/twi: add support for flexcom twi
739688f6c6 is described below

commit 739688f6c6fd95363ff70459a7a0f26eaff75545
Author: Janne Rosberg 
AuthorDate: Wed Feb 8 16:40:34 2023 +0200

sama5/twi: add support for flexcom twi
---
 arch/arm/src/sama5/Kconfig|  55 ++-
 arch/arm/src/sama5/Make.defs  |   3 +
 arch/arm/src/sama5/hardware/_sama5d2x_memorymap.h |   4 +
 arch/arm/src/sama5/sam_twi.c  | 177 +-
 4 files changed, 234 insertions(+), 5 deletions(-)

diff --git a/arch/arm/src/sama5/Kconfig b/arch/arm/src/sama5/Kconfig
index 07fb9d84a0..fd4d945a0e 100644
--- a/arch/arm/src/sama5/Kconfig
+++ b/arch/arm/src/sama5/Kconfig
@@ -203,6 +203,26 @@ config SAMA5_FLEXCOM_TWI
bool
default n
 
+config SAMA5_FLEXCOM_TWI0
+   bool
+   default n
+
+config SAMA5_FLEXCOM_TWI1
+   bool
+   default n
+
+config SAMA5_FLEXCOM_TWI2
+   bool
+   default n
+
+config SAMA5_FLEXCOM_TWI3
+   bool
+   default n
+
+config SAMA5_FLEXCOM_TWI4
+   bool
+   default n
+
 # Chip Selection
 
 config ARCH_CHIP_SAMA5D2
@@ -864,6 +884,7 @@ config SAMA5_FLEXCOM0_SPI
 config SAMA5_FLEXCOM0_TWI
bool "TWI"
select SAMA5_FLEXCOM_TWI
+   select SAMA5_FLEXCOM_TWI0
 
 endchoice # FLEXCOM0 Configuration
 
@@ -885,6 +906,7 @@ config SAMA5_FLEXCOM1_SPI
 config SAMA5_FLEXCOM1_TWI
bool "TWI"
select SAMA5_FLEXCOM_TWI
+   select SAMA5_FLEXCOM_TWI1
 
 endchoice # FLEXCOM1 Configuration
 
@@ -906,6 +928,7 @@ config SAMA5_FLEXCOM2_SPI
 config SAMA5_FLEXCOM2_TWI
bool "TWI"
select SAMA5_FLEXCOM_TWI
+   select SAMA5_FLEXCOM_TWI2
 
 endchoice # FLEXCOM2 Configuration
 
@@ -927,6 +950,7 @@ config SAMA5_FLEXCOM3_SPI
 config SAMA5_FLEXCOM3_TWI
bool "TWI"
select SAMA5_FLEXCOM_TWI
+   select SAMA5_FLEXCOM_TWI3
 
 endchoice # FLEXCOM3 Configuration
 
@@ -948,6 +972,7 @@ config SAMA5_FLEXCOM4_SPI
 config SAMA5_FLEXCOM4_TWI
bool "TWI"
select SAMA5_FLEXCOM_TWI
+   select SAMA5_FLEXCOM_TWI4
 
 endchoice # FLEXCOM4 Configuration
 endmenu # Flexcom Configuration
@@ -3172,7 +3197,7 @@ config SAMA5_FLEXCOM_SPI_DMADEBUG
 endmenu # Flexcom SPI device driver options
 endif # SAMA5_FLEXCOM0_SPI || SAMA5_FLEXCOM1_SPI || SAMA5_FLEXCOM2_SPI || 
SAMA5_FLEXCOM3_SPI || SAMA5_FLEXCOM4_SPI
 
-if SAMA5_TWI0 || SAMA5_TWI1 || SAMA5_TWI2 || SAMA5_TWI3
+if SAMA5_TWI0 || SAMA5_TWI1 || SAMA5_TWI2 || SAMA5_TWI3 || SAMA5_FLEXCOM_TWI
 
 menu "TWI device driver options"
 
@@ -3196,6 +3221,32 @@ config SAMA5_TWI3_FREQUENCY
default 10
depends on SAMA5_TWI3
 
+config SAMA5_TWI_FC0_FREQUENCY
+int "TWI4 (flexcom-0) Frequency"
+default 10
+depends on SAMA5_FLEXCOM_TWI0
+
+config SAMA5_TWI_FC1_FREQUENCY
+int "TWI5 (flexcom-1) Frequency"
+default 10
+depends on SAMA5_FLEXCOM_TWI1
+
+config SAMA5_TWI_FC2_FREQUENCY
+int "TWI6 (flexcom-2) Frequency"
+default 10
+depends on SAMA5_FLEXCOM_TWI2
+
+config SAMA5_TWI_FC3_FREQUENCY
+int "TWI7 (flexcom-3) Frequency"
+default 10
+depends on SAMA5_FLEXCOM_TWI3
+
+config SAMA5_TWI_FC4_FREQUENCY
+int "TWI8 (flexcom-4) Frequency"
+default 10
+depends on SAMA5_FLEXCOM_TWI4
+
+
 config SAMA5_TWI_REGDEBUG
bool "TWI register level debug"
depends on DEBUG_I2C_INFO
@@ -3205,7 +3256,7 @@ config SAMA5_TWI_REGDEBUG
Very invasive! Requires also CONFIG_DEBUG_I2C_INFO.
 
 endmenu # TWI device driver options
-endif # SAMA5_TWI0 || SAMA5_TWI1 || SAMA5_TWI2 || SAMA5_TWI3
+endif # SAMA5_TWI0 || SAMA5_TWI1 || SAMA5_TWI2 || SAMA5_TWI3 | 
SAMA5_FLEXCOM_TWI
 
 if SAMA5_SSC0 || SAMA5_SSC1
 menu "SSC Configuration"
diff --git a/arch/arm/src/sama5/Make.defs b/arch/arm/src/sama5/Make.defs
index c26f442a6a..ccd4599bea 100644
--- a/arch/arm/src/sama5/Make.defs
+++ b/arch/arm/src/sama5/Make.defs
@@ -187,6 +187,9 @@ else
 ifeq ($(CONFIG_SAMA5_TWI2),y)
 CHIP_CSRCS += sam_twi.c
 endif
+ifeq ($(CONFIG_SAMA5_FLEXCOM_TWI),y)
+CHIP_CSRCS += sam_twi.c
+endif
 endif
 endif
 
diff --git a/arch/arm/src/sama5/hardware/_sama5d2x_memorymap.h 
b/arch/arm/src/sama5/hardware/_sama5d2x_memorymap.h
index c8dddb7255..e5b870e5a6 100644
--- a/arch/arm/src/sama5/hardware/_sama5d2x_memorymap.h
+++ b/arch/arm/src/sama5/hardware/_sama5d2x_memorymap.h
@@ -522,6 +522,10 @@
 #define SAM_PIOC_VBASE   SAM_PIO_IOGROUPC_VBASE
 #define SAM_PIOD_VBASE   SAM_PIO_IOGROUPD_VBASE
 
+#define SAM_FLEXCOM_USART_OFFSET (0x200)
+#define SAM_FLEXCOM_SPI_OFFSET   (0x400)
+#define SAM_FLEXCOM_TWI_OFFSET   (0x600)
+
 /* NuttX virtual base address
  *
  * The boot logic will create a temporarily mapping 

[GitHub] [nuttx] xiaoxiang781216 merged pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8484:
URL: https://github.com/apache/nuttx/pull/8484


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


xiaoxiang781216 commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1425105230

   Ok, let's ignore the special requirement.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 opened a new pull request, #8492: Fix imxrt1060-evk:knsh

2023-02-09 Thread via GitHub


masayuki2009 opened a new pull request, #8492:
URL: https://github.com/apache/nuttx/pull/8492

   ## Summary
   
   - This PR consists of the following 3 commits
 - commit1: arch: imxrt: Fix imxrt for CONFIG_BUILD_PROTECTED=y
- Fix imxrt_allocateheap.c for CONFIG_BUILD_PROTECTED=y
- Call mpu_reset() in imxrt_mpuinit.c
 - commit2: boards: imxrt1060-evk: Fix knsh and related linker script files
   - Fix knsh/defconfig to work with pyOCD
   - Fix kernel-space.ld to boot
   - Fix memory.ld for CONFIG_BUILD_PROTECTED=y
 - commit3: Update knsh
   - Add built-in apps such as ostest, getprime, hello
   - Enable some debug configurations
   - Enable interrupt stack and stack coloring 
   
   ## Impact
   
   - CONFIG_BUILD_PROTECTED=y onl
   
   ## Testing
   
   - Tested with imxrt1060-evk


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx-website] branch asf-site updated: Publishing web: b50f5ca4ed22743959c1160aab5dcc9ae18b3eff docs: 725dfd5db94dada5cc38405764955c81bccc77f1

2023-02-09 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a commit to branch asf-site
in repository https://gitbox.apache.org/repos/asf/nuttx-website.git


The following commit(s) were added to refs/heads/asf-site by this push:
 new c1ae2b2a Publishing web: b50f5ca4ed22743959c1160aab5dcc9ae18b3eff 
docs: 725dfd5db94dada5cc38405764955c81bccc77f1
c1ae2b2a is described below

commit c1ae2b2a95997c81eca105ac74763d31e801d7b7
Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
AuthorDate: Fri Feb 10 00:13:09 2023 +

Publishing web: b50f5ca4ed22743959c1160aab5dcc9ae18b3eff docs: 
725dfd5db94dada5cc38405764955c81bccc77f1
---
 content/docs/10.0.0/index.html | 2 +-
 content/docs/10.0.0/searchindex.js | 2 +-
 content/docs/10.0.1/index.html | 2 +-
 content/docs/10.0.1/searchindex.js | 2 +-
 content/docs/10.1.0/index.html | 2 +-
 content/docs/10.1.0/searchindex.js | 2 +-
 content/docs/10.2.0/index.html | 2 +-
 content/docs/10.2.0/searchindex.js | 2 +-
 content/docs/10.3.0/index.html | 2 +-
 content/docs/10.3.0/searchindex.js | 2 +-
 content/docs/11.0.0/index.html | 2 +-
 content/docs/11.0.0/searchindex.js | 2 +-
 content/docs/12.0.0/index.html | 2 +-
 content/docs/12.0.0/searchindex.js | 2 +-
 content/docs/latest/index.html | 2 +-
 content/docs/latest/searchindex.js | 2 +-
 content/feed.xml   | 4 ++--
 17 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/content/docs/10.0.0/index.html b/content/docs/10.0.0/index.html
index 31670c48..0b2a30b6 100644
--- a/content/docs/10.0.0/index.html
+++ b/content/docs/10.0.0/index.html
@@ -133,7 +133,7 @@ by following these 
 NuttX Documentation
 NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 32-bit microcontroller 
environments, the primary governing standards in NuttX are Posix and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).
-Last Updated: 09 February 23 at 00:11
+Last Updated: 10 February 23 at 00:10
 
 Table of 
Contents
 
diff --git a/content/docs/10.0.0/searchindex.js 
b/content/docs/10.0.0/searchindex.js
index a85ef8f0..02772f59 100644
--- a/content/docs/10.0.0/searchindex.js
+++ b/content/docs/10.0.0/searchindex.js
@@ -1 +1 @@
-Search.setIndex({docnames:["applications/index","boards/index","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/index","components/drivers/character/keypad","components/drivers/character/pwm","components/drivers/character/quadrature","components/drivers/character/rtc","components/drivers/character/serial","components/drivers/character/timer","components/drivers/character/touchscreen
 [...]
\ No newline at end of file
+Search.setIndex({docnames:["applications/index","boards/index","components/binfmt","components/drivers/block/index","components/drivers/character/analog","components/drivers/character/can","components/drivers/character/index","components/drivers/character/keypad","components/drivers/character/pwm","components/drivers/character/quadrature","components/drivers/character/rtc","components/drivers/character/serial","components/drivers/character/timer","components/drivers/character/touchscreen
 [...]
\ No newline at end of file
diff --git a/content/docs/10.0.1/index.html b/content/docs/10.0.1/index.html
index 698a4adc..23813364 100644
--- a/content/docs/10.0.1/index.html
+++ b/content/docs/10.0.1/index.html
@@ -147,7 +147,7 @@ by following these 
 NuttX Documentation
 NuttX is a real-time operating system (RTOS) with an emphasis on standards 
compliance and small footprint. Scalable from 8-bit to 32-bit microcontroller 
environments, the primary governing standards in NuttX are Posix and ANSI 
standards. Additional standard APIs from Unix and other common RTOS’s (such as 
VxWorks) are adopted for functionality not available under these standards, or 
for functionality that is not appropriate for deeply-embedded environments 
(such as fork()).
-Last Updated: 09 February 23 at 00:11
+Last Updated: 10 February 23 at 00:11
 
 Table of 
Contents
 
diff --git a/content/docs/10.0.1/searchindex.js 
b/content/docs/10.0.1/searchindex.js
index a85ef8f0..18fc3c03 100644
--- a/content/docs/10.0.1/searchindex.js
+++ b/content/docs/10.0.1/searchindex.js
@@ -1 +1 @@

[GitHub] [nuttx] pussuw commented on pull request #8486: sched/nxtask_sigchild: Set process exit code to group exit code

2023-02-09 Thread via GitHub


pussuw commented on PR #8486:
URL: https://github.com/apache/nuttx/pull/8486#issuecomment-1424903447

   I am a bit confused at this point, the test where the failure occurs is a 
bit odd.
   
   ```
 else if (WEXITSTATUS(stat_loc) != RETURN_STATUS)
   {
 printf("waitpid_test: ERROR: "
"PID %d return status is %d, expected %d\n",
g_waitpids[0], WEXITSTATUS(stat_loc), RETURN_STATUS);
 ASSERT(false);
   }
   ```
   Is this testing the child return code ? I'm very confused. The original test 
seems to be a bit incomplete, as it sets #define RETURN_STATUS 14 for every one 
and then tests if all return this.
   
   I'm not at all certain how to fix this.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] adamfeuer commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


adamfeuer commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424868094

   @jrosberg Deleted my previous comment since it was wrong - with FLEXCOM TWI 
on and the include in the include block it doesn't compile.
   
   Would you be willing to add a defconfig file that has FLEXCOM TWI turned on? 
I am not sure from the Kconfig settings what needs to be enabled.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pussuw commented on pull request #8486: sched/nxtask_sigchild: Set process exit code to group exit code

2023-02-09 Thread via GitHub


pussuw commented on PR #8486:
URL: https://github.com/apache/nuttx/pull/8486#issuecomment-1424846016

   > @pussuw I noticed that qemu-intel64:ostest failed withi this PR.
   > 
   > ```
   > + /home/ishikawa/opensource/QEMU/qemu-7.1/build/qemu-system-x86_64 -cpu 
host -enable-kvm -m 256M -cdrom boot.iso -nographic -serial mon:stdio
   > SeaBIOS (version rel-1.16.0-0-gd239552ce722-prebuilt.qemu.org)
   > 
   > 
   > iPXE (http://ipxe.org) 00:03.0 CA00 PCI2.10 PnP PMM+0FF91160+0FEF1160 CA00
   > 
   > 
   > 
   > Booting from Hard Disk...
   > Boot failed: could not read the boot disk
   > 
   > Booting from Floppy...
   > Boot failed: could not read the boot disk
   > 
   > Booting from DVD/CD...
   > stdio_test: write fd=1
   > stdio_test: Standard I/O Check: printf
   > stdio_test: write fd=2
   > ostest_main: putenv(Variable1=BadValue3)
   > ostest_main: setenv(Variable1, GoodValue1, TRUE)
   > ostest_main: setenv(Variable2, BadValue1, FALSE)
   > ostest_main: setenv(Variable2, GoodValue2, TRUE)
   > ostest_main: setenv(Variable3, GoodValue3, FALSE)
   > ostest_main: setenv(Variable3, BadValue2, FALSE)
   > show_variable: Variable=Variable1 has value=GoodValue1
   > show_variable: Variable=Variable2 has value=GoodValue2
   > show_variable: Variable=Variable3 has value=GoodValue3
   > ostest_main: Started user_main at PID=2
   > ...
   > Test waitpid()
   > waitpid_start_child: Started waitpid_main at PID=7
   > waitpid_start_child: Started waitpid_main at PID=11
   > waitpid_start_child: Started waitpid_main at PID=12
   > waitpid_test: Waiting for PID=7 with waitpid()
   > waitpid_main: PID 7 Started
   > waitpid_main: PID 11 Started
   > waitpid_main: PID 12 Started
   > waitpid_main: PID 7 exitting with result=14
   > waitpid_main: PID 11 exitting with result=14
   > waitpid_main: PID 12 exitting with result=14
   > waitpid_test: ERROR: PID 7 return status is 0, expected 14
   > ```
   
   Thank you for bringing this up, I will investigate


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] adamfeuer commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


adamfeuer commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424845307

   @jrosberg I moved the include on line 383 into the include block at the top 
of the file, did a `make clean`, and recompiled. Everything passed. So perhaps 
something changed since that include was put in the odd place? 
   
   Moving it into the include block and removing the comment is my proposal for 
how to resolve this.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] adamfeuer commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


adamfeuer commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424749203

   @jrosberg Will you say more about what feels wrong about it? That the 
include block is not at the beginning of the file?
   
   If possible I'd like to make checkpatch pass to make this file better even 
though the sama5d3 and sama5d4 have the same problem. But if you can't find a 
good way to do that, let me know and I will merge it.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #8486: sched/nxtask_sigchild: Set process exit code to group exit code

2023-02-09 Thread via GitHub


masayuki2009 commented on PR #8486:
URL: https://github.com/apache/nuttx/pull/8486#issuecomment-1424701343

   @pussuw 
   I noticed that qemu-intel64:ostest failed withi this PR.
   
   ```
   + /home/ishikawa/opensource/QEMU/qemu-7.1/build/qemu-system-x86_64 -cpu host 
-enable-kvm -m 256M -cdrom boot.iso -nographic -serial mon:stdio
   SeaBIOS (version rel-1.16.0-0-gd239552ce722-prebuilt.qemu.org)
   
   
   iPXE (http://ipxe.org) 00:03.0 CA00 PCI2.10 PnP PMM+0FF91160+0FEF1160 CA00
   
   
   
   Booting from Hard Disk...
   Boot failed: could not read the boot disk
   
   Booting from Floppy...
   Boot failed: could not read the boot disk
   
   Booting from DVD/CD...
   stdio_test: write fd=1
   stdio_test: Standard I/O Check: printf
   stdio_test: write fd=2
   ostest_main: putenv(Variable1=BadValue3)
   ostest_main: setenv(Variable1, GoodValue1, TRUE)
   ostest_main: setenv(Variable2, BadValue1, FALSE)
   ostest_main: setenv(Variable2, GoodValue2, TRUE)
   ostest_main: setenv(Variable3, GoodValue3, FALSE)
   ostest_main: setenv(Variable3, BadValue2, FALSE)
   show_variable: Variable=Variable1 has value=GoodValue1
   show_variable: Variable=Variable2 has value=GoodValue2
   show_variable: Variable=Variable3 has value=GoodValue3
   ostest_main: Started user_main at PID=2
   ...
   Test waitpid()
   waitpid_start_child: Started waitpid_main at PID=7
   waitpid_start_child: Started waitpid_main at PID=11
   waitpid_start_child: Started waitpid_main at PID=12
   waitpid_test: Waiting for PID=7 with waitpid()
   waitpid_main: PID 7 Started
   waitpid_main: PID 11 Started
   waitpid_main: PID 12 Started
   waitpid_main: PID 7 exitting with result=14
   waitpid_main: PID 11 exitting with result=14
   waitpid_main: PID 12 exitting with result=14
   waitpid_test: ERROR: PID 7 return status is 0, expected 14
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated: samv7: fix compilation error when only DAC1 is configured

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
 new 725dfd5db9 samv7: fix compilation error when only DAC1 is configured
725dfd5db9 is described below

commit 725dfd5db94dada5cc38405764955c81bccc77f1
Author: Michal Lenc 
AuthorDate: Thu Feb 9 14:51:14 2023 +0100

samv7: fix compilation error when only DAC1 is configured

The function call dac_txdone(_dac1dev) was not contained in ifdef
section. This was cousing compilation error if only DAC1 was configured
as the structure g_dac1dev is defined only if DAC0 is used.

This commit fixes the error and ensures the function is called only if
corresponding DAC is configured.

Signed-off-by: Michal Lenc 
---
 arch/arm/src/samv7/sam_dac.c | 15 +--
 1 file changed, 9 insertions(+), 6 deletions(-)

diff --git a/arch/arm/src/samv7/sam_dac.c b/arch/arm/src/samv7/sam_dac.c
index f67d57a6bb..1601e27c22 100644
--- a/arch/arm/src/samv7/sam_dac.c
+++ b/arch/arm/src/samv7/sam_dac.c
@@ -189,20 +189,23 @@ static struct sam_dac_s g_dacmodule;
 
 static int dac_interrupt(int irq, void *context, void *arg)
 {
-#ifdef CONFIG_SAMV7_DAC1
   uint32_t status;
 
   status = getreg32(SAM_DACC_ISR) & getreg32(SAM_DACC_IMR);
-  if (status & DACC_INT_TXRDY1)
-{
-  dac_txdone(_dac2dev);
-}
 
+#ifdef CONFIG_SAMV7_DAC0
   if (status & DACC_INT_TXRDY0)
-#endif
 {
   dac_txdone(_dac1dev);
 }
+#endif
+
+#ifdef CONFIG_SAMV7_DAC1
+  if (status & DACC_INT_TXRDY1)
+{
+  dac_txdone(_dac2dev);
+}
+#endif
 
   return OK;
 }



[GitHub] [nuttx] xiaoxiang781216 merged pull request #8488: samv7: fix compilation error when only DAC1 is configured

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8488:
URL: https://github.com/apache/nuttx/pull/8488


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 merged pull request #8490: Fixes to PR that enables SAMA5 OTG/DRP support

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8490:
URL: https://github.com/apache/nuttx/pull/8490


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated (b3365858ee -> becaf3bf9d)

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from b3365858ee Fix sam_udphs to allow RNDIS to work
 add becaf3bf9d Correct SAMA5_USBA_DRP to be SAMA5_USB_DRP

No new revisions were added by this update.

Summary of changes:
 arch/arm/src/sama5/sam_ehci.c | 2 +-
 arch/arm/src/sama5/sam_ohci.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)



[GitHub] [nuttx] xiaoxiang781216 commented on pull request #8490: Fixes to PR that enables SAMA5 OTG/DRP support

2023-02-09 Thread via GitHub


xiaoxiang781216 commented on PR #8490:
URL: https://github.com/apache/nuttx/pull/8490#issuecomment-1424516078

   Let's ignore the false CI failure.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated: Fix sam_udphs to allow RNDIS to work

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/master by this push:
 new b3365858ee Fix sam_udphs to allow RNDIS to work
b3365858ee is described below

commit b3365858ee946aac624287f97362b4ca48e5758d
Author: TimJTi <56726697+tim...@users.noreply.github.com>
AuthorDate: Wed Feb 8 16:17:36 2023 +

Fix sam_udphs to allow RNDIS to work

Update sam_udphs.c
---
 arch/arm/src/sama5/sam_udphs.c | 33 +++--
 1 file changed, 19 insertions(+), 14 deletions(-)

diff --git a/arch/arm/src/sama5/sam_udphs.c b/arch/arm/src/sama5/sam_udphs.c
index 85f5ddaf2b..c1f9e0e4c8 100644
--- a/arch/arm/src/sama5/sam_udphs.c
+++ b/arch/arm/src/sama5/sam_udphs.c
@@ -371,9 +371,13 @@ struct sam_usbdev_s
* of valid dat in the buffer is given by ctrlreg.len[].  For the
* case of EP0 SETUP IN transaction, the normal request mechanism is
* used and the class driver provides the buffering.
+   *
+   * A buffer 4* the EP0_MAXPACKETSIZE is used to allow for data that
+   * is sent in consecutive packets although for the same transaction.
*/
 
-  uint8_t  ep0out[SAM_EP0_MAXPACKET];
+  uint8_t  ep0out[4 * SAM_EP0_MAXPACKET];
+  uint16_t ep0datlen;
 };
 
 /
@@ -2637,10 +2641,6 @@ static void sam_ep_interrupt(struct sam_usbdev_s *priv, 
int epno)
 {
   uint16_t len;
 
-  /* Yes.. back to the IDLE state */
-
-  privep->epstate = UDPHS_EPSTATE_IDLE;
-
   /* Get the size of the packet that we just received */
 
   pktsize = (uint16_t)
@@ -2650,27 +2650,32 @@ static void sam_ep_interrupt(struct sam_usbdev_s *priv, 
int epno)
   /* Get the size that we expected to receive */
 
   len = GETUINT16(priv->ctrl.len);
-  if (len == pktsize)
+
+  /* Copy the OUT data from the EP0 FIFO into the EP0 buffer. */
+
+  sam_ep0_read(priv->ep0out + priv->ep0datlen, pktsize);
+
+  priv->ep0datlen += pktsize;
+
+  if (priv->ep0datlen == len)
 {
-  /* Copy the OUT data from the EP0 FIFO into a special EP0
-   * buffer and clear RXRDYTXKL in order to receive more data.
+  /* Back to the IDLE state and clear RXRDYTXKL
+   * in order to receive more data.
*/
 
-  sam_ep0_read(priv->ep0out, len);
+  privep->epstate = UDPHS_EPSTATE_IDLE;
+
   sam_putreg(UDPHS_EPTSTA_RXRDYTXKL, SAM_UDPHS_EPTCLRSTA(epno));
 
   /* And handle the EP0 SETUP now. */
 
   sam_ep0_setup(priv);
+  priv->ep0datlen = 0;
 }
   else
 {
-  usbtrace(TRACE_DEVERROR(SAM_TRACEERR_EP0SETUPOUTSIZE),
-   pktsize);
-
-  /* STALL and discard received data. */
+  /* Clear RXRDYTXKL in order to receive more data. */
 
-  sam_ep_stall(>ep, false);
   sam_putreg(UDPHS_EPTSTA_RXRDYTXKL, SAM_UDPHS_EPTCLRSTA(epno));
 }
 }



[GitHub] [nuttx] xiaoxiang781216 merged pull request #8479: Fix sam_udphs to allow RNDIS to work

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8479:
URL: https://github.com/apache/nuttx/pull/8479


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 closed issue #8325: RNDIS/CDC-ECM/CDC-NCM

2023-02-09 Thread via GitHub


xiaoxiang781216 closed issue #8325: RNDIS/CDC-ECM/CDC-NCM
URL: https://github.com/apache/nuttx/issues/8325


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] xiaoxiang781216 commented on a diff in pull request #1557: Wolfssl code back

2023-02-09 Thread via GitHub


xiaoxiang781216 commented on code in PR #1557:
URL: https://github.com/apache/nuttx-apps/pull/1557#discussion_r1101746138


##
crypto/wolfssl/Makefile:
##
@@ -0,0 +1,152 @@
+include $(APPDIR)/Make.defs
+
+# wolfSSL SSL/TLS crypto library
+
+# Set up build configuration and environment
+https://github.com/wolfSSL/wolfssl/archive/refs/tags/v5.5.4-stable.zip
+WOLFSSL_URL ?= "https://github.com/wolfSSL/wolfssl/archive/refs/tags;
+
+WOLFSSL_VERSION = $(patsubst "%",%,$(strip $(CONFIG_WOLFSSL_VERSION)))
+WOLFSSL_ZIP = v$(WOLFSSL_VERSION)-stable.zip
+
+WOLFSSL_UNPACKNAME = wolfssl
+WOLFSSL_EXAMPLESNAME = wolfssl-examples
+UNPACK ?= unzip -q -o
+
+# WOLFSSL TLS FILES
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/crl.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/internal.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/keys.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/ocsp.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/sniffer.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/ssl.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/tls.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/tls13.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/src/wolfio.c
+
+# wolfCrypt Core (FIPS validated crypto available contact f...@wolfssl.com)
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/aes.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/cmac.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/des3.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/dh.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/ecc.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/hmac.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/random.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/rsa.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sha.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sha256.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sha512.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sha3.c
+
+# wolfCrypt Additional
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/asm.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/asn.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/blake2s.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/chacha.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/chacha20_poly1305.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/coding.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/compress.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/cpuid.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/cryptocb.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/curve25519.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/curve448.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/ecc_fp.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/eccsi.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/ed25519.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/ed448.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/error.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/fe_448.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/fe_low_mem.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/fe_operations.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/ge_448.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/ge_low_mem.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/ge_operations.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/hash.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/kdf.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/integer.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/logging.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/md5.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/memory.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/pkcs12.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/pkcs7.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/poly1305.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/pwdbased.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/rc2.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sakke.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/signature.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/srp.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_arm32.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_arm64.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_armthumb.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_c32.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_c64.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_cortexm.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_dsp32.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_int.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/sp_x86_64.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/tfm.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/wc_dsp.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/wc_encrypt.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/wc_pkcs11.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/wc_port.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/wolfevent.c
+CSRCS += $(WOLFSSL_UNPACKNAME)/wolfcrypt/src/wolfmath.c
+
+
+CFLAGS += -DWOLFSSL_USER_SETTINGS
+
+
+ifneq ($(CONFIG_WOLFCRYPT_APPS),)
+
+MODULE = $(CONFIG_WOLFSSL_APPS)
+
+ifeq ($(CONFIG_WOLFCRYPT_APP_BENCHMARK),y)
+
+PROGNAME  += $(CONFIG_WOLFCRYPT_APP_BENCHMARK_PROGNAME)
+PRIORITY  += 

[GitHub] [nuttx] jrosberg commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


jrosberg commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424485928

   That actually "fixes" the checkpatch, but feels so wrong 
   I can't make a call what is the proper solution for this. Maybe ignore.
   d3x and d4x have the same issue


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 merged pull request #8486: sched/nxtask_sigchild: Set process exit code to group exit code

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8486:
URL: https://github.com/apache/nuttx/pull/8486


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated (1949991fe0 -> 9638187192)

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 1949991fe0 drivers/video: add sequence number to video frames
 add 9638187192 sched/nxtask_sigchild: Set process exit code to group exit 
code

No new revisions were added by this update.

Summary of changes:
 include/nuttx/sched.h  | 3 +++
 sched/task/task_exithook.c | 4 ++--
 2 files changed, 5 insertions(+), 2 deletions(-)



[GitHub] [nuttx] adamfeuer commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


adamfeuer commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424481514

   @jrosberg Looks like everything compiles if that change is made. Would you 
be willing to move the include block down to line 383?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] jpbland1 opened a new pull request, #1557: Wolfssl code back

2023-02-09 Thread via GitHub


jpbland1 opened a new pull request, #1557:
URL: https://github.com/apache/nuttx-apps/pull/1557

   ## Summary
   Add wolfSSL build files, allows wolfSSL to be cloned in and used quickly
   
   ## Impact
   Allows wolfSSL to be built into NuttX
   
   ## Testing
   Tested using wolfSSL tests in the NuttX simulator and on the STM32F746ZG, 
STM32H753 and STM32L552ZE


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] adamfeuer commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


adamfeuer commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424456132

   @jrosberg It looks like if we put the whole `Included files` block down at 
line 383, and put the `#include ` line in that 
block, it passes checkpatch. 
   
   What do you think about doing that?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] adamfeuer commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


adamfeuer commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424451364

   @jrosberg It doesn't come from your change- is there a way to fix this 
easily?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] adamfeuer commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


adamfeuer commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424446111

   @jrosberg ­Thanks- I was looking at the diff. That `#include` line and the 
comment didn't come from your change, is that right?
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] jrosberg commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


jrosberg commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424439648

   @adamfeuer @xiaoxiang781216 
   the #include line is unmodified from previous version...
   
   there is a comment above the include:
   
   ```
* board_memorymap.h contains special mappings that are needed when a ROM
* memory map is used.  It is included in this odd location because it
* depends on some the virtual address definitions provided above.
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] adamfeuer commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


adamfeuer commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424415191

   @jrosberg On your branch I get the following when I run `checkpatch.sh`:
   
   ```
   $ git diff HEAD~1 HEAD | ./tools/checkpatch.sh -
   nuttx/arch/arm/src/sama5/hardware/_sama5d2x_memorymap.h:383:1: warning: 
#include outside of 'Included Files' section
   ```
   
   Otherwise it looks good to me.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] 02/02: drivers/video: add sequence number to video frames

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 1949991fe0b4672a2107ba767a943b0fec373c23
Author: Peter Bee 
AuthorDate: Tue Feb 7 12:32:49 2023 +0800

drivers/video: add sequence number to video frames

Signed-off-by: Peter Bee 
---
 drivers/video/video.c | 4 
 1 file changed, 4 insertions(+)

diff --git a/drivers/video/video.c b/drivers/video/video.c
index ec66781efa..c2e587b496 100644
--- a/drivers/video/video.c
+++ b/drivers/video/video.c
@@ -119,6 +119,7 @@ struct video_type_inf_s
   struct v4l2_fractframe_interval;
   video_framebuff_tbufinf;
   FAR uint8_t  *bufheap;   /* for V4L2_MEMORY_MMAP buffers */
+  uint32_t seqnum;
 };
 
 typedef struct video_type_inf_s video_type_inf_t;
@@ -701,6 +702,7 @@ static void change_video_state(FAR video_mng_t*vmng,
   video_framebuff_get_vacant_container(>video_inf.bufinf);
   if (container != NULL)
 {
+  vmng->video_inf.seqnum = 0;
   start_capture(V4L2_BUF_TYPE_VIDEO_CAPTURE,
 vmng->video_inf.nr_fmt,
 vmng->video_inf.fmt,
@@ -1280,6 +1282,7 @@ static int video_qbuf(FAR struct video_mng_s *vmng,
 video_framebuff_get_vacant_container(_inf->bufinf);
   if (container != NULL)
 {
+  type_inf->seqnum = 0;
   start_capture(buf->type,
 type_inf->nr_fmt,
 type_inf->fmt,
@@ -3310,6 +3313,7 @@ static int video_complete_capture(uint8_t err_code, 
uint32_t datasize,
   IMGDATA_SET_BUF(g_video_data,
 (FAR uint8_t *)container->buf.m.userptr,
 container->buf.length);
+  container->buf.sequence = type_inf->seqnum++;
 }
 }
 



[nuttx] branch master updated (74ce3b81d3 -> 1949991fe0)

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 74ce3b81d3 build/Kconfig: add BINDIR/APPSBINDIR to support out of tree 
build
 new 2ebccd82b6 drivers/video: add timestamp support
 new 1949991fe0 drivers/video: add sequence number to video frames

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 arch/arm/src/cxd56xx/cxd56_cisif.c | 10 +-
 arch/sim/src/sim/sim_video.c   |  7 ++-
 drivers/video/video.c  | 15 +--
 include/nuttx/video/imgdata.h  |  4 +++-
 4 files changed, 27 insertions(+), 9 deletions(-)



[nuttx] 01/02: drivers/video: add timestamp support

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 2ebccd82b62857adfc0b34df358edb212bcdf43e
Author: Peter Bee 
AuthorDate: Mon Feb 6 17:08:31 2023 +0800

drivers/video: add timestamp support

Add support for timestamp and change in related drivers

Signed-off-by: Peter Bee 
---
 arch/arm/src/cxd56xx/cxd56_cisif.c | 10 +-
 arch/sim/src/sim/sim_video.c   |  7 ++-
 drivers/video/video.c  | 11 +--
 include/nuttx/video/imgdata.h  |  4 +++-
 4 files changed, 23 insertions(+), 9 deletions(-)

diff --git a/arch/arm/src/cxd56xx/cxd56_cisif.c 
b/arch/arm/src/cxd56xx/cxd56_cisif.c
index 0086457900..c1d0da5e78 100644
--- a/arch/arm/src/cxd56xx/cxd56_cisif.c
+++ b/arch/arm/src/cxd56xx/cxd56_cisif.c
@@ -373,7 +373,7 @@ static void cisif_callback_for_intlev(uint8_t code)
 
   /* Notify and get next addr */
 
-  g_cxd56_cisif_complete_capture(0, size);
+  g_cxd56_cisif_complete_capture(0, size, NULL);
 
   g_jpgint_receive = false;
 
@@ -413,7 +413,7 @@ static void cisif_ycc_axi_trdn_int(uint8_t code)
   else
 {
   size = cisif_reg_read(CISIF_YCC_DSTRG_CONT);
-  g_cxd56_cisif_complete_capture(0, size);
+  g_cxd56_cisif_complete_capture(0, size, NULL);
   cisif_reg_write(CISIF_YCC_DREAD_CONT, 0);
 }
 }
@@ -463,7 +463,7 @@ static void cisif_jpg_axi_trdn_int(uint8_t code)
   else
 {
   size = cisif_reg_read(CISIF_JPG_DSTRG_CONT);
-  g_cxd56_cisif_complete_capture(0, size);
+  g_cxd56_cisif_complete_capture(0, size, NULL);
   cisif_reg_write(CISIF_JPG_DREAD_CONT, 0);
 }
 }
@@ -495,7 +495,7 @@ static void cisif_ycc_err_int(uint8_t code)
 #endif
 
   size = cisif_reg_read(CISIF_YCC_DSTRG_CONT);
-  g_cxd56_cisif_complete_capture(code, size);
+  g_cxd56_cisif_complete_capture(code, size, NULL);
   cisif_reg_write(CISIF_YCC_DREAD_CONT, 0);
   g_errint_receive = true;
 }
@@ -513,7 +513,7 @@ static void cisif_jpg_err_int(uint8_t code)
 #endif
 
   size = cisif_reg_read(CISIF_JPG_DSTRG_CONT);
-  g_cxd56_cisif_complete_capture(code, size);
+  g_cxd56_cisif_complete_capture(code, size, NULL);
   cisif_reg_write(CISIF_JPG_DREAD_CONT, 0);
   g_errint_receive = true;
 }
diff --git a/arch/sim/src/sim/sim_video.c b/arch/sim/src/sim/sim_video.c
index cddb547723..38dfea1eaf 100644
--- a/arch/sim/src/sim/sim_video.c
+++ b/arch/sim/src/sim/sim_video.c
@@ -46,6 +46,7 @@ typedef struct
   imgdata_capture_t capture_cb;
   uint32_t buf_size;
   uint8_t  *next_buf;
+  struct timeval *next_ts;
   struct host_video_dev_s *vdev;
 } sim_video_priv_t;
 
@@ -336,6 +337,8 @@ int sim_video_uninitialize(void)
 void sim_video_loop(void)
 {
   sim_video_priv_t *priv = _sim_video_priv;
+  struct timespec ts;
+  struct timeval tv;
   int ret;
 
   if (priv->next_buf)
@@ -343,7 +346,9 @@ void sim_video_loop(void)
   ret = host_video_dqbuf(priv->vdev, priv->next_buf, priv->buf_size);
   if (ret > 0)
 {
-  priv->capture_cb(0, ret);
+  clock_gettime(CLOCK_MONOTONIC, );
+  TIMESPEC_TO_TIMEVAL(, );
+  priv->capture_cb(0, ret, );
 }
 }
 }
diff --git a/drivers/video/video.c b/drivers/video/video.c
index 923099d681..ec66781efa 100644
--- a/drivers/video/video.c
+++ b/drivers/video/video.c
@@ -216,7 +216,8 @@ static bool is_sem_waited(FAR sem_t *sem);
 static int save_scene_param(enum v4l2_scene_mode mode,
 uint32_t id,
 struct v4l2_ext_control *control);
-static int video_complete_capture(uint8_t err_code, uint32_t datasize);
+static int video_complete_capture(uint8_t err_code, uint32_t datasize,
+  FAR const struct timeval *ts);
 static int validate_frame_setting(enum v4l2_buf_type type,
   uint8_t nr_fmt,
   FAR video_format_t *vfmt,
@@ -3226,7 +3227,8 @@ static int video_unregister(FAR video_mng_t *priv)
 
 /* Callback function which device driver call when capture has done. */
 
-static int video_complete_capture(uint8_t err_code, uint32_t datasize)
+static int video_complete_capture(uint8_t err_code, uint32_t datasize,
+  FAR const struct timeval *ts)
 {
   FAR video_mng_t  *vmng = (FAR video_mng_t *)g_video_handler;
   FAR video_type_inf_t *type_inf;
@@ -3260,6 +3262,11 @@ static int video_complete_capture(uint8_t err_code, 
uint32_t datasize)
 }
 
   type_inf->bufinf.vbuf_curr->buf.bytesused = datasize;
+  if (ts != NULL)
+{
+  type_inf->bufinf.vbuf_curr->buf.timestamp = *ts;
+}
+
   video_framebuff_capture_done(_inf->bufinf);
 
   if (is_sem_waited(_inf->wait_capture.dqbuf_wait_flg))
diff --git a/include/nuttx/video/imgdata.h b/include/nuttx/video/imgdata.h
index 387c9f7ef7..c36290e6e9 100644
--- a/include/nuttx/video/imgdata.h
+++ b/include/nuttx/video/imgdata.h
@@ 

[GitHub] [nuttx] xiaoxiang781216 merged pull request #8447: Add v4l2_buffer timestamp and sequence

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8447:
URL: https://github.com/apache/nuttx/pull/8447


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] hartmannathan opened a new pull request, #1556: Kconfig: Make indent consistent with TABS

2023-02-09 Thread via GitHub


hartmannathan opened a new pull request, #1556:
URL: https://github.com/apache/nuttx-apps/pull/1556

   ## Summary
   
   Throughout Kconfig, we indent with TABS. However, some Kconfig files had 
areas indented with spaces. Making these consistent with the rest.
   
   ## Impact
   
   Consistent style.
   
   ## Testing
   
   N/A


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi opened a new pull request, #8490: Fixes to PR that enables SAMA5 OTG/DRP support

2023-02-09 Thread via GitHub


TimJTi opened a new pull request, #8490:
URL: https://github.com/apache/nuttx/pull/8490

   ## Summary
   Fixes errors in PR #8480
   
   ## Impact
   Make it work as intended
   
   ## Testing
   Custom board with SAMA5D27C-D1G
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] GUIDINGLI commented on pull request #8469: sim: realize sim timer tickless

2023-02-09 Thread via GitHub


GUIDINGLI commented on PR #8469:
URL: https://github.com/apache/nuttx/pull/8469#issuecomment-1424258852

   @masayuki2009 
   Thanks for the reporting, here is the fix PR:
   https://github.com/apache/nuttx/pull/8489


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] GUIDINGLI opened a new pull request, #8489: sim: remove the critical_section in IRQ handler

2023-02-09 Thread via GitHub


GUIDINGLI opened a new pull request, #8489:
URL: https://github.com/apache/nuttx/pull/8489

   ## Summary
   
   sim: remove the critical_section in IRQ handler
   To fix hang on configure sim:smp when (CONFIG_SMP_NCPUS=1)
   
   ## Impact
   
   SIM
   
   ## Testing
   
   sim:smp both CONFIG_SMP_NCPUS = 1 & CONFIG_SMP_NCPUS = 4


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] michallenc opened a new pull request, #8488: samv7: fix compilation error when only DAC1 is configured

2023-02-09 Thread via GitHub


michallenc opened a new pull request, #8488:
URL: https://github.com/apache/nuttx/pull/8488

   ## Summary
   The function call dac_txdone(_dac1dev) was not contained in ifdef section. 
This was cousing compilation error if only DAC1 was configured as the structure 
g_dac1dev is defined only if DAC0 is used.
   
   This commit fixes the error and ensures the function is called only if 
corresponding DAC is configured.
   
   ## Impact
   
   SAMV7 MCUs only.
   
   ## Testing
   
   Compilation test. Device driver run on a SAMV7 based board.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] zhhyu7 opened a new pull request, #8487: net: modify find device logic

2023-02-09 Thread via GitHub


zhhyu7 opened a new pull request, #8487:
URL: https://github.com/apache/nuttx/pull/8487

   The priorities for finding a network adapter are as follows:
   1. if laddr is not ANY, use laddr to find device;
   2. if laddr is ANY, and bound index is not 0, use bound index to find device;
   3. if laddr is ANY and no device is bound, use raddr to find device.
   
   Signed-off-by: zhanghongyu 
   
   ## Summary
   
   ## Impact
   
   ## Testing
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi commented on a diff in pull request #8482: FUSB302

2023-02-09 Thread via GitHub


TimJTi commented on code in PR #8482:
URL: https://github.com/apache/nuttx/pull/8482#discussion_r1101453017


##
drivers/usbmisc/fusb302.c:
##
@@ -0,0 +1,1941 @@
+/
+ * drivers/usbmisc/fusb302.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+/
+ * Pre-processor Definitions
+ /
+
+#ifndef FUSB302_I2C_FREQUENCY
+#  define FUSB302_I2C_FREQUENCY 80
+#endif
+
+#ifdef CONFIG_DEBUG_USB_ERROR
+#  define fusb302_err(x, ...)_err(x, ##__VA_ARGS__)
+#else
+#  define fusb302_err(x, ...)uerr(x, ##__VA_ARGS__)
+#endif
+
+#if defined(CONFIG_DEBUG_USB_INFO) || defined (CONFIG_DEBUG_FUSB302_REG)
+#  define fusb302_info(x, ...)   _info(x, ##__VA_ARGS__)
+#else
+#  define fusb302_info(x, ...)   uinfo(x, ##__VA_ARGS__)
+#endif
+
+#define FUSB302_I2C_RETRIES  10
+
+/* Switches0 - 0x02 */
+#define SWITCHES0_PULLDOWN_CC1(1 << 0)
+#define SWITCHES0_PULLDOWN_CC2(1 << 1)
+#define SWITCHES0_PULLDOWN_SHIFT  (0)
+#define SWITCHES0_PULLDOWN_MASK   (3 << SWITCHES0_PULLDOWN_SHIFT)
+#define SWITCHES0_MEASURE_CC1 (1 << 2)
+#define SWITCHES0_MEASURE_CC2 (1 << 3)
+#define SWITCHES0_MEASURE_SHIFT   (3)
+#define SWITCHES0_MEASURE_MASK(3 << SWITCHES0_MEASURE_SHIFT)
+#define SWITCHES0_VCONN_CC1   (1 << 4)
+#define SWITCHES0_VCONN_CC2   (1 << 5)
+#define SWITCHES0_VCONN_SHIFT (4)
+#define SWITCHES0_VCONN_MASK  (3 << SWITCHES0_VCONN_SHIFT)
+#define SWITCHES0_PULLUP_CC1  (1 << 6)   
+#define SWITCHES0_PULLUP_CC2  (1 << 7)
+#define SWITCHES0_PULLUP_SHIFT(6)
+#define SWITCHES0_PULLUP_MASK (3 << SWITCHES0_PULLUP_SHIFT)
+
+/* Switches1 */
+#define SWITCHES1_TXCC1_MASK  (1 << 0)
+#define SWITCHES1_TXCC2_MASK  (1 << 1)
+#define SWITCHES1_AUTO_CRC_MASK   (1 << 2)
+#define SWITCHES1_DATAROLE_MASK   (1 << 3)
+#define SWITCHES1_SPECREV_SHIFT   (1 << 5) /* Bits 6:5 Specrole */
+#define SWITCHES1_SPECREV_MASK(0x03 << 6)
+#define SWITCHES1_SPECREV(n)  ((uint8_t)(n) << SWITCHES1_SPECREV_SHIFT)
+#define SWITCHES1_POWERROLE_MASK  (1 << 6)
+
+/* Measure - 0x04 */
+#define MEASURE_MDAC_SHIFT(0)/* Bits 5:0 MDAC */
+#define MEASURE_MDAC_MASK (0b11 << MEASURE_MDAC_SHIFT)
+#define MEASURE_MDAC(n)   ((uint8_t)(n)) << MEASURE_MDAC_SHIFT
+#define MEASURE_VBUS_BY_MDAC  (1 << 6) 
+#define SET_MDAC(n)   ((uint8_t)(n)) << MEASURE_MDAC_SHIFT)
+
+/* Slice - 0x05 */
+#define MEASURE_SDAC_SHIFT(0)  /* Bits 5:0 SDAC */
+#define MEASURE_SDAC_MASK (0b11 < MEASURE_SDAC_SHIFT)
+#define MEASURE_SDAC(n)   ((uint8_t)(n)) << MEASURE_SDAC_SHIFT)
+#define MEASURE_SDAC_HYS_SHIFT(6) /* Bits 7:6 SDAC hysteris */ 
   
+#define MEASURE_SDAC_HYS_MASK (0b11 << MEASURE_SDAC_HYS_SHIFT)
+#define SDAC_HYS_VAL(n)   ((uint8)t)(n)) << MEASURE_SDAC_HYS_SHIFT)
+
+/* Control0 - 0x06 */
+#define CONTROL0_TX_START_MASK(1 << 0)
+#define CONTROL0_AUTO_PRE_SHIFT   (1) 
+#define CONTROL0_HOST_CUR_SHIFT   (2) /* Bits 3:2 Host Current mode */
+#define CONTROL0_HOST_CUR_MASK(3 << CONTROL0_HOST_CUR_SHIFT)
+#define HOST_CURRENT_NONE (0) /* no current */
+#define HOST_CURRENT_80UA (1) /* default USB power */
+#define HOST_CURRENT_180UA(2) /* medium power, 1.5A */
+#define HOST_CURRENT_330UA(3) /* high power, 3A */
+#define HOST_CURRENT(n)   ((uint8_t)(n) 

[GitHub] [nuttx] TimJTi commented on a diff in pull request #8482: FUSB302

2023-02-09 Thread via GitHub


TimJTi commented on code in PR #8482:
URL: https://github.com/apache/nuttx/pull/8482#discussion_r1101452683


##
drivers/usbmisc/fusb302.c:
##
@@ -0,0 +1,1941 @@
+/
+ * drivers/usbmisc/fusb302.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+/
+ * Pre-processor Definitions
+ /
+
+#ifndef FUSB302_I2C_FREQUENCY
+#  define FUSB302_I2C_FREQUENCY 80

Review Comment:
   @acassis Fast mode plus at 1MHz. I just don't like running things at at 
absolute maximum, but I will make 1MHz  the default.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] PeterBee97 commented on a diff in pull request #8447: Add v4l2_buffer timestamp and sequence

2023-02-09 Thread via GitHub


PeterBee97 commented on code in PR #8447:
URL: https://github.com/apache/nuttx/pull/8447#discussion_r1101428569


##
drivers/video/video.c:
##
@@ -667,6 +669,7 @@ static int start_capture(enum v4l2_buf_type type,
   convert_to_imgsensorfmt([VIDEO_FMT_SUB], [IMGSENSOR_FMT_SUB]);
   convert_to_imgsensorinterval(interval, );
 
+  *seqnum = 0;

Review Comment:
   sure



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] pussuw opened a new pull request, #8486: sched/nxtask_sigchild: Set process exit code to group exit code

2023-02-09 Thread via GitHub


pussuw opened a new pull request, #8486:
URL: https://github.com/apache/nuttx/pull/8486

   ## Summary
   There is an issue where the wrong process exit code is given to the parent 
when a process exits. This happens when the process has pthreads running user 
code i.e. not within a cancel point / system call.
   
   Why does this happen ?
   
   When exit() is called, the following steps are done:
   - group_kill_children(), which tells the children to die via pthread_cancel()
   
   Then, one of two things can happen:
   1. if the child is in a cancel point, it gets scheduled to allow it to leave 
the cancel point and gets destroyed immediately
   2. if the child is not in a cancel point, a "cancel pending" flag is set and 
the child will die when the next cancel point is encountered
   
   So what is the problem here?
   
   The last thread alive dispatches SIGCHLD to the parent, which carries the 
process's exit code. The group head has the only meaningful exit code and this 
is what should be passed. However, in the second case, the group head exits 
before the child, taking the process exit code to its grave. The child that was 
alive will exit next and will pass its "status" to the parent process, but this 
status is not the correct value to pass.
   
   This commit fixes the issue by passing the group head's exit code ALWAYS to 
the parent process.
   ## Impact
   Fixes process exit code, when parent dies before its children die
   ## Testing
   icicle:knsh
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi commented on a diff in pull request #8482: FUSB302

2023-02-09 Thread via GitHub


TimJTi commented on code in PR #8482:
URL: https://github.com/apache/nuttx/pull/8482#discussion_r1101408234


##
drivers/usbmisc/fusb302.c:
##
@@ -0,0 +1,1941 @@
+/
+ * drivers/usbmisc/fusb302.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+/
+ * Pre-processor Definitions
+ /
+
+#ifndef FUSB302_I2C_FREQUENCY
+#  define FUSB302_I2C_FREQUENCY 80
+#endif
+
+#ifdef CONFIG_DEBUG_USB_ERROR
+#  define fusb302_err(x, ...)_err(x, ##__VA_ARGS__)
+#else
+#  define fusb302_err(x, ...)uerr(x, ##__VA_ARGS__)
+#endif
+
+#if defined(CONFIG_DEBUG_USB_INFO) || defined (CONFIG_DEBUG_FUSB302_REG)
+#  define fusb302_info(x, ...)   _info(x, ##__VA_ARGS__)
+#else
+#  define fusb302_info(x, ...)   uinfo(x, ##__VA_ARGS__)
+#endif
+
+#define FUSB302_I2C_RETRIES  10
+
+/* Switches0 - 0x02 */
+#define SWITCHES0_PULLDOWN_CC1(1 << 0)
+#define SWITCHES0_PULLDOWN_CC2(1 << 1)
+#define SWITCHES0_PULLDOWN_SHIFT  (0)
+#define SWITCHES0_PULLDOWN_MASK   (3 << SWITCHES0_PULLDOWN_SHIFT)
+#define SWITCHES0_MEASURE_CC1 (1 << 2)
+#define SWITCHES0_MEASURE_CC2 (1 << 3)
+#define SWITCHES0_MEASURE_SHIFT   (3)
+#define SWITCHES0_MEASURE_MASK(3 << SWITCHES0_MEASURE_SHIFT)
+#define SWITCHES0_VCONN_CC1   (1 << 4)
+#define SWITCHES0_VCONN_CC2   (1 << 5)
+#define SWITCHES0_VCONN_SHIFT (4)
+#define SWITCHES0_VCONN_MASK  (3 << SWITCHES0_VCONN_SHIFT)
+#define SWITCHES0_PULLUP_CC1  (1 << 6)   
+#define SWITCHES0_PULLUP_CC2  (1 << 7)
+#define SWITCHES0_PULLUP_SHIFT(6)
+#define SWITCHES0_PULLUP_MASK (3 << SWITCHES0_PULLUP_SHIFT)
+
+/* Switches1 */
+#define SWITCHES1_TXCC1_MASK  (1 << 0)
+#define SWITCHES1_TXCC2_MASK  (1 << 1)
+#define SWITCHES1_AUTO_CRC_MASK   (1 << 2)
+#define SWITCHES1_DATAROLE_MASK   (1 << 3)
+#define SWITCHES1_SPECREV_SHIFT   (1 << 5) /* Bits 6:5 Specrole */
+#define SWITCHES1_SPECREV_MASK(0x03 << 6)
+#define SWITCHES1_SPECREV(n)  ((uint8_t)(n) << SWITCHES1_SPECREV_SHIFT)
+#define SWITCHES1_POWERROLE_MASK  (1 << 6)
+
+/* Measure - 0x04 */
+#define MEASURE_MDAC_SHIFT(0)/* Bits 5:0 MDAC */
+#define MEASURE_MDAC_MASK (0b11 << MEASURE_MDAC_SHIFT)
+#define MEASURE_MDAC(n)   ((uint8_t)(n)) << MEASURE_MDAC_SHIFT
+#define MEASURE_VBUS_BY_MDAC  (1 << 6) 
+#define SET_MDAC(n)   ((uint8_t)(n)) << MEASURE_MDAC_SHIFT)
+
+/* Slice - 0x05 */
+#define MEASURE_SDAC_SHIFT(0)  /* Bits 5:0 SDAC */
+#define MEASURE_SDAC_MASK (0b11 < MEASURE_SDAC_SHIFT)
+#define MEASURE_SDAC(n)   ((uint8_t)(n)) << MEASURE_SDAC_SHIFT)
+#define MEASURE_SDAC_HYS_SHIFT(6) /* Bits 7:6 SDAC hysteris */ 
   
+#define MEASURE_SDAC_HYS_MASK (0b11 << MEASURE_SDAC_HYS_SHIFT)
+#define SDAC_HYS_VAL(n)   ((uint8)t)(n)) << MEASURE_SDAC_HYS_SHIFT)
+
+/* Control0 - 0x06 */
+#define CONTROL0_TX_START_MASK(1 << 0)
+#define CONTROL0_AUTO_PRE_SHIFT   (1) 
+#define CONTROL0_HOST_CUR_SHIFT   (2) /* Bits 3:2 Host Current mode */
+#define CONTROL0_HOST_CUR_MASK(3 << CONTROL0_HOST_CUR_SHIFT)
+#define HOST_CURRENT_NONE (0) /* no current */
+#define HOST_CURRENT_80UA (1) /* default USB power */
+#define HOST_CURRENT_180UA(2) /* medium power, 1.5A */
+#define HOST_CURRENT_330UA(3) /* high power, 3A */
+#define HOST_CURRENT(n)   ((uint8_t)(n) 

[GitHub] [nuttx] xiaoxiang781216 commented on a diff in pull request #8447: Add v4l2_buffer timestamp and sequence

2023-02-09 Thread via GitHub


xiaoxiang781216 commented on code in PR #8447:
URL: https://github.com/apache/nuttx/pull/8447#discussion_r1101409762


##
drivers/video/video.c:
##
@@ -667,6 +669,7 @@ static int start_capture(enum v4l2_buf_type type,
   convert_to_imgsensorfmt([VIDEO_FMT_SUB], [IMGSENSOR_FMT_SUB]);
   convert_to_imgsensorinterval(interval, );
 
+  *seqnum = 0;

Review Comment:
   look like it's better to zero at caller site, sorry please ignore my 
previous comment.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi commented on a diff in pull request #8482: FUSB302

2023-02-09 Thread via GitHub


TimJTi commented on code in PR #8482:
URL: https://github.com/apache/nuttx/pull/8482#discussion_r1101408234


##
drivers/usbmisc/fusb302.c:
##
@@ -0,0 +1,1941 @@
+/
+ * drivers/usbmisc/fusb302.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+/
+ * Pre-processor Definitions
+ /
+
+#ifndef FUSB302_I2C_FREQUENCY
+#  define FUSB302_I2C_FREQUENCY 80
+#endif
+
+#ifdef CONFIG_DEBUG_USB_ERROR
+#  define fusb302_err(x, ...)_err(x, ##__VA_ARGS__)
+#else
+#  define fusb302_err(x, ...)uerr(x, ##__VA_ARGS__)
+#endif
+
+#if defined(CONFIG_DEBUG_USB_INFO) || defined (CONFIG_DEBUG_FUSB302_REG)
+#  define fusb302_info(x, ...)   _info(x, ##__VA_ARGS__)
+#else
+#  define fusb302_info(x, ...)   uinfo(x, ##__VA_ARGS__)
+#endif
+
+#define FUSB302_I2C_RETRIES  10
+
+/* Switches0 - 0x02 */
+#define SWITCHES0_PULLDOWN_CC1(1 << 0)
+#define SWITCHES0_PULLDOWN_CC2(1 << 1)
+#define SWITCHES0_PULLDOWN_SHIFT  (0)
+#define SWITCHES0_PULLDOWN_MASK   (3 << SWITCHES0_PULLDOWN_SHIFT)
+#define SWITCHES0_MEASURE_CC1 (1 << 2)
+#define SWITCHES0_MEASURE_CC2 (1 << 3)
+#define SWITCHES0_MEASURE_SHIFT   (3)
+#define SWITCHES0_MEASURE_MASK(3 << SWITCHES0_MEASURE_SHIFT)
+#define SWITCHES0_VCONN_CC1   (1 << 4)
+#define SWITCHES0_VCONN_CC2   (1 << 5)
+#define SWITCHES0_VCONN_SHIFT (4)
+#define SWITCHES0_VCONN_MASK  (3 << SWITCHES0_VCONN_SHIFT)
+#define SWITCHES0_PULLUP_CC1  (1 << 6)   
+#define SWITCHES0_PULLUP_CC2  (1 << 7)
+#define SWITCHES0_PULLUP_SHIFT(6)
+#define SWITCHES0_PULLUP_MASK (3 << SWITCHES0_PULLUP_SHIFT)
+
+/* Switches1 */
+#define SWITCHES1_TXCC1_MASK  (1 << 0)
+#define SWITCHES1_TXCC2_MASK  (1 << 1)
+#define SWITCHES1_AUTO_CRC_MASK   (1 << 2)
+#define SWITCHES1_DATAROLE_MASK   (1 << 3)
+#define SWITCHES1_SPECREV_SHIFT   (1 << 5) /* Bits 6:5 Specrole */
+#define SWITCHES1_SPECREV_MASK(0x03 << 6)
+#define SWITCHES1_SPECREV(n)  ((uint8_t)(n) << SWITCHES1_SPECREV_SHIFT)
+#define SWITCHES1_POWERROLE_MASK  (1 << 6)
+
+/* Measure - 0x04 */
+#define MEASURE_MDAC_SHIFT(0)/* Bits 5:0 MDAC */
+#define MEASURE_MDAC_MASK (0b11 << MEASURE_MDAC_SHIFT)
+#define MEASURE_MDAC(n)   ((uint8_t)(n)) << MEASURE_MDAC_SHIFT
+#define MEASURE_VBUS_BY_MDAC  (1 << 6) 
+#define SET_MDAC(n)   ((uint8_t)(n)) << MEASURE_MDAC_SHIFT)
+
+/* Slice - 0x05 */
+#define MEASURE_SDAC_SHIFT(0)  /* Bits 5:0 SDAC */
+#define MEASURE_SDAC_MASK (0b11 < MEASURE_SDAC_SHIFT)
+#define MEASURE_SDAC(n)   ((uint8_t)(n)) << MEASURE_SDAC_SHIFT)
+#define MEASURE_SDAC_HYS_SHIFT(6) /* Bits 7:6 SDAC hysteris */ 
   
+#define MEASURE_SDAC_HYS_MASK (0b11 << MEASURE_SDAC_HYS_SHIFT)
+#define SDAC_HYS_VAL(n)   ((uint8)t)(n)) << MEASURE_SDAC_HYS_SHIFT)
+
+/* Control0 - 0x06 */
+#define CONTROL0_TX_START_MASK(1 << 0)
+#define CONTROL0_AUTO_PRE_SHIFT   (1) 
+#define CONTROL0_HOST_CUR_SHIFT   (2) /* Bits 3:2 Host Current mode */
+#define CONTROL0_HOST_CUR_MASK(3 << CONTROL0_HOST_CUR_SHIFT)
+#define HOST_CURRENT_NONE (0) /* no current */
+#define HOST_CURRENT_80UA (1) /* default USB power */
+#define HOST_CURRENT_180UA(2) /* medium power, 1.5A */
+#define HOST_CURRENT_330UA(3) /* high power, 3A */
+#define HOST_CURRENT(n)   ((uint8_t)(n) 

[GitHub] [nuttx] xiaoxiang781216 commented on pull request #8484: sama5/twi: add support for flexcom twi

2023-02-09 Thread via GitHub


xiaoxiang781216 commented on PR #8484:
URL: https://github.com/apache/nuttx/pull/8484#issuecomment-1424125676

   @jrosberg please style issue


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi commented on a diff in pull request #8482: FUSB302

2023-02-09 Thread via GitHub


TimJTi commented on code in PR #8482:
URL: https://github.com/apache/nuttx/pull/8482#discussion_r1101403805


##
drivers/usbmisc/fusb302.c:
##
@@ -0,0 +1,1941 @@
+/
+ * drivers/usbmisc/fusb302.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+/
+ * Pre-processor Definitions
+ /
+
+#ifndef FUSB302_I2C_FREQUENCY
+#  define FUSB302_I2C_FREQUENCY 80
+#endif
+
+#ifdef CONFIG_DEBUG_USB_ERROR
+#  define fusb302_err(x, ...)_err(x, ##__VA_ARGS__)
+#else
+#  define fusb302_err(x, ...)uerr(x, ##__VA_ARGS__)
+#endif
+
+#if defined(CONFIG_DEBUG_USB_INFO) || defined (CONFIG_DEBUG_FUSB302_REG)
+#  define fusb302_info(x, ...)   _info(x, ##__VA_ARGS__)
+#else
+#  define fusb302_info(x, ...)   uinfo(x, ##__VA_ARGS__)
+#endif
+
+#define FUSB302_I2C_RETRIES  10
+
+/* Switches0 - 0x02 */
+#define SWITCHES0_PULLDOWN_CC1(1 << 0)
+#define SWITCHES0_PULLDOWN_CC2(1 << 1)
+#define SWITCHES0_PULLDOWN_SHIFT  (0)
+#define SWITCHES0_PULLDOWN_MASK   (3 << SWITCHES0_PULLDOWN_SHIFT)
+#define SWITCHES0_MEASURE_CC1 (1 << 2)
+#define SWITCHES0_MEASURE_CC2 (1 << 3)
+#define SWITCHES0_MEASURE_SHIFT   (3)
+#define SWITCHES0_MEASURE_MASK(3 << SWITCHES0_MEASURE_SHIFT)
+#define SWITCHES0_VCONN_CC1   (1 << 4)
+#define SWITCHES0_VCONN_CC2   (1 << 5)
+#define SWITCHES0_VCONN_SHIFT (4)
+#define SWITCHES0_VCONN_MASK  (3 << SWITCHES0_VCONN_SHIFT)
+#define SWITCHES0_PULLUP_CC1  (1 << 6)   
+#define SWITCHES0_PULLUP_CC2  (1 << 7)
+#define SWITCHES0_PULLUP_SHIFT(6)
+#define SWITCHES0_PULLUP_MASK (3 << SWITCHES0_PULLUP_SHIFT)
+
+/* Switches1 */
+#define SWITCHES1_TXCC1_MASK  (1 << 0)
+#define SWITCHES1_TXCC2_MASK  (1 << 1)
+#define SWITCHES1_AUTO_CRC_MASK   (1 << 2)
+#define SWITCHES1_DATAROLE_MASK   (1 << 3)
+#define SWITCHES1_SPECREV_SHIFT   (1 << 5) /* Bits 6:5 Specrole */
+#define SWITCHES1_SPECREV_MASK(0x03 << 6)
+#define SWITCHES1_SPECREV(n)  ((uint8_t)(n) << SWITCHES1_SPECREV_SHIFT)
+#define SWITCHES1_POWERROLE_MASK  (1 << 6)
+
+/* Measure - 0x04 */
+#define MEASURE_MDAC_SHIFT(0)/* Bits 5:0 MDAC */
+#define MEASURE_MDAC_MASK (0b11 << MEASURE_MDAC_SHIFT)
+#define MEASURE_MDAC(n)   ((uint8_t)(n)) << MEASURE_MDAC_SHIFT
+#define MEASURE_VBUS_BY_MDAC  (1 << 6) 
+#define SET_MDAC(n)   ((uint8_t)(n)) << MEASURE_MDAC_SHIFT)
+
+/* Slice - 0x05 */
+#define MEASURE_SDAC_SHIFT(0)  /* Bits 5:0 SDAC */
+#define MEASURE_SDAC_MASK (0b11 < MEASURE_SDAC_SHIFT)
+#define MEASURE_SDAC(n)   ((uint8_t)(n)) << MEASURE_SDAC_SHIFT)
+#define MEASURE_SDAC_HYS_SHIFT(6) /* Bits 7:6 SDAC hysteris */ 
   
+#define MEASURE_SDAC_HYS_MASK (0b11 << MEASURE_SDAC_HYS_SHIFT)
+#define SDAC_HYS_VAL(n)   ((uint8)t)(n)) << MEASURE_SDAC_HYS_SHIFT)
+
+/* Control0 - 0x06 */
+#define CONTROL0_TX_START_MASK(1 << 0)
+#define CONTROL0_AUTO_PRE_SHIFT   (1) 
+#define CONTROL0_HOST_CUR_SHIFT   (2) /* Bits 3:2 Host Current mode */
+#define CONTROL0_HOST_CUR_MASK(3 << CONTROL0_HOST_CUR_SHIFT)
+#define HOST_CURRENT_NONE (0) /* no current */
+#define HOST_CURRENT_80UA (1) /* default USB power */
+#define HOST_CURRENT_180UA(2) /* medium power, 1.5A */
+#define HOST_CURRENT_330UA(3) /* high power, 3A */
+#define HOST_CURRENT(n)   ((uint8_t)(n) 

[GitHub] [nuttx] TimJTi commented on a diff in pull request #8482: FUSB302

2023-02-09 Thread via GitHub


TimJTi commented on code in PR #8482:
URL: https://github.com/apache/nuttx/pull/8482#discussion_r1101399720


##
drivers/usbmisc/fusb302.c:
##
@@ -0,0 +1,1941 @@
+/
+ * drivers/usbmisc/fusb302.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+#include 
+#include 
+
+/
+ * Pre-processor Definitions
+ /
+
+#ifndef FUSB302_I2C_FREQUENCY
+#  define FUSB302_I2C_FREQUENCY 80
+#endif
+
+#ifdef CONFIG_DEBUG_USB_ERROR
+#  define fusb302_err(x, ...)_err(x, ##__VA_ARGS__)
+#else
+#  define fusb302_err(x, ...)uerr(x, ##__VA_ARGS__)
+#endif
+
+#if defined(CONFIG_DEBUG_USB_INFO) || defined (CONFIG_DEBUG_FUSB302_REG)
+#  define fusb302_info(x, ...)   _info(x, ##__VA_ARGS__)
+#else
+#  define fusb302_info(x, ...)   uinfo(x, ##__VA_ARGS__)
+#endif
+
+#define FUSB302_I2C_RETRIES  10
+
+/* Switches0 - 0x02 */

Review Comment:
   @acassis checkpatch.sh didn't pick these up. I'll fix.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi commented on pull request #8480: Changes to allow board-specific SAMA5 DRP/OTG support

2023-02-09 Thread via GitHub


TimJTi commented on PR #8480:
URL: https://github.com/apache/nuttx/pull/8480#issuecomment-1424116578

   > both are fine, depends on you.
   
   I'll do a new PR. Sorry!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] xiaoxiang781216 commented on pull request #8480: Changes to allow board-specific SAMA5 DRP/OTG support

2023-02-09 Thread via GitHub


xiaoxiang781216 commented on PR #8480:
URL: https://github.com/apache/nuttx/pull/8480#issuecomment-1424113963

   both are fine, depends on you.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] TimJTi commented on pull request #8480: Changes to allow board-specific SAMA5 DRP/OTG support

2023-02-09 Thread via GitHub


TimJTi commented on PR #8480:
URL: https://github.com/apache/nuttx/pull/8480#issuecomment-1424107214

   @xiaoxiang781216 - I have committed files with inconsistencies. Only affects 
me of course - I have a mix/match of CONFIG_SAMA5_USBA_DRP and 
CONFIG_SAMA5_USB_DRP in the code (USBA vs USB).
   
   Shall I do a new PR are do you prefer to revert this and I'll try again?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] masayuki2009 commented on pull request #8469: sim: realize sim timer tickless

2023-02-09 Thread via GitHub


masayuki2009 commented on PR #8469:
URL: https://github.com/apache/nuttx/pull/8469#issuecomment-1424099063

   @GUIDINGLI 
   I noticed that sim:smp (CONFIG_SMP_NCPUS=1) does not work withi this PR.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated (2d536059f0 -> 74ce3b81d3)

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 2d536059f0 mm/mempool: fix visual studio Compiler Warning C4098
 add 74ce3b81d3 build/Kconfig: add BINDIR/APPSBINDIR to support out of tree 
build

No new revisions were added by this update.

Summary of changes:
 Kconfig| 18 +-
 arch/Kconfig   |  2 +-
 boards/Kconfig |  2 +-
 boards/arm/cxd56xx/drivers/Kconfig |  4 ++--
 drivers/Kconfig|  2 +-
 tools/Unix.mk  | 19 +++
 tools/Win.mk   | 17 +++--
 7 files changed, 44 insertions(+), 20 deletions(-)



[GitHub] [nuttx] xiaoxiang781216 merged pull request #8449: build/Kconfig: add BINDIR/APPSBINDIR to support out of tree build

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8449:
URL: https://github.com/apache/nuttx/pull/8449


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] 08/08: mm/mempool: fix visual studio Compiler Warning C4098

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 2d536059f0bc60d777c7692fdc615392d22d3d65
Author: chao an 
AuthorDate: Wed Feb 8 17:06:59 2023 +0800

mm/mempool: fix visual studio Compiler Warning C4098

D:\archer\code\nuttx\mm\mempool\mempool_multiple.c(180,72): warning C4098: 
"mempool_multiple_free_callback":"void" void function returning a value

Compiler Warning C4098:
A function declared with return type void has a return statement that 
returns a value. The compiler assumes the function returns a value of type int.

Reference:

https://learn.microsoft.com/en-us/cpp/error-messages/compiler-warnings/compiler-warning-level-1-c4098?view=msvc-170

Signed-off-by: chao an 
---
 mm/mempool/mempool_multiple.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mm/mempool/mempool_multiple.c b/mm/mempool/mempool_multiple.c
index 9e28212917..d5a7f79fac 100644
--- a/mm/mempool/mempool_multiple.c
+++ b/mm/mempool/mempool_multiple.c
@@ -177,7 +177,7 @@ static void mempool_multiple_free_callback(FAR struct 
mempool_s *pool,
 {
   FAR struct mempool_multiple_s *mpool = pool->priv;
 
-  return mpool->free(mpool->arg, (FAR char *)addr - mpool->minpoolsize);
+  mpool->free(mpool->arg, (FAR char *)addr - mpool->minpoolsize);
 }
 
 /



[nuttx] 04/08: fs/smart: fix visual studio Compiler Error C2016

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit ccaa6259308bc5a5829b756d8fb902340710735b
Author: chao an 
AuthorDate: Wed Feb 8 16:26:00 2023 +0800

fs/smart: fix visual studio Compiler Error C2016

D:\archer\code\nuttx\include\nuttx/fs/smart.h(118,1):
  error C2016: C requires that a struct or union has at least one member

Compiler error C2016: C requires that a struct or union has at least one 
member

Reference:

https://docs.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-errors-c2001-through-c2099?view=msvc-170

Signed-off-by: chao.an 
Signed-off-by: chao an 
---
 include/nuttx/fs/smart.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/include/nuttx/fs/smart.h b/include/nuttx/fs/smart.h
index bab05ca680..46aade7d58 100644
--- a/include/nuttx/fs/smart.h
+++ b/include/nuttx/fs/smart.h
@@ -114,6 +114,8 @@ struct smart_procfs_data_s
 #ifdef CONFIG_MTD_SMART_ERASE_DEBUG
   const uint16_t  *erasecounts;   /* Pointer to the erase counts array */
   uint16_terasesize;  /* Number of entries in the erase counts 
array */
+#else
+  uint8_t __pad;
 #endif
 };
 #endif



[nuttx] 05/08: net/netfilter: fix visual studio Compiler Error C2229

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 5580de06851b99b80f43e44d97932476aa49
Author: chao an 
AuthorDate: Wed Feb 8 16:29:48 2023 +0800

net/netfilter: fix visual studio Compiler Error C2229

D:\archer\code\nuttx\include\nuttx/net/netfilter/x_tables.h(71,7):
  error C2229: type 'struct xt_standard_target' has an illegal zero-sized 
array

Compiler error C2229:
A member of a structure or bit field contains a zero-sized array that is 
not the last member.

Reference:

https://learn.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-error-c2229?view=msvc-170

Signed-off-by: chao an 
---
 include/nuttx/net/netfilter/ip_tables.h | 2 +-
 include/nuttx/net/netfilter/x_tables.h  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/nuttx/net/netfilter/ip_tables.h 
b/include/nuttx/net/netfilter/ip_tables.h
index 0ac092fce0..0828e36e68 100644
--- a/include/nuttx/net/netfilter/ip_tables.h
+++ b/include/nuttx/net/netfilter/ip_tables.h
@@ -117,7 +117,7 @@ struct ipt_entry
 
   struct xt_counters counters; /* Packet and byte counters. */
 
-  unsigned char elems[0];  /* The matches (if any), then the target. */
+  unsigned char elems[1];  /* The matches (if any), then the target. */
 };
 
 /* Note 1: How entries are organized in following interface arguments.
diff --git a/include/nuttx/net/netfilter/x_tables.h 
b/include/nuttx/net/netfilter/x_tables.h
index 721dcaa24a..d180c18ea8 100644
--- a/include/nuttx/net/netfilter/x_tables.h
+++ b/include/nuttx/net/netfilter/x_tables.h
@@ -62,7 +62,7 @@ struct xt_entry_target
   uint16_t target_size; /* Total length */
 } u;
 
-  unsigned char data[0];
+  unsigned char data[1];
 };
 
 struct xt_standard_target



[nuttx] 02/08: sys/sysinfo: align sysinfo define with linux

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 86aed8748776c359104678dffa4cd52a97529440
Author: chao an 
AuthorDate: Wed Feb 8 16:15:48 2023 +0800

sys/sysinfo: align sysinfo define with linux

__reserved is a meaningful macro definition in msvc, cannot use this name

Fix visual studio Compiler Error:

https://social.msdn.microsoft.com/Forums/vstudio/en-US/d86ad86b-47b7-4677-95fb-e28b3230a009/reserved-problem?forum=vclanguage

Signed-off-by: chao an 
---
 include/sys/sysinfo.h | 27 +--
 1 file changed, 13 insertions(+), 14 deletions(-)

diff --git a/include/sys/sysinfo.h b/include/sys/sysinfo.h
index 822bfce4cb..352b95c6ff 100644
--- a/include/sys/sysinfo.h
+++ b/include/sys/sysinfo.h
@@ -39,20 +39,19 @@
 
 struct sysinfo
 {
-  unsigned long uptime;
-  unsigned long loads[3];
-  unsigned long totalram;
-  unsigned long freeram;
-  unsigned long sharedram;
-  unsigned long bufferram;
-  unsigned long totalswap;
-  unsigned long freeswap;
-  unsigned short procs;
-  unsigned short pad;
-  unsigned long totalhigh;
-  unsigned long freehigh;
-  unsigned mem_unit;
-  char __reserved[256];
+  unsigned long uptime;/* Seconds since boot */
+  unsigned long loads[3];  /* 1, 5, and 15 minute load averages */
+  unsigned long totalram;  /* Total usable main memory size */
+  unsigned long freeram;   /* Available memory size */
+  unsigned long sharedram; /* Amount of shared memory */
+  unsigned long bufferram; /* Memory used by buffers */
+  unsigned long totalswap; /* Total swap space size */
+  unsigned long freeswap;  /* Swap space still available */
+  unsigned short procs;/* Number of current processes */
+  unsigned short pad;  /* Padding for alignment */
+  unsigned long totalhigh; /* Total high memory size */
+  unsigned long freehigh;  /* Available high memory size */
+  unsigned mem_unit;   /* Memory unit size in bytes */
 };
 
 /



[nuttx] 07/08: fs/epoll: fix visual studio Compiler Error C2059

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 77f68b121bb0f00fd1b3b37d89c0c2d049d964a4
Author: chao an 
AuthorDate: Wed Feb 8 16:56:16 2023 +0800

fs/epoll: fix visual studio Compiler Error C2059

D:\archer\code\nuttx\fs\vfs\fs_epoll.c(456,15): error C2059: syntax error : 
'{'

Compiler error C2059:
The token caused a syntax error.

Reference:

https://learn.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-error-c2059?view=msvc-170

Signed-off-by: chao an 
---
 fs/vfs/fs_epoll.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/vfs/fs_epoll.c b/fs/vfs/fs_epoll.c
index a75c793022..0a74780c4a 100644
--- a/fs/vfs/fs_epoll.c
+++ b/fs/vfs/fs_epoll.c
@@ -453,7 +453,7 @@ int epoll_ctl(int epfd, int op, int fd, FAR struct 
epoll_event *ev)
 eph->size += eph->size;
   }
 
-epn = list_remove_head_type(>free, epoll_node_t, node);
+epn = container_of(list_remove_head(>free), epoll_node_t, node);
 epn->data= ev->data;
 epn->pfd.events  = ev->events;
 epn->pfd.fd  = fd;



[nuttx] 06/08: net/procfs: fix visual studio Compiler Error C2057

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 4a8cd8ca0c0c01d3bb602b378513b528610dd195
Author: chao an 
AuthorDate: Wed Feb 8 16:37:04 2023 +0800

net/procfs: fix visual studio Compiler Error C2057

D:\archer\code\nuttx\net\procfs\net_tcp.c(63,15): error C2057: expected 
constant expression

Compiler error C2057:
The context requires a constant expression, an expression whose value is 
known at compile time.

Reference:

https://learn.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-error-c2057?view=msvc-170

Signed-off-by: chao an 
---
 net/procfs/net_tcp.c | 4 ++--
 net/procfs/net_udp.c | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/net/procfs/net_tcp.c b/net/procfs/net_tcp.c
index c3962d686d..48155f5538 100644
--- a/net/procfs/net_tcp.c
+++ b/net/procfs/net_tcp.c
@@ -60,8 +60,8 @@ static ssize_t netprocfs_tcpstats(FAR struct netprocfs_file_s 
*priv,
   int addrlen = (domain == PF_INET) ?
 INET_ADDRSTRLEN : INET6_ADDRSTRLEN;
   FAR struct tcp_conn_s *conn = NULL;
-  char remote[addrlen + 1];
-  char local[addrlen + 1];
+  char remote[INET6_ADDRSTRLEN + 1];
+  char local[INET6_ADDRSTRLEN + 1];
   int len = 0;
   void *laddr;
   void *raddr;
diff --git a/net/procfs/net_udp.c b/net/procfs/net_udp.c
index 0dab03b68a..424de2f198 100644
--- a/net/procfs/net_udp.c
+++ b/net/procfs/net_udp.c
@@ -60,8 +60,8 @@ static ssize_t netprocfs_udpstats(FAR struct netprocfs_file_s 
*priv,
   int addrlen = (domain == PF_INET) ?
 INET_ADDRSTRLEN : INET6_ADDRSTRLEN;
   FAR struct udp_conn_s *conn = NULL;
-  char remote[addrlen + 1];
-  char local[addrlen + 1];
+  char remote[INET6_ADDRSTRLEN + 1];
+  char local[INET6_ADDRSTRLEN + 1];
   int len = 0;
   void *laddr;
   void *raddr;



[nuttx] 03/08: libs: workaround for Visual Studio(MSVC) Compiler Error C2124

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 634baa5a2f309812d8f2cc54511254f20d7a2aa7
Author: chao an 
AuthorDate: Wed Feb 8 16:15:56 2023 +0800

libs: workaround for Visual Studio(MSVC) Compiler Error C2124

D:\archer\code\nuttx\libs\libc\stdlib\lib_strtod.c: error C2124: divide or 
mod by zero

Windows MSVC restrictions, MSVC doesn't allow division through a
zero literal, but allows it through const variable set to zero

Reference:

https://docs.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-error-c2124?view=msvc-170

Signed-off-by: chao an 
---
 include/nuttx/lib/math.h   | 18 +++---
 libs/libc/math/lib_gamma.c | 30 +-
 2 files changed, 32 insertions(+), 16 deletions(-)

diff --git a/include/nuttx/lib/math.h b/include/nuttx/lib/math.h
index 3737c1715d..a5469c2e3f 100644
--- a/include/nuttx/lib/math.h
+++ b/include/nuttx/lib/math.h
@@ -74,15 +74,19 @@
 
 /* General Constants /
 
-#define INFINITY(1.0/0.0)
-#define NAN (0.0/0.0)
-#define HUGE_VALINFINITY
+#ifndef _HUGE_ENUF
+#  define _HUGE_ENUF (1e+300)  /* _HUGE_ENUF*_HUGE_ENUF must overflow */
+#endif
+
+#define INFINITY   ((double)(_HUGE_ENUF * _HUGE_ENUF))
+#define NAN((double)(INFINITY * 0.0F))
+#define HUGE_VAL   INFINITY
 
-#define INFINITY_F  (1.0F/0.0F)
-#define NAN_F   (0.0F/0.0F)
+#define INFINITY_F ((float)INFINITY)
+#define NAN_F  ((float)(INFINITY * 0.0F))
 
-#define INFINITY_L  (1.0L/0.0L)
-#define NAN_L   (0.0L/0.0L)
+#define INFINITY_L ((long double)INFINITY)
+#define NAN_L  ((long double)(INFINITY * 0.0F))
 
 #define isnan(x)   ((x) != (x))
 #define isnanf(x)  ((x) != (x))
diff --git a/libs/libc/math/lib_gamma.c b/libs/libc/math/lib_gamma.c
index 60728e5c0e..a93c4629fb 100644
--- a/libs/libc/math/lib_gamma.c
+++ b/libs/libc/math/lib_gamma.c
@@ -32,9 +32,12 @@
  *
  /
 
-/* "A Precision Approximation of the Gamma Function" - Cornelius Lanczos (1964)
- * "Lanczos Implementation of the Gamma Function" - Paul Godfrey (2001)
- * "An Analysis of the Lanczos Gamma Approximation" - Glendon Ralph Pugh (2004)
+/* "A Precision Approximation of the Gamma Function"
+ *   - Cornelius Lanczos (1964)
+ * "Lanczos Implementation of the Gamma Function"
+ *   - Paul Godfrey (2001)
+ * "An Analysis of the Lanczos Gamma Approximation"
+ *   - Glendon Ralph Pugh (2004)
  *
  * Approximation method:
  *
@@ -133,9 +136,10 @@ static const double g_sden[N + 1] =
 static const double g_fact[] =
 {
   1, 1, 2, 6, 24, 120, 720, 5040.0, 40320.0, 362880.0, 3628800.0, 39916800.0,
-  479001600.0, 6227020800.0, 87178291200.0, 1307674368000.0, 20922789888000.0,
-  355687428096000.0, 6402373705728000.0, 121645100408832000.0,
-  243290200817664.0, 5109094217170944.0, 11240007260768.0,
+  479001600.0, 6227020800.0, 87178291200.0, 1307674368000.0,
+  20922789888000.0, 355687428096000.0, 6402373705728000.0,
+  121645100408832000.0, 243290200817664.0, 5109094217170944.0,
+  11240007260768.0,
 };
 
 /* S(x) rational function for positive x */
@@ -151,6 +155,7 @@ static double sinpi(double x)
   int n;
 
   /* argument reduction: x = |x| mod 2 */
+
   /* spurious inexact when x is odd int */
 
   x = x * 0.5;
@@ -205,7 +210,7 @@ static double s(double x)
 }
 }
 
-  return num/den;
+  return num / den;
 }
 
 /
@@ -219,6 +224,7 @@ double tgamma(double x)
   double f;
   uint64_t i;
 } u;
+
   u.f = x;
 
   double absx;
@@ -241,17 +247,19 @@ double tgamma(double x)
   if (ix < (0x3ff - 54) << 20)
 {
   /* |x| < 2^-54: tgamma(x) ~ 1/x, +-0 raises div-by-zero */
+
   return 1 / x;
 }
 
   /* integer arguments */
+
   /* raise inexact when non-integer */
 
   if (x == floor(x))
 {
   if (sign)
 {
-  return 0 / 0.0;
+  return NAN;
 }
 
   if (x <= sizeof g_fact / sizeof *g_fact)
@@ -261,6 +269,7 @@ double tgamma(double x)
 }
 
   /* x >= 172: tgamma(x)=inf with overflow */
+
   /* x =< -184: tgamma(x)=+-0 with underflow */
 
   if (ix >= 0x4067)
@@ -269,11 +278,13 @@ double tgamma(double x)
 
   if (sign)
 {
-  FORCE_EVAL((float)(0x1p-126 / x));
+  FORCE_EVAL((float)(ldexp(1.0, -126) / x));
+
   if (floor(x) * 0.5 == floor(x * 0.5))
 {
   return 0;
 }
+
   return -0.0;
 }
 
@@ -302,6 +313,7 @@ double tgamma(double x)
   if (x < 0)
 {
   /* reflection formula for negative x */
+
   /* sinpi(absx) is not 0, integers are already handled */
 
   r = -pi / (sinpi(absx) * absx * r);



[nuttx] branch master updated (4b4cee8916 -> 2d536059f0)

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 4b4cee8916 build/kconfig: refresh all defconfig
 new 8761cc9bfc libs: fix visual studio Compiler Error C2036
 new 86aed87487 sys/sysinfo: align sysinfo define with linux
 new 634baa5a2f libs: workaround for Visual Studio(MSVC) Compiler Error 
C2124
 new ccaa625930 fs/smart: fix visual studio Compiler Error C2016
 new 5580de0685 net/netfilter: fix visual studio Compiler Error C2229
 new 4a8cd8ca0c net/procfs: fix visual studio Compiler Error C2057
 new 77f68b121b fs/epoll: fix visual studio Compiler Error C2059
 new 2d536059f0 mm/mempool: fix visual studio Compiler Warning C4098

The 8 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 fs/vfs/fs_epoll.c   |  2 +-
 include/nuttx/fs/smart.h|  2 ++
 include/nuttx/lib/math.h| 18 +++---
 include/nuttx/net/netdev.h  |  3 ++-
 include/nuttx/net/netfilter/ip_tables.h |  2 +-
 include/nuttx/net/netfilter/x_tables.h  |  2 +-
 include/sys/sysinfo.h   | 27 +--
 libs/libc/math/lib_gamma.c  | 30 +-
 libs/libc/net/lib_inetpton.c|  5 +++--
 mm/mempool/mempool_multiple.c   |  2 +-
 net/procfs/net_tcp.c|  4 ++--
 net/procfs/net_udp.c|  4 ++--
 12 files changed, 60 insertions(+), 41 deletions(-)



[nuttx] 01/08: libs: fix visual studio Compiler Error C2036

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 8761cc9bfc3bc3905c0d0c4e3932b38e71e84226
Author: chao an 
AuthorDate: Wed Feb 8 13:58:23 2023 +0800

libs: fix visual studio Compiler Error C2036

D:\code\nuttx\libs\libc\net\lib_inetpton.c(300,52): error C2036: "void *" : 
unknown size

Reference:

https://learn.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/compiler-error-c2036?view=msvc-170

Signed-off-by: chao an 
---
 include/nuttx/net/netdev.h   | 3 ++-
 libs/libc/net/lib_inetpton.c | 5 +++--
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/include/nuttx/net/netdev.h b/include/nuttx/net/netdev.h
index 33a4f8c7da..cb6d69d58c 100644
--- a/include/nuttx/net/netdev.h
+++ b/include/nuttx/net/netdev.h
@@ -162,7 +162,8 @@
  */
 
 #define IPBUF(hl) ((FAR void *)(IOB_DATA(dev->d_iob) + (hl)))
-#define NETLLBUF  (IPBUF(0) - NET_LL_HDRLEN(dev))
+#define NETLLBUF  ((FAR void *) \
+   ((FAR uint8_t *)IPBUF(0) - NET_LL_HDRLEN(dev)))
 
 #define IPv4BUF ((FAR struct ipv4_hdr_s *)IPBUF(0))
 #define IPv6BUF ((FAR struct ipv6_hdr_s *)IPBUF(0))
diff --git a/libs/libc/net/lib_inetpton.c b/libs/libc/net/lib_inetpton.c
index f1636fcf61..724759dcd9 100644
--- a/libs/libc/net/lib_inetpton.c
+++ b/libs/libc/net/lib_inetpton.c
@@ -107,7 +107,7 @@ static int inet_ipv4_pton(FAR const char *src, FAR void 
*dest)
 
   memset(dest, 0, sizeof(struct in_addr));
 
-  ip= (uint8_t *)dest;
+  ip= (FAR uint8_t *)dest;
   srcoffset = 0;
   numoffset = 0;
   ndots = 0;
@@ -297,7 +297,8 @@ static int inet_ipv6_pton(FAR const char *src, FAR void 
*dest)
 
   if (nrsep > 0)
 {
-  memcpy(dest + (16 - (nrsep << 1)), [0], nrsep << 1);
+  memcpy((FAR uint8_t *)dest +
+ (16 - (nrsep << 1)), [0], nrsep << 1);
 }
 
   /* Return 1 if the conversion succeeds */



[GitHub] [nuttx] xiaoxiang781216 merged pull request #8471: fix visual studio Compiler Error

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8471:
URL: https://github.com/apache/nuttx/pull/8471


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] branch master updated (3a0fdb019d -> 4b4cee8916)

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 3a0fdb019d nuttx: replace all ARRAY_SIZE()/ARRAYSIZE() to nitems()
 add e942a7c55e build/Kconfig: fix warnings detected by kconfiglib
 add 4b4cee8916 build/kconfig: refresh all defconfig

No new revisions were added by this update.

Summary of changes:
 arch/arm/Kconfig  | 10 +-
 arch/arm/src/efm32/Kconfig|  4 ++--
 arch/arm/src/imx6/Kconfig |  8 
 arch/arm/src/imxrt/Kconfig| 10 +-
 arch/arm/src/nrf52/Kconfig|  3 +--
 arch/arm/src/sama5/Kconfig|  2 +-
 arch/arm/src/stm32/Kconfig|  2 +-
 arch/avr/src/avr/Kconfig  |  2 +-
 arch/sparc/Kconfig|  8 
 arch/z80/src/ez80/Kconfig |  4 ++--
 arch/z80/src/z180/Kconfig |  2 +-
 arch/z80/src/z8/Kconfig   |  2 +-
 boards/Kconfig|  5 +
 boards/arm/gd32f4/gd32f450zk-eval/Kconfig |  3 ---
 boards/arm/lpc17xx_40xx/lx_cpu/Kconfig|  2 +-
 boards/arm/samd5e5/metro-m4/Kconfig   |  4 ++--
 boards/arm/samd5e5/same54-xplained-pro/Kconfig|  4 ++--
 boards/arm/stm32/b-g431b-esc1/Kconfig |  2 +-
 boards/arm/stm32/nucleo-f429zi/Kconfig|  2 --
 boards/arm/stm32/nucleo-g431rb/Kconfig|  2 +-
 boards/arm/stm32f7/nucleo-144/Kconfig |  4 
 boards/arm/stm32wl5/nucleo-wl55jc/Kconfig |  8 
 boards/arm/tiva/tm4c1294-launchpad/Kconfig|  2 +-
 boards/z80/ez80/z20x/Kconfig  |  6 +++---
 boards/z80/z8/z8encore000zco/configs/ostest/defconfig |  1 -
 boards/z80/z8/z8f64200100kit/configs/ostest/defconfig |  1 -
 drivers/serial/Kconfig|  2 +-
 drivers/virtio/Kconfig|  7 ---
 libs/libc/machine/Kconfig |  2 +-
 net/usrsock/Kconfig   |  1 -
 30 files changed, 46 insertions(+), 69 deletions(-)



[GitHub] [nuttx] xiaoxiang781216 merged pull request #8485: build/Kconfig: fix warnings detected by kconfiglib

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8485:
URL: https://github.com/apache/nuttx/pull/8485


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx] 02/02: nuttx: replace all ARRAY_SIZE()/ARRAYSIZE() to nitems()

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 3a0fdb019d279fb657774177f7e806d9e37ef6c8
Author: chao an 
AuthorDate: Thu Feb 2 20:31:22 2023 +0800

nuttx: replace all ARRAY_SIZE()/ARRAYSIZE() to nitems()

Signed-off-by: chao an 
---
 arch/arm/include/cxd56xx/crashdump.h   |  4 ++--
 arch/arm/src/cxd56xx/cxd56_pinconfig.h |  3 ++-
 arch/arm/src/rtl8720c/chip.h   |  6 +++---
 arch/arm/src/stm32h7/stm32_fmc.c   |  6 +++---
 arch/arm64/src/a64/a64_boot.c  |  2 +-
 arch/arm64/src/common/arm64_arch.h |  4 
 arch/arm64/src/common/arm64_mmu.c  |  2 +-
 arch/arm64/src/qemu/qemu_boot.c|  2 +-
 arch/sim/src/sim/posix/sim_hostusrsock.c   |  7 +--
 binfmt/libelf/libelf_coredump.c|  4 ++--
 boards/arm/cxd56xx/common/src/cxd56_crashdump.c|  8 
 .../gd32f4/gd32f450zk-eval/src/gd32f4xx_autoleds.c | 10 +++---
 .../gd32f4/gd32f450zk-eval/src/gd32f4xx_userleds.c | 14 +-
 boards/arm/samv7/same70-qmtech/src/sam_bringup.c   |  5 ++---
 boards/arm/samv7/same70-xplained/src/sam_bringup.c |  5 ++---
 boards/arm/samv7/samv71-xult/src/sam_bringup.c |  5 ++---
 .../arm/stm32/nucleo-f207zg/src/stm32_autoleds.c   | 10 +++---
 .../arm/stm32/nucleo-f207zg/src/stm32_userleds.c   | 14 +-
 .../arm/stm32/nucleo-f303ze/src/stm32_autoleds.c   | 10 +++---
 .../arm/stm32/nucleo-f303ze/src/stm32_userleds.c   | 14 +-
 .../arm/stm32/nucleo-f429zi/src/stm32_autoleds.c   | 10 +++---
 boards/arm/stm32/nucleo-f429zi/src/stm32_bbsram.c  | 14 +++---
 boards/arm/stm32/nucleo-f429zi/src/stm32_spi.c | 16 
 .../arm/stm32/nucleo-f429zi/src/stm32_userleds.c   | 14 +-
 boards/arm/stm32f7/nucleo-144/src/stm32_autoleds.c | 10 +++---
 boards/arm/stm32f7/nucleo-144/src/stm32_bbsram.c   | 14 +++---
 boards/arm/stm32f7/nucleo-144/src/stm32_spi.c  | 16 
 boards/arm/stm32f7/nucleo-144/src/stm32_userleds.c | 14 +-
 .../stm32f777zit6-meadow/src/stm32_autoleds.c  | 10 +++---
 .../arm/stm32h7/nucleo-h743zi/src/stm32_autoleds.c | 10 +++---
 .../arm/stm32h7/nucleo-h743zi/src/stm32_progmem.c  |  5 ++---
 .../arm/stm32h7/nucleo-h743zi/src/stm32_userleds.c | 14 +-
 .../stm32h7/nucleo-h743zi2/src/stm32_autoleds.c| 10 +++---
 .../stm32h7/nucleo-h743zi2/src/stm32_userleds.c| 14 +-
 .../stm32h7/stm32h747i-disco/src/stm32_autoleds.c  | 10 +++---
 .../stm32h7/stm32h747i-disco/src/stm32_userleds.c  | 14 +-
 .../arm/stm32l4/nucleo-l496zg/src/stm32_autoleds.c | 10 +++---
 boards/arm/stm32l4/nucleo-l496zg/src/stm32_spi.c   | 16 
 .../arm/stm32l4/nucleo-l496zg/src/stm32_userleds.c | 14 +-
 .../arm/stm32l5/nucleo-l552ze/src/stm32_autoleds.c | 10 +++---
 .../arm/stm32l5/nucleo-l552ze/src/stm32_userleds.c | 14 +-
 .../arm/stm32l5/stm32l562e-dk/src/stm32_autoleds.c | 10 +++---
 .../arm/stm32l5/stm32l562e-dk/src/stm32_userleds.c | 14 +-
 .../arm64/a64/pinephone/src/pinephone_autoleds.c   | 10 +++---
 .../arm64/a64/pinephone/src/pinephone_userleds.c   | 14 +-
 .../renesas/rx65n/rx65n-grrose/src/rx65n_sbram.c   | 14 +++---
 .../renesas/rx65n/rx65n-rsk2mb/src/rx65n_sbram.c   | 14 +++---
 .../esp32c3/common/src/esp32c3_board_spiflash.c|  6 +++---
 .../xtensa/esp32/common/src/esp32_board_spiflash.c |  6 +++---
 .../xtensa/esp32/esp32-lyrat/src/esp32_buttons.c   | 10 --
 crypto/testmngr.c  | 18 --
 drivers/audio/cs4344.c |  2 +-
 drivers/audio/cs4344.h |  6 ++
 drivers/audio/es8388.c | 12 +++-
 drivers/clk/clk_rpmsg.c|  8 +++-
 drivers/ioexpander/ioe_rpmsg.c |  8 +++-
 drivers/misc/rpmsgblk.c|  2 +-
 drivers/misc/rpmsgblk.h|  6 ++
 drivers/misc/rpmsgblk_server.c |  2 +-
 drivers/misc/rpmsgdev.c|  2 +-
 drivers/misc/rpmsgdev.h|  6 ++
 drivers/misc/rpmsgdev_server.c |  2 +-
 drivers/mtd/rpmsgmtd.c |  2 +-
 drivers/mtd/rpmsgmtd.h |  5 +
 drivers/mtd/rpmsgmtd_server.c  |  2 +-
 drivers/power/pm/pm_procfs.c   | 14 ++
 drivers/power/supply/regulator_rpmsg.c |  8 +++-
 drivers/sensors/wtgahrs2.c |  6 +++---
 drivers/usrsock/usrsock_dev.c  |  8 
 

[nuttx] 01/02: include: Add nitems() definition to sys/param.h

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit cf0769d6135dafdd7ed25e315b68c7005dfe808e
Author: chao an 
AuthorDate: Thu Feb 2 20:30:31 2023 +0800

include: Add nitems() definition to sys/param.h

Signed-off-by: chao an 
---
 include/sys/param.h | 8 
 1 file changed, 8 insertions(+)

diff --git a/include/sys/param.h b/include/sys/param.h
index 4e94f51bbc..831a552eae 100644
--- a/include/sys/param.h
+++ b/include/sys/param.h
@@ -43,6 +43,14 @@
 #  define MAX(a,b)  (((a) > (b)) ? (a) : (b))
 #endif  /* MAX */
 
+/* Macros for number of items.
+ * (aka. ARRAY_SIZE, ArraySize, Size of an Array)
+ */
+
+#ifndef nitems
+#  define nitems(_a)(sizeof(_a) / sizeof(0[(_a)]))
+#endif /* nitems */
+
 /
  * Public Type Definitions
  /



[nuttx] branch master updated (3f3e090716 -> 3a0fdb019d)

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git


from 3f3e090716 Revert "include/sys/socket.h: Add SOCK_CTRL to socket type"
 new cf0769d613 include: Add nitems() definition to sys/param.h
 new 3a0fdb019d nuttx: replace all ARRAY_SIZE()/ARRAYSIZE() to nitems()

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 arch/arm/include/cxd56xx/crashdump.h   |  4 ++--
 arch/arm/src/cxd56xx/cxd56_pinconfig.h |  3 ++-
 arch/arm/src/rtl8720c/chip.h   |  6 +++---
 arch/arm/src/stm32h7/stm32_fmc.c   |  6 +++---
 arch/arm64/src/a64/a64_boot.c  |  2 +-
 arch/arm64/src/common/arm64_arch.h |  4 
 arch/arm64/src/common/arm64_mmu.c  |  2 +-
 arch/arm64/src/qemu/qemu_boot.c|  2 +-
 arch/sim/src/sim/posix/sim_hostusrsock.c   |  7 +--
 binfmt/libelf/libelf_coredump.c|  4 ++--
 boards/arm/cxd56xx/common/src/cxd56_crashdump.c|  8 
 .../gd32f4/gd32f450zk-eval/src/gd32f4xx_autoleds.c | 10 +++---
 .../gd32f4/gd32f450zk-eval/src/gd32f4xx_userleds.c | 14 +-
 boards/arm/samv7/same70-qmtech/src/sam_bringup.c   |  5 ++---
 boards/arm/samv7/same70-xplained/src/sam_bringup.c |  5 ++---
 boards/arm/samv7/samv71-xult/src/sam_bringup.c |  5 ++---
 .../arm/stm32/nucleo-f207zg/src/stm32_autoleds.c   | 10 +++---
 .../arm/stm32/nucleo-f207zg/src/stm32_userleds.c   | 14 +-
 .../arm/stm32/nucleo-f303ze/src/stm32_autoleds.c   | 10 +++---
 .../arm/stm32/nucleo-f303ze/src/stm32_userleds.c   | 14 +-
 .../arm/stm32/nucleo-f429zi/src/stm32_autoleds.c   | 10 +++---
 boards/arm/stm32/nucleo-f429zi/src/stm32_bbsram.c  | 14 +++---
 boards/arm/stm32/nucleo-f429zi/src/stm32_spi.c | 16 
 .../arm/stm32/nucleo-f429zi/src/stm32_userleds.c   | 14 +-
 boards/arm/stm32f7/nucleo-144/src/stm32_autoleds.c | 10 +++---
 boards/arm/stm32f7/nucleo-144/src/stm32_bbsram.c   | 14 +++---
 boards/arm/stm32f7/nucleo-144/src/stm32_spi.c  | 16 
 boards/arm/stm32f7/nucleo-144/src/stm32_userleds.c | 14 +-
 .../stm32f777zit6-meadow/src/stm32_autoleds.c  | 10 +++---
 .../arm/stm32h7/nucleo-h743zi/src/stm32_autoleds.c | 10 +++---
 .../arm/stm32h7/nucleo-h743zi/src/stm32_progmem.c  |  5 ++---
 .../arm/stm32h7/nucleo-h743zi/src/stm32_userleds.c | 14 +-
 .../stm32h7/nucleo-h743zi2/src/stm32_autoleds.c| 10 +++---
 .../stm32h7/nucleo-h743zi2/src/stm32_userleds.c| 14 +-
 .../stm32h7/stm32h747i-disco/src/stm32_autoleds.c  | 10 +++---
 .../stm32h7/stm32h747i-disco/src/stm32_userleds.c  | 14 +-
 .../arm/stm32l4/nucleo-l496zg/src/stm32_autoleds.c | 10 +++---
 boards/arm/stm32l4/nucleo-l496zg/src/stm32_spi.c   | 16 
 .../arm/stm32l4/nucleo-l496zg/src/stm32_userleds.c | 14 +-
 .../arm/stm32l5/nucleo-l552ze/src/stm32_autoleds.c | 10 +++---
 .../arm/stm32l5/nucleo-l552ze/src/stm32_userleds.c | 14 +-
 .../arm/stm32l5/stm32l562e-dk/src/stm32_autoleds.c | 10 +++---
 .../arm/stm32l5/stm32l562e-dk/src/stm32_userleds.c | 14 +-
 .../arm64/a64/pinephone/src/pinephone_autoleds.c   | 10 +++---
 .../arm64/a64/pinephone/src/pinephone_userleds.c   | 14 +-
 .../renesas/rx65n/rx65n-grrose/src/rx65n_sbram.c   | 14 +++---
 .../renesas/rx65n/rx65n-rsk2mb/src/rx65n_sbram.c   | 14 +++---
 .../esp32c3/common/src/esp32c3_board_spiflash.c|  6 +++---
 .../xtensa/esp32/common/src/esp32_board_spiflash.c |  6 +++---
 .../xtensa/esp32/esp32-lyrat/src/esp32_buttons.c   | 10 --
 crypto/testmngr.c  | 18 --
 drivers/audio/cs4344.c |  2 +-
 drivers/audio/cs4344.h |  6 ++
 drivers/audio/es8388.c | 12 +++-
 drivers/clk/clk_rpmsg.c|  8 +++-
 drivers/ioexpander/ioe_rpmsg.c |  8 +++-
 drivers/misc/rpmsgblk.c|  2 +-
 drivers/misc/rpmsgblk.h|  6 ++
 drivers/misc/rpmsgblk_server.c |  2 +-
 drivers/misc/rpmsgdev.c|  2 +-
 drivers/misc/rpmsgdev.h|  6 ++
 drivers/misc/rpmsgdev_server.c |  2 +-
 drivers/mtd/rpmsgmtd.c |  2 +-
 drivers/mtd/rpmsgmtd.h |  5 +
 drivers/mtd/rpmsgmtd_server.c  |  2 +-
 

[GitHub] [nuttx] xiaoxiang781216 merged pull request #8414: include: Add nitems() definition to sys/param.h

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #8414:
URL: https://github.com/apache/nuttx/pull/8414


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx-apps] branch master updated: testing/drivertest: add block driver test

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git


The following commit(s) were added to refs/heads/master by this push:
 new 9ee3640b6 testing/drivertest: add block driver test
9ee3640b6 is described below

commit 9ee3640b626264b4bbe3ca0a8d59f43e3fc3a7f9
Author: crafcat7 
AuthorDate: Thu Feb 9 14:00:01 2023 +0800

testing/drivertest: add block driver test
---
 testing/drivertest/Makefile   |   5 +
 testing/drivertest/drivertest_block.c | 283 ++
 2 files changed, 288 insertions(+)

diff --git a/testing/drivertest/Makefile b/testing/drivertest/Makefile
index 954292f70..ab26f47f3 100644
--- a/testing/drivertest/Makefile
+++ b/testing/drivertest/Makefile
@@ -49,4 +49,9 @@ MAINSRC  += drivertest_watchdog.c
 PROGNAME += cmocka_driver_watchdog
 endif
 
+ifneq ($(CONFIG_BCH),)
+PROGNAME += cmocka_driver_block
+MAINSRC  += drivertest_block.c
+endif
+
 include $(APPDIR)/Application.mk
diff --git a/testing/drivertest/drivertest_block.c 
b/testing/drivertest/drivertest_block.c
new file mode 100644
index 0..220e0c49a
--- /dev/null
+++ b/testing/drivertest/drivertest_block.c
@@ -0,0 +1,283 @@
+/
+ * apps/testing/drivertest/drivertest_block.c
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.  The
+ * ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the
+ * License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
+ * License for the specific language governing permissions and limitations
+ * under the License.
+ *
+ /
+
+/
+ * Included Files
+ /
+
+#include 
+
+#include 
+#include 
+
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+#include 
+
+/
+ * Private Type
+ /
+
+/
+ * Pre-processor Definitions
+ /
+
+#define BLKTEST_MAXLEN  255
+#define BLKTEST_LOOPS   100
+
+/
+ * Private Types
+ /
+
+struct pre_build
+{
+  FAR const char *mountpt;
+};
+
+struct test_state_s
+{
+  FAR char *context[BLKTEST_MAXLEN];
+  size_t len[BLKTEST_LOOPS];
+  uint32_t crc[BLKTEST_LOOPS];
+  int fd;
+};
+
+/
+ * Private Functions
+ /
+
+/
+ * Name: show_usage
+ /
+
+static void show_usage(FAR const char *progname, int exitcode)
+{
+  printf("Usage: %s -m \n", progname);
+  printf("Where:\n");
+  printf("  -m  Block device or mtd device"
+ " mount location[default location: dev/ram10].\n");
+  exit(exitcode);
+}
+
+/
+ * Name: parse_commandline
+ /
+
+static void parse_commandline(int argc, FAR char **argv,
+  FAR struct pre_build *pre_build)
+{
+  int option;
+
+  while ((option = getopt(argc, argv, "m:")) != ERROR)
+{
+  switch (option)
+{
+  case 'm':
+pre_build->mountpt = optarg;
+break;
+  case '?':
+printf("Unknown option: %c\n", optopt);
+show_usage(argv[0], EXIT_FAILURE);
+break;
+}
+}
+}
+
+/
+ * Name: blktest_randchar
+ /
+
+static inline char blktest_randchar(void)
+{
+  int value 

[GitHub] [nuttx-apps] xiaoxiang781216 merged pull request #1555: testing/drivertest: add block driver test

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #1555:
URL: https://github.com/apache/nuttx-apps/pull/1555


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[nuttx-apps] branch master updated: build/Kconfig: fix warnings detected by kconfiglib

2023-02-09 Thread xiaoxiang
This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git


The following commit(s) were added to refs/heads/master by this push:
 new 42d34fcef build/Kconfig: fix warnings detected by kconfiglib
42d34fcef is described below

commit 42d34fcef3984b4da92b9cb5fb8658d84af9dab9
Author: chao an 
AuthorDate: Thu Feb 9 16:17:46 2023 +0800

build/Kconfig: fix warnings detected by kconfiglib

Signed-off-by: chao an 
---
 examples/calib_udelay/Kconfig | 2 --
 graphics/twm4nx/Kconfig   | 2 +-
 mlearning/cmsis/Kconfig   | 2 +-
 mlearning/libnnablart/Kconfig | 2 +-
 netutils/thttpd/Kconfig   | 1 -
 netutils/webserver/Kconfig| 3 +--
 system/dumpstack/Kconfig  | 1 -
 7 files changed, 4 insertions(+), 9 deletions(-)

diff --git a/examples/calib_udelay/Kconfig b/examples/calib_udelay/Kconfig
index c1759bc16..a6a8e6932 100644
--- a/examples/calib_udelay/Kconfig
+++ b/examples/calib_udelay/Kconfig
@@ -17,11 +17,9 @@ if EXAMPLES_CALIB_UDELAY
 config EXAMPLES_CALIB_UDELAY_NUM_MEASUREMENTS
int "Number of measurements to take for each loop iteration count"
default 3
-   ---help---
 
 config EXAMPLES_CALIB_UDELAY_NUM_RESULTS
int "Number of results to generate for calibration slope"
default 20
-   ---help---
 
 endif
diff --git a/graphics/twm4nx/Kconfig b/graphics/twm4nx/Kconfig
index 9e1322dd0..3f9600f68 100644
--- a/graphics/twm4nx/Kconfig
+++ b/graphics/twm4nx/Kconfig
@@ -97,7 +97,7 @@ choice
 
 config TWM4NX_MOUSE
bool "Mouse"
-   select NX_SWCURSOR
+   depends on NX_SWCURSOR
 
 config TWM4NX_TOUCHSCREEN
bool "Touchscreen"
diff --git a/mlearning/cmsis/Kconfig b/mlearning/cmsis/Kconfig
index f33a8cbe1..364326f61 100644
--- a/mlearning/cmsis/Kconfig
+++ b/mlearning/cmsis/Kconfig
@@ -16,7 +16,7 @@ if CMSIS
 
 config CMSIS_VER
string "Default CMSIS version"
-   default 5.8.0
+   default "5.8.0"
 
 config CMSIS_DSP
bool "CMSIS DSP"
diff --git a/mlearning/libnnablart/Kconfig b/mlearning/libnnablart/Kconfig
index 77a55b238..f1f02d734 100644
--- a/mlearning/libnnablart/Kconfig
+++ b/mlearning/libnnablart/Kconfig
@@ -15,6 +15,6 @@ if NNABLA_RT
 
 config NNABLA_RT_VER
string "Default NNABLA Runtime version"
-   default 1.24.0
+   default "1.24.0"
 
 endif # NNABLA_RT
diff --git a/netutils/thttpd/Kconfig b/netutils/thttpd/Kconfig
index b6a72e4c3..765728cf0 100644
--- a/netutils/thttpd/Kconfig
+++ b/netutils/thttpd/Kconfig
@@ -314,7 +314,6 @@ config THTTPD_TILDE_MAP2
 config THTTPD_GENERATE_INDICES
bool "Generate name indices"
default n
-   ---help---
 
 config THTTPD_USE_URLPATTERN
bool "Use URL pattern"
diff --git a/netutils/webserver/Kconfig b/netutils/webserver/Kconfig
index 323625bfb..92fd293d2 100644
--- a/netutils/webserver/Kconfig
+++ b/netutils/webserver/Kconfig
@@ -143,8 +143,7 @@ config NETUTILS_HTTPD_PATH
 
 config NETUTILS_HTTPD_KEEPALIVE_DISABLE
bool "Keepalive Disable"
-   default y if !NETUTILS_HTTPD_TIMEOUT
-   default n if NETUTILS_HTTPD_TIMEOUT
+   default y
---help---
Disabled HTTP keep-alive for HTTP clients.  Keep-alive permits a
client to make multiple requests over the same connection, 
rather
diff --git a/system/dumpstack/Kconfig b/system/dumpstack/Kconfig
index ad7f0a9c2..3187e636a 100644
--- a/system/dumpstack/Kconfig
+++ b/system/dumpstack/Kconfig
@@ -7,7 +7,6 @@ menuconfig SYSTEM_DUMPSTACK
tristate "dumpstack tool for show the task backtrace"
default n
depends on SCHED_BACKTRACE
-   ---help---
 
 if SYSTEM_DUMPSTACK
 



[GitHub] [nuttx-apps] xiaoxiang781216 merged pull request #1554: build/Kconfig: fix warnings detected by kconfiglib

2023-02-09 Thread via GitHub


xiaoxiang781216 merged PR #1554:
URL: https://github.com/apache/nuttx-apps/pull/1554


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] crafcat7 opened a new pull request, #1555: testing/drivertest: add block driver test

2023-02-09 Thread via GitHub


crafcat7 opened a new pull request, #1555:
URL: https://github.com/apache/nuttx-apps/pull/1555

   ## Summary
   add cmocka block driver test
   ## Impact
   
   ## Testing
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] anchao commented on pull request #8414: include: Add nitems() definition to sys/param.h

2023-02-09 Thread via GitHub


anchao commented on PR #8414:
URL: https://github.com/apache/nuttx/pull/8414#issuecomment-1423882491

   > > But this will make the code diverse, some uses nitems, other uses 
ARRAY_SIZE.
   > 
   > That is exactly what I am trying to avoid:
   > 
   > 1. Add comment to nitems `/* Macros for number of items. (aka. ARRAY_SIZE, 
ArraySize, Size of an Array) */`
   > 2. replace all ARRAY_SIZE with nitems()
   
   Done


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] SPRESENSE commented on pull request #8474: Revert "include/sys/socket.h: Add SOCK_CTRL to socket type"

2023-02-09 Thread via GitHub


SPRESENSE commented on PR #8474:
URL: https://github.com/apache/nuttx/pull/8474#issuecomment-1423880979

   @masayuki2009 san
   
   Thank you for sharing command to run qemu, I confirmed it and found it same 
behavior.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx] anchao commented on a diff in pull request #8449: build/Kconfig: add BINDIR/APPSBINDIR to support out of tree build

2023-02-09 Thread via GitHub


anchao commented on code in PR #8449:
URL: https://github.com/apache/nuttx/pull/8449#discussion_r1101165021


##
Kconfig:
##
@@ -2124,7 +2132,7 @@ source "openamp/Kconfig"
 endmenu
 
 menu "Application Configuration"
-source "$APPSDIR/Kconfig"
+source "$APPSBINDIR/Kconfig"

Review Comment:
   Done, added some comments on help manual:
   
   ```bash
   config APPSBINDIR
  string
  option env="APPSBINDIR"
  ---help---
  Output path of Kconfig which dynamically generated by NuttX 
Apps
  This option is consistent with the APPSDIR by default, and 
will
  be changed when out-of-tree compilation is supported
   
   config BINDIR
  string
  option env="BINDIR"
  ---help---
  Output path of Kconfig which dynamically generated by NuttX 
Kernel
  This option is consistent with the TOPDIR by default, and will
  be changed when out-of-tree compilation is supported
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [nuttx-apps] anchao opened a new pull request, #1554: build/Kconfig: fix warnings detected by kconfiglib

2023-02-09 Thread via GitHub


anchao opened a new pull request, #1554:
URL: https://github.com/apache/nuttx-apps/pull/1554

   ## Summary
   
   build/Kconfig: fix warnings detected by kconfiglib
   
   Part of https://github.com/apache/nuttx/pull/8485
   
   Signed-off-by: chao an 
   
   ## Impact
   
   N/A
   
   ## Testing
   
   before:
   
   $ APPSDIR=../apps/ EXTERNALDIR=dummy menuconfig
   
   ```bash
   Kconfig:233: warning: the 'modules' option is not supported. Let me know if 
this is a problem for you, as it wouldn't be that hard to implement. Note that 
modules are supported -- Kconfiglib just assumes the symbol name MODULES, like 
older versions of the C implementation did when 'option modules' wasn't used.
   arch/arm/Kconfig:1361: warning: style: quotes recommended around 
'arch/arm/src/s32k3xx/Kconfig' in 'source arch/arm/src/s32k3xx/Kconfig'
   arch/arm/Kconfig:1418: warning: style: quotes recommended around 
'arch/arm/src/stm32wb/Kconfig' in 'source arch/arm/src/stm32wb/Kconfig'
   arch/sparc/Kconfig:65: warning: style: quotes recommended around 
'arch/sparc/src/sparc_v8/Kconfig' in 'source arch/sparc/src/sparc_v8/Kconfig'
   arch/sparc/Kconfig:66: warning: style: quotes recommended around 
'arch/sparc/src/bm3803/Kconfig' in 'source arch/sparc/src/bm3803/Kconfig'
   arch/sparc/Kconfig:67: warning: style: quotes recommended around 
'arch/sparc/src/bm3823/Kconfig' in 'source arch/sparc/src/bm3823/Kconfig'
   arch/sparc/Kconfig:68: warning: style: quotes recommended around 
'arch/sparc/src/s698pm/Kconfig' in 'source arch/sparc/src/s698pm/Kconfig'
   warning: ARCH_BOARD_STM32G071B_DISCO (defined at boards/Kconfig:1446) has 
leading or trailing whitespace in its prompt
   warning: DRIVERS_VIRTIO (defined at drivers/virtio/Kconfig:6) has 'help' but 
empty help text
   warning: DRIVERS_VIRTIO_MMIO_NUM (defined at drivers/virtio/Kconfig:13) has 
'help' but empty help text
   warning: DRIVERS_VIRTIO_MMIO_BASE (defined at drivers/virtio/Kconfig:19) has 
'help' but empty help text
   warning: DRIVERS_VIRTIO_MMIO_REGSIZE (defined at drivers/virtio/Kconfig:23) 
has 'help' but empty help text
   warning: DRIVERS_VIRTIO_MMIO_IRQ (defined at drivers/virtio/Kconfig:28) has 
'help' but empty help text
   warning: DRIVERS_VIRTIO_NET (defined at drivers/virtio/Kconfig:34) has 
'help' but empty help text
   warning: DRIVERS_VIRTIO_NET_QUEUE_LEN (defined at drivers/virtio/Kconfig:42) 
has 'help' but empty help text
   warning: NET_USRSOCK_UDP (defined at net/usrsock/Kconfig:41) has 'help' but 
empty help text
   libs/libc/machine/Kconfig:209: warning: style: quotes recommended around 
'libs/libc/machine/sparc/Kconfig' in 'source libs/libc/machine/sparc/Kconfig'
   warning: the hex symbol TTY_LAUNCH_STACKSIZE (defined at 
drivers/serial/Kconfig:201) has a non-hex default INIT_STACKSIZE (defined at 
sched/Kconfig:338)
   warning: the choice symbol ARCH_DEBUG_H (defined at Kconfig:559) is selected 
by the following symbols, but select/imply has no effect on choice symbols
- AVR_HAS_MEMX_PTR (defined at arch/avr/src/avr/Kconfig:63)
   warning: the choice symbol GD32F4_FLASH_CONFIG_K (defined at 
arch/arm/src/gd32f4/Kconfig:105) is selected by the following symbols, but 
select/imply has no effect on choice symbols
- GD32F450ZK_EVAL_CONSOLE_BOARD (defined at 
boards/arm/gd32f4/gd32f450zk-eval/Kconfig:35)
   warning: the default selection IMXRT_PROVIDES_TXC (undefined) of  
(defined at arch/arm/src/imxrt/Kconfig:1777) is not contained in the choice
   warning: the choice symbol TIVA_UART2 (defined at 
arch/arm/src/tiva/Kconfig:798) is selected by the following symbols, but 
select/imply has no effect on choice symbols
- TM4C1294_LAUNCHPAD_JUMPERS_CAN (defined at 
boards/arm/tiva/tm4c1294-launchpad/Kconfig:75)
   warning: the choice symbol NRF52_LFCLK_XTAL (defined at 
arch/arm/src/nrf52/Kconfig:304) is selected by the following symbols, but 
select/imply has no effect on choice symbols
- NRF52_SOFTDEVICE_CONTROLLER (defined at arch/arm/src/nrf52/Kconfig:661)
   warning: the default selection SAMA5_ADC_PWMTRIG_LINE0 (undefined) of 
 (defined at arch/arm/src/sama5/Kconfig:4416) is not contained in the 
choice
   warning: the default selection Z180_NO_SERIAL_CONSOLE (undefined) of 
 (defined at arch/z80/src/z180/Kconfig:534) is not contained in the 
choice
   warning: the default selection EZ80_ZDSII_V522 (undefined) of  
(defined at arch/z80/src/z8/Kconfig:53) is not contained in the choice
   warning: the choice symbol BOOT_RUNFROMEXTSRAM (defined at 
arch/Kconfig:1126) is selected by the following symbols, but select/imply has 
no effect on choice symbols
- IMX6_BOOT_SRAM (defined at arch/arm/src/imx6/Kconfig:194)
- IMXRT_BOOT_SRAM (defined at arch/arm/src/imxrt/Kconfig:1907)
- EZ80_PROGRAM (defined at arch/z80/src/ez80/Kconfig:96)
- Z20X_COPYTORAM (defined at boards/z80/ez80/z20x/Kconfig:47)
   warning: the choice symbol BOOT_RUNFROMFLASH (defined at arch/Kconfig:1131) 
is selected by the following symbols, 

[GitHub] [nuttx] anchao opened a new pull request, #8485: build/Kconfig: fix warnings detected by kconfiglib

2023-02-09 Thread via GitHub


anchao opened a new pull request, #8485:
URL: https://github.com/apache/nuttx/pull/8485

   ## Summary
   
   build/Kconfig: fix warnings detected by kconfiglib
   build/kconfig: refresh all defconfig
   
   
   ## Impact
   
   N/A
   
   ## Testing
   
   before:
   
   $ APPSDIR=../apps/ EXTERNALDIR=dummy menuconfig
   
   ```bash
   Kconfig:233: warning: the 'modules' option is not supported. Let me know if 
this is a problem for you, as it wouldn't be that hard to implement. Note that 
modules are supported -- Kconfiglib just assumes the symbol name MODULES, like 
older versions of the C implementation did when 'option modules' wasn't used.
   arch/arm/Kconfig:1361: warning: style: quotes recommended around 
'arch/arm/src/s32k3xx/Kconfig' in 'source arch/arm/src/s32k3xx/Kconfig'
   arch/arm/Kconfig:1418: warning: style: quotes recommended around 
'arch/arm/src/stm32wb/Kconfig' in 'source arch/arm/src/stm32wb/Kconfig'
   arch/sparc/Kconfig:65: warning: style: quotes recommended around 
'arch/sparc/src/sparc_v8/Kconfig' in 'source arch/sparc/src/sparc_v8/Kconfig'
   arch/sparc/Kconfig:66: warning: style: quotes recommended around 
'arch/sparc/src/bm3803/Kconfig' in 'source arch/sparc/src/bm3803/Kconfig'
   arch/sparc/Kconfig:67: warning: style: quotes recommended around 
'arch/sparc/src/bm3823/Kconfig' in 'source arch/sparc/src/bm3823/Kconfig'
   arch/sparc/Kconfig:68: warning: style: quotes recommended around 
'arch/sparc/src/s698pm/Kconfig' in 'source arch/sparc/src/s698pm/Kconfig'
   warning: ARCH_BOARD_STM32G071B_DISCO (defined at boards/Kconfig:1446) has 
leading or trailing whitespace in its prompt
   warning: DRIVERS_VIRTIO (defined at drivers/virtio/Kconfig:6) has 'help' but 
empty help text
   warning: DRIVERS_VIRTIO_MMIO_NUM (defined at drivers/virtio/Kconfig:13) has 
'help' but empty help text
   warning: DRIVERS_VIRTIO_MMIO_BASE (defined at drivers/virtio/Kconfig:19) has 
'help' but empty help text
   warning: DRIVERS_VIRTIO_MMIO_REGSIZE (defined at drivers/virtio/Kconfig:23) 
has 'help' but empty help text
   warning: DRIVERS_VIRTIO_MMIO_IRQ (defined at drivers/virtio/Kconfig:28) has 
'help' but empty help text
   warning: DRIVERS_VIRTIO_NET (defined at drivers/virtio/Kconfig:34) has 
'help' but empty help text
   warning: DRIVERS_VIRTIO_NET_QUEUE_LEN (defined at drivers/virtio/Kconfig:42) 
has 'help' but empty help text
   warning: NET_USRSOCK_UDP (defined at net/usrsock/Kconfig:41) has 'help' but 
empty help text
   libs/libc/machine/Kconfig:209: warning: style: quotes recommended around 
'libs/libc/machine/sparc/Kconfig' in 'source libs/libc/machine/sparc/Kconfig'
   warning: the hex symbol TTY_LAUNCH_STACKSIZE (defined at 
drivers/serial/Kconfig:201) has a non-hex default INIT_STACKSIZE (defined at 
sched/Kconfig:338)
   warning: the choice symbol ARCH_DEBUG_H (defined at Kconfig:559) is selected 
by the following symbols, but select/imply has no effect on choice symbols
- AVR_HAS_MEMX_PTR (defined at arch/avr/src/avr/Kconfig:63)
   warning: the choice symbol GD32F4_FLASH_CONFIG_K (defined at 
arch/arm/src/gd32f4/Kconfig:105) is selected by the following symbols, but 
select/imply has no effect on choice symbols
- GD32F450ZK_EVAL_CONSOLE_BOARD (defined at 
boards/arm/gd32f4/gd32f450zk-eval/Kconfig:35)
   warning: the default selection IMXRT_PROVIDES_TXC (undefined) of  
(defined at arch/arm/src/imxrt/Kconfig:1777) is not contained in the choice
   warning: the choice symbol TIVA_UART2 (defined at 
arch/arm/src/tiva/Kconfig:798) is selected by the following symbols, but 
select/imply has no effect on choice symbols
- TM4C1294_LAUNCHPAD_JUMPERS_CAN (defined at 
boards/arm/tiva/tm4c1294-launchpad/Kconfig:75)
   warning: the choice symbol NRF52_LFCLK_XTAL (defined at 
arch/arm/src/nrf52/Kconfig:304) is selected by the following symbols, but 
select/imply has no effect on choice symbols
- NRF52_SOFTDEVICE_CONTROLLER (defined at arch/arm/src/nrf52/Kconfig:661)
   warning: the default selection SAMA5_ADC_PWMTRIG_LINE0 (undefined) of 
 (defined at arch/arm/src/sama5/Kconfig:4416) is not contained in the 
choice
   warning: the default selection Z180_NO_SERIAL_CONSOLE (undefined) of 
 (defined at arch/z80/src/z180/Kconfig:534) is not contained in the 
choice
   warning: the default selection EZ80_ZDSII_V522 (undefined) of  
(defined at arch/z80/src/z8/Kconfig:53) is not contained in the choice
   warning: the choice symbol BOOT_RUNFROMEXTSRAM (defined at 
arch/Kconfig:1126) is selected by the following symbols, but select/imply has 
no effect on choice symbols
- IMX6_BOOT_SRAM (defined at arch/arm/src/imx6/Kconfig:194)
- IMXRT_BOOT_SRAM (defined at arch/arm/src/imxrt/Kconfig:1907)
- EZ80_PROGRAM (defined at arch/z80/src/ez80/Kconfig:96)
- Z20X_COPYTORAM (defined at boards/z80/ez80/z20x/Kconfig:47)
   warning: the choice symbol BOOT_RUNFROMFLASH (defined at arch/Kconfig:1131) 
is selected by the following symbols, but select/imply has no effect on choice 

  1   2   >