[GitHub] [nuttx] xiaoxiang781216 commented on pull request #9138: libc/string: select arch's libc for kernel/userspace optionally
xiaoxiang781216 commented on PR #9138: URL: https://github.com/apache/nuttx/pull/9138#issuecomment-1550784058 @mu578 but all possible combination(4) are valid and useful. -- 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/02: libc/string: prevent libc in the kernel/userspace optionally
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 58e97e521c9ef38851dccab84c6313c04aaa95d8 Author: Tiago Medicci Serrano AuthorDate: Fri Apr 28 13:55:23 2023 -0300 libc/string: prevent libc in the kernel/userspace optionally Add the `LIBC_PREVENT_STRING_KERNEL` and `LIBC_PREVENT_STRING_USER` that are meant to be selected by the chip if no libc implementation is going to be built. If selected, neither NuttX's software version of the libc nor any architecture-specific implementation will be built in the kernel or in the userspace, respectively. In this case, the linker may provide a ROM-defined version of the libc functions instead. --- libs/libc/Makefile | 1 + libs/libc/libc.h | 30 ++ libs/libc/machine/Kconfig| 24 +++ libs/libc/machine/arm/armv7-a/gnu/arch_memchr.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_memcpy.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_memset.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_strlen.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_memchr.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_memcpy.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_memset.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_strcpy.S | 5 +++ libs/libc/machine/arm/armv7-m/gnu/arch_strlen.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_memchr.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_memcpy.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_memset.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_strlen.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_memchr.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_memcpy.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_memset.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_strlen.S | 6 +++ libs/libc/machine/arm64/gnu/arch_memchr.S| 6 +++ libs/libc/machine/arm64/gnu/arch_memcmp.S| 6 +++ libs/libc/machine/arm64/gnu/arch_memcpy.S| 6 +++ libs/libc/machine/arm64/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm64/gnu/arch_memset.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strchr.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strchrnul.S | 6 +++ libs/libc/machine/arm64/gnu/arch_strcmp.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strcpy.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strlen.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strncmp.S | 6 +++ libs/libc/machine/arm64/gnu/arch_strnlen.S | 6 +++ libs/libc/machine/arm64/gnu/arch_strrchr.S | 6 +++ libs/libc/machine/risc-v/gnu/arch_memcpy.S | 10 + libs/libc/machine/risc-v/gnu/arch_memset.S | 6 +++ libs/libc/machine/risc-v/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/xtensa/arch_memcpy.S | 6 +++ libs/libc/machine/xtensa/arch_memmove.S | 6 +++ libs/libc/machine/xtensa/arch_memset.S | 6 +++ libs/libc/machine/xtensa/arch_strcmp.S | 5 +++ libs/libc/machine/xtensa/arch_strcpy.S | 6 +++ libs/libc/machine/xtensa/arch_strlen.S | 6 +++ libs/libc/machine/xtensa/arch_strncpy.S | 6 +++ libs/libc/string/Make.defs | 52 ++-- libs/libc/string/lib_memchr.c| 4 ++ libs/libc/string/lib_memcmp.c| 4 +- libs/libc/string/lib_memcpy.c| 4 +- libs/libc/string/lib_memmove.c | 4 +- libs/libc/string/lib_memset.c| 4 +- libs/libc/string/lib_strcasecmp.c| 4 +- libs/libc/string/lib_strcat.c| 4 +- libs/libc/string/lib_strchr.c| 4 +- libs/libc/string/lib_strchrnul.c | 4 +- libs/libc/string/lib_strcmp.c| 4 +- libs/libc/string/lib_strcpy.c| 4 +- libs/libc/string/lib_strlcat.c | 4 +- libs/libc/string/lib_strlcpy.c | 4 +- libs/libc/string/lib_strlen.c| 4 +- libs/libc/string/lib_strncasecmp.c | 4 +- libs/libc/string/lib_strncat.c | 4 +- libs/libc/string/lib_strncmp.c | 4 +- libs/libc/string/lib_strncpy.c | 4 +- libs/libc/string/lib_strnlen.c
[nuttx] 02/02: arch/xtensa/esp32_esp32s3: prevent arch's libc in the userspace
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 496a77653a57845c660d0e3758d92f7c4cfd6adf Author: Tiago Medicci Serrano AuthorDate: Wed May 3 15:30:20 2023 -0300 arch/xtensa/esp32_esp32s3: prevent arch's libc in the userspace ESP32 and ESP32-S3 should use the ROM-defined versions of the libc in flat build and, when building the protected mode, in the kernel. The ROM-defined version of the libc functions can't be used in the userspace, however, because it isn't allowed to access the memory region in flash directly from the userspace. That being said, `LIBC_PREVENT_STRING_KERNEL` should be selected to avoid building any implementation of the libc, being the ROM-defined versions linked instead. NuttX's software implemented version of the libc will be built in the userspace. Also, the assembly-defined version of some of the libc functions (`XTENSA_xxx`) may also be selected to be used in the userspace. --- arch/xtensa/Kconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/xtensa/Kconfig b/arch/xtensa/Kconfig index b168f93ea1..48ff80958e 100644 --- a/arch/xtensa/Kconfig +++ b/arch/xtensa/Kconfig @@ -21,6 +21,7 @@ config ARCH_CHIP_ESP32 select ARCH_HAVE_TESTSET select ARCH_HAVE_TEXT_HEAP select ARCH_VECNOTIRQ + select LIBC_PREVENT_STRING_KERNEL select LIBC_ARCH_ATOMIC select LIBC_ARCH_MEMCPY if BUILD_FLAT select LIBC_ARCH_MEMCHR if BUILD_FLAT @@ -83,6 +84,7 @@ config ARCH_CHIP_ESP32S3 select ARCH_HAVE_RESET select ARCH_HAVE_TESTSET select ARCH_VECNOTIRQ + select LIBC_PREVENT_STRING_KERNEL select LIBC_ARCH_MEMCPY if BUILD_FLAT select LIBC_ARCH_MEMCHR if BUILD_FLAT select LIBC_ARCH_MEMCMP if BUILD_FLAT
[nuttx] branch master updated (6be363ff35 -> 496a77653a)
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 6be363ff35 drivers/serial: fix race condition in multi-thread write new 58e97e521c libc/string: prevent libc in the kernel/userspace optionally new 496a77653a arch/xtensa/esp32_esp32s3: prevent arch's libc in the userspace 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/xtensa/Kconfig | 2 + libs/libc/Makefile | 1 + libs/libc/libc.h | 30 ++ libs/libc/machine/Kconfig| 24 +++ libs/libc/machine/arm/armv7-a/gnu/arch_memchr.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_memcpy.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_memset.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/arm/armv7-a/gnu/arch_strlen.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_memchr.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_memcpy.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_memset.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/arm/armv7-m/gnu/arch_strcpy.S | 5 +++ libs/libc/machine/arm/armv7-m/gnu/arch_strlen.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_memchr.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_memcpy.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_memset.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/arm/armv7-r/gnu/arch_strlen.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_memchr.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_memcpy.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_memset.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/arm/armv8-m/gnu/arch_strlen.S | 6 +++ libs/libc/machine/arm64/gnu/arch_memchr.S| 6 +++ libs/libc/machine/arm64/gnu/arch_memcmp.S| 6 +++ libs/libc/machine/arm64/gnu/arch_memcpy.S| 6 +++ libs/libc/machine/arm64/gnu/arch_memmove.S | 6 +++ libs/libc/machine/arm64/gnu/arch_memset.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strchr.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strchrnul.S | 6 +++ libs/libc/machine/arm64/gnu/arch_strcmp.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strcpy.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strlen.S| 6 +++ libs/libc/machine/arm64/gnu/arch_strncmp.S | 6 +++ libs/libc/machine/arm64/gnu/arch_strnlen.S | 6 +++ libs/libc/machine/arm64/gnu/arch_strrchr.S | 6 +++ libs/libc/machine/risc-v/gnu/arch_memcpy.S | 10 + libs/libc/machine/risc-v/gnu/arch_memset.S | 6 +++ libs/libc/machine/risc-v/gnu/arch_strcmp.S | 6 +++ libs/libc/machine/xtensa/arch_memcpy.S | 6 +++ libs/libc/machine/xtensa/arch_memmove.S | 6 +++ libs/libc/machine/xtensa/arch_memset.S | 6 +++ libs/libc/machine/xtensa/arch_strcmp.S | 5 +++ libs/libc/machine/xtensa/arch_strcpy.S | 6 +++ libs/libc/machine/xtensa/arch_strlen.S | 6 +++ libs/libc/machine/xtensa/arch_strncpy.S | 6 +++ libs/libc/string/Make.defs | 52 ++-- libs/libc/string/lib_memchr.c| 4 ++ libs/libc/string/lib_memcmp.c| 4 +- libs/libc/string/lib_memcpy.c| 4 +- libs/libc/string/lib_memmove.c | 4 +- libs/libc/string/lib_memset.c| 4 +- libs/libc/string/lib_strcasecmp.c| 4 +- libs/libc/string/lib_strcat.c| 4 +- libs/libc/string/lib_strchr.c| 4 +- libs/libc/string/lib_strchrnul.c | 4 +- libs/libc/string/lib_strcmp.c| 4 +- libs/libc/string/lib_strcpy.c| 4 +- libs/libc/string/lib_strlcat.c | 4 +- libs/libc/string/lib_strlcpy.c | 4 +- libs/libc/string/lib_strlen.c| 4 +- libs/libc/string/lib_strncasecmp.c | 4 +- libs/libc/string/lib_strncat.c | 4 +- libs/libc/string/lib_strncmp.c | 4 +- libs/libc/string/lib_strncpy.c | 4 +- libs/libc/string/lib_strnlen.c | 4 +- libs/libc/string/lib_strrchr.c | 4 +-
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9138: libc/string: select arch's libc for kernel/userspace optionally
xiaoxiang781216 merged PR #9138: URL: https://github.com/apache/nuttx/pull/9138 -- 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] btashton commented on a diff in pull request #9287: usbhost: Make unplugging hubs more reliable.
btashton commented on code in PR #9287: URL: https://github.com/apache/nuttx/pull/9287#discussion_r1195974689 ## drivers/usbhost/usbhost_hub.c: ## @@ -1491,7 +1521,7 @@ static int usbhost_disconnected(struct usbhost_class_s *hubclass) { Review Comment: Is this correct for powered hubs? They will be disconnected, but will remain powered in this case. Should instead we place a disconnect on the work queue and then have the work item traverse the tree starting from leafs and working back to the root of the disconnect? -- 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] lupyuen commented on a diff in pull request #9304: arm64/pinephone: Add driver for PinePhone LTE Modem (Quectel EG25-G)
lupyuen commented on code in PR #9304: URL: https://github.com/apache/nuttx/pull/9304#discussion_r1195973988 ## boards/arm64/a64/pinephone/Kconfig: ## @@ -17,4 +17,10 @@ config PINEPHONE_LCD ---help--- Select to enable support for LCD Display. +config PINEPHONE_MODEM + bool "LTE Modem" + default n + ---help--- + Select to enable support for Quectel EG25-G LTE Modem. Review Comment: Thanks let me take a look again. The last time I searched, I found AT Commands referenced in 2 places: - [uart_lorawan_layer.c](https://github.com/apache/nuttx-apps/blob/master/examples/tcp_ipc_server/uart_lorawan_layer.c#L262-L274) - [esp8266.c](https://github.com/apache/nuttx-apps/blob/master/netutils/esp8266/esp8266.c#L1573-L1582) -- 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 (23ad4700a9 -> 6be363ff35)
This is an automated email from the ASF dual-hosted git repository. jerpelea pushed a change to branch master in repository https://gitbox.apache.org/repos/asf/nuttx.git from 23ad4700a9 drivers/serial/pty.c: Fix coverity issue add 6be363ff35 drivers/serial: fix race condition in multi-thread write No new revisions were added by this update. Summary of changes: arch/z80/src/ez80/ez80_serial.c| 2 -- arch/z80/src/z180/z180_scc.c | 6 arch/z80/src/z8/z8_serial.c| 4 --- boards/z80/z80/z80sim/src/z80_serial.c | 2 -- drivers/serial/serial.c| 60 -- include/nuttx/serial/serial.h | 2 -- 6 files changed, 21 insertions(+), 55 deletions(-)
[GitHub] [nuttx] jerpelea merged pull request #9292: drivers/serial: fix race condition in multi-thread write
jerpelea merged PR #9292: URL: https://github.com/apache/nuttx/pull/9292 -- 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 a diff in pull request #9304: arm64/pinephone: Add driver for PinePhone LTE Modem (Quectel EG25-G)
xiaoxiang781216 commented on code in PR #9304: URL: https://github.com/apache/nuttx/pull/9304#discussion_r1195969655 ## boards/arm64/a64/pinephone/Kconfig: ## @@ -17,4 +17,10 @@ config PINEPHONE_LCD ---help--- Select to enable support for LCD Display. +config PINEPHONE_MODEM + bool "LTE Modem" + default n + ---help--- + Select to enable support for Quectel EG25-G LTE Modem. Review Comment: There are some in drivers/modem, but I am not sure where the common driver interface exists or not. It will be good additional to unify the interface between apps and all possible modem hardware. -- 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 pull request #1755: nshlib: Add support for disabling echoback
xiaoxiang781216 commented on PR #1755: URL: https://github.com/apache/nuttx-apps/pull/1755#issuecomment-1550774421 @takumiando could you fetch the latest master, rebase your change and push again? CI break is fixed. -- 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: examples/foc: improve the readability of the motor structures
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 111e02dbd examples/foc: improve the readability of the motor structures 111e02dbd is described below commit 111e02dbdbac00280c2160ebeaec53579764a72f Author: raiden00pl AuthorDate: Tue May 16 12:49:30 2023 +0200 examples/foc: improve the readability of the motor structures --- examples/foc/foc_motor_b16.h | 77 examples/foc/foc_motor_f32.h | 77 2 files changed, 100 insertions(+), 54 deletions(-) diff --git a/examples/foc/foc_motor_b16.h b/examples/foc/foc_motor_b16.h index 0c0e238ed..5b660bf83 100644 --- a/examples/foc/foc_motor_b16.h +++ b/examples/foc/foc_motor_b16.h @@ -66,31 +66,41 @@ struct foc_setpoint_b16_s struct foc_motor_b16_s { + /* App data ***/ + FAR struct foc_ctrl_env_s*envp; /* Thread env */ + struct foc_mq_s mq; /* MQ data */ bool fault;/* Fault flag */ bool startstop;/* Start/stop request */ -#ifdef CONFIG_EXAMPLES_FOC_HAVE_OPENLOOP - bool openloop_now; /* Open-loop now */ - b16_t angle_ol; /* Phase angle open-loop */ - foc_angle_b16_t openloop; /* Open-loop angle handler */ -#endif -#ifdef CONFIG_EXAMPLES_FOC_HAVE_HALL - char hldpath[32]; /* Hall devpath */ - foc_angle_b16_t hall; /* Hall angle handler */ -#endif -#ifdef CONFIG_EXAMPLES_FOC_HAVE_QENCO - char qedpath[32]; /* Qenco devpath */ - foc_angle_b16_t qenco;/* Qenco angle handler */ -#endif - int foc_mode; /* FOC mode */ + int ctrl_state; /* Controller state */ #ifdef CONFIG_EXAMPLES_FOC_HAVE_RUN int foc_mode_run; /* FOC mode for run state */ #endif - int ctrl_state; /* Controller state */ + + /* FOC data ***/ + + struct foc_state_b16_sfoc_state;/* FOC controller sate */ + foc_handler_b16_t handler; /* FOC controller */ + dq_frame_b16_tdq_ref; /* DQ reference */ + dq_frame_b16_tvdq_comp; /* DQ voltage compensation */ + int foc_mode; /* FOC mode */ b16_t vbus; /* Power bus voltage */ + b16_t per; /* Controller period in seconds */ + b16_t iphase_adc; /* Iphase ADC scaling factor */ + b16_t pwm_duty_max; /* PWM duty max */ + + /* Velocity controller data ***/ + + struct foc_ramp_b16_s ramp; /* Velocity ramp data */ + + /* Motor state / + b16_t angle_now;/* Phase angle now */ b16_t angle_m; /* Motor mechanical angle */ b16_t angle_el; /* Motor electrical angle */ + + /* Motor setpoints / + #ifdef CONFIG_EXAMPLES_FOC_HAVE_TORQ struct foc_setpoint_b16_s torq; /* Torque setpoint */ #endif @@ -101,16 +111,9 @@ struct foc_motor_b16_s struct foc_setpoint_b16_s pos; /* Position setpoint */ #endif b16_t dir; /* Motor's direction */ - b16_t per; /* Controller period in seconds */ - b16_t iphase_adc; /* Iphase ADC scaling factor */ - b16_t pwm_duty_max; /* PWM duty max */ - uint8_t poles;/* Motor poles */ - dq_frame_b16_tdq_ref; /* DQ reference */ - dq_frame_b16_tvdq_comp; /* DQ voltage compensation */ - foc_handler_b16_t handler; /* FOC controller */ - struct foc_mq_s mq; /* MQ data */ - struct foc_state_b16_sfoc_state;/* FOC controller sate */ - struct foc_ramp_b16_s ramp; /* Velocity ramp data */ + + /* Motor routines */ + #ifdef CONFIG_EXAMPLES_FOC_HAVE_ALIGN struct foc_routine_b16_s align;/* Alignment routine */ bool align_done; /* Alignment done */ @@ -120,9 +123,29 @@ struct foc_motor_b16_s struct motor_phy_params_b16_s phy_ident;/* Motor phy from ident */ bool
[GitHub] [nuttx-apps] xiaoxiang781216 merged pull request #1757: examples/foc: improve the readability of the motor structures
xiaoxiang781216 merged PR #1757: URL: https://github.com/apache/nuttx-apps/pull/1757 -- 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: drivers/serial/pty.c: Fix coverity issue
This is an automated email from the ASF dual-hosted git repository. jerpelea 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 23ad4700a9 drivers/serial/pty.c: Fix coverity issue 23ad4700a9 is described below commit 23ad4700a9464a6a625d46243ceb3a694f560399 Author: Huang Qi AuthorDate: Wed May 17 09:29:07 2023 +0800 drivers/serial/pty.c: Fix coverity issue Coverity report that `ntotal` may be a negative value. Signed-off-by: Huang Qi --- drivers/serial/pty.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/serial/pty.c b/drivers/serial/pty.c index 3db349cf4d..249bb1a584 100644 --- a/drivers/serial/pty.c +++ b/drivers/serial/pty.c @@ -471,7 +471,7 @@ static ssize_t pty_read(FAR struct file *filep, FAR char *buffer, size_t len) ntotal = file_read(>pd_src, buffer, len); } - if (dev->pd_lflag & ECHO) + if ((dev->pd_lflag & ECHO) && (ntotal > 0)) { pty_write(filep, buffer, ntotal); }
[GitHub] [nuttx] jerpelea merged pull request #9305: drivers/serial/pty.c: Fix coverity issue
jerpelea merged PR #9305: URL: https://github.com/apache/nuttx/pull/9305 -- 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] btashton merged pull request #1758: nshlib: fix memory leak found out by -fanalyzer
btashton merged PR #1758: URL: https://github.com/apache/nuttx-apps/pull/1758 -- 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] btashton merged pull request #1759: add fdsan unit test
btashton merged PR #1759: URL: https://github.com/apache/nuttx-apps/pull/1759 -- 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: nshlib: fix memory leak found out by -fanalyzer
This is an automated email from the ASF dual-hosted git repository. btashton 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 28973a37b nshlib: fix memory leak found out by -fanalyzer 28973a37b is described below commit 28973a37b356d1a688fd603b2cfcfb07ce409c57 Author: chao an AuthorDate: Tue May 16 17:39:35 2023 +0800 nshlib: fix memory leak found out by -fanalyzer Signed-off-by: chao an --- nshlib/nsh_ddcmd.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/nshlib/nsh_ddcmd.c b/nshlib/nsh_ddcmd.c index dea661408..1d25b2ad7 100644 --- a/nshlib/nsh_ddcmd.c +++ b/nshlib/nsh_ddcmd.c @@ -391,7 +391,7 @@ int cmd_dd(FAR struct nsh_vtbl_s *vtbl, int argc, FAR char **argv) ret = dd_infopen(infile, ); if (ret < 0) { - goto errout_with_paths; + goto errout_with_alloc; } /* Open the output file */ @@ -475,6 +475,8 @@ errout_with_outf: errout_with_inf: close(dd.infd); + +errout_with_alloc: free(dd.buffer); errout_with_paths:
[nuttx-apps] branch master updated: add fdsan unit test
This is an automated email from the ASF dual-hosted git repository. btashton 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 aea9b50dc add fdsan unit test aea9b50dc is described below commit aea9b50dc8efc8f1b3d206eeb53ff36073d1364d Author: hujun5 AuthorDate: Mon May 8 20:40:39 2023 +0800 add fdsan unit test Due to the current Nuttx not supporting death test, we removed death test from the original test cases of Android Signed-off-by: hujun5 --- testing/fdsantest/Kconfig| 27 +++ testing/fdsantest/Make.defs | 23 ++ testing/fdsantest/Makefile | 32 + testing/fdsantest/fdsantest_simple.c | 134 +++ 4 files changed, 216 insertions(+) diff --git a/testing/fdsantest/Kconfig b/testing/fdsantest/Kconfig new file mode 100644 index 0..97d82510c --- /dev/null +++ b/testing/fdsantest/Kconfig @@ -0,0 +1,27 @@ +# +# For a description of the syntax of this configuration file, +# see the file kconfig-language.txt in the NuttX tools repository. +# + +config TESTING_FDSAN_TEST + tristate "vela cmocka fdsan test" + default n + depends on TESTING_CMOCKA + ---help--- + Enable the cmocka fdsan test + +if TESTING_FDSAN_TEST + +config TESTING_FDSAN_TEST_PRIORITY + int "Task priority" + default 100 + +config TESTING_FDSAN_TEST_STACKSIZE + int "Stack size" + default DEFAULT_TASK_STACKSIZE + +config TESTING_FDSAN_TEST_SIMPLE + bool "Enable cmocka fdsan simple test" + default y + +endif diff --git a/testing/fdsantest/Make.defs b/testing/fdsantest/Make.defs new file mode 100644 index 0..3cab033df --- /dev/null +++ b/testing/fdsantest/Make.defs @@ -0,0 +1,23 @@ + +# apps/testing/fdsantest/Make.defs +# +# 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. +# + + +ifneq ($(CONFIG_TESTING_FDSAN_TEST),) +CONFIGURED_APPS += $(APPDIR)/testing/fdsantest +endif diff --git a/testing/fdsantest/Makefile b/testing/fdsantest/Makefile new file mode 100644 index 0..3dc7f4a12 --- /dev/null +++ b/testing/fdsantest/Makefile @@ -0,0 +1,32 @@ + +# apps/testing/fdsantest/Makefile +# +# 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. +# + + +include $(APPDIR)/Make.defs + +PRIORITY = $(CONFIG_TESTING_FDSAN_TEST_PRIORITY) +STACKSIZE = $(CONFIG_TESTING_FDSAN_TEST_STACKSIZE) +MODULE= $(CONFIG_TESTING_FDSAN_TEST) + +ifneq ($(CONFIG_TESTING_FDSAN_TEST_SIMPLE),) +MAINSRC += fdsantest_simple.c +PROGNAME += cmocka_fdsan_simple +endif + +include $(APPDIR)/Application.mk diff --git a/testing/fdsantest/fdsantest_simple.c b/testing/fdsantest/fdsantest_simple.c new file mode 100644 index 0..4f8c802e6 --- /dev/null +++ b/testing/fdsantest/fdsantest_simple.c @@ -0,0 +1,134 @@ +/ + * apps/testing/fdsantest/fdsantest_simple.c + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for
[GitHub] [nuttx] lywind opened a new pull request, #9307: Fix windows compile errors because of double quotes in config
lywind opened a new pull request, #9307: URL: https://github.com/apache/nuttx/pull/9307 The "CONFIG_APPS_DIR" generated in .config has double quotes and is not recognized as a path by most make systems. This commits removes these double quotes to make the compile successfully. ## Summary The "CONFIG_APPS_DIR" generated in .config has double quotes. For example, by default "CONFIG_APPS_DIR" is: CONFIG_APPS_DIR="../apps" And thus when the make system expands "$(CONFIG_APPS_DIR)\Makefile", it will expand as "../apps"\Makefile And this path is not recognized by most make systems in windows (The make.exe in GnuWin32 recognizes this kind of path, but this program is quite out dated and tend to have other problems) and will result the APPDIR to be empty and thus the whole apps directory will not be built. ## Impact * The build system when "CONFIG_WINDOWS_NATIVE=y" is defined. ## Testing * sim:ostest * s32k144evb -- 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] btashton commented on pull request #9204: fdt: Add initial FDT support and procfs for userspace export
btashton commented on PR #9204: URL: https://github.com/apache/nuttx/pull/9204#issuecomment-1550762515 So I do not forget. The boot spec that qemu uses matches Linux understanding for arm64, so the address to the dtb should be in the `x0` register for arm64 https://github.com/torvalds/linux/blob/v6.3/Documentation/arm64/booting.rst?plain=1#L162 `r2`for arm https://github.com/torvalds/linux/blob/v6.3/Documentation/arm/booting.rst?plain=1#L194 -- 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] btashton opened a new issue, #9306: docs: Sphinx warnings to be fixed up
btashton opened a new issue, #9306: URL: https://github.com/apache/nuttx/issues/9306 Creating an issue so I dont forget to circle back to these. Ignore the `Duplicate C declaration` warnings as they are a known deficiency in Sphinx that has not been resolved upstream. - [ ] nuttx/Documentation/platforms/sim/sim/boards/sim/index.rst:370: CRITICAL: Unexpected section title. - [ ] nuttx/Documentation/platforms/sim/sim/boards/sim/index.rst:394: CRITICAL: Unexpected section title. - [ ] nuttx/Documentation/platforms/sim/sim/boards/sim/index.rst:1494: ERROR: Inconsistent literal block quoting. - [ ] nuttx/Documentation/platforms/sim/sim/boards/sim/index.rst:1569: WARNING: Literal block expected; none found. - [ ] nuttx/Documentation/platforms/xtensa/esp32s2/boards/esp32s2-kaluga-1/index.rst:207: WARNING: download file not readable: /home/runner/work/nuttx/nuttx/Documentation/platforms/xtensa/esp32s2/boards/esp32s2-kaluga-1/tone.wav - [ ] nuttx/Documentation/guides/zerolatencyinterrupts.rst: WARNING: document isn't included in any toctree - [ ] nuttx/Documentation/reference/os/newreno.rst: WARNING: document isn't included in any toctree -- 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.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
[GitHub] [nuttx] btashton commented on pull request #9297: virtio: add virtio framework in NuttX
btashton commented on PR #9297: URL: https://github.com/apache/nuttx/pull/9297#issuecomment-1550743722 I am very interested in this PR, but do not let my review hold this up since I likely wont have time to give it a detailed review for a few days. -- 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] btashton opened a new pull request, #1760: CI: set-output command is deprecated
btashton opened a new pull request, #1760: URL: https://github.com/apache/nuttx-apps/pull/1760 ## Summary CI currently runs with the warning: The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/ ## Testing Passing CI should be sufficient to verify we are still pulling the correct source references for the two repos. -- 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] hujun260 opened a new pull request, #1759: add fdsan unit test
hujun260 opened a new pull request, #1759: URL: https://github.com/apache/nuttx-apps/pull/1759 ## Summary Add fdsan unit test. Due to the current Nuttx not supporting death test, we removed death test from the original test cases of Android ## Impact none ## Testing none -- 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] zhang-2019 commented on pull request #9057: dma support 16550 uart
zhang-2019 commented on PR #9057: URL: https://github.com/apache/nuttx/pull/9057#issuecomment-1550601969 I have rebased to the last commit, please review -- 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] lupyuen commented on a diff in pull request #9304: arm64/pinephone: Add driver for PinePhone LTE Modem (Quectel EG25-G)
lupyuen commented on code in PR #9304: URL: https://github.com/apache/nuttx/pull/9304#discussion_r1195863100 ## boards/arm64/a64/pinephone/Kconfig: ## @@ -17,4 +17,10 @@ config PINEPHONE_LCD ---help--- Select to enable support for LCD Display. +config PINEPHONE_MODEM + bool "LTE Modem" + default n + ---help--- + Select to enable support for Quectel EG25-G LTE Modem. Review Comment: Sorry I need to do some research to see how the SoC can support other modems. I don't believe NuttX has a modem interface today? -- 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] lupyuen commented on a diff in pull request #9304: arm64/pinephone: Add driver for PinePhone LTE Modem (Quectel EG25-G)
lupyuen commented on code in PR #9304: URL: https://github.com/apache/nuttx/pull/9304#discussion_r1195862416 ## Documentation/platforms/arm/a64/boards/pinephone/index.rst: ## @@ -155,6 +155,13 @@ Supports all the features in ``lcd``, plus LVGL Graphics Library and Touch Panel (GT917S). Serial Console is enabled on UART0 at 115.2 kbps. +modem +- + +Supports LTE Modem (EG25-G). Accepts AT Commands on UART3 +at ``/dev/ttyS1``. Review Comment: Unfortunately UARTx won't match ttySx on PinePhone. Here are the upcoming UART ports: - UART0 (ttyS0): Serial Console - UART1 (ttyS1): Bluetooth Module (Realtek RTL8723CS, not integrated with NuttX yet) - UART2: Unused, wired to Light Sensor and Compass Sensor - UART3 (ttyS2): LTE Modem (Quectel EG25-G, integrated with NuttX) [More details here](https://lupyuen.github.io/articles/serial#appendix-uart-ports-on-pinephone) I could modify `modem/defconfig` to enable UART1 on ttyS1 (Bluetooth). But UART3 will always map to ttyS2 (LTE Modem) because UART2 is unused. Shall I make this change? Thanks. -- 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 (81bdb97536 -> e1096bd35c)
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 81bdb97536 libc/misc: add fdsan api doc add e1096bd35c libc/regex: add regex implementation No new revisions were added by this update. Summary of changes: LICENSE | 32 + include/regex.h | 104 + libs/libc/Makefile |1 + {arch/arm/src/a1x => libs/libc/regex}/Make.defs | 15 +- libs/libc/regex/regcomp.c | 4036 +++ libs/libc/regex/regerror.c | 92 + libs/libc/regex/regexec.c | 1267 +++ libs/libc/regex/tre-mem.c | 194 ++ libs/libc/regex/tre.h | 288 ++ 9 files changed, 6022 insertions(+), 7 deletions(-) create mode 100644 include/regex.h copy {arch/arm/src/a1x => libs/libc/regex}/Make.defs (79%) create mode 100644 libs/libc/regex/regcomp.c create mode 100644 libs/libc/regex/regerror.c create mode 100644 libs/libc/regex/regexec.c create mode 100644 libs/libc/regex/tre-mem.c create mode 100644 libs/libc/regex/tre.h
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9284: nuttx/libs/libc: add regex implementation
xiaoxiang781216 merged PR #9284: URL: https://github.com/apache/nuttx/pull/9284 -- 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 (242127556c -> 81bdb97536)
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 242127556c Documentation: Add "High Performance, Zero Latency Interrupts" add 90387a5b41 libc/misc: add fdsan module add 81bdb97536 libc/misc: add fdsan api doc No new revisions were added by this update. Summary of changes: Documentation/reference/user/10_filesystem.rst | 56 +++ fs/inode/fs_files.c| 8 + fs/vfs/fs_ioctl.c | 17 ++ include/android/fdsan.h| 190 +++ include/nuttx/fs/fs.h | 3 + include/nuttx/fs/ioctl.h | 12 ++ libs/libc/dirent/lib_closedir.c| 15 ++ libs/libc/dirent/lib_opendir.c | 12 ++ libs/libc/misc/Kconfig | 6 + libs/libc/misc/Make.defs | 6 + libs/libc/misc/lib_fdsan.c | 206 + libs/libc/stdio/lib_fclose.c | 11 ++ libs/libc/stdio/lib_fopen.c| 10 ++ 13 files changed, 552 insertions(+) create mode 100644 include/android/fdsan.h create mode 100644 libs/libc/misc/lib_fdsan.c
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9260: libc/misc: add Fdsan module
xiaoxiang781216 merged PR #9260: URL: https://github.com/apache/nuttx/pull/9260 -- 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 a diff in pull request #9303: Nucleo watchdog
xiaoxiang781216 commented on code in PR #9303: URL: https://github.com/apache/nuttx/pull/9303#discussion_r1195859242 ## boards/arm/stm32h7/nucleo-h743zi2/src/stm32_bringup.c: ## @@ -96,6 +96,21 @@ int stm32_bringup(void) } #endif +#ifdef CONFIG_STM32_IWDG + /* Initialize the watchdog timer */ + + stm32_iwdginitialize("/dev/watchdog0", STM32_LSI_FREQUENCY); Review Comment: @slorquet you can try the built-in watchdog monitor instead: https://github.com/apache/nuttx/blob/master/drivers/timers/Kconfig#L395-L464 -- 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 a diff in pull request #9304: arm64/pinephone: Add driver for PinePhone LTE Modem (Quectel EG25-G)
xiaoxiang781216 commented on code in PR #9304: URL: https://github.com/apache/nuttx/pull/9304#discussion_r1195857955 ## boards/arm64/a64/pinephone/Kconfig: ## @@ -17,4 +17,10 @@ config PINEPHONE_LCD ---help--- Select to enable support for LCD Display. +config PINEPHONE_MODEM + bool "LTE Modem" + default n + ---help--- + Select to enable support for Quectel EG25-G LTE Modem. Review Comment: Can we abstract a modem interface? So, the SoC can support the different modem, and the modem can support different SoC. ## Documentation/platforms/arm/a64/boards/pinephone/index.rst: ## @@ -155,6 +155,13 @@ Supports all the features in ``lcd``, plus LVGL Graphics Library and Touch Panel (GT917S). Serial Console is enabled on UART0 at 115.2 kbps. +modem +- + +Supports LTE Modem (EG25-G). Accepts AT Commands on UART3 +at ``/dev/ttyS1``. Review Comment: should we make /dev/ttySx match the datasheet number(UARTx)? -- 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] liqinhuixm commented on a diff in pull request #9295: net: Add the check that socket domain is equal to bound address type, when do bind.
liqinhuixm commented on code in PR #9295: URL: https://github.com/apache/nuttx/pull/9295#discussion_r1195855844 ## net/tcp/tcp_conn.c: ## @@ -1193,6 +1193,15 @@ FAR struct tcp_conn_s *tcp_alloc_accept(FAR struct net_driver_s *dev, int tcp_bind(FAR struct tcp_conn_s *conn, FAR const struct sockaddr *addr) { +#if defined(CONFIG_NET_IPv4) && defined(CONFIG_NET_IPv6) + if (conn->domain != addr->sa_family) +{ + nerr("ERROR: Invalid address type: %d != %d\n", conn->domain, + addr->sa_family); Review Comment: Done. ## net/udp/udp_conn.c: ## @@ -807,6 +807,15 @@ int udp_bind(FAR struct udp_conn_s *conn, FAR const struct sockaddr *addr) uint16_t portno; int ret; +#if defined(CONFIG_NET_IPv4) && defined(CONFIG_NET_IPv6) + if (conn->domain != addr->sa_family) +{ + nerr("ERROR: Invalid address type: %d != %d\n", conn->domain, + addr->sa_family); Review Comment: 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] zhang-2019 closed pull request #9057: dma support 16550 uart
zhang-2019 closed pull request #9057: dma support 16550 uart URL: https://github.com/apache/nuttx/pull/9057 -- 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 #9292: drivers/serial: fix race condition in multi-thread write
anchao commented on PR #9292: URL: https://github.com/apache/nuttx/pull/9292#issuecomment-1550574117 > Sorry I do not have time this week. I have verify this PR on sim/usbdev, everything works as expected. -- 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] no1wudi opened a new pull request, #9305: drivers/serial/pty.c: Fix coverity issue
no1wudi opened a new pull request, #9305: URL: https://github.com/apache/nuttx/pull/9305 ## Summary Coverity report that `ntotal` may be a negative value. ## Impact Minor ## Testing sim and CI -- 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] lupyuen commented on pull request #9304: arm64/pinephone: Add driver for PinePhone LTE Modem (Quectel EG25-G)
lupyuen commented on PR #9304: URL: https://github.com/apache/nuttx/pull/9304#issuecomment-1550549856 Fixed the UART3 configuration. Sorry about 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
[nuttx-website] branch asf-site updated: Publishing web: b5385572da9781727954ec9d98f5329c0d33acf2 docs: 242127556c27f336f394ab073ecc70ef010fbabd
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 cc240d2f Publishing web: b5385572da9781727954ec9d98f5329c0d33acf2 docs: 242127556c27f336f394ab073ecc70ef010fbabd cc240d2f is described below commit cc240d2f632e9317e5f43f7cf51700b9480eab2f Author: Brennan Ashton AuthorDate: Wed May 17 00:13:35 2023 + Publishing web: b5385572da9781727954ec9d98f5329c0d33acf2 docs: 242127556c27f336f394ab073ecc70ef010fbabd --- 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/12.1.0/index.html | 2 +- content/docs/12.1.0/searchindex.js | 2 +- content/docs/latest/_images/NXOrganization.gif | Bin 34880 -> 0 bytes content/docs/latest/_images/NXOrganization.png | Bin 0 -> 25180 bytes content/docs/latest/_images/pinout.png | Bin 0 -> 699239 bytes content/docs/latest/_images/pinout.webp| Bin 125938 -> 0 bytes .../_sources/components/nxgraphics/index.rst.txt | 2 +- .../_sources/guides/zerolatencyinterrupts.rst.txt | 249 + .../arm/nrf52/boards/nrf52832-mdk/index.rst.txt| 2 +- .../latest/_sources/reference/os/newreno.rst.txt | 172 + .../docs/latest/components/nxgraphics/index.html | 2 +- .../docs/latest/guides/zerolatencyinterrupts.html | 389 + content/docs/latest/index.html | 2 +- content/docs/latest/objects.inv| Bin 45758 -> 46207 bytes .../arm/nrf52/boards/nrf52832-mdk/index.html | 2 +- content/docs/latest/reference/os/newreno.html | 345 ++ content/docs/latest/searchindex.js | 2 +- content/feed.xml | 4 +- 32 files changed, 1179 insertions(+), 24 deletions(-) diff --git a/content/docs/10.0.0/index.html b/content/docs/10.0.0/index.html index be62ea21..03f52558 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: 16 May 23 at 00:09 +Last Updated: 17 May 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 402f523e..5413a095 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 2da67407..25978d08 100644 ---
[GitHub] [nuttx] lupyuen opened a new pull request, #9304: arm64/pinephone: Add driver for PinePhone LTE Modem (Quectel EG25-G)
lupyuen opened a new pull request, #9304: URL: https://github.com/apache/nuttx/pull/9304 ## Summary This PR adds the PinePhone Driver for Quectel EG25-G LTE Modem. When the driver is started, the LTE Modem accepts AT Commands over UART3 and `/dev/ttyS1`. PinePhone's LTE Modem is explained in [this article](https://lupyuen.github.io/articles/lte). ### New Files in `boards/arm64/a64/pinephone` `src/pinephone_modem.c`, `pinephone_modem.h`: Driver for Quectel EG25-G LTE Modem `configs/modem/defconfig`: New Build Configuration `pinephone:modem` that enables the LTE Modem at UART3 and `/dev/ttyS1` ### Modified Files in `boards/arm64/a64/pinephone` `Kconfig`: Added Kconfig Setting `PINEPHONE_MODEM` to enable the LTE Modem at "Board Selection > Board-Specific Options > LTE Modem" `src/pinephone_bringup.c`: Start the LTE Modem if `PINEPHONE_MODEM` is selected `src/Makefile`: Added LTE Modem Driver to Makefile ### Updated Documentation `platforms/arm/a64/boards/pinephone/index.rst`: Added Build Configuration `pinephone:modem` that enables the LTE Modem ## Impact With this PR, NuttX Apps will be able to control the PinePhone LTE Modem with AT Commands over UART3 and `/dev/ttyS1`. There is no impact on existing code because the driver is not used currently. ## Testing We tested the LTE Modem Driver on PinePhone by sending AT Commands. For Regression Testing, we tested PinePhone with the LTE Modem Driver disabled. ### LTE Modem Test To test the LTE Modem Driver, we selected the `pinephone:modem` Build Configuration: ```bash tools/configure.sh pinephone:modem make ``` We ran a Modem Test App that sends AT Commands to make phone calls and send SMS messages: - [Modem Test App: hello_main.c](https://github.com/lupyuen2/wip-pinephone-nuttx-apps/blob/modem/examples/hello/hello_main.c) [(As explained here)](https://lupyuen.github.io/articles/lte2#send-at-commands) The modem responds correctly to our AT Commands: - [Modem Test Log](https://gist.github.com/lupyuen/b4195155d0899986ab72d955e386fcdb) ### Regression Test For Regression Testing, we selected the `pinephone:lvgl` Build Configuration that disables the LTE Modem: ```bash tools/configure.sh pinephone:lvgl make ``` NuttX boots correctly and starts the LCD Display, with the LTE Modem disabled: - [Regression Test Log](https://gist.github.com/lupyuen/a823283f3adae9f23de02a65cff56940) -- 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] slorquet opened a new pull request, #9303: Nucleo watchdog
slorquet opened a new pull request, #9303: URL: https://github.com/apache/nuttx/pull/9303 ## Summary Add a config to test the stm32h7 watchdog ## Impact None ## Testing Builds and run -- 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] hartmannathan commented on pull request #9302: Documentation: Add "High Performance, Zero Latency Interrupts"
hartmannathan commented on PR #9302: URL: https://github.com/apache/nuttx/pull/9302#issuecomment-1550201552 > Thanks for doing this! My pleasure! I plan to continue doing this, one article at a time, with the other documents that are currently parked in the CWIKI that haven't migrated to Documentation yet. -- 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] ldube commented on a diff in pull request #9287: usbhost: Make unplugging hubs more reliable.
ldube commented on code in PR #9287: URL: https://github.com/apache/nuttx/pull/9287#discussion_r1195572019 ## drivers/usbhost/usbhost_hub.c: ## @@ -1491,7 +1521,7 @@ static int usbhost_disconnected(struct usbhost_class_s *hubclass) { Review Comment: @xiaoxiang781216 I think agree with you now and will not use the flag. I am beginning to question my approach. Doing this : CLASS_DISCONNECTED(child->devclass) does not free the other device types quickly. Only hubs are freed immediately. I have to do it your way: CLASS_DISCONNECTED(child->devclass, true) to make it clean. But all the other drivers will have to be modified so ... I am thinking of finding another way to fix the problem. I have done some testing and so far only hubs crash the system when their parent is freed first. After I find out why, I will decide 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
[nuttx] branch master updated (f61dc72892 -> 242127556c)
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 f61dc72892 net/tcp:Add NewReno congestion control. add 242127556c Documentation: Add "High Performance, Zero Latency Interrupts" No new revisions were added by this update. Summary of changes: Documentation/guides/zerolatencyinterrupts.rst | 249 + 1 file changed, 249 insertions(+) create mode 100644 Documentation/guides/zerolatencyinterrupts.rst
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9302: Documentation: Add "High Performance, Zero Latency Interrupts"
xiaoxiang781216 merged PR #9302: URL: https://github.com/apache/nuttx/pull/9302 -- 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] mu578 commented on issue #9298: Signal must be masked when it is delivered to a signal handler
mu578 commented on issue #9298: URL: https://github.com/apache/nuttx/issues/9298#issuecomment-1550138175 You write faster that I can read (I have a slow morning today). Yes about priority handling, not particularly just for signal API, it is always nice to have. Anyway, in a general context, any item which is enqueued should be considered read-only ; it could be handled with a private bitset ; because if something is marked deferred ; it should not be possible to externally change it (user). -- 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] hartmannathan opened a new pull request, #9302: Documentation: Add "High Performance, Zero Latency Interrupts"
hartmannathan opened a new pull request, #9302: URL: https://github.com/apache/nuttx/pull/9302 ## Summary Add the document "High Performance, Zero Latency Interrupts"; until now, this was found only in the [CWIKI](https://cwiki.apache.org/confluence/display/NUTTX/High+Performance%2C+Zero+Latency+Interrupts). Converted from CWIKI to reStructuredText. ## Impact Improves NuttX documentation. Will appear on the website after CI, and therefore will be easier for users to find. ## Testing None. -- 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] tmedicci opened a new issue, #9301: Interdependencies errors on CI
tmedicci opened a new issue, #9301: URL: https://github.com/apache/nuttx/issues/9301 The job https://github.com/apache/nuttx/actions/runs/4993159615/jobs/8941973789?pr=9138#step:7:448 shows an error while refreshing the `arty_a7:netnsh` defconfig. This very same error happens while trying to build the master branch (OS: f61dc72892, APPS: 70a4010635): ``` make -j distclean && ./tools/configure.sh arty_a7:netnsh Copy files Select CONFIG_HOST_LINUX=y Refreshing... CP: arch/dummy/Kconfig to /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/arch/dummy/dummy_kconfig CP: boards/dummy/Kconfig to /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/boards/dummy/dummy_kconfig LN: platform/board to /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/platform/dummy LN: include/arch to arch/risc-v/include LN: include/arch/board to /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/boards/risc-v/litex/arty_a7/include LN: drivers/platform to /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/drivers/dummy LN: include/arch/chip to /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/arch/risc-v/include/litex LN: arch/risc-v/src/chip to /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/arch/risc-v/src/litex LN: arch/risc-v/src/board to /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/nuttx/boards/risc-v/litex/arty_a7/src mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/audioutils mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/benchmarks mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/boot mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/canutils mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/crypto mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/examples/mcuboot mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/examples mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/fsutils mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/games mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/gpsutils mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/graphics mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/industry mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/interpreters/luamodules mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/interpreters mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/logging mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/math mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/mlearning mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/netutils mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/sdr mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/system mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/testing mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/wireless/bluetooth mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/wireless/ieee802154 mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/wireless mkkconfig in /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps Loaded configuration '.config' Configuration saved to '.config' warning: LIBC_FLOATINGPOINT (defined at libs/libc/stdio/Kconfig:55) has direct dependencies !LIBM_NONE with value n, but is currently being y-selected by the following symbols: - NETUTILS_IPERF (defined at /home/tiago/Documents/work/espressif/projects/nuttx/nuttxspace/apps/netutils/iperf/Kconfig:6), with value y, direct dependencies NET (value: y), and select condition NET (value: y) make: *** [tools/Unix.mk:663: olddefconfig] Error 1 ERROR: failed to refresh ``` I couldn't find any recent change to the `Kconfig`s that define those symbols. My guess: CI's machine was not using `kconfiglib` and was updated recently. -- 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.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org
[GitHub] [nuttx] patacongo commented on pull request #9299: Signal must be masked when it is delivered to a signal handler
patacongo commented on PR #9299: URL: https://github.com/apache/nuttx/pull/9299#issuecomment-1550062895 I believe that this is a correct and complete change as submitted. However, there are other unrelated issues that could make this unreliable. See #9300 -- 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 a diff in pull request #9287: usbhost: Make unplugging hubs more reliable.
xiaoxiang781216 commented on code in PR #9287: URL: https://github.com/apache/nuttx/pull/9287#discussion_r1195459866 ## drivers/usbhost/usbhost_hub.c: ## @@ -1491,7 +1521,7 @@ static int usbhost_disconnected(struct usbhost_class_s *hubclass) { Review Comment: If so, can we call usbhost_disconnect_event directly instead setting no_delay flag. -- 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] patacongo opened a new pull request, #9299: Signal must be masked when it is delivered to a signal handler
patacongo opened a new pull request, #9299: URL: https://github.com/apache/nuttx/pull/9299 ## Summary Signal must be masked when it is delivered to a signal handler per: > https://pubs.opengroup.org/onlinepubs/007904875/functions/sigaction.html: > > When a signal is caught by a signal-catching function installed by sigaction(), a new signal mask is calculated and installed for the duration of the signal-catching function (or until a call to either sigprocmask() or sigsuspend() is made). This mask is formed by taking the union of the current signal mask and the value of the sa_mask for the signal being delivered [XSI] [Option Start] unless SA_NODEFER or SA_RESETHAND is set, [Option End] and then including the signal being delivered. If and when the user's signal handler returns normally, the original signal mask is restored. Any action queued for that signal while the signal is masked should be deferred. It should go into the group pending signal list and should not be processed until until the signal is unmasked (which should occur when the signal handler returns). See Issue #9298 ## Impact - Follows POSIX more closely - Probably has little effect because sa_mask typically does mask the signal explicitly - Probably does not effect re-entrancy of the signal handler because that is protected by other means. ## Testing sim:ostest -- 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] CV-Bowen opened a new pull request, #9297: virtio: add virtio framework in NuttX
CV-Bowen opened a new pull request, #9297: URL: https://github.com/apache/nuttx/pull/9297 ## Summary 1. virtio devics/drivers match and probe/remote mechanism; 2. virtio mmio transport layer based on OpenAmp; 3. virtio-serial driver based on new virtio framework; 4. virtio-rng driver based on new virtio framework; 5. virtio-net driver based on new virtio framework (IOB Offload implementation); 6. virtio-blk driver based on new virtio framework; 7. Remove the old virtio mmio framework, the old framework only support mmio transport layer, and the new framwork support more transport layer and this commit has implemented all the old virtio drivers; 8. Refresh the the qemu-arm64 and qemu-riscv virtio related configs, and update its README.txt; TODO: should update the openamp also. ## Impact The qemu-arm64 and qemu-rv board ## Testing Local test with qmeu-arm64, qemu-rv board 1. test virtio-net with iperf, ping, telnet; 2. test virtio-blk with dd command; 3. test virtio-rand with rand example; 4. test virtio-serial with linux telnet; -- 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] ldube commented on a diff in pull request #9287: usbhost: Make unplugging hubs more reliable.
ldube commented on code in PR #9287: URL: https://github.com/apache/nuttx/pull/9287#discussion_r1195388713 ## drivers/usbhost/usbhost_hub.c: ## @@ -1491,7 +1521,7 @@ static int usbhost_disconnected(struct usbhost_class_s *hubclass) { Review Comment: I think we should restrict the change to this file because "no_delay" does not make sense for other drivers. Queuing works well in most cases. The exception is the hub driver which needs the ability to free many devices recursively. When CLASS_DISCONNECTED is called **within** the hub driver, we know we are running a thread. I set the flag to skip the queue and allow recursion to happen in this case. Hubs are a special case and I don't know if there is a reason to do this in other drivers. Eventually, only the hub driver should manage the connection/disconnection of devices. We are not there yet. Right now every host controller driver (HCD) is also a root hub driver. That is why they all call CLASS_DISCONNECTED too. We need to embed some hub descriptors in the OS and write some glue code to make the root hub look like a real hub and use usbhost_hub as its driver. This would remove all the CLASS_DISCONNECTED calls from the all the HCDs. -- 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: net/tcp:Add NewReno congestion control.
This is an automated email from the ASF dual-hosted git repository. acassis 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 f61dc72892 net/tcp:Add NewReno congestion control. f61dc72892 is described below commit f61dc728927b1c61ccbb277cee08fdbb3a8df8b7 Author: liqinhui AuthorDate: Thu Apr 20 11:08:02 2023 +0800 net/tcp:Add NewReno congestion control. - NewReno congestion control algorithm is used to solve the problem of network congestion breakdown. NewReno congestion control includes slow start, collision avoidance, fast retransmission, and fast recovery. The implementation refers to RFC6582 and RFC5681. - In addition, we optimize the congestion algorithm. In the conflict avoidance stage, the maximum congestion window max_cwnd is used to limit the excessive growth of cwnd and prevent network jitter caused by congestion. Maximum congestion window max_cwnd is updated with the current congestion window cwnd and the update weight is 0.875 when an RTO timeout occurs. Signed-off-by: liqinhui --- Documentation/reference/os/newreno.rst | 172 +++ net/tcp/Kconfig| 9 + net/tcp/Make.defs | 6 + net/tcp/tcp.h | 85 +- net/tcp/tcp_cc.c | 301 + net/tcp/tcp_conn.c | 12 ++ net/tcp/tcp_input.c| 11 ++ net/tcp/tcp_send_buffered.c| 40 - net/tcp/tcp_timer.c| 19 +++ net/tcp/tcp_wrbuffer.c | 2 +- 10 files changed, 652 insertions(+), 5 deletions(-) diff --git a/Documentation/reference/os/newreno.rst b/Documentation/reference/os/newreno.rst new file mode 100644 index 00..7f238e5a60 --- /dev/null +++ b/Documentation/reference/os/newreno.rst @@ -0,0 +1,172 @@ +== +Congestion Control NewReno +== + +NewReno congestion control algorithm is used to solve the problem of network congestion breakdown, which includes: + - Slow Start + - Congestion Avoidance + - Fast Retransmission + - Fast Recovery. + + The implementation refers to RFC6582 and RFC5681. In addition, we optimize the congestion algorithm. In the congestion avoidance state, the maximum congestion window (max_cwnd) is used to limit the excessive growth of cwnd and prevent network jitter caused by congestion. Maximum congestion window (max_cwnd) is updated with the current congestion window (cwnd) and the update weight is 0.875 when an RTO timeout occurs. + +Workflow + + + +The NewReno on the tcp sender adjusts the cwnd and ssthresh based on received ack and Retransmitted Timeout (RTO) events. + +Using the cwnd, together with snd_wnd, controls the number of bytes sent to the network. Here's how newreno works, as following: + +- Initialize the ssthresh and cwnd, on establishing the tcp connection. +- When the ack is received, check whether the ack is repeated. + + + If yes, increase the dupack counts. If the dupack exceeds the Fast Retransmission Threshold 3, after retransmitting the lost segments (Fast Retransmission), enter to the Fast Recovery state. + + If no, receive the new ack. + + * If the current ackno is bigger than fr_ack which is the snd_seq when Fast Retransmission ocurrs, exit the Fast Recovery state and enter to congestion avoidance. + * If the cwnd is less than ssthresh, increase the cwnd on slow start state. + * If the cwnd is greater than or equal to ssthresh, the increased cwnd can not exceed max_cwnd. + +- when RTO times out, reset the values of cwnd and ssthresh, update the max_cwnd, and enter to Slow Start state. +- When sending a segment, the minimum value of cwnd and snd_wnd is used to calculate the number of bytes that can be sent. + +The simple state transition diagram of the NewReno is shown below. + +:: + +| ^ +| +| initialize cwnd ssthresh +V + ++ + .--->| Slow Start |-. + |++ | + | | | | + |timeout | | recv dup ack| recv new ack + |-- | | --- | + |reset cwnd ssthresh | | dupack >= 3 | cwnd >= ssthresh + |update max_cwnd | | fr_ack = snd_seq| + |<' |<--. | + || | | + |
[GitHub] [nuttx] acassis merged pull request #9262: Add NewReno congestion control.
acassis merged PR #9262: URL: https://github.com/apache/nuttx/pull/9262 -- 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] davids5 commented on pull request #9292: drivers/serial: fix race condition in multi-thread write
davids5 commented on PR #9292: URL: https://github.com/apache/nuttx/pull/9292#issuecomment-1549906080 > > Does that use CDCACM? > > @davids5 emm ... I don't have real hardware for CDCACM yet, could you please help to verify this PR? Sorry I do not have time this week. -- 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 (26361ee1d2 -> 7a8cf7ff70)
This is an automated email from the ASF dual-hosted git repository. acassis pushed a change to branch master in repository https://gitbox.apache.org/repos/asf/nuttx.git from 26361ee1d2 tools/nuttx-gdbinit/armv7-a: add fpu support add 7a8cf7ff70 Indent the include statement by two spaces No new revisions were added by this update. Summary of changes: arch/arm/src/dm320/dm320_uart.h| 2 +- arch/arm/src/lpc17xx_40xx/lpc17_40_can.c | 12 ++-- arch/avr/include/arch.h| 4 ++-- arch/avr/include/irq.h | 4 ++-- arch/avr/include/limits.h | 4 ++-- arch/avr/include/types.h | 4 ++-- arch/avr/src/common/avr_internal.h | 4 ++-- arch/hc/include/irq.h | 4 ++-- arch/hc/include/limits.h | 4 ++-- arch/hc/include/types.h| 4 ++-- arch/mips/include/irq.h| 2 +- arch/misoc/include/irq.h | 4 ++-- arch/risc-v/src/bl602/bl602_start.c| 2 +- arch/sim/src/sim/sim_deviceimage.c | 22 +++--- arch/sparc/include/irq.h | 2 +- arch/sparc/src/common/sparc_internal.h | 2 +- arch/x86/include/arch.h| 4 ++-- arch/x86/include/io.h | 2 +- arch/x86/include/limits.h | 2 +- arch/x86/include/types.h | 2 +- arch/x86_64/include/arch.h | 4 ++-- arch/x86_64/include/io.h | 2 +- arch/x86_64/include/irq.h | 2 +- arch/x86_64/include/limits.h | 2 +- arch/x86_64/include/types.h| 2 +- boards/arm/gd32f4/gd32f450zk-eval/include/board.h | 2 +- boards/arm/kinetis/freedom-k28f/include/board.h| 6 +++--- boards/arm/kinetis/kwikstik-k40/include/board.h| 2 +- boards/arm/kinetis/teensy-3.x/include/board.h | 4 ++-- boards/arm/kinetis/twr-k60n512/include/board.h | 2 +- boards/arm/kinetis/twr-k64f120m/include/board.h| 2 +- boards/arm/kl/freedom-kl25z/include/board.h| 2 +- boards/arm/kl/freedom-kl26z/include/board.h| 2 +- boards/arm/kl/teensy-lc/include/board.h| 2 +- boards/arm/lpc31xx/ea3131/include/board.h | 4 ++-- boards/arm/lpc31xx/ea3152/include/board.h | 4 ++-- .../arm/lpc31xx/olimex-lpc-h3131/include/board.h | 4 ++-- boards/arm/nuc1xx/nutiny-nuc120/include/board.h| 2 +- boards/arm/phy62xx/phy6222/include/board.h | 2 +- .../rp2040/adafruit-feather-rp2040/include/board.h | 2 +- boards/arm/rp2040/adafruit-kb2040/include/board.h | 2 +- .../rp2040/adafruit-qt-py-rp2040/include/board.h | 2 +- .../arm/rp2040/pimoroni-tiny2040/include/board.h | 2 +- .../arm/rp2040/raspberrypi-pico-w/include/board.h | 2 +- boards/arm/rp2040/raspberrypi-pico/include/board.h | 2 +- .../waveshare-rp2040-lcd-1.28/include/board.h | 2 +- boards/arm/stm32/cloudctrl/include/board.h | 2 +- boards/arm/stm32/et-stm32-stamp/include/board.h| 2 +- boards/arm/stm32/fire-stm32v2/include/board.h | 2 +- boards/arm/stm32/maple/include/board.h | 2 +- boards/arm/stm32/mikroe-stm32f4/include/board.h| 2 +- boards/arm/stm32/nucleo-f410rb/include/board.h | 2 +- boards/arm/stm32/nucleo-f412zg/include/board.h | 2 +- boards/arm/stm32/nucleo-f429zi/include/board.h | 2 +- boards/arm/stm32/nucleo-f446re/include/board.h | 2 +- boards/arm/stm32/nucleo-f4x1re/include/board.h | 2 +- .../stm32/nucleo-f4x1re/include/nucleo-f401re.h| 2 +- .../stm32/nucleo-f4x1re/include/nucleo-f411re.h| 2 +- boards/arm/stm32/olimex-stm32-h405/include/board.h | 2 +- boards/arm/stm32/olimex-stm32-p107/include/board.h | 2 +- boards/arm/stm32/olimex-stm32-p207/include/board.h | 2 +- boards/arm/stm32/olimex-stm32-p407/include/board.h | 2 +- boards/arm/stm32/olimexino-stm32/include/board.h | 2 +- boards/arm/stm32/shenzhou/include/board.h | 2 +- boards/arm/stm32/stm3220g-eval/include/board.h | 2 +- boards/arm/stm32/stm3240g-eval/include/board.h | 2 +- boards/arm/stm32/stm32_tiny/include/board.h| 2 +- boards/arm/stm32/stm32butterfly2/include/board.h | 2 +- .../arm/stm32/stm32f103-minimum/src/stm32_hyt271.c | 2 +- boards/arm/stm32/stm32f3discovery/include/board.h | 2 +- boards/arm/stm32/stm32f411-minimum/include/board.h | 2 +- boards/arm/stm32/stm32f411e-disco/include/board.h | 2 +- boards/arm/stm32/stm32f429i-disco/include/board.h | 2 +- boards/arm/stm32/stm32ldiscovery/include/board.h | 2 +- boards/arm/stm32/stm32vldiscovery/include/board.h | 2 +- .../include/board-stm32f103vct6.h | 2 +-
[GitHub] [nuttx] acassis merged pull request #9267: Indent the include statement by two spaces
acassis merged PR #9267: URL: https://github.com/apache/nuttx/pull/9267 -- 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] acassis commented on a diff in pull request #9287: usbhost: Make unplugging hubs more reliable.
acassis commented on code in PR #9287: URL: https://github.com/apache/nuttx/pull/9287#discussion_r1195350305 ## drivers/usbhost/usbhost_hub.c: ## @@ -1513,10 +1543,20 @@ static int usbhost_disconnected(struct usbhost_class_s *hubclass) work_cancel(LPWORK, >work); - /* Schedule the disconnection work */ + if (priv->no_delay) +{ + /* Disconnect immediately */ - ret = work_queue(LPWORK, >work, + usbhost_disconnect_event(hubclass); +} + else +{ + /* Schedule the disconnection work */ + + ret = work_queue(LPWORK, >work, usbhost_disconnect_event, hubclass, 0); Review Comment: ```suggestion usbhost_disconnect_event, hubclass, 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] acassis commented on a diff in pull request #9295: net: Add the check that socket domain is equal to bound address type, when do bind.
acassis commented on code in PR #9295: URL: https://github.com/apache/nuttx/pull/9295#discussion_r1195343334 ## net/tcp/tcp_conn.c: ## @@ -1193,6 +1193,15 @@ FAR struct tcp_conn_s *tcp_alloc_accept(FAR struct net_driver_s *dev, int tcp_bind(FAR struct tcp_conn_s *conn, FAR const struct sockaddr *addr) { +#if defined(CONFIG_NET_IPv4) && defined(CONFIG_NET_IPv6) + if (conn->domain != addr->sa_family) +{ + nerr("ERROR: Invalid address type: %d != %d\n", conn->domain, + addr->sa_family); Review Comment: ```suggestion addr->sa_family); ## net/udp/udp_conn.c: ## @@ -807,6 +807,15 @@ int udp_bind(FAR struct udp_conn_s *conn, FAR const struct sockaddr *addr) uint16_t portno; int ret; +#if defined(CONFIG_NET_IPv4) && defined(CONFIG_NET_IPv6) + if (conn->domain != addr->sa_family) +{ + nerr("ERROR: Invalid address type: %d != %d\n", conn->domain, + addr->sa_family); Review Comment: ```suggestion addr->sa_family); -- 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] mu578 commented on pull request #9138: libc/string: select arch's libc for kernel/userspace optionally
mu578 commented on PR #9138: URL: https://github.com/apache/nuttx/pull/9138#issuecomment-1549817140 Maybe you should enforce an explicit LIBC_ARCH_BUILD_SHARED instead of defaulting. -- 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] tmedicci commented on a diff in pull request #9138: libc/string: select arch's libc for kernel/userspace optionally
tmedicci commented on code in PR #9138: URL: https://github.com/apache/nuttx/pull/9138#discussion_r1195243859 ## libs/libc/libc.h: ## @@ -53,6 +55,12 @@ #define LIB_BUFLEN_UNKNOWN INT_MAX +#if defined(CONFIG_BUILD_FLAT) || \ +((!defined(CONFIG_LIBC_PREVENT_STRING_USER) && !defined(__KERNEL__)) || \ + (!defined(CONFIG_LIBC_PREVENT_STRING_KERNEL) && defined(__KERNEL__))) +# define LIBC_BUILD_FUNCTION Review Comment: 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] anchao commented on pull request #9292: drivers/serial: fix race condition in multi-thread write
anchao commented on PR #9292: URL: https://github.com/apache/nuttx/pull/9292#issuecomment-1549758216 > Does that use CDCACM? @davids5 emm ... I don't have real hardware for CDCACM yet, could you please help to verify 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
[GitHub] [nuttx] xiaoxiang781216 commented on a diff in pull request #9103: arch/riscv: Fixed FPU register error
xiaoxiang781216 commented on code in PR #9103: URL: https://github.com/apache/nuttx/pull/9103#discussion_r1195185751 ## arch/risc-v/src/common/riscv_macros.S: ## @@ -227,8 +222,15 @@ REGLOAD t0, REG_INT_CTX(\out) li t1, MSTATUS_FS and t2, t0, t1 - li t1, MSTATUS_FS_INIT - ble t2, t1, 1f + li t1, MSTATUS_FS_DIRTY + bne t2, t1, 1f + + /* Reset FS bit to MSTATUS_FS_CLEAN */ + li t1, MSTATUS_FS_CLEAN Review Comment: Ok, let's wait your result. -- 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 (eb47312518 -> 26361ee1d2)
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 eb47312518 netdev_upper: Protect quota by spin lock to allow netpkt_xxx be called in interrupt context add 26361ee1d2 tools/nuttx-gdbinit/armv7-a: add fpu support No new revisions were added by this update. Summary of changes: tools/nuttx-gdbinit | 76 +++-- 1 file changed, 39 insertions(+), 37 deletions(-)
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9234: tools/nuttx-gdbinit/armv7-a: add fpu support
xiaoxiang781216 merged PR #9234: URL: https://github.com/apache/nuttx/pull/9234 -- 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 #9057: dma support 16550 uart
xiaoxiang781216 commented on PR #9057: URL: https://github.com/apache/nuttx/pull/9057#issuecomment-1549696373 > I have resolved all the confilcts, please review please fetch the last main and rebase your change to remove the merge commit from 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 (36591af615 -> eb47312518)
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 36591af615 net/rpmsg: initialize semaphore count before wait add eb47312518 netdev_upper: Protect quota by spin lock to allow netpkt_xxx be called in interrupt context No new revisions were added by this update. Summary of changes: drivers/net/netdev_upperhalf.c | 65 ++ 1 file changed, 53 insertions(+), 12 deletions(-)
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9293: netdev_upper: Protect quota by spin lock to allow netpkt_xxx be called in interrupt context
xiaoxiang781216 merged PR #9293: URL: https://github.com/apache/nuttx/pull/9293 -- 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] davids5 commented on pull request #9292: drivers/serial: fix race condition in multi-thread write
davids5 commented on PR #9292: URL: https://github.com/apache/nuttx/pull/9292#issuecomment-1549682285 > Yes, I verify this change on our real product(Cortex-M55/Cortex-A7(SMP 2 Core)) Does that use CDCACM? -- 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 #9284: nuttx/libs/libc: add regex implementation
xiaoxiang781216 commented on PR #9284: URL: https://github.com/apache/nuttx/pull/9284#issuecomment-1549620628 Another fix the issue from https://github.com/apache/nuttx/pull/9294 -- 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, #1758: nshlib: fix memory leak found out by -fanalyzer
anchao opened a new pull request, #1758: URL: https://github.com/apache/nuttx-apps/pull/1758 ## Summary nshlib: fix memory leak found out by -fanalyzer ```bash nsh_ddcmd.c: In function ‘cmd_dd’: nsh_ddcmd.c:492:1: warning: leak of ‘dd.buffer’ [CWE-401] [-Wanalyzer-malloc-leak] 492 | } | ^ ‘cmd_dd’: events 1-14 | | 294 | int cmd_dd(FAR struct nsh_vtbl_s *vtbl, int argc, FAR char **argv) | | ^~ | | | | | (1) entry to ‘cmd_dd’ |.. | 334 | for (i = 1; i < argc; i++) | | | | | | | (2) following ‘true’ branch (when ‘i < argc’)... | 335 | { | 336 | if (strncmp(argv[i], "if=", 3) == 0) | | ~~ | | || | | |(3) ...to here | | (4) following ‘true’ branch... | 337 | { | 338 | if (infile != NULL) | | ~ | | | | | (5) ...to here | | (6) following ‘false’ branch (when ‘infile’ is NULL)... |.. | 343 | infile = nsh_getfullpath(vtbl, [i][3]); | | ~~~ | | | | | (7) ...to here |.. | 373 | if (infile == NULL || outfile == NULL) | | ~ | | | | | (8) following ‘false’ branch... |.. | 382 | dd.buffer = malloc(dd.sectsize); | | ~~~ | | || | | |(9) ...to here | | (10) allocated here | 383 | if (!dd.buffer) | | ~ | | | | | (11) assuming ‘dd.buffer’ is non-NULL | | (12) following ‘false’ branch... |.. | 391 | ret = dd_infopen(infile, ); | | ~~~ | | | | | (13) ...to here | | (14) calling ‘dd_infopen’ from ‘cmd_dd’ | +--> ‘dd_infopen’: events 15-17 | | 158 | static inline int dd_infopen(FAR const char *name, FAR struct dd_s *dd) | | ^~ | | | | | (15) entry to ‘dd_infopen’ |.. | 161 | if (dd->infd < 0) | | ~ | | | | | (16) following ‘true’ branch... | 162 | { | 163 | FAR struct nsh_vtbl_s *vtbl = dd->vtbl; | | | | | | | (17) ...to here | <--+ | ‘cmd_dd’: events 18-25 | | 391 | ret = dd_infopen(infile, ); | | ^~~ | | | | | (18) returning to ‘cmd_dd’ from ‘dd_infopen’ | 392 | if (ret < 0) | | ~ | | | | | (19) following ‘true’ branch (when ‘ret < 0’)... | 393 | { | 394 | goto errout_with_paths; | | | | | | | (20) ...to here |.. | 481 | if (infile) | | ~ | | | | | (21) following ‘true’ branch (when ‘infile’ is non-NULL)... | 482 | { | 483 | nsh_freefullpath(infile); | | | | | | | (22) ...to here |.. | 486 | if (outfile) | | ~ | | | | | (23) following ‘false’ branch (when ‘outfile’ is NULL)... |.. | 491 | return ret; | | ~~~ | | | | | (24) ...to here | 492 | } | | ~ | | | | | (25) ‘dd.buffer’ leaks here; was allocated at (10) | ``` ## Impact N/A ## 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:
[GitHub] [nuttx] anchao commented on pull request #9292: drivers/serial: fix race condition in multi-thread write
anchao commented on PR #9292: URL: https://github.com/apache/nuttx/pull/9292#issuecomment-1549472094 > @anchao Did you test this on real HW? Did you test the CDCACM driver, and ensure the lead/lag on connect/disconnect was handled? I.E Data sent in connected state, then disconnected etc Yes, I verify this change on our real product(Cortex-M55/Cortex-A7(SMP 2 Core)) -- 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] raiden00pl opened a new pull request, #1757: examples/foc: improve the readability of the motor structures
raiden00pl opened a new pull request, #1757: URL: https://github.com/apache/nuttx-apps/pull/1757 ## Summary examples/foc: improve the readability of the motor structures ## Impact Purely cosmetic change ## Testing CI -- 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 opened a new pull request, #9296: arch: Save sigdeliver into xcp in the case of signal self delevery
xiaoxiang781216 opened a new pull request, #9296: URL: https://github.com/apache/nuttx/pull/9296 ## Summary to avoid the infinite recusive dispatch: ``` *0 myhandler (signo=27, info=0xf3e38b9c, context=0x0) at ltp/testcases/open_posix_testsuite/conformance/interfaces/sigqueue/7-1.c:39 *1 0x58f1c39e in nxsig_deliver (stcb=0xf4e20f40) at signal/sig_deliver.c:167 *2 0x58fa0664 in up_schedule_sigaction (tcb=0xf4e20f40, sigdeliver=0x58f1bab5 ) at sim/sim_schedulesigaction.c:88 *3 0x58f19907 in nxsig_queue_action (stcb=0xf4e20f40, info=0xf4049334) at signal/sig_dispatch.c:115 *4 0x58f1b089 in nxsig_tcbdispatch (stcb=0xf4e20f40, info=0xf4049334) at signal/sig_dispatch.c:435 *5 0x58f31853 in nxsig_unmask_pendingsignal () at signal/sig_unmaskpendingsignal.c:104 *6 0x58f1ca09 in nxsig_deliver (stcb=0xf4e20f40) at signal/sig_deliver.c:199 *7 0x58fa0664 in up_schedule_sigaction (tcb=0xf4e20f40, sigdeliver=0x58f1bab5 ) at sim/sim_schedulesigaction.c:88 *8 0x58f19907 in nxsig_queue_action (stcb=0xf4e20f40, info=0xf4049304) at signal/sig_dispatch.c:115 *9 0x58f1b089 in nxsig_tcbdispatch (stcb=0xf4e20f40, i nfo=0xf4049304) at signal/sig_dispatch.c:435 *10 0x58f31853 in nxsig_unmask_pendingsignal () at signal/sig_unmaskpendingsignal.c:104 *11 0x58f1ca09 in nxsig_deliver (stcb=0xf4e20f40) at signal/sig_deliver.c:199 *12 0x58fa0664 in up_schedule_sigaction (tcb=0xf4e20f40, sigdeliver=0x58f1bab5 ) at sim/sim_schedulesigaction.c:88 *13 0x58f19907 in nxsig_queue_action (stcb=0xf4e20f40, info=0xf40492d4) at signal/sig_dispatch.c:115 *14 0x58f1b089 in nxsig_tcbdispatch (stcb=0xf4e20f40, info=0xf40492d4) at signal/sig_dispatch.c:435 *15 0x58f31853 in nxsig_unmask_pendingsignal () at signal/sig_unmaskpendingsignal.c:104 *16 0x58f1ca09 in nxsig_deliver (stcb=0xf4e20f40) at signal/sig_deliver.c:199 *17 0x58fa0664 in up_schedule_sigaction (tcb=0xf4e20f40, sigdeliver=0x58f1bab5 ) at sim/sim_schedulesigaction.c:88 *18 0x58f19907 in nxsig_queue_action (stcb=0xf4e20f40, info=0xf40492a4) at signal/sig_dispatch.c:115 *19 0x58f1b089 in nxsig_tcbdispatch (stcb=0xf4e20f40, info =0xf40492a4) at signal/sig_dispatch.c:435 *20 0x58f31853 in nxsig_unmask_pendingsignal () at signal/sig_unmaskpendingsignal.c:104 *21 0x58f1ca09 in nxsig_deliver (stcb=0xf4e20f40) at signal/sig_deliver.c:199 *22 0x58fa0664 in up_schedule_sigaction (tcb=0xf4e20f40, sigdeliver=0x58f1bab5 ) at sim/sim_schedulesigaction.c:88 *23 0x58f19907 in nxsig_queue_action (stcb=0xf4e20f40, info=0xf4049274) at signal/sig_dispatch.c:115 *24 0x58f1b089 in nxsig_tcbdispatch (stcb=0xf4e20f40, info=0xf4049274) at signal/sig_dispatch.c:435 *25 0x58f31853 in nxsig_unmask_pendingsignal () at signal/sig_unmaskpendingsignal.c:104 *26 0x58f1ca09 in nxsig_deliver (stcb=0xf4e20f40) at signal/sig_deliver.c:199 *27 0x58fa0664 in up_schedule_sigaction (tcb=0xf4e20f40, sigdeliver=0x58f1bab5 ) at sim/sim_schedulesigaction.c:88 *28 0x58f19907 in nxsig_queue_action (stcb=0xf4e20f40, info=0xf4049244) at signal/sig_dispatch.c:115 *29 0x58f1b089 in nxsig_tcbdispatch (stcb=0xf4e20f40, info=0x f4049244) at signal/sig_dispatch.c:435 *30 0x58f31853 in nxsig_unmask_pendingsignal () at signal/sig_unmaskpendingsignal.c:104 *31 0x58f1ca09 in nxsig_deliver (stcb=0xf4e20f40) at signal/sig_deliver.c:199 ``` ## Impact signal send to self ## Testing https://github.com/linux-test-project/ltp/blob/master/testcases/open_posix_testsuite/conformance/interfaces/signal/7-1.c -- 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] davids5 commented on pull request #9292: drivers/serial: fix race condition in multi-thread write
davids5 commented on PR #9292: URL: https://github.com/apache/nuttx/pull/9292#issuecomment-1549348546 @anchao Did you test this on real HW? Did you test the CDCACM driver, and ensure the lead/lag on connect/disconnect was handled? I.E Data sent in connected state, then disconnected etc -- 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: net/rpmsg: initialize semaphore count before wait
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 36591af615 net/rpmsg: initialize semaphore count before wait 36591af615 is described below commit 36591af61594a105b78af259a20a1b385c514c53 Author: chao an AuthorDate: Mon May 15 14:26:51 2023 +0800 net/rpmsg: initialize semaphore count before wait recvmsg() will incorrectly return 0 if the count of sema before waiting is greater than 0, This commit will reinitialize the sema count before waiting: 1181 static ssize_t rpmsg_socket_recvmsg(FAR struct socket *psock, 1182 FAR struct msghdr *msg, int flags) 1183 { ... 1255 ret = net_sem_timedwait(>recvsem, 1256 _SO_TIMEOUT(conn->sconn.s_rcvtimeo)); // recvsem.sem_count == 1; return 0 ... 1264 if (!conn->recvdata) // recvdata not consumed; goto else 1265 { 1266 ret = conn->recvlen; 1267 } 1268 else 1269 { 1270 conn->recvdata = NULL; 1271 } ... 1282 return ret;// BUGON! incorrectly return 0 to user 1283 } Signed-off-by: chao an --- net/rpmsg/rpmsg_sockif.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/net/rpmsg/rpmsg_sockif.c b/net/rpmsg/rpmsg_sockif.c index da150f783b..5f54b52c04 100644 --- a/net/rpmsg/rpmsg_sockif.c +++ b/net/rpmsg/rpmsg_sockif.c @@ -342,7 +342,7 @@ static int rpmsg_socket_ept_cb(FAR struct rpmsg_endpoint *ept, } conn->recvdata = NULL; - nxsem_post(>recvsem); + rpmsg_socket_post(>recvsem); } if (len > 0) @@ -1249,6 +1249,7 @@ static ssize_t rpmsg_socket_recvmsg(FAR struct socket *psock, conn->recvdata = buf; conn->recvlen = len; + nxsem_reset(>recvsem, 0); nxmutex_unlock(>recvlock); ret = net_sem_timedwait(>recvsem,
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9290: net/rpmsg: initialize semaphore count before wait
xiaoxiang781216 merged PR #9290: URL: https://github.com/apache/nuttx/pull/9290 -- 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] liqinhuixm commented on pull request #9294: net/udp: Populate the udp connection structure with the address family.
liqinhuixm commented on PR #9294: URL: https://github.com/apache/nuttx/pull/9294#issuecomment-1549293559 The connection domain cannot be modified after the socket is created. -- 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 a diff in pull request #9294: net/udp: Populate the udp connection structure with the address family.
xiaoxiang781216 commented on code in PR #9294: URL: https://github.com/apache/nuttx/pull/9294#discussion_r1194857172 ## net/udp/udp_conn.c: ## @@ -807,6 +807,7 @@ int udp_bind(FAR struct udp_conn_s *conn, FAR const struct sockaddr *addr) uint16_t portno; int ret; + conn->domain = addr->sa_family == AF_INET ? PF_INET : PF_INET6; Review Comment: @g2gps should we return error here like: https://github.com/apache/nuttx/pull/9295? -- 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 (6417ca79ad -> 50cf3d8577)
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 6417ca79ad CI: set-output command is deprecated add 150e5a1a0f sim/posix/backtrace: process host backtrace with critical section add 50cf3d8577 tools/nxstyle: add "_NSGetExecutablePath" into ignore list No new revisions were added by this update. Summary of changes: arch/sim/src/sim/posix/sim_hostmisc.c | 8 +++- tools/nxstyle.c | 6 ++ 2 files changed, 13 insertions(+), 1 deletion(-)
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9291: sim/posix/backtrace: process host backtrace with critical section
xiaoxiang781216 merged PR #9291: URL: https://github.com/apache/nuttx/pull/9291 -- 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] liqinhuixm opened a new pull request, #9295: net: Add the check that socket domain is equal to bound address type, when do bind.
liqinhuixm opened a new pull request, #9295: URL: https://github.com/apache/nuttx/pull/9295 When do socket bind, if the connection domain is not equal to the bound address type, this will cause the stack-buffer-overflow. ## Summary When bind the sockaddr, Check conn->domain and addr->sa_family. If they aren't equal, return an error early. which can avoid the problem of stack buffer overflow. ## Impact Avoid an exception caused by using the bad address on binding. ## Testing When the socket of type AF_INET4, if the sockaddr of type AF_INET6 are used, the bind interface returns an error and does not cause any other exception. -- 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] extinguish commented on pull request #9284: nuttx/libs/libc: add regex implementation
extinguish commented on PR #9284: URL: https://github.com/apache/nuttx/pull/9284#issuecomment-1549230594 the issues that posted in https://github.com/apache/nuttx/pull/9282 is fixed in this new pull request. -- 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] extinguish commented on pull request #9282: nuttx/libs/libc: add regex implementation
extinguish commented on PR #9282: URL: https://github.com/apache/nuttx/pull/9282#issuecomment-1549219224 > I see that you already closed this. However, you need to know this: This is BSD-licenses, third party code and must be handled in a different way from a real, original, Apache contribution. At a minimum you need to: > > * Add the license for the third party code in the LICENSES file for each third party file. > * You must condition building this with CONFIG_ALLOW_BSD_COMPONENTS (https://github.com/apache/nuttx/blob/master/Kconfig#L29) so that the user can avoid contaminating the Apache license. the comments is fixed, and with a new pull request in: https://github.com/apache/nuttx/pull/9284 please to review. thanks -- 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] liqinhuixm commented on pull request #9262: Add NewReno congestion control.
liqinhuixm commented on PR #9262: URL: https://github.com/apache/nuttx/pull/9262#issuecomment-1549192789 > Hi @liqinhuixm please include the summary information in the log message. Please consider transforming this Testing selection in a small user guide at Documentation/ to explain people how to test this NewReno congestion control on NuttX. The newreno.rst file is added in the directory (Documentation/reference/os) to explain this function and how to test 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] liqinhuixm commented on a diff in pull request #9262: Add NewReno congestion control.
liqinhuixm commented on code in PR #9262: URL: https://github.com/apache/nuttx/pull/9262#discussion_r1194771645 ## net/tcp/tcp.h: ## @@ -71,7 +71,7 @@ # define TCP_WBPKTLEN(wrb) ((wrb)->wb_iob->io_pktlen) # define TCP_WBSENT(wrb)((wrb)->wb_sent) # define TCP_WBNRTX(wrb)((wrb)->wb_nrtx) -#ifdef CONFIG_NET_TCP_FAST_RETRANSMIT +#if defined(CONFIG_NET_TCP_FAST_RETRANSMIT) && !defined(CONFIG_NET_TCP_CC_NEWRENO) # define TCP_WBNACK(wrb)((wrb)->wb_nack) Review Comment: Given the independence of the Fast Retransmit and NewReno functions, the wb_nack needs to be temporarily reserved for use when only Fast Retransmit is 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] liqinhuixm commented on a diff in pull request #9262: Add NewReno congestion control.
liqinhuixm commented on code in PR #9262: URL: https://github.com/apache/nuttx/pull/9262#discussion_r1194764628 ## net/tcp/tcp_send_buffered.c: ## @@ -584,6 +584,10 @@ static uint16_t psock_send_eventhandler(FAR struct net_driver_s *dev, } else if (ackno == TCP_WBSEQNO(wrb)) { +#ifdef CONFIG_NET_TCP_CC_NEWRENO + if ((flags & TCP_ACKDATA) != 0 && Review Comment: Remove the condition. 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
[nuttx] branch master updated (9a654b658e -> 6417ca79ad)
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 9a654b658e docs: Generate pdf version of docs for #9095 add 6417ca79ad CI: set-output command is deprecated No new revisions were added by this update. Summary of changes: .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9289: CI: set-output command is deprecated
xiaoxiang781216 merged PR #9289: URL: https://github.com/apache/nuttx/pull/9289 -- 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] liqinhuixm commented on a diff in pull request #9262: Add NewReno congestion control.
liqinhuixm commented on code in PR #9262: URL: https://github.com/apache/nuttx/pull/9262#discussion_r1194763584 ## net/tcp/tcp_cc.c: ## @@ -0,0 +1,293 @@ +/ + * net/tcp/tcp_cc.c + * Handling TCP congestion control + * + * 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 "tcp/tcp.h" + +/ + * Pre-processor Definitions + / + +/* Calculate the Initial Window, also used as Restart Window + * RFC5681 Section 3.1 specifies the default conservative values. + */ + +#define CC_INIT_CWND(cwnd, mss) \ + do { \ + if ((mss) > 2190) \ Review Comment: 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] liqinhuixm commented on a diff in pull request #9262: Add NewReno congestion control.
liqinhuixm commented on code in PR #9262: URL: https://github.com/apache/nuttx/pull/9262#discussion_r1194763177 ## net/tcp/tcp_send_buffered.c: ## @@ -614,11 +619,12 @@ static uint16_t psock_send_eventhandler(FAR struct net_driver_s *dev, /* Do fast retransmit */ rexmitno = ackno; -#endif - +#if !defined(CONFIG_NET_TCP_CC_NEWRENO) Review Comment: done ## net/tcp/tcp_cc.c: ## @@ -0,0 +1,293 @@ +/ + * net/tcp/tcp_cc.c + * Handling TCP congestion control + * + * 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 "tcp/tcp.h" + +/ + * Pre-processor Definitions + / + +/* Calculate the Initial Window, also used as Restart Window + * RFC5681 Section 3.1 specifies the default conservative values. + */ + +#define CC_INIT_CWND(cwnd, mss) \ + do { \ + if ((mss) > 2190) \ +{ \ + (cwnd) = 2 * (mss); \ +} \ + else if ((mss) > 1095) \ Review Comment: 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] zhang-2019 commented on a diff in pull request #9057: dma support 16550 uart
zhang-2019 commented on code in PR #9057: URL: https://github.com/apache/nuttx/pull/9057#discussion_r1194741598 ## drivers/serial/uart_16550.c: ## @@ -1157,25 +1317,198 @@ static bool u16550_rxflowcontrol(struct uart_dev_s *dev, * / -#ifdef CONFIG_SERIAL_TXDMA +#ifdef HAVE_16550_UART_DMA +static void u16550_dmasend_done(FAR struct dma_chan_s *chan, +FAR void *arg, ssize_t len) +{ + FAR struct uart_dev_s *dev = arg; + + if (len > 0) +{ + dev->dmatx.nbytes = len; + uart_xmitchars_done(dev); + uart_xmitchars_dma(dev); +} + else /* Fail, resend */ +{ + u16550_dmasend(dev); +} +} + static void u16550_dmasend(FAR struct uart_dev_s *dev) { + FAR struct u16550_s *priv = dev->priv; + FAR void *buffer = dev->dmatx.buffer; + size_t length = dev->dmatx.length; + + up_clean_dcache((uintptr_t)buffer, (uintptr_t)buffer + length); + DMA_START(priv->chantx, u16550_dmasend_done, dev, +up_addrenv_va_to_pa((void *)priv->uartbase), +up_addrenv_va_to_pa(buffer), length); +} + +static void u16550_dmareceive_done(FAR struct dma_chan_s *chan, + FAR void *arg, ssize_t len) +{ + FAR struct uart_dev_s *dev = arg; + FAR struct u16550_s *priv = dev->priv; + + if (len >= 0) +{ + size_t slot = priv->dmarxhead / priv->dmarxsize; + size_t offset = priv->dmarxhead - slot * priv->dmarxsize; + + if (len >= priv->dmarxsize) +{ + len = 0; +} + if (len < offset) +{ + slot++; /* Wrap, move to the next slot */ +} + + priv->dmarxhead = slot * priv->dmarxsize + len; + if (priv->dmarxhead - priv->dmarxtail >= priv->dmarxsize) +{ + serr("The receive dma buffer is overrun\n"); + priv->dmarxtail = priv->dmarxhead - priv->dmarxsize / 2; +} + + /* The receive isn't in the process? */ + if (dev->dmarx.length == 0) +{ + /* Trigger the receive process */ + uart_recvchars_dma(dev); +} + else +{ + /* Copy the received data */ + u16550_dmareceive(dev); +} +} } -#endif -#ifdef CONFIG_SERIAL_RXDMA static void u16550_dmareceive(FAR struct uart_dev_s *dev) { + FAR struct u16550_s *priv = dev->priv; + + if (priv->dmarxhead != priv->dmarxtail) +{ + size_t length = priv->dmarxhead - priv->dmarxtail; + size_t offset = priv->dmarxtail % priv->dmarxsize; + FAR void *buffer = priv->dmarxbuf + offset; Review Comment: change the type of dmarxbuf from void * to char * would be ok -- 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] zhang-2019 commented on pull request #9057: dma support 16550 uart
zhang-2019 commented on PR #9057: URL: https://github.com/apache/nuttx/pull/9057#issuecomment-1549136539 I have resolved all the confilcts, please review -- 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] g2gps opened a new pull request, #9294: net/udp: Populate the udp connection structure with the address family.
g2gps opened a new pull request, #9294: URL: https://github.com/apache/nuttx/pull/9294 ## Summary The udp connection structure contains the field, "domain", which defines which address family it belongs to. Prior to this change, this field was not populated correctly, and was read as zero in subsequent udp packet processing. As a result, packet information was not processed in udp_recvpktinfo, as expected when the appropriate socket option was enabled. ## Impact Further processing of UDP packets, i.e in `udp_recvpktinfo`, can correctly read the address domain and provide appropriate actions. ## Testing In our application: - We are now able to fetch using `in6_pktinfo` using `recvmsg`. Previously this wasn't possible if only the IPV6 stack was enabled. When both IPV4 and IPV6 was enabled, this wasn't an issue. In NuttX: - Using syslog messages to log the value of the `udp_conn_s::domain` field. -- 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, #9293: netdev_upper: Protect quota by spin lock to allow netpkt_xxx be called in interrupt context
wengzhe opened a new pull request, #9293: URL: https://github.com/apache/nuttx/pull/9293 ## Summary Before `atomic` is ready on every platform, we need a way to protect `quota`, previously it's protected by `net_lock`, but this makes `netpkt_xxx` interfaces unable to be called under interrupt context, so changed to spin lock. Also, we can easily change them into atomic under this implementation. ## Impact netdev_upperhalf (currently only used on sim) ## Testing manually on sim -- 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 a diff in pull request #9252: Add ATSAMA5D2/D4 Secure Fuse Controller (SFC) driver
xiaoxiang781216 commented on code in PR #9252: URL: https://github.com/apache/nuttx/pull/9252#discussion_r1194716367 ## include/nuttx/efuse/sama5_sfc_fuses.h: ## @@ -0,0 +1,247 @@ +/ + * include/nuttx/efuse/sama5_sfc_fuses.h + * + * 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. + * + / + +#ifndef __INCLUDE_NUTTX_EFUSE_SAMA5_FUSES_H +#define __INCLUDE_NUTTX_EFUSE_SAMA5_FUSES_H + +/ + * Pre-processor Definitions + / + +#if defined(ATSAMA5D2) +#define SAM_SFC_EFUSE_MAX_LEN 544/* Max length of sfc area. */ +#elif defined ATSAMA5D4 +#define SAM_SFC_EFUSE_MAX_LEN 512/* Max length of sfc area. */ +#endif + +/ + * Included Files + / + +/ + * Type Definitions + / + +#if defined(CONFIG_EFUSE) && defined(CONFIG_SAMA5_SFC) Review Comment: Ok, look like the designer of efuse want to expose the chip specific info to application. It's strange why design in this way. -- 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: docs: Generate pdf version of docs for #9095
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 9a654b658e docs: Generate pdf version of docs for #9095 9a654b658e is described below commit 9a654b658e6bbf454a00131aa7f4cc5677036a80 Author: Brennan Ashton AuthorDate: Mon May 15 21:04:16 2023 -0700 docs: Generate pdf version of docs for #9095 This implements the changes required to genreate the pdf version of the documentation. The pdf will be generated as a build artifact attached to the build. This is the first patch to enable this a follow on patch to the website repo will publish the pdf to the NuttX website. --- .github/workflows/doc.yml | 14 -- Documentation/components/nxgraphics/NXOrganization.gif | Bin 34880 -> 0 bytes Documentation/components/nxgraphics/NXOrganization.png | Bin 0 -> 25180 bytes Documentation/components/nxgraphics/index.rst | 2 +- Documentation/conf.py | 2 ++ .../platforms/arm/nrf52/boards/nrf52832-mdk/index.rst | 2 +- .../platforms/arm/nrf52/boards/nrf52832-mdk/pinout.png | Bin 0 -> 699239 bytes .../arm/nrf52/boards/nrf52832-mdk/pinout.webp | Bin 125938 -> 0 bytes 8 files changed, 16 insertions(+), 4 deletions(-) diff --git a/.github/workflows/doc.yml b/.github/workflows/doc.yml index 883db0468b..53c6c51825 100644 --- a/.github/workflows/doc.yml +++ b/.github/workflows/doc.yml @@ -10,6 +10,7 @@ # See the License for the specific language governing permissions and # limitations under the License. # +--- name: "Build Documentation" on: pull_request: @@ -30,13 +31,22 @@ jobs: - uses: actions/setup-python@v4 with: python-version: '3.8' + - name: Install LaTeX packages +run: | + sudo apt-get update -y + sudo apt-get install -y \ +texlive-latex-recommended texlive-fonts-recommended \ +texlive-latex-base texlive-latex-extra latexmk texlive-luatex \ +fonts-freefont-otf xindy - name: Generate Documentation run: | cd Documentation/ pip3 install pipenv pipenv install - pipenv run make html + pipenv run make html latexpdf - uses: actions/upload-artifact@v3 with: name: sphinx-docs - path: Documentation/_build/html/ + path: | +Documentation/_build/html/ +Documentation/_build/latex/*.pdf diff --git a/Documentation/components/nxgraphics/NXOrganization.gif b/Documentation/components/nxgraphics/NXOrganization.gif deleted file mode 100644 index 6bae8e5529..00 Binary files a/Documentation/components/nxgraphics/NXOrganization.gif and /dev/null differ diff --git a/Documentation/components/nxgraphics/NXOrganization.png b/Documentation/components/nxgraphics/NXOrganization.png new file mode 100644 index 00..37f9c1ab38 Binary files /dev/null and b/Documentation/components/nxgraphics/NXOrganization.png differ diff --git a/Documentation/components/nxgraphics/index.rst b/Documentation/components/nxgraphics/index.rst index 7c0614be4a..f5740a45c8 100644 --- a/Documentation/components/nxgraphics/index.rst +++ b/Documentation/components/nxgraphics/index.rst @@ -83,7 +83,7 @@ That NuttX directory organization is discussed in `Appendix B <#grapicsdirs>`__ of this document. The logic modules are discussed in the following sub-paragraphs. -.. figure:: NXOrganization.gif +.. figure:: NXOrganization.png :align: center NX Graphics Library (``NXGL``) diff --git a/Documentation/conf.py b/Documentation/conf.py index d485278e45..c4d696d92f 100644 --- a/Documentation/conf.py +++ b/Documentation/conf.py @@ -119,3 +119,5 @@ linkcheck_ignore = [ "https://github.com/pyenv/pyenv#installation;, "http://openocd.zylin.com/#/c/4103/;, ] + +latex_engine = "lualatex" diff --git a/Documentation/platforms/arm/nrf52/boards/nrf52832-mdk/index.rst b/Documentation/platforms/arm/nrf52/boards/nrf52832-mdk/index.rst index 388f81ab5f..17fd92a2c4 100644 --- a/Documentation/platforms/arm/nrf52/boards/nrf52832-mdk/index.rst +++ b/Documentation/platforms/arm/nrf52/boards/nrf52832-mdk/index.rst @@ -7,7 +7,7 @@ the nRF52832 SoC from Nordic. It features 24 I/Os an on-board RGB led and a chip It also includes an embedded DAPlink debugger which allows to flash/debug and monitor UART from the USB port. -.. figure:: pinout.webp +.. figure:: pinout.png :align: center Pinout diagram diff --git a/Documentation/platforms/arm/nrf52/boards/nrf52832-mdk/pinout.png b/Documentation/platforms/arm/nrf52/boards/nrf52832-mdk/pinout.png new file mode 100644 index 00..9ee05cfb79 Binary files /dev/null and b/Documentation/platforms/arm/nrf52/boards/nrf52832-mdk/pinout.png differ
[GitHub] [nuttx] xiaoxiang781216 merged pull request #9288: docs: Generate pdf version of docs for #9095
xiaoxiang781216 merged PR #9288: URL: https://github.com/apache/nuttx/pull/9288 -- 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