[incubator-nuttx] branch master updated: Add DAC2 configuration for stm32f405.

2022-02-24 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 9603b8f  Add DAC2 configuration for stm32f405.
9603b8f is described below

commit 9603b8f67c09e178943a044ff521f7d5d66401e3
Author: Anton Potapov 
AuthorDate: Thu Feb 24 18:42:48 2022 +0300

Add DAC2 configuration for stm32f405.
---
 arch/arm/src/stm32/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/src/stm32/Kconfig b/arch/arm/src/stm32/Kconfig
index 4f22990..796707f 100644
--- a/arch/arm/src/stm32/Kconfig
+++ b/arch/arm/src/stm32/Kconfig
@@ -1724,6 +1724,7 @@ config STM32_STM32F405
select STM32_HAVE_CAN1
select STM32_HAVE_CAN2
select STM32_HAVE_DAC1
+   select STM32_HAVE_DAC2
select STM32_HAVE_SPI3
select STM32_HAVE_I2S3
select STM32_HAVE_I2C3


[incubator-nuttx] branch master updated: sched/timer: remove unused variable

2022-02-27 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new fa761a8  sched/timer: remove unused variable
fa761a8 is described below

commit fa761a8a6ab2c87b8f52add2ff07d6bceddb4fe2
Author: Petro Karashchenko 
AuthorDate: Sun Feb 27 17:06:56 2022 +0200

sched/timer: remove unused variable

Signed-off-by: Petro Karashchenko 
---
 sched/timer/timer.h | 1 -
 sched/timer/timer_settime.c | 9 +
 2 files changed, 1 insertion(+), 9 deletions(-)

diff --git a/sched/timer/timer.h b/sched/timer/timer.h
index 5cdc406..5f37000 100644
--- a/sched/timer/timer.h
+++ b/sched/timer/timer.h
@@ -55,7 +55,6 @@ struct posix_timer_s
   uint8_t  pt_crefs;   /* Reference count */
   pid_tpt_owner;   /* Creator of timer */
   int  pt_delay;   /* If non-zero, used to reset repetitive 
timers */
-  int  pt_last;/* Last value used to set watchdog */
   struct wdog_spt_wdog;/* The watchdog that provides the timing */
   struct sigevent  pt_event;   /* Notification information */
   struct sigwork_s pt_work;
diff --git a/sched/timer/timer_settime.c b/sched/timer/timer_settime.c
index d32ee9d..780f4b5 100644
--- a/sched/timer/timer_settime.c
+++ b/sched/timer/timer_settime.c
@@ -98,7 +98,6 @@ static inline void timer_restart(FAR struct posix_timer_s 
*timer,
 
   if (timer->pt_delay)
 {
-  timer->pt_last = timer->pt_delay;
   wd_start(&timer->pt_wdog, timer->pt_delay, timer_timeout, itimer);
 }
 }
@@ -313,13 +312,7 @@ int timer_settime(timer_t timerid, int flags,
 
   if (delay > 0)
 {
-  /* REVISIT: Should pt_last be sclock_t? Should wd_start delay be
-   *  sclock_t?
-   */
-
-  timer->pt_last = delay;
-  ret = wd_start(&timer->pt_wdog, delay,
- timer_timeout, (wdparm_t)timer);
+  ret = wd_start(&timer->pt_wdog, delay, timer_timeout, (wdparm_t)timer);
   if (ret < 0)
 {
   set_errno(-ret);


[incubator-nuttx] 02/02: Corrections to Tiva KConfig

2022-03-15 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 8c471db932d7c76e64c3ffca145752329d6909e1
Author: Matthew Trescott 
AuthorDate: Mon Mar 14 18:08:24 2022 -0400

Corrections to Tiva KConfig
---
 arch/arm/src/tiva/Kconfig | 9 -
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/arch/arm/src/tiva/Kconfig b/arch/arm/src/tiva/Kconfig
index 4558c85..3d344b5 100644
--- a/arch/arm/src/tiva/Kconfig
+++ b/arch/arm/src/tiva/Kconfig
@@ -97,6 +97,7 @@ config ARCH_CHIP_TM4C123AH6PM
select TIVA_HAVE_EEPROM
select TIVA_HAVE_I2C4
select TIVA_HAVE_I2C5
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
select TIVA_HAVE_QEI1
 
@@ -109,6 +110,7 @@ config ARCH_CHIP_TM4C123GH6ZRB
select TIVA_HAVE_GPIOQ_IRQS
select TIVA_HAVE_I2C4
select TIVA_HAVE_I2C5
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
select TIVA_HAVE_QEI1
 
@@ -146,6 +148,7 @@ config ARCH_CHIP_TM4C123GH6PZ
select TIVA_HAVE_GPIOK_IRQS
select TIVA_HAVE_ADC0
select TIVA_HAVE_ADC1
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
select TIVA_HAVE_QEI1
 
@@ -170,10 +173,10 @@ config ARCH_CHIP_TM4C123GH6PGE
select TIVA_HAVE_GPIOP_IRQS
select TIVA_HAVE_ADC0
select TIVA_HAVE_ADC1
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
select TIVA_HAVE_QEI1
 
-config ARCH_CHIP_TM4C123GH6PGE
 config ARCH_CHIP_TM4C1294NCPDT
bool "TM4C1294NCPDT"
depends on ARCH_CHIP_TIVA
@@ -190,6 +193,7 @@ config ARCH_CHIP_TM4C1294NCPDT
select TIVA_HAVE_GPION_IRQS
select TIVA_HAVE_GPIOP_IRQS
select TIVA_HAVE_GPIOQ_IRQS
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
 
 config ARCH_CHIP_TM4C129ENCPDT
@@ -208,6 +212,7 @@ config ARCH_CHIP_TM4C129ENCPDT
select TIVA_HAVE_GPION_IRQS
select TIVA_HAVE_GPIOP_IRQS
select TIVA_HAVE_GPIOQ_IRQS
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
 
 config ARCH_CHIP_TM4C129ENCZAD
@@ -229,6 +234,7 @@ config ARCH_CHIP_TM4C129ENCZAD
select TIVA_HAVE_GPIOR_IRQS
select TIVA_HAVE_GPIOS_IRQS
select TIVA_HAVE_GPIOT_IRQS
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
 
 config ARCH_CHIP_TM4C129XNCZAD
@@ -249,6 +255,7 @@ config ARCH_CHIP_TM4C129XNCZAD
select TIVA_HAVE_GPIOR_IRQS
select TIVA_HAVE_GPIOS_IRQS
select TIVA_HAVE_GPIOT_IRQS
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
 
 config ARCH_CHIP_CC1310


[incubator-nuttx] branch master updated (0df3139 -> 8c471db)

2022-03-15 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 0df3139  drivers/timers: rename oneshot to periodic notification 
parameter
 new bc80bbd  Add Tiva CAN driver
 new 8c471db  Corrections to Tiva KConfig

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


Summary of changes:
 arch/arm/src/tiva/Kconfig  |  151 +-
 arch/arm/src/tiva/Make.defs|4 +
 arch/arm/src/tiva/common/tiva_can.c| 2409 
 arch/arm/src/tiva/hardware/tiva_can.h  |  459 
 arch/arm/src/{sama5/sam_ssc.h => tiva/tiva_can.h}  |   50 +-
 boards/arm/tiva/tm4c123g-launchpad/Kconfig |   32 +
 boards/arm/tiva/tm4c123g-launchpad/include/board.h |   22 +
 boards/arm/tiva/tm4c123g-launchpad/src/Makefile|4 +
 .../tm4c123g-launchpad/src/tm4c123g-launchpad.h|   12 +
 .../arm/tiva/tm4c123g-launchpad/src/tm4c_bringup.c |   10 +
 .../tm4c123g-launchpad/src/tm4c_can.c} |  106 +-
 11 files changed, 3206 insertions(+), 53 deletions(-)
 create mode 100644 arch/arm/src/tiva/common/tiva_can.c
 create mode 100644 arch/arm/src/tiva/hardware/tiva_can.h
 copy arch/arm/src/{sama5/sam_ssc.h => tiva/tiva_can.h} (77%)
 copy boards/arm/{stm32l4/nucleo-l476rg/src/stm32_as726x.c => 
tiva/tm4c123g-launchpad/src/tm4c_can.c} (58%)


[incubator-nuttx] 01/02: Add Tiva CAN driver

2022-03-15 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit bc80bbddc7bffe1375475473be472bb4121ddb65
Author: Matthew Trescott 
AuthorDate: Mon Feb 28 20:46:58 2022 -0500

Add Tiva CAN driver
---
 arch/arm/src/tiva/Kconfig  |  142 ++
 arch/arm/src/tiva/Make.defs|4 +
 arch/arm/src/tiva/common/tiva_can.c| 2409 
 arch/arm/src/tiva/hardware/tiva_can.h  |  459 
 .../tm4c_bringup.c => arch/arm/src/tiva/tiva_can.h |  101 +-
 boards/arm/tiva/tm4c123g-launchpad/Kconfig |   32 +
 boards/arm/tiva/tm4c123g-launchpad/include/board.h |   22 +
 boards/arm/tiva/tm4c123g-launchpad/src/Makefile|4 +
 .../tm4c123g-launchpad/src/tm4c123g-launchpad.h|   12 +
 .../arm/tiva/tm4c123g-launchpad/src/tm4c_bringup.c |   10 +
 boards/arm/tiva/tm4c123g-launchpad/src/tm4c_can.c  |  153 ++
 11 files changed, 3294 insertions(+), 54 deletions(-)

diff --git a/arch/arm/src/tiva/Kconfig b/arch/arm/src/tiva/Kconfig
index 582786d..4558c85 100644
--- a/arch/arm/src/tiva/Kconfig
+++ b/arch/arm/src/tiva/Kconfig
@@ -125,6 +125,7 @@ config ARCH_CHIP_TM4C123GH6PM
select TIVA_HAVE_GPIOF_IRQS
select TIVA_HAVE_ADC0
select TIVA_HAVE_ADC1
+   select TIVA_HAVE_CAN1
select TIVA_HAVE_QEI0
select TIVA_HAVE_QEI1
 
@@ -350,6 +351,7 @@ config ARCH_CHIP_TM4C
select ARCH_HAVE_FPU
select TIVA_HAVE_ADC0
select TIVA_HAVE_ADC1
+   select TIVA_HAVE_CAN0
select TIVA_HAVE_I2C1
select TIVA_HAVE_I2C2
select TIVA_HAVE_I2C3
@@ -423,6 +425,21 @@ config TIVA_HAVE_ADC1
bool
default n
 
+config TIVA_CAN
+   bool
+   default n
+   select ARCH_HAVE_CAN_ERRORS
+   select CAN_TXREADY
+   select CAN_USE_RTR
+
+config TIVA_HAVE_CAN0
+   bool
+   default n
+
+config TIVA_HAVE_CAN1
+   bool
+   default n
+
 config TIVA_QEI
bool
default n
@@ -582,6 +599,40 @@ config TIVA_ADC1
depends on TIVA_HAVE_ADC0
select TIVA_ADC
 
+config TIVA_CAN0
+   bool "CAN0"
+   default n
+   depends on TIVA_HAVE_CAN0
+   select CAN
+   select TIVA_CAN
+
+config TIVA_CAN0_PRIO
+   int "CAN0 kthread priority"
+   default 300
+   depends on TIVA_CAN0
+   ---help---
+   The Tiva CAN driver retrieves messages using a kthread rather
+   than in the ISR or using a work queue. The ISR signals the
+   kthread, but the kthread can be preempted if needed. This
+   option sets the thread priority for CAN module 0.
+
+config TIVA_CAN1
+   bool "CAN1"
+   default n
+   depends on TIVA_HAVE_CAN1
+   select CAN
+   select TIVA_CAN
+
+config TIVA_CAN1_PRIO
+   int "CAN1 kthread priority"
+   default 300
+   depends on TIVA_CAN1
+   ---help---
+   The Tiva CAN driver retrieves messages using a kthread rather
+   than in the ISR or using a work queue. The ISR signals the
+   kthread, but the kthread can be preempted if needed. This
+   option sets the thread priority for CAN module 1.
+
 config TIVA_QEI0
bool "QEI0"
default n
@@ -1461,6 +1512,97 @@ config TIVA_ADC_REGDEBUG
 endmenu # Tiva ADC Configuration
 endif # TIVA_ADC
 
+menu "CAN Driver Configuration"
+   depends on TIVA_CAN
+
+config TIVA_CAN_REGDEBUG
+   bool "CAN register level debug"
+   depends on  DEBUG_CAN_INFO
+   default n
+   ---help---
+   Output detailed register-level CAN device debug information.
+   Requires also CONFIG_DEBUG_CAN_INFO.
+
+config TIVA_CAN_TX_FIFO_DEPTH
+   int "Size of the hardware TX FIFO"
+   range 1 31
+   default 8
+   ---help---
+   This number determines the depth of the hardware transmit
+   FIFO, which cannot be resized. Using a transmit FIFO allows
+   the application to transmit messages at maximum speed and
+   reduces jitter caused by excessive interrupts. However, it
+   occupies extra mailboxes that might be used for more fine-
+   grained filtering; hence there is a trade-off.
+
+   Because the mailboxes on the Tiva chips cannot be used as
+   a ring buffer for outbound messages, a larger TX FIFO
+   directly increases the maximum number of messages that
+   can be sent in a "burst" at maximum speed.
+
+   However, the TX FIFO makes implementation of
+   "pre-arbitration" more difficult. Although the classic
+   character device CAN model does not support this anyway,
+   transmission of

[incubator-nuttx] branch master updated: lib/stdio: Handle 64bits off_t correctly

2021-11-18 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new fe94670  lib/stdio: Handle 64bits off_t correctly
fe94670 is described below

commit fe94670ca99191acf6f89df38fef3d543cb0504e
Author: Xiang Xiao 
AuthorDate: Mon Nov 15 03:46:06 2021 +0800

lib/stdio: Handle 64bits off_t correctly

Signed-off-by: Xiang Xiao 
---
 libs/libc/stdio/lib_fgetpos.c |  8 ++--
 libs/libc/stdio/lib_fseek.c   | 37 +-
 libs/libc/stdio/lib_fseeko.c  | 55 +-
 libs/libc/stdio/lib_fsetpos.c |  2 +-
 libs/libc/stdio/lib_ftell.c   | 78 +
 libs/libc/stdio/lib_ftello.c  | 90 ++-
 6 files changed, 150 insertions(+), 120 deletions(-)

diff --git a/libs/libc/stdio/lib_fgetpos.c b/libs/libc/stdio/lib_fgetpos.c
index d5a7671..6a77e77 100644
--- a/libs/libc/stdio/lib_fgetpos.c
+++ b/libs/libc/stdio/lib_fgetpos.c
@@ -51,7 +51,7 @@
 
 int fgetpos(FAR FILE *stream, FAR fpos_t *pos)
 {
-  long position;
+  off_t position;
 
 #ifdef CONFIG_DEBUG_FEATURES
   if (!stream || !pos)
@@ -61,12 +61,12 @@ int fgetpos(FAR FILE *stream, FAR fpos_t *pos)
 }
 #endif
 
-  position = ftell(stream);
-  if (position == -1)
+  position = ftello(stream);
+  if (position == (off_t)-1)
 {
   return ERROR;
 }
 
-  *pos = (fpos_t)position;
+  *pos = position;
   return OK;
 }
diff --git a/libs/libc/stdio/lib_fseek.c b/libs/libc/stdio/lib_fseek.c
index b10ca41..9dd5dcf 100644
--- a/libs/libc/stdio/lib_fseek.c
+++ b/libs/libc/stdio/lib_fseek.c
@@ -22,15 +22,7 @@
  * Included Files
  /
 
-#include 
-
-#include 
 #include 
-#include 
-#include 
-#include 
-
-#include "libc.h"
 
 /
  * Public Functions
@@ -56,32 +48,5 @@
 
 int fseek(FAR FILE *stream, long int offset, int whence)
 {
-#ifdef CONFIG_DEBUG_FEATURES
-  /* Verify that we were provided with a stream */
-
-  if (!stream)
-{
-  set_errno(EBADF);
-  return ERROR;
-}
-#endif
-
-#ifndef CONFIG_STDIO_DISABLE_BUFFERING
-  /* Flush any valid read/write data in the buffer (also verifies stream) */
-
-  if (lib_rdflush(stream) < 0 || lib_wrflush(stream) < 0)
-{
-  return ERROR;
-}
-#endif
-
-  /* On success or failure, discard any characters saved by ungetc() */
-
-#if CONFIG_NUNGET_CHARS > 0
-  stream->fs_nungotten = 0;
-#endif
-
-  /* Perform the fseek on the underlying file descriptor */
-
-  return lseek(stream->fs_fd, offset, whence) == (off_t)-1 ? ERROR : OK;
+  return fseeko(stream, offset, whence);
 }
diff --git a/libs/libc/stdio/lib_fseeko.c b/libs/libc/stdio/lib_fseeko.c
index 50ac370..69dc01e 100644
--- a/libs/libc/stdio/lib_fseeko.c
+++ b/libs/libc/stdio/lib_fseeko.c
@@ -22,13 +22,66 @@
  * Included Files
  /
 
+#include 
+
+#include 
 #include 
+#include 
+#include 
+#include 
+
+#include "libc.h"
 
 /
  * Public Functions
  /
 
+/
+ * Name: fseeko
+ *
+ * Description:
+ *   The fseeko() function sets the file position indicator for the stream
+ *   pointed to by stream. The new position, measured in bytes, is obtained
+ *   by adding offset bytes to the position specified by whence. If whence is
+ *   set to SEEK_SET, SEEK_CUR, or SEEK_END, the offset is relative to the
+ *   start of the file, the current position indicator, or end-of-file,
+ *   respectively. A successful call to the fseeko() function clears the
+ *   end-of-file indicator for the stream and undoes any effects of the
+ *   ungetc(3) function on the same stream.
+ *
+ * Returned Value:
+ *   Zero on success; -1 on failure with errno set appropriately.
+ *
+ /
+
 int fseeko(FAR FILE *stream, off_t offset, int whence)
 {
-  return fseek(stream, offset, whence);
+#ifdef CONFIG_DEBUG_FEATURES
+  /* Verify that we were provided with a stream */
+
+  if (!stream)
+{
+  set_errno(EBADF);
+  return ERROR;
+}
+#endif
+
+#ifndef CONFIG_STDIO_DISABLE_BUFFERING
+  /* Flush any valid read/write data in the buffer (also verifies stream) */
+
+  if (lib_rdflush(stream) < 0 || lib_wrflush(stream) < 0)
+{
+  return ERROR;
+}
+#endif
+
+  /* On success or failure, discard any characters saved by ungetc() */
+
+#if CONFIG_NUNGET_CHARS > 0
+  stream->fs_nungotten = 0;
+#endif
+
+  /* Perfo

[incubator-nuttx] branch master updated (a3b643f -> 3b62765)

2020-05-19 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from a3b643f  olimex-stm32-p407: update HAVE_MODSYMS judge for protected 
build
 add 3b62765  nxstyle:  Fix distinction be source and header file for long 
lines.

No new revisions were added by this update.

Summary of changes:
 tools/nxstyle.c | 10 +-
 1 file changed, 1 insertion(+), 9 deletions(-)



[incubator-nuttx] branch master updated: fs/fat: Run all .c and .h files through nxstyle

2020-05-31 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 0f7c2d6  fs/fat:  Run all .c and .h files through nxstyle
0f7c2d6 is described below

commit 0f7c2d6fbf87a09facb3d810e88a0a32c2761c02
Author: Gregory Nutt 
AuthorDate: Sun May 31 09:48:21 2020 -0600

fs/fat:  Run all .c and .h files through nxstyle

Run all .c and .h files through nxstyle and correct all reported issues.
---
 fs/fat/fs_fat32.c   |  72 +-
 fs/fat/fs_fat32.h   |  40 ++
 fs/fat/fs_fat32attrib.c |  39 ++
 fs/fat/fs_fat32dirent.c | 343 +---
 fs/fat/fs_fat32util.c   |  78 +--
 5 files changed, 272 insertions(+), 300 deletions(-)

diff --git a/fs/fat/fs_fat32.c b/fs/fat/fs_fat32.c
index d2c0ad1..fe0c528 100644
--- a/fs/fat/fs_fat32.c
+++ b/fs/fat/fs_fat32.c
@@ -1,42 +1,20 @@
 /
  * fs/fat/fs_fat32.c
  *
- *   Copyright (C) 2007-2009, 2011-2015, 2017-2018 Gregory Nutt. All rights
- * reserved.
- *   Author: Gregory Nutt 
+ * 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
  *
- * References:
- *   Microsoft FAT documentation
- *   Some good ideas were leveraged from the FAT implementation:
- * 'Copyright (C) 2007, ChaN, all right reserved.'
- * which has an unrestricted license.
+ *   http://www.apache.org/licenses/LICENSE-2.0
  *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- *notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *notice, this list of conditions and the following disclaimer in
- *the documentation and/or other materials provided with the
- *distribution.
- * 3. Neither the name NuttX nor the names of its contributors may be
- *used to endorse or promote products derived from this software
- *without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
- * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
- * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- * POSSIBILITY OF SUCH DAMAGE.
+ * 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.
  *
  /
 
@@ -341,7 +319,9 @@ static int fat_open(FAR struct file *filep, FAR const char 
*relpath,
   goto errout_with_struct;
 }
 
-  /* Initialize the file private data (only need to initialize non-zero 
elements) */
+  /* Initialize the file private data (only need to initialize non-zero
+   * elements).
+   */
 
   ff->ff_oflags   = oflags;
 
@@ -375,7 +355,9 @@ static int fat_open(FAR struct file *filep, FAR const char 
*relpath,
 
   fat_semgive(fs);
 
-  /* In write/append mode, we need to set the file pointer to the end of the 
file */
+  /* In write/append mode, we need to set the file pointer to the end of
+   * the file.
+   */
 
   if ((oflags & (O_APPEND | O_WRONLY)) == (O_APPEND | O_WRONLY))
 {
@@ -1654,7 +1636,9 @@ static int fat_opendir(FAR struct inode *mountpt, FAR 
const char *relpath,
 }
   else
 {
-  /* This is not the root directory.  Verify that it is some kind of 
directory */
+  /* This is not the root directory.  Verify that it is some kind of
+   * directory

[incubator-nuttx] branch master updated: drivers/mtd/filemtd.c: fix build error

2020-05-11 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new d666aa6  drivers/mtd/filemtd.c: fix build error
d666aa6 is described below

commit d666aa623f025062f927f26c73fea0f2727509f1
Author: Juha Niskanen 
AuthorDate: Mon May 11 14:23:22 2020 +0300

drivers/mtd/filemtd.c: fix build error
---
 drivers/mtd/filemtd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/filemtd.c b/drivers/mtd/filemtd.c
index 252d50a..9f1b0a3 100644
--- a/drivers/mtd/filemtd.c
+++ b/drivers/mtd/filemtd.c
@@ -506,9 +506,9 @@ FAR struct mtd_dev_s *blockmtd_initialize(FAR const char 
*path,
   return NULL;
 }
 
-  /* Determine the file open mode */
+  /* Set the file open mode. */
 
-  mode = O_RDOK |= O_WROK;
+  mode = O_RDOK | O_WROK;
 
   /* Try to open the file.  NOTE that block devices will use a character
* driver proxy.



[incubator-nuttx] branch master updated (46baccb -> 2b5ff17)

2020-05-11 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 46baccb  Remove unnecessary enter/leave_critical_section() in 
setlogmask() because it is MT-unsafe.
 add 2b5ff17  setlogmask():  Add comments

No new revisions were added by this update.

Summary of changes:
 include/syslog.h  | 47 +++
 libs/libc/syslog/lib_setlogmask.c | 47 ++-
 2 files changed, 35 insertions(+), 59 deletions(-)



[incubator-nuttx] branch master updated: arch/: Trivial typos, mostly "their is" to "there is"

2020-09-09 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 06ca12e  arch/: Trivial typos, mostly "their is" to "there is"
06ca12e is described below

commit 06ca12e6b9ffdf061b14dfb8d68f0897b9c8c873
Author: Ouss4 
AuthorDate: Wed Sep 9 18:56:35 2020 +0100

arch/: Trivial typos, mostly "their is" to "there is"
---
 arch/README.txt|  6 +++---
 arch/arm/src/common/arm_idle.c |  2 +-
 arch/arm/src/cxd56xx/cxd56_idle.c  |  2 +-
 arch/arm/src/efm32/efm32_idle.c|  2 +-
 arch/arm/src/eoss3/eoss3_idle.c|  2 +-
 arch/arm/src/imx6/imx_idle.c   |  2 +-
 arch/arm/src/imxrt/imxrt_idle.c|  2 +-
 arch/arm/src/kinetis/kinetis_idle.c|  2 +-
 arch/arm/src/kl/kl_idle.c  |  2 +-
 arch/arm/src/lc823450/lc823450_idle.c  |  2 +-
 arch/arm/src/lpc17xx_40xx/lpc17_40_idle.c  |  2 +-
 arch/arm/src/lpc43xx/lpc43_idle.c  |  2 +-
 arch/arm/src/lpc54xx/lpc54_idle.c  |  2 +-
 arch/arm/src/max326xx/common/max326_idle.c |  2 +-
 arch/arm/src/moxart/moxart_idle.c  |  2 +-
 arch/arm/src/nrf52/nrf52_idle.c|  2 +-
 arch/arm/src/nuc1xx/nuc_idle.c |  2 +-
 arch/arm/src/s32k1xx/s32k1xx_idle.c|  2 +-
 arch/arm/src/sam34/sam4cm_cpuidlestack.c   |  2 +-
 arch/arm/src/sam34/sam4cm_idle.c   |  2 +-
 arch/arm/src/samd2l2/sam_idle.c|  2 +-
 arch/arm/src/samd5e5/sam_idle.c|  2 +-
 arch/arm/src/stm32/stm32_idle.c|  8 
 arch/arm/src/stm32f0l0g0/stm32_idle.c  |  2 +-
 arch/arm/src/stm32l4/stm32l4_idle.c|  2 +-
 arch/arm/src/tiva/common/tiva_idle.c   |  2 +-
 arch/arm/src/xmc4/xmc4_idle.c  |  2 +-
 arch/avr/src/common/up_idle.c  |  2 +-
 arch/hc/src/common/up_idle.c   |  2 +-
 arch/mips/src/common/mips_idle.c   |  2 +-
 arch/misoc/src/minerva/minerva_idle.c  | 12 ++--
 arch/or1k/src/common/up_idle.c |  2 +-
 arch/risc-v/src/common/riscv_idle.c|  2 +-
 arch/risc-v/src/fe310/fe310_idle.c |  2 +-
 arch/risc-v/src/gap8/gap8_idle.c   |  2 +-
 arch/risc-v/src/k210/k210_idle.c   |  2 +-
 arch/risc-v/src/litex/litex_idle.c |  2 +-
 arch/sim/src/sim/up_idle.c |  2 +-
 arch/x86/src/qemu/qemu_idle.c  |  2 +-
 arch/x86_64/src/intel64/intel64_idle.c |  2 +-
 arch/xtensa/src/common/xtensa_idle.c   |  2 +-
 boards/README.txt  |  6 ++
 42 files changed, 53 insertions(+), 55 deletions(-)

diff --git a/arch/README.txt b/arch/README.txt
index b9317fd..324fb0e 100644
--- a/arch/README.txt
+++ b/arch/README.txt
@@ -45,8 +45,8 @@ Directory Structure
 
 The arch/ directory contains architecture-specific logic.  The complete
 board port is defined by the architecture-specific code in this
-directory plus the board-specific configurations in the config/
-subdirectory.  Each architecture must provide a subdirectory 
+directory plus the board-specific configurations in the boards/
+directory.  Each architecture must provide a subdirectory 
 under arch/ with the following characteristics:
 
 
@@ -110,7 +110,7 @@ include/irq.h
 
   - irqstate_t up_irq_save(void) -- Used to disable all interrupts.
 
-  - void upirq_restore(irqstate_t flags) -- Used to restore interrupt
+  - void up_irq_restore(irqstate_t flags) -- Used to restore interrupt
 enables to the same state as before up_irq_save was called.
 
   NOTE: These interfaces are not available to application code but can
diff --git a/arch/arm/src/common/arm_idle.c b/arch/arm/src/common/arm_idle.c
index d29fca0..8343dc0 100644
--- a/arch/arm/src/common/arm_idle.c
+++ b/arch/arm/src/common/arm_idle.c
@@ -50,7 +50,7 @@
  * Name: up_idle
  *
  * Description:
- *   up_idle() is the logic that will be executed when their is no other
+ *   up_idle() is the logic that will be executed when there is no other
  *   ready-to-run task.  This is processor idle time and will continue until
  *   some interrupt occurs to cause a context switch from the idle task.
  *
diff --git a/arch/arm/src/cxd56xx/cxd56_idle.c 
b/arch/arm/src/cxd56xx/cxd56_idle.c
index ecec21c..d508ee8 100644
--- a/arch/arm/src/cxd56xx/cxd56_idle.c
+++ b/arch/arm/src/cxd56xx/cxd56_idle.c
@@ -157,7 +157,7 @@ static void up_idlepm(void)
  * Name: up_idle
  *
  * Description:
- *   up_idle() is the logic that will be executed when their is no other
+ *   up_idle() is the logic that will be executed when there is no other
  *   ready-to-run task.  This is processor idle time and will continue until
  *   some interrupt occurs to cause a context switch from the idle task.
  *
diff --git a/arch/arm/src/efm32/efm32_idle.c

[incubator-nuttx] branch master updated: arch/xtensa: Few typos and style fixes.

2020-09-21 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new a128995  arch/xtensa: Few typos and style fixes.
a128995 is described below

commit a128995eaba007e132ddc295dee0dccb0c56e23a
Author: Abdelatif Guettouche 
AuthorDate: Sat Sep 12 12:50:49 2020 +0100

arch/xtensa: Few typos and style fixes.

Signed-off-by: Abdelatif Guettouche 
---
 arch/xtensa/src/common/xtensa_coproc.S   | 74 ++--
 arch/xtensa/src/common/xtensa_cpuint.S   | 14 +++---
 arch/xtensa/src/common/xtensa_cpupause.c | 22 -
 arch/xtensa/src/common/xtensa_int_handlers.S |  2 +-
 arch/xtensa/src/esp32/esp32_start.c  |  4 +-
 arch/xtensa/src/lx6/Toolchain.defs   |  1 -
 6 files changed, 58 insertions(+), 59 deletions(-)

diff --git a/arch/xtensa/src/common/xtensa_coproc.S 
b/arch/xtensa/src/common/xtensa_coproc.S
index 6af4849..3b2b6bf 100644
--- a/arch/xtensa/src/common/xtensa_coproc.S
+++ b/arch/xtensa/src/common/xtensa_coproc.S
@@ -31,7 +31,7 @@
  *
  /
 
-   .file   "xtensa_coproc.S"
+  .file"xtensa_coproc.S"
 
 /
  * Included Files
@@ -54,26 +54,26 @@
  * Public Data
  /
 
-   .section .rodata, "a"
+  .section .rodata, "a"
 
-   /* Offset to CP n save area in thread's CP save area. */
+  /* Offset to CP n save area in thread's CP save area. */
 
-   .global _xtensa_coproc_saoffsets
-   .type   _xtensa_coproc_saoffsets, @object
-   .align  16  /* Minimize crossing cache boundaries */
+  .global  _xtensa_coproc_saoffsets
+  .type_xtensa_coproc_saoffsets, @object
+  .align   16  /* Minimize crossing cache boundaries */
 
 _xtensa_coproc_saoffsets:
 
-   .word   XTENSA_CP0_SA, XTENSA_CP1_SA, XTENSA_CP2_SA, XTENSA_CP3_SA
-   .word   XTENSA_CP4_SA, XTENSA_CP5_SA, XTENSA_CP6_SA, XTENSA_CP7_SA
+  .wordXTENSA_CP0_SA, XTENSA_CP1_SA, XTENSA_CP2_SA, XTENSA_CP3_SA
+  .wordXTENSA_CP4_SA, XTENSA_CP5_SA, XTENSA_CP6_SA, XTENSA_CP7_SA
 
-   .size   _xtensa_coproc_saoffsets, . - _xtensa_coproc_saoffsets
+  .size_xtensa_coproc_saoffsets, . - _xtensa_coproc_saoffsets
 
 /
  * Public Functions
  /
 
-   .text
+  .text
 
 /
  * Name: _xtensa_coproc_savestate
@@ -102,12 +102,12 @@ _xtensa_coproc_saoffsets:
  *
  /
 
-   .global _xtensa_coproc_savestate
-   .type   _xtensa_coproc_savestate, @function
+  .global  _xtensa_coproc_savestate
+  .type_xtensa_coproc_savestate, @function
 
-   .align  4
-   .literal_position
-   .align  4
+  .align   4
+  .literal_position
+  .align   4
 
 _xtensa_coproc_savestate:
 
@@ -225,9 +225,9 @@ xtensa_coproc_savestate:
 #ifdef __XTENSA_CALL0_ABI__
 
/* Need to preserve a8-11.  _xtensa_coproc_savestate modifies a2-a7,
-* a13-a15. a12-a15 are callee saved registers so a13-a14 must be
-* preserved.
-*/
+   * a13-a15. a12-a15 are callee saved registers so a13-a14 must be
+   * preserved.
+   */
 
ENTRY(16)
s32ia13, sp, LOCAL_OFFSET(1)/* Save clobbered 
registers */
@@ -235,8 +235,8 @@ xtensa_coproc_savestate:
s32ia15, sp, LOCAL_OFFSET(3)
 
/* Call _xtensa_coproc_savestate() with A2=address of co-processor
-* save area.
-*/
+   * save area.
+   */
 
call0 _xtensa_coproc_savestate
 
@@ -249,15 +249,15 @@ xtensa_coproc_savestate:
 
 #else
/* Need to preserve a8-15.  _xtensa_coproc_savestate modifies a2-a7,
-* a13-a15.  So a13-a15 may need to be preserved.
-*/
+   * a13-a15.  So a13-a15 may need to be preserved.
+   */
 
ENTRY(32 /*16*/)/* 
REVISIT: Why 32? */
s32ia0,  sp, LOCAL_OFFSET(1)/* Save return address 
*/
 
/* Call _xtensa_coproc_savestate() with A2=address of co-processor
-* save area.
-*/
+   * save area.
+   */
 
call0 _xtensa_coproc_savestate
 
@@ -424,9 +424,9 @@ xtensa_coproc_restorestate:
 #ifdef __XTENSA_CALL0_ABI__
 
/* Need to preserve a8-11.  _xtensa_coproc_restorestate modifies a2-a7,
-* a13-a15. a12-a15 are callee saved

[incubator-nuttx] branch master updated (54bb982 -> f10261f)

2020-10-18 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 54bb982  freedom-k64f: Lint freedom-k64f.h
 add 77160c7  Documentation: replace bitbucket links with github ones
 add 9c43ca3  Documentation/components/nsh/login.rst: fix a couple of repo 
links manually
 add f10261f  Documentation/quickstart/debugging: fix micro-ros tutorial 
link

No new revisions were added by this update.

Summary of changes:
 Documentation/components/nsh/login.rst   |   6 +-
 Documentation/components/nxflat.rst  |   4 +-
 Documentation/components/nxgraphics/appendix.rst |   2 +-
 Documentation/introduction/detailed_support.rst  | 168 +++
 Documentation/quickstart/debugging.rst   |   2 +-
 Documentation/quickstart/organization.rst|   2 +-
 6 files changed, 92 insertions(+), 92 deletions(-)



[incubator-nuttx] branch master updated (54bb982 -> f10261f)

2020-10-18 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 54bb982  freedom-k64f: Lint freedom-k64f.h
 add 77160c7  Documentation: replace bitbucket links with github ones
 add 9c43ca3  Documentation/components/nsh/login.rst: fix a couple of repo 
links manually
 add f10261f  Documentation/quickstart/debugging: fix micro-ros tutorial 
link

No new revisions were added by this update.

Summary of changes:
 Documentation/components/nsh/login.rst   |   6 +-
 Documentation/components/nxflat.rst  |   4 +-
 Documentation/components/nxgraphics/appendix.rst |   2 +-
 Documentation/introduction/detailed_support.rst  | 168 +++
 Documentation/quickstart/debugging.rst   |   2 +-
 Documentation/quickstart/organization.rst|   2 +-
 6 files changed, 92 insertions(+), 92 deletions(-)



[incubator-nuttx] branch master updated (a49a3ea -> 80be4a5)

2020-10-18 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from a49a3ea  tools: Remove the special handle for Ubuntu under Windows 10
 add 80be4a5  freedom-k64f: Fix k64_buttons.c

No new revisions were added by this update.

Summary of changes:
 boards/arm/kinetis/freedom-k64f/src/k64_buttons.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)



[incubator-nuttx] 01/01: boards/tm4c129e-launchpad: Enable priority inheritance in ostest config

2022-10-07 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a commit to branch tm4c129e-launchpad-ostest-prio
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit 422bf1a3f0d65d9144329da00a66379215379920
Author: Nathan Hartman <59230071+hartmannat...@users.noreply.github.com>
AuthorDate: Fri Oct 7 11:50:02 2022 -0400

boards/tm4c129e-launchpad: Enable priority inheritance in ostest config
---
 boards/arm/tiva/tm4c129e-launchpad/configs/ostest/defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/boards/arm/tiva/tm4c129e-launchpad/configs/ostest/defconfig 
b/boards/arm/tiva/tm4c129e-launchpad/configs/ostest/defconfig
index f8f4a4ad8d..2c54cad265 100644
--- a/boards/arm/tiva/tm4c129e-launchpad/configs/ostest/defconfig
+++ b/boards/arm/tiva/tm4c129e-launchpad/configs/ostest/defconfig
@@ -58,6 +58,7 @@ CONFIG_NSH_FILEIOSIZE=512
 CONFIG_NSH_LINELEN=64
 CONFIG_NSH_READLINE=y
 CONFIG_PREALLOC_TIMERS=4
+CONFIG_PRIORITY_INHERITANCE=y
 CONFIG_RAM_SIZE=262144
 CONFIG_RAM_START=0x2000
 CONFIG_RAW_BINARY=y



[incubator-nuttx] branch tm4c129e-launchpad-ostest-prio created (now 422bf1a3f0)

2022-10-07 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a change to branch tm4c129e-launchpad-ostest-prio
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git


  at 422bf1a3f0 boards/tm4c129e-launchpad: Enable priority inheritance in 
ostest config

This branch includes the following new commits:

 new 422bf1a3f0 boards/tm4c129e-launchpad: Enable priority inheritance in 
ostest config

The 1 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.




[incubator-nuttx-apps] branch master updated (893387b2c -> 8e460e7e1)

2022-10-16 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 893387b2c Fix the minor style issue
 new cf70d8f95 nshlib: Call nsh_sysinitscript in usb or alt console like 
normal one
 new 964747dd3 nshlib: Call nsh_telnetstart in nsh_initialize to avoid the 
dupliation
 new 0d210c322 nshlib: Move commoin initialization from console_main to 
nsh_initialize
 new 8e460e7e1 nshlib: Move symbol table initialization from nsh_main to 
nsh_initialize

The 4 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:
 examples/nxterm/nxterm_main.c|  16 ---
 graphics/nxwm/src/cnxterm.cxx|  14 --
 graphics/twm4nx/apps/cnxterm.cxx |  14 --
 nshlib/nsh_altconsole.c  |  29 ---
 nshlib/nsh_consolemain.c |  32 -
 nshlib/nsh_init.c| 101 +--
 nshlib/nsh_telnetd.c |  38 ---
 nshlib/nsh_usbconsole.c  |  24 --
 system/nsh/nsh_main.c|  77 ++---
 9 files changed, 101 insertions(+), 244 deletions(-)



[incubator-nuttx-apps] 03/04: nshlib: Move commoin initialization from console_main to nsh_initialize

2022-10-16 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 0d210c3227f2b49955e59e04d0f9c674223c9066
Author: Xiang Xiao 
AuthorDate: Sat Oct 15 17:31:04 2022 +0800

nshlib: Move commoin initialization from console_main to nsh_initialize

to avoid the code duplication

Signed-off-by: Xiang Xiao 
---
 nshlib/nsh_altconsole.c  | 34 --
 nshlib/nsh_consolemain.c | 32 
 nshlib/nsh_init.c| 43 +--
 nshlib/nsh_telnetd.c | 38 --
 nshlib/nsh_usbconsole.c  | 30 --
 system/nsh/nsh_main.c|  7 +++
 6 files changed, 44 insertions(+), 140 deletions(-)

diff --git a/nshlib/nsh_altconsole.c b/nshlib/nsh_altconsole.c
index f407ceffd..750fc845f 100644
--- a/nshlib/nsh_altconsole.c
+++ b/nshlib/nsh_altconsole.c
@@ -34,8 +34,6 @@
 #include "nsh.h"
 #include "nsh_console.h"
 
-#include "netutils/netinit.h"
-
 #if defined(CONFIG_NSH_ALTCONDEV) && !defined(HAVE_USB_CONSOLE)
 
 /
@@ -251,38 +249,6 @@ int nsh_consolemain(int argc, FAR char *argv[])
 
   DEBUGASSERT(pstate);
 
-  /* Initialize any USB tracing options that were requested */
-
-#ifdef CONFIG_NSH_USBDEV_TRACE
-  usbtrace_enable(TRACE_BITSET);
-#endif
-
-#if defined(CONFIG_NSH_ROMFSETC) && !defined(CONFIG_NSH_DISABLESCRIPT)
-  /* Execute the system init script */
-
-  nsh_sysinitscript(&pstate->cn_vtbl);
-#endif
-
-#ifdef CONFIG_NSH_NETINIT
-  /* Bring up the network */
-
-  netinit_bringup();
-#endif
-
-#if defined(CONFIG_NSH_ARCHINIT) && defined(CONFIG_BOARDCTL_FINALINIT)
-  /* Perform architecture-specific final-initialization (if configured) */
-
-  boardctl(BOARDIOC_FINALINIT, 0);
-#endif
-
-  /* Execute the one-time start-up script.
-   * Any output will go to /dev/console.
-   */
-
-#ifdef CONFIG_NSH_ROMFSETC
-  nsh_initscript(&pstate->cn_vtbl);
-#endif
-
   /* First map stderr and stdout to alternative devices */
 
   ret = nsh_clone_console(pstate);
diff --git a/nshlib/nsh_consolemain.c b/nshlib/nsh_consolemain.c
index 13cb6eb94..463c30b02 100644
--- a/nshlib/nsh_consolemain.c
+++ b/nshlib/nsh_consolemain.c
@@ -32,8 +32,6 @@
 #include "nsh.h"
 #include "nsh_console.h"
 
-#include "netutils/netinit.h"
-
 #if !defined(CONFIG_NSH_ALTCONDEV) && !defined(HAVE_USB_CONSOLE) && \
 !defined(HAVE_USB_KEYBOARD)
 
@@ -71,36 +69,6 @@ int nsh_consolemain(int argc, FAR char *argv[])
 
   DEBUGASSERT(pstate != NULL);
 
-#ifdef CONFIG_NSH_USBDEV_TRACE
-  /* Initialize any USB tracing options that were requested */
-
-  usbtrace_enable(TRACE_BITSET);
-#endif
-
-#if defined(CONFIG_NSH_ROMFSETC) && !defined(CONFIG_NSH_DISABLESCRIPT)
-  /* Execute the system init script */
-
-  nsh_sysinitscript(&pstate->cn_vtbl);
-#endif
-
-#ifdef CONFIG_NSH_NETINIT
-  /* Bring up the network */
-
-  netinit_bringup();
-#endif
-
-#if defined(CONFIG_NSH_ARCHINIT) && defined(CONFIG_BOARDCTL_FINALINIT)
-  /* Perform architecture-specific final-initialization (if configured) */
-
-  boardctl(BOARDIOC_FINALINIT, 0);
-#endif
-
-#if defined(CONFIG_NSH_ROMFSETC) && !defined(CONFIG_NSH_DISABLESCRIPT)
-  /* Execute the start-up script */
-
-  nsh_initscript(&pstate->cn_vtbl);
-#endif
-
   /* Execute the session */
 
   ret = nsh_session(pstate, true, argc, argv);
diff --git a/nshlib/nsh_init.c b/nshlib/nsh_init.c
index 251e6c452..fdd9a9208 100644
--- a/nshlib/nsh_init.c
+++ b/nshlib/nsh_init.c
@@ -27,9 +27,11 @@
 #include 
 
 #include "system/readline.h"
+#include "netutils/netinit.h"
 #include "nshlib/nshlib.h"
 
 #include "nsh.h"
+#include "nsh_console.h"
 
 /
  * Private Data
@@ -66,28 +68,65 @@ static const struct extmatch_vtable_s g_nsh_extmatch =
 
 void nsh_initialize(void)
 {
+#if defined(CONFIG_NSH_ROMFSETC) && !defined(CONFIG_NSH_DISABLESCRIPT)
+  FAR struct console_stdio_s *pstate;
+#endif
+
 #if defined(CONFIG_NSH_READLINE) && defined(CONFIG_READLINE_TABCOMPLETION)
   /* Configure the NSH prompt */
 
   readline_prompt(g_nshprompt);
 
-#ifdef CONFIG_READLINE_HAVE_EXTMATCH
+#  ifdef CONFIG_READLINE_HAVE_EXTMATCH
   /* Set up for tab completion on NSH commands */
 
   readline_extmatch(&g_nsh_extmatch);
-#endif
+#  endif
 #endif
 
   /* Mount the /etc filesystem */
 
   (void)nsh_romfsetc();
 
+#ifdef CONFIG_NSH_USBDEV_TRACE
+  /* Initialize any USB tracing options that were requested */
+
+  usbtrace_enable(TRACE_BITSET);
+#endif
+
 #ifdef CONFIG_NSH_ARCHINIT
   /* Perform architectu

[incubator-nuttx-apps] 04/04: nshlib: Move symbol table initialization from nsh_main to nsh_initialize

2022-10-16 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 8e460e7e19747ff8cb148f7bde5492cd118f20fd
Author: Xiang Xiao 
AuthorDate: Sat Oct 15 17:53:09 2022 +0800

nshlib: Move symbol table initialization from nsh_main to nsh_initialize

Signed-off-by: Xiang Xiao 
---
 nshlib/nsh_init.c | 44 
 system/nsh/nsh_main.c | 49 -
 2 files changed, 44 insertions(+), 49 deletions(-)

diff --git a/nshlib/nsh_init.c b/nshlib/nsh_init.c
index fdd9a9208..c49bdfd34 100644
--- a/nshlib/nsh_init.c
+++ b/nshlib/nsh_init.c
@@ -25,6 +25,7 @@
 #include 
 
 #include 
+#include 
 
 #include "system/readline.h"
 #include "netutils/netinit.h"
@@ -33,6 +34,32 @@
 #include "nsh.h"
 #include "nsh_console.h"
 
+/
+ * Pre-processor Definitions
+ /
+
+/* Symbol table is not needed if loadable binary modules are not supported */
+
+#if !defined(CONFIG_LIBC_EXECFUNCS)
+#  undef CONFIG_SYSTEM_NSH_SYMTAB
+#endif
+
+/* boardctl() support is also required for application-space symbol table
+ * support.
+ */
+
+#if !defined(CONFIG_BOARDCTL) || !defined(CONFIG_BOARDCTL_APP_SYMTAB)
+#  undef CONFIG_SYSTEM_NSH_SYMTAB
+#endif
+
+/* If a symbol table is provided by board-specific logic, then we do not
+ * need to do anything from the application space.
+ */
+
+#ifdef CONFIG_EXECFUNCS_HAVE_SYMTAB
+#  undef CONFIG_SYSTEM_NSH_SYMTAB
+#endif
+
 /
  * Private Data
  /
@@ -46,6 +73,11 @@ static const struct extmatch_vtable_s g_nsh_extmatch =
 };
 #endif
 
+#if defined(CONFIG_SYSTEM_NSH_SYMTAB)
+extern const struct symtab_s CONFIG_SYSTEM_NSH_SYMTAB_ARRAYNAME[];
+extern const int CONFIG_SYSTEM_NSH_SYMTAB_COUNTNAME;
+#endif
+
 /
  * Public Functions
  /
@@ -68,6 +100,9 @@ static const struct extmatch_vtable_s g_nsh_extmatch =
 
 void nsh_initialize(void)
 {
+#if defined (CONFIG_SYSTEM_NSH_SYMTAB)
+  struct boardioc_symtab_s symdesc;
+#endif
 #if defined(CONFIG_NSH_ROMFSETC) && !defined(CONFIG_NSH_DISABLESCRIPT)
   FAR struct console_stdio_s *pstate;
 #endif
@@ -94,6 +129,15 @@ void nsh_initialize(void)
   usbtrace_enable(TRACE_BITSET);
 #endif
 
+#if defined(CONFIG_SYSTEM_NSH_SYMTAB)
+  /* Make sure that we are using our symbol table */
+
+  symdesc.symtab   = (FAR struct symtab_s 
*)CONFIG_SYSTEM_NSH_SYMTAB_ARRAYNAME; /* Discard 'const' */
+  symdesc.nsymbols = CONFIG_SYSTEM_NSH_SYMTAB_COUNTNAME;
+
+  boardctl(BOARDIOC_APP_SYMTAB, (uintptr_t)&symdesc);
+#endif
+
 #ifdef CONFIG_NSH_ARCHINIT
   /* Perform architecture-specific initialization (if configured) */
 
diff --git a/system/nsh/nsh_main.c b/system/nsh/nsh_main.c
index 44d93cb73..ebf27d46c 100644
--- a/system/nsh/nsh_main.c
+++ b/system/nsh/nsh_main.c
@@ -31,55 +31,18 @@
 #include 
 #include 
 
-#if defined(CONFIG_LIBC_EXECFUNCS)
-#  include 
-#endif
-
 #include "nshlib/nshlib.h"
 
 /
  * Pre-processor Definitions
  /
 
-/* Symbol table is not needed if loadable binary modules are not supported */
-
-#if !defined(CONFIG_LIBC_EXECFUNCS)
-#  undef CONFIG_SYSTEM_NSH_SYMTAB
-#endif
-
-/* boardctl() support is also required for application-space symbol table
- * support.
- */
-
-#if !defined(CONFIG_BOARDCTL) || !defined(CONFIG_BOARDCTL_APP_SYMTAB)
-#  undef CONFIG_SYSTEM_NSH_SYMTAB
-#endif
-
-/* If a symbol table is provided by board-specific logic, then we do not
- * need to do anything from the application space.
- */
-
-#ifdef CONFIG_EXECFUNCS_HAVE_SYMTAB
-#  undef CONFIG_SYSTEM_NSH_SYMTAB
-#endif
-
 /* The NSH telnet console requires networking support (and TCP/IP) */
 
 #ifndef CONFIG_NET
 #  undef CONFIG_NSH_TELNET
 #endif
 
-/
- * Private Data
- /
-
-#if defined(CONFIG_SYSTEM_NSH_SYMTAB)
-
-extern const struct symtab_s CONFIG_SYSTEM_NSH_SYMTAB_ARRAYNAME[];
-extern const int CONFIG_SYSTEM_NSH_SYMTAB_COUNTNAME;
-
-#endif
-
 /
  * Public Functions
  /
@@ -96,9 +59,6 @@ extern const int 

[incubator-nuttx-apps] 01/04: nshlib: Call nsh_sysinitscript in usb or alt console like normal one

2022-10-16 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit cf70d8f95bccb265ba84acc5e3957ada64cdf379
Author: Xiang Xiao 
AuthorDate: Sat Oct 15 16:31:12 2022 +0800

nshlib: Call nsh_sysinitscript in usb or alt console like normal one

forget in the pull request:
https://github.com/apache/incubator-nuttx-apps/pull/1142

Signed-off-by: Xiang Xiao 
---
 nshlib/nsh_altconsole.c | 17 +++--
 nshlib/nsh_usbconsole.c | 12 +---
 2 files changed, 20 insertions(+), 9 deletions(-)

diff --git a/nshlib/nsh_altconsole.c b/nshlib/nsh_altconsole.c
index f003f4276..f407ceffd 100644
--- a/nshlib/nsh_altconsole.c
+++ b/nshlib/nsh_altconsole.c
@@ -257,12 +257,10 @@ int nsh_consolemain(int argc, FAR char *argv[])
   usbtrace_enable(TRACE_BITSET);
 #endif
 
-  /* Execute the one-time start-up script.
-   * Any output will go to /dev/console.
-   */
+#if defined(CONFIG_NSH_ROMFSETC) && !defined(CONFIG_NSH_DISABLESCRIPT)
+  /* Execute the system init script */
 
-#ifdef CONFIG_NSH_ROMFSETC
-  nsh_initscript(&pstate->cn_vtbl);
+  nsh_sysinitscript(&pstate->cn_vtbl);
 #endif
 
 #ifdef CONFIG_NSH_NETINIT
@@ -277,10 +275,17 @@ int nsh_consolemain(int argc, FAR char *argv[])
   boardctl(BOARDIOC_FINALINIT, 0);
 #endif
 
+  /* Execute the one-time start-up script.
+   * Any output will go to /dev/console.
+   */
+
+#ifdef CONFIG_NSH_ROMFSETC
+  nsh_initscript(&pstate->cn_vtbl);
+#endif
+
   /* First map stderr and stdout to alternative devices */
 
   ret = nsh_clone_console(pstate);
-
   if (ret < 0)
 {
   return ret;
diff --git a/nshlib/nsh_usbconsole.c b/nshlib/nsh_usbconsole.c
index 5ec2ac4c9..bdde01986 100644
--- a/nshlib/nsh_usbconsole.c
+++ b/nshlib/nsh_usbconsole.c
@@ -284,10 +284,10 @@ int nsh_consolemain(int argc, FAR char *argv[])
   nsh_nullstdio();
 #endif
 
-  /* Execute the one-time start-up script (output may go to /dev/null) */
+#if defined(CONFIG_NSH_ROMFSETC) && !defined(CONFIG_NSH_DISABLESCRIPT)
+  /* Execute the system init script */
 
-#ifdef CONFIG_NSH_ROMFSETC
-  nsh_initscript(&pstate->cn_vtbl);
+  nsh_sysinitscript(&pstate->cn_vtbl);
 #endif
 
 #ifdef CONFIG_NSH_NETINIT
@@ -302,6 +302,12 @@ int nsh_consolemain(int argc, FAR char *argv[])
   boardctl(BOARDIOC_FINALINIT, 0);
 #endif
 
+  /* Execute the one-time start-up script (output may go to /dev/null) */
+
+#ifdef CONFIG_NSH_ROMFSETC
+  nsh_initscript(&pstate->cn_vtbl);
+#endif
+
   /* Now loop, executing creating a session for each USB connection */
 
   for (; ; )



[incubator-nuttx-apps] 02/04: nshlib: Call nsh_telnetstart in nsh_initialize to avoid the dupliation

2022-10-16 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 964747dd36db46428bd767d13aaee6f60f32d0b5
Author: Xiang Xiao 
AuthorDate: Sat Oct 15 17:00:22 2022 +0800

nshlib: Call nsh_telnetstart in nsh_initialize to avoid the dupliation

Signed-off-by: Xiang Xiao 
---
 examples/nxterm/nxterm_main.c| 16 
 graphics/nxwm/src/cnxterm.cxx| 14 --
 graphics/twm4nx/apps/cnxterm.cxx | 14 --
 nshlib/nsh_init.c| 14 +-
 system/nsh/nsh_main.c| 21 -
 5 files changed, 13 insertions(+), 66 deletions(-)

diff --git a/examples/nxterm/nxterm_main.c b/examples/nxterm/nxterm_main.c
index 57c19576b..8555980c5 100644
--- a/examples/nxterm/nxterm_main.c
+++ b/examples/nxterm/nxterm_main.c
@@ -223,22 +223,6 @@ int main(int argc, FAR char *argv[])
   printf("nxterm_main: Initialize NSH\n");
   nsh_initialize();
 
-  /* If the Telnet console is selected as a front-end, then start the
-   * Telnet daemon.
-   */
-
-#ifdef CONFIG_NSH_TELNET
-  ret = nsh_telnetstart(AF_UNSPEC);
-  if (ret < 0)
-{
-  /* The daemon is NOT running.  Report the error then fail...
-   * either with the serial console up or just exiting.
-   */
-
-  fprintf(stderr, "ERROR: Failed to start TELNET daemon: %d\n", ret);
-}
-#endif
-
   /* NX Initialization **/
 
   /* Initialize NX */
diff --git a/graphics/nxwm/src/cnxterm.cxx b/graphics/nxwm/src/cnxterm.cxx
index 1143f0032..d84fd1b03 100644
--- a/graphics/nxwm/src/cnxterm.cxx
+++ b/graphics/nxwm/src/cnxterm.cxx
@@ -653,19 +653,5 @@ bool NxWM::nshlibInitialize(void)
   // Initialize the NSH library
 
   nsh_initialize();
-
-  // If the Telnet console is selected as a front-end, then start the
-  // Telnet daemon.
-
-#ifdef CONFIG_NSH_TELNET
-  int ret = nsh_telnetstart(AF_UNSPEC);
-  if (ret < 0)
-{
-  // The daemon is NOT running!
-
-  return false;
-   }
-#endif
-
   return true;
 }
diff --git a/graphics/twm4nx/apps/cnxterm.cxx b/graphics/twm4nx/apps/cnxterm.cxx
index 3bd9821e6..d3cbd99d0 100644
--- a/graphics/twm4nx/apps/cnxterm.cxx
+++ b/graphics/twm4nx/apps/cnxterm.cxx
@@ -574,20 +574,6 @@ bool CNxTermFactory::nshlibInitialize(void)
   // Initialize the NSH library
 
   nsh_initialize();
-
-  // If the Telnet console is selected as a front-end, then start the
-  // Telnet daemon.
-
-#ifdef CONFIG_NSH_TELNET
-  int ret = nsh_telnetstart(AF_UNSPEC);
-  if (ret < 0)
-{
-  // The daemon is NOT running!
-
-  return false;
-   }
-#endif
-
   return true;
 }
 
diff --git a/nshlib/nsh_init.c b/nshlib/nsh_init.c
index 2cf68035e..251e6c452 100644
--- a/nshlib/nsh_init.c
+++ b/nshlib/nsh_init.c
@@ -54,7 +54,7 @@ static const struct extmatch_vtable_s g_nsh_extmatch =
  * Description:
  *   This interface is used to initialize the NuttShell (NSH).
  *   nsh_initialize() should be called once during application start-up prior
- *   to executing either nsh_consolemain() or nsh_telnetstart().
+ *   to executing nsh_consolemain().
  *
  * Input Parameters:
  *   None
@@ -87,4 +87,16 @@ void nsh_initialize(void)
 
   boardctl(BOARDIOC_INIT, 0);
 #endif
+
+#if defined(CONFIG_NSH_TELNET) && !defined(CONFIG_NSH_DISABLE_TELNETSTART) && \
+  !defined(CONFIG_NETINIT_NETLOCAL)
+  /* If the Telnet console is selected as a front-end, then start the
+   * Telnet daemon UNLESS network initialization is deferred via
+   * CONFIG_NETINIT_NETLOCAL.  In that case, the telnet daemon must be
+   * started manually with the telnetd command after the network has
+   * been initialized
+   */
+
+  nsh_telnetstart(AF_UNSPEC);
+#endif
 }
diff --git a/system/nsh/nsh_main.c b/system/nsh/nsh_main.c
index 5db22980f..7212fccbe 100644
--- a/system/nsh/nsh_main.c
+++ b/system/nsh/nsh_main.c
@@ -127,27 +127,6 @@ int main(int argc, FAR char *argv[])
 
   nsh_initialize();
 
-#if defined(CONFIG_NSH_TELNET) && !defined(CONFIG_NSH_DISABLE_TELNETSTART) && \
-  !defined(CONFIG_NETINIT_NETLOCAL)
-  /* If the Telnet console is selected as a front-end, then start the
-   * Telnet daemon UNLESS network initialization is deferred via
-   * CONFIG_NETINIT_NETLOCAL.  In that case, the telnet daemon must be
-   * started manually with the telnetd command after the network has
-   * been initialized
-   */
-
-  ret = nsh_telnetstart(AF_UNSPEC);
-  if (ret < 0)
-{
-  /* The daemon is NOT running.  Report the error then fail...
-   * either with the serial console up or just exiting.
-   */
-
-  fprintf(stderr, "ERROR: Failed to start TELNET daemon: %d\n", ret);
-  exitval = 1;
-}
-#endif
-
 #ifdef CONFIG_NSH_CONSOLE
   /* If the serial console front end is selected, run it on this thread */
 



[incubator-nuttx] branch master updated: net: move device buffer define to common header

2022-10-27 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new a8d3286258 net: move device buffer define to common header
a8d3286258 is described below

commit a8d32862586b47d9d3157328a0e7462cceb00486
Author: chao an 
AuthorDate: Wed Oct 26 12:35:08 2022 +0800

net: move device buffer define to common header

Signed-off-by: chao an 
---
 arch/arm/src/lpc54xx/lpc54_ethernet.c | 37 +++---
 arch/arm/src/tiva/lm/lm3s_ethernet.c  | 59 +--
 arch/z80/src/ez80/ez80_emac.c |  4 ---
 drivers/net/loopback.c|  5 ---
 drivers/net/slip.c|  7 ++---
 drivers/net/tun.c | 31 +-
 include/nuttx/net/netdev.h| 20 ++--
 net/arp/arp.h |  5 +++
 net/arp/arp_arpin.c   |  7 -
 net/arp/arp_format.c  |  7 -
 net/arp/arp_ipin.c| 11 ++-
 net/arp/arp_out.c | 10 +-
 net/can/can_poll.c|  2 +-
 net/devif/devif_loopback.c|  9 --
 net/devif/ipv4_input.c| 10 +-
 net/devif/ipv6_input.c|  5 +--
 net/icmp/icmp_input.c |  7 ++---
 net/icmp/icmp_poll.c  |  2 +-
 net/icmp/icmp_recvmsg.c   |  6 ++--
 net/icmp/icmp_reply.c |  2 --
 net/icmp/icmp_sendmsg.c   | 11 +--
 net/icmpv6/icmpv6_advertise.c | 11 +--
 net/icmpv6/icmpv6_input.c |  7 ++---
 net/icmpv6/icmpv6_poll.c  |  2 +-
 net/icmpv6/icmpv6_radvertise.c| 11 +--
 net/icmpv6/icmpv6_recvmsg.c   | 10 ++
 net/icmpv6/icmpv6_reply.c |  2 --
 net/icmpv6/icmpv6_rsolicit.c  | 10 +-
 net/icmpv6/icmpv6_sendmsg.c   | 11 +--
 net/icmpv6/icmpv6_solicit.c   | 10 +-
 net/igmp/igmp_input.c | 11 ++-
 net/igmp/igmp_poll.c  |  6 ++--
 net/igmp/igmp_send.c  |  6 ++--
 net/ipforward/ipfwd_forward.c |  4 +--
 net/ipforward/ipfwd_poll.c|  5 ++-
 net/ipforward/ipv4_forward.c  |  2 +-
 net/ipforward/ipv6_forward.c  |  2 +-
 net/mld/mld_poll.c|  2 +-
 net/mld/mld_query.c   |  6 
 net/mld/mld_send.c| 26 +--
 net/neighbor/neighbor_ethernet_out.c  |  7 -
 net/pkt/pkt_poll.c|  2 +-
 net/sixlowpan/sixlowpan_input.c   | 28 ++---
 net/tcp/tcp.h |  5 +++
 net/tcp/tcp_conn.c|  7 -
 net/tcp/tcp_input.c   | 47 +++-
 net/tcp/tcp_ipselect.c|  4 +--
 net/tcp/tcp_recvfrom.c| 10 --
 net/tcp/tcp_send.c| 10 --
 net/tcp/tcp_send_buffered.c   |  3 --
 net/tcp/tcp_send_unbuffered.c |  3 --
 net/tcp/tcp_sendfile.c|  7 -
 net/udp/udp.h |  5 +++
 net/udp/udp_callback.c| 10 --
 net/udp/udp_conn.c|  7 -
 net/udp/udp_input.c   | 19 ++-
 net/udp/udp_ipselect.c|  4 +--
 net/udp/udp_recvfrom.c| 10 --
 net/udp/udp_send.c| 14 -
 net/udp/udp_sendto_buffered.c |  3 --
 net/utils/net_icmpchksum.c| 10 ++
 net/utils/net_ipchksum.c  | 13 ++--
 62 files changed, 185 insertions(+), 444 deletions(-)

diff --git a/arch/arm/src/lpc54xx/lpc54_ethernet.c 
b/arch/arm/src/lpc54xx/lpc54_ethernet.c
index 15c7cf1a05..7a6aa7f7e4 100644
--- a/arch/arm/src/lpc54xx/lpc54_ethernet.c
+++ b/arch/arm/src/lpc54xx/lpc54_ethernet.c
@@ -251,7 +251,6 @@
  * header.
  */
 
-#define ETHBUF   ((struct eth_hdr_s *)priv->eth_dev.d_buf)
 #define ETH8021QWBUF ((struct eth_8021qhdr_s *)priv->eth_dev.d_buf)
 
 /
@@ -934,10 +933,12 @@ static void lpc54_eth_reply(struct lpc54_ethdriver_s 
*priv)
 
 static void lpc54_eth_rxdispatch(struct lpc54_ethdriver_s *priv)
 {
+  struct net_driver_s *dev = &priv->eth_dev;
+
 #ifdef CONFIG_NET_PKT
   /* When packet sockets are enabled, feed the frame into the tap */
 
-  pkt_input(&priv->eth_dev);
+  pkt_input(dev);
 #endif
 
   /* We only accept IP packets of the configured type and ARP packets */
@@ -946,14 +947,14 @@ static void lpc54_eth_rxdispatch(struct lpc54_ethdriver_s 
*priv)
   if (ETHBUF->type == HTONS(ETHTYPE_IP))
 {
   ninfo("IPv4 packet\n");
-  NETDEV_RXIPV4(&priv->eth_dev);
+  NETDEV_RXIPV4(dev);
 
   /* Handle AR

[incubator-nuttx] 02/02: Update stm32_bmp180.c

2022-07-26 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 0fddf71b2d517f2265a156b0b156d454d89e36d6
Author: simbit18 <101105604+simbi...@users.noreply.github.com>
AuthorDate: Tue Jul 26 11:08:23 2022 +0200

Update stm32_bmp180.c
---
 boards/arm/stm32l4/nucleo-l476rg/src/stm32_bmp180.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/boards/arm/stm32l4/nucleo-l476rg/src/stm32_bmp180.c 
b/boards/arm/stm32l4/nucleo-l476rg/src/stm32_bmp180.c
index 391695c75b..19713a3003 100644
--- a/boards/arm/stm32l4/nucleo-l476rg/src/stm32_bmp180.c
+++ b/boards/arm/stm32l4/nucleo-l476rg/src/stm32_bmp180.c
@@ -44,7 +44,7 @@
  * Name: stm32_bmp180initialize
  *
  * Description:
- *   Initialize and register the MPL115A Pressure Sensor driver.
+ *   Initialize and register the BMP180 Pressure Sensor driver.
  *
  * Input Parameters:
  *   devpath - The full path to the driver to register. E.g., "/dev/press0"



[incubator-nuttx] 01/02: Update stm32_bh1750.h

2022-07-26 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 3b3147ad75b246587ec675c955aaa8bda1d10523
Author: simbit18 <101105604+simbi...@users.noreply.github.com>
AuthorDate: Tue Jul 26 11:04:40 2022 +0200

Update stm32_bh1750.h
---
 boards/arm/stm32/common/include/stm32_bh1750.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/boards/arm/stm32/common/include/stm32_bh1750.h 
b/boards/arm/stm32/common/include/stm32_bh1750.h
index b3213013ea..8a089683bd 100644
--- a/boards/arm/stm32/common/include/stm32_bh1750.h
+++ b/boards/arm/stm32/common/include/stm32_bh1750.h
@@ -59,7 +59,7 @@ extern "C"
  * Name: board_bh1750_initialize
  *
  * Description:
- *   Initialize and register the MPL115A Pressure Sensor driver.
+ *   Initialize and register the BH1750FVI Ambient Light driver.
  *
  * Input Parameters:
  *   devno - The device number, used to build the device path as /dev/lightN



[incubator-nuttx] branch master updated (62e4f8ee79 -> 0fddf71b2d)

2022-07-26 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 62e4f8ee79 Update stm32_bh1750.c
 new 3b3147ad75 Update stm32_bh1750.h
 new 0fddf71b2d Update stm32_bmp180.c

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:
 boards/arm/stm32/common/include/stm32_bh1750.h  | 2 +-
 boards/arm/stm32l4/nucleo-l476rg/src/stm32_bmp180.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)



[incubator-nuttx] branch fix-tiva-typo created (now b322e8d02d)

2022-08-24 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a change to branch fix-tiva-typo
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git


  at b322e8d02d arch/tiva: Fix typo and minor code formatting

This branch includes the following new commits:

 new b322e8d02d arch/tiva: Fix typo and minor code formatting

The 1 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.




[incubator-nuttx] 01/01: arch/tiva: Fix typo and minor code formatting

2022-08-24 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a commit to branch fix-tiva-typo
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit b322e8d02dbc812558e0041f60992853ef97034f
Author: Nathan Hartman <59230071+hartmannat...@users.noreply.github.com>
AuthorDate: Wed Aug 24 10:40:22 2022 -0400

arch/tiva: Fix typo and minor code formatting
---
 arch/arm/src/tiva/common/tiva_serial.c | 14 +++---
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/arch/arm/src/tiva/common/tiva_serial.c 
b/arch/arm/src/tiva/common/tiva_serial.c
index 83d6f7f1c5..df4b7903ad 100644
--- a/arch/arm/src/tiva/common/tiva_serial.c
+++ b/arch/arm/src/tiva/common/tiva_serial.c
@@ -64,8 +64,8 @@
 #  error "No UARTs enabled"
 #endif
 
-/* Which UART with be tty0/console and which tty1-7?  The console will always
- * be ttyS0.  If there is no console then will use the lowest numbered UART.
+/* Which UART will be tty0/console and which tty1-7?  The console will always
+ * be ttyS0.  If there is no console then we'll use the lowest numbered UART.
  */
 
 /* First pick the console and ttys0.  This could be any of UART0-5 */
@@ -123,10 +123,10 @@
 #define TTYS0_DEV   g_uart5port /* UART5 is ttyS0 */
 #define UART5_ASSIGNED  1
 #  elif defined(CONFIG_TIVA_UART6)
-#define TTYS0_DEV   g_uart6port /* UART5 is ttyS0 */
+#define TTYS0_DEV   g_uart6port /* UART6 is ttyS0 */
 #define UART6_ASSIGNED  1
 #  elif defined(CONFIG_TIVA_UART7)
-#define TTYS0_DEV   g_uart7port /* UART5 is ttyS0 */
+#define TTYS0_DEV   g_uart7port /* UART7 is ttyS0 */
 #define UART7_ASSIGNED  1
 #  endif
 #endif
@@ -270,8 +270,8 @@
 #endif
 
 /* Pick ttys7. This could be one of UART6-7. It can't be UART0-5 because
- * those have already been assigned to ttsyS0, 1, 2, 3, 4, or 6.  One of
- * UART 6-7 could also be the console.
+ * those have already been assigned to ttsyS0, 1, 2, 3, 4, 5, or 6.  One
+ * of UART 6-7 could also be the console.
  */
 
 #if defined(CONFIG_TIVA_UART6) && !defined(UART6_ASSIGNED)
@@ -844,8 +844,8 @@ static void up_set_format(struct uart_dev_s *dev)
   case 7:
   lcrh |= UART_LCRH_WLEN_7BITS;
   break;
-  case 8:
 
+  case 8:
   default:
   lcrh |= UART_LCRH_WLEN_8BITS;
   break;



[incubator-nuttx] branch strtod-fixes created (now 1d803dd7a8)

2022-08-29 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a change to branch strtod-fixes
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git


  at 1d803dd7a8 libc: Port strtod fixes to strtof, strtold and improve 
comments

This branch includes the following new commits:

 new 1d803dd7a8 libc: Port strtod fixes to strtof, strtold and improve 
comments

The 1 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.




[incubator-nuttx] 01/01: libc: Port strtod fixes to strtof, strtold and improve comments

2022-08-29 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a commit to branch strtod-fixes
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit 1d803dd7a81a09097cd0dee66ef396ad55452457
Author: Nathan Hartman <59230071+hartmannat...@users.noreply.github.com>
AuthorDate: Mon Aug 29 16:53:36 2022 -0400

libc: Port strtod fixes to strtof, strtold and improve comments

* libs/libc/stdlib/lib_strtod.c:
  (strtod): Add a note about limitations of this implementation
   as compared to POSIX in the function's docstring. Also fix a
   typo.

* libs/libc/stdlib/lib_strtof.c:
  (strtof): Port the changes made to strtod in PR-6952 (commit
   c83985c5ce7) and add same note as above to docstring.

* libs/libc/stdlib/lib_strtold.c:
  (strtold): Same changes as strtof.
---
 libs/libc/stdlib/lib_strtod.c  |  6 +-
 libs/libc/stdlib/lib_strtof.c  | 15 ++-
 libs/libc/stdlib/lib_strtold.c | 15 ++-
 3 files changed, 33 insertions(+), 3 deletions(-)

diff --git a/libs/libc/stdlib/lib_strtod.c b/libs/libc/stdlib/lib_strtod.c
index 358eb5aec2..fe8e48ff4b 100644
--- a/libs/libc/stdlib/lib_strtod.c
+++ b/libs/libc/stdlib/lib_strtod.c
@@ -79,12 +79,16 @@ static inline int is_real(double x)
  * Public Functions
  /
 
-/***(
+/
  * Name: strtod
  *
  * Description:
  *   Convert a string to a double value
  *
+ *   NOTE: This implementation is limited as compared to POSIX:
+ *   - Hexadecimal input is not supported
+ *   - INF, INFINITY, NAN, and NAN(...) are not supported
+ *
  /
 
 double strtod(FAR const char *str, FAR char **endptr)
diff --git a/libs/libc/stdlib/lib_strtof.c b/libs/libc/stdlib/lib_strtof.c
index 246a5183ad..176a5c5333 100644
--- a/libs/libc/stdlib/lib_strtof.c
+++ b/libs/libc/stdlib/lib_strtof.c
@@ -86,12 +86,16 @@ static inline int is_real(float x)
  * Public Functions
  /
 
-/***(
+/
  * Name: strtof
  *
  * Description:
  *   Convert a string to a float value
  *
+ *   NOTE: This implementation is limited as compared to POSIX:
+ *   - Hexadecimal input is not supported
+ *   - INF, INFINITY, NAN, and NAN(...) are not supported
+ *
  /
 
 float strtof(FAR const char *str, FAR char **endptr)
@@ -173,6 +177,7 @@ float strtof(FAR const char *str, FAR char **endptr)
 {
   set_errno(ERANGE);
   number = 0.0F;
+  p = (FAR char *)str;
   goto errout;
 }
 
@@ -208,6 +213,14 @@ float strtof(FAR const char *str, FAR char **endptr)
 
   /* Process string of digits */
 
+  if (!isdigit(*p))
+{
+  set_errno(ERANGE);
+  number = 0.0F;
+  p = (FAR char *)str;
+  goto errout;
+}
+
   n = 0;
   while (isdigit(*p))
 {
diff --git a/libs/libc/stdlib/lib_strtold.c b/libs/libc/stdlib/lib_strtold.c
index 322685f699..cd569561d2 100644
--- a/libs/libc/stdlib/lib_strtold.c
+++ b/libs/libc/stdlib/lib_strtold.c
@@ -79,12 +79,16 @@ static inline int is_real(long double x)
  * Public Functions
  /
 
-/***(
+/
  * Name: strtold
  *
  * Description:
  *   Convert a string to a long double value
  *
+ *   NOTE: This implementation is limited as compared to POSIX:
+ *   - Hexadecimal input is not supported
+ *   - INF, INFINITY, NAN, and NAN(...) are not supported
+ *
  /
 
 long double strtold(FAR const char *str, FAR char **endptr)
@@ -160,6 +164,7 @@ long double strtold(FAR const char *str, FAR char **endptr)
 {
   set_errno(ERANGE);
   number = 0.0L;
+  p = (FAR char *)str;
   goto errout;
 }
 
@@ -195,6 +200,14 @@ long double strtold(FAR const char *str, FAR char **endptr)
 
   /* Process string of digits */
 
+  if (!isdigit(*p))
+{
+  set_errno(ERANGE);
+  number = 0.0L;
+  p = (FAR char *)str;
+  goto errout;
+}
+
   n = 0;
   while (isdigit(*p))
 {



[incubator-nuttx] branch master updated: arch/arm: change context switch to macro

2022-08-31 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new c82798c66a arch/arm: change context switch to macro
c82798c66a is described below

commit c82798c66a0c9cdb0def74edd4ee0b3939a78973
Author: zhangyuan21 
AuthorDate: Wed Aug 31 17:31:45 2022 +0800

arch/arm: change context switch to macro
---
 arch/arm/src/common/Make.defs|  4 +--
 arch/arm/src/common/arm_exit.c   |  6 
 arch/arm/src/common/arm_fullcontextrestore.c | 49 
 arch/arm/src/common/arm_internal.h   | 11 +--
 arch/arm/src/common/arm_switchcontext.c  | 47 --
 5 files changed, 17 insertions(+), 100 deletions(-)

diff --git a/arch/arm/src/common/Make.defs b/arch/arm/src/common/Make.defs
index 4d5061fa06..cbd3054948 100644
--- a/arch/arm/src/common/Make.defs
+++ b/arch/arm/src/common/Make.defs
@@ -21,12 +21,12 @@
 # Common ARM files
 
 CMN_CSRCS += arm_allocateheap.c arm_assert.c arm_blocktask.c
-CMN_CSRCS += arm_createstack.c arm_exit.c arm_fullcontextrestore.c
+CMN_CSRCS += arm_createstack.c arm_exit.c
 CMN_CSRCS += arm_initialize.c arm_lowputs.c
 CMN_CSRCS += arm_modifyreg16.c arm_modifyreg32.c
 CMN_CSRCS += arm_modifyreg8.c arm_nputs.c arm_releasepending.c
 CMN_CSRCS += arm_releasestack.c arm_reprioritizertr.c arm_saveusercontext.c
-CMN_CSRCS += arm_stackframe.c arm_switchcontext.c
+CMN_CSRCS += arm_stackframe.c
 CMN_CSRCS += arm_vfork.c arm_unblocktask.c arm_usestack.c
 
 ifneq ($(CONFIG_ALARM_ARCH),y)
diff --git a/arch/arm/src/common/arm_exit.c b/arch/arm/src/common/arm_exit.c
index 972db8d265..a8689672ea 100644
--- a/arch/arm/src/common/arm_exit.c
+++ b/arch/arm/src/common/arm_exit.c
@@ -139,4 +139,10 @@ void up_exit(int status)
   /* Then switch contexts */
 
   arm_fullcontextrestore(tcb->xcp.regs);
+
+  /* arm_fullcontextrestore() should not return but could if the software
+   * interrupts are disabled.
+   */
+
+  PANIC();
 }
diff --git a/arch/arm/src/common/arm_fullcontextrestore.c 
b/arch/arm/src/common/arm_fullcontextrestore.c
deleted file mode 100644
index 4ed95305b9..00
--- a/arch/arm/src/common/arm_fullcontextrestore.c
+++ /dev/null
@@ -1,49 +0,0 @@
-/
- * arch/arm/src/common/arm_fullcontextrestore.c
- *
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.  The
- * ASF licenses this file to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance with the
- * License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
- * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.  See the
- * License for the specific language governing permissions and limitations
- * under the License.
- *
- /
-
-/
- * Included Files
- /
-
-#include 
-
-#include 
-
-/
- * Public Functions
- /
-
-/
- * Name: arm_fullcontextrestore
- *
- * Description:
- *   Restore the current thread context.  Full prototype is:
- *
- *   void arm_fullcontextrestore(uint32_t *restoreregs) noreturn_function;
- *
- * Returned Value:
- *   None
- *
- /
-
-void arm_fullcontextrestore(uint32_t *restoreregs)
-{
-  sys_call1(SYS_restore_context, (uintptr_t)restoreregs);
-}
diff --git a/arch/arm/src/common/arm_internal.h 
b/arch/arm/src/common/arm_internal.h
index 02c0b53852..4130043bd9 100644
--- a/arch/arm/src/common/arm_internal.h
+++ b/arch/arm/src/common/arm_internal.h
@@ -32,6 +32,7 @@
 #  include 
 #  include 
 #  include 
+#  include 
 #endif
 
 /
@@ -139,6 +140,14 @@
 #define modreg16(v,m,a) putreg16((getreg16(a) & ~(m)) | ((v) & (m)), (a))
 #define modreg32(v,m,a) putreg32((getreg32(a) & ~(m)) | ((v) & (m)), (a))
 
+/* Context switching */
+
+#define arm_fullcontextrestore(restoreregs) \
+  sys_call1(SYS_restore_conte

[incubator-nuttx-apps] branch master updated: ftpd: server port made configurable.

2022-09-04 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 387eba2ef ftpd: server port made configurable.
387eba2ef is described below

commit 387eba2efd53b057fc53a7c49590a6e1c9786017
Author: Fotis Panagiotopoulos 
AuthorDate: Sat Sep 3 17:42:08 2022 +0300

ftpd: server port made configurable.
---
 examples/ftpd/Kconfig |  4 
 examples/ftpd/ftpd_main.c |  6 --
 include/netutils/ftpd.h   |  3 ++-
 netutils/ftpd/ftpd.c  | 12 +---
 4 files changed, 15 insertions(+), 10 deletions(-)

diff --git a/examples/ftpd/Kconfig b/examples/ftpd/Kconfig
index b2edd881e..ab9b1e94c 100644
--- a/examples/ftpd/Kconfig
+++ b/examples/ftpd/Kconfig
@@ -11,6 +11,10 @@ config EXAMPLES_FTPD
 
 if EXAMPLES_FTPD
 
+config EXAMPLES_FTPD_PORT
+   int "FTP Daemon Port"
+   default 21
+
 config EXAMPLES_FTPD_STACKSIZE
int "FTP Daemon Stack Size"
default DEFAULT_TASK_STACKSIZE
diff --git a/examples/ftpd/ftpd_main.c b/examples/ftpd/ftpd_main.c
index 14991e158..755b534a0 100644
--- a/examples/ftpd/ftpd_main.c
+++ b/examples/ftpd/ftpd_main.c
@@ -22,6 +22,8 @@
  * Included Files
  /
 
+#include 
+
 #include 
 
 #include 
@@ -169,9 +171,9 @@ int ftpd_daemon(int s_argc, char **s_argv)
   /* Open FTPD */
 
 #if ADDR_FAMILY == AF_INET6
-  handle = ftpd_open(AF_INET6);
+  handle = ftpd_open(CONFIG_EXAMPLES_FTPD_PORT, AF_INET6);
 #else
-  handle = ftpd_open(AF_INET);
+  handle = ftpd_open(CONFIG_EXAMPLES_FTPD_PORT, AF_INET);
 #endif
 
   if (!handle)
diff --git a/include/netutils/ftpd.h b/include/netutils/ftpd.h
index 1ebf8164e..31b3ffd1c 100644
--- a/include/netutils/ftpd.h
+++ b/include/netutils/ftpd.h
@@ -119,6 +119,7 @@ extern "C"
  *   used to run the server.
  *
  * Input Parameters:
+ *port - The port that the server will listen to.
  *family - The type of INET family to use when opening the socket.
  *AF_INET and AF_INET6 are supported.
  *
@@ -128,7 +129,7 @@ extern "C"
  *
  /
 
-FTPD_SESSION ftpd_open(sa_family_t family);
+FTPD_SESSION ftpd_open(int port, sa_family_t family);
 
 /
  * Name: ftpd_adduser
diff --git a/netutils/ftpd/ftpd.c b/netutils/ftpd/ftpd.c
index 5dc40e5ed..4aff864a3 100644
--- a/netutils/ftpd/ftpd.c
+++ b/netutils/ftpd/ftpd.c
@@ -4262,7 +4262,9 @@ static FAR void *ftpd_worker(FAR void *arg)
  *   used to run the server.
  *
  * Input Parameters:
- *None
+ *port - The port that the server will listen to.
+ *family - The type of INET family to use when opening the socket.
+ *AF_INET and AF_INET6 are supported.
  *
  * Returned Value:
  *   On success, a non-NULL handle is returned that can be used to reference
@@ -4270,15 +4272,11 @@ static FAR void *ftpd_worker(FAR void *arg)
  *
  /
 
-FTPD_SESSION ftpd_open(sa_family_t family)
+FTPD_SESSION ftpd_open(int port, sa_family_t family)
 {
   FAR struct ftpd_server_s *server;
 
-  server = ftpd_openserver(21, family);
-  if (server == NULL)
-{
-  server = ftpd_openserver(2211, family);
-}
+  server = ftpd_openserver(port, family);
 
   return (FTPD_SESSION)server;
 }



[incubator-nuttx] 02/02: stm32h7: SPI is no more experimental

2022-09-06 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 179d64d99919dd77b1ae43087d82361344e00126
Author: Sebastien Lorquet 
AuthorDate: Tue Sep 6 15:39:49 2022 +0200

stm32h7: SPI is no more experimental
---
 arch/arm/src/stm32h7/Kconfig | 9 +++--
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/arch/arm/src/stm32h7/Kconfig b/arch/arm/src/stm32h7/Kconfig
index 8854ab0cb8..d22b2f92e0 100644
--- a/arch/arm/src/stm32h7/Kconfig
+++ b/arch/arm/src/stm32h7/Kconfig
@@ -655,42 +655,39 @@ menu "STM32H7 SPI Selection"
 config STM32H7_SPI1
bool "SPI1"
default n
-   depends on EXPERIMENTAL
select SPI
select STM32H7_SPI
 
 config STM32H7_SPI2
bool "SPI2"
default n
-   depends on EXPERIMENTAL
select SPI
select STM32H7_SPI
 
 config STM32H7_SPI3
bool "SPI3"
default n
-   depends on EXPERIMENTAL
select SPI
select STM32H7_SPI
 
 config STM32H7_SPI4
bool "SPI4"
default n
-   depends on STM32H7_HAVE_SPI4 && EXPERIMENTAL
+   depends on STM32H7_HAVE_SPI4
select SPI
select STM32H7_SPI
 
 config STM32H7_SPI5
bool "SPI5"
default n
-   depends on STM32H7_HAVE_SPI5 && EXPERIMENTAL
+   depends on STM32H7_HAVE_SPI5
select SPI
select STM32H7_SPI
 
 config STM32H7_SPI6
bool "SPI6"
default n
-   depends on STM32H7_HAVE_SPI6 && EXPERIMENTAL
+   depends on STM32H7_HAVE_SPI6
select SPI
select STM32H7_SPI
 



[incubator-nuttx] 01/02: update conditionals to select stm32h7 spi peripherals

2022-09-06 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 3e16b6c9f168bb26d708dfaef420f61b246facf2
Author: Sebastien Lorquet 
AuthorDate: Tue Sep 6 15:38:41 2022 +0200

update conditionals to select stm32h7 spi peripherals
---
 arch/arm/src/stm32h7/Kconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/src/stm32h7/Kconfig b/arch/arm/src/stm32h7/Kconfig
index 1e1aa4b98d..8854ab0cb8 100644
--- a/arch/arm/src/stm32h7/Kconfig
+++ b/arch/arm/src/stm32h7/Kconfig
@@ -694,12 +694,12 @@ config STM32H7_SPI6
select SPI
select STM32H7_SPI
 
+endmenu # STM32H7 SPI Selection
+
 config STM32H7_SYSCFG
bool "SYSCFG"
default y
 
-endmenu # STM32H7 SPI Selection
-
 menu "STM32H7 Timer Selection"
 
 config STM32H7_TIM1



[incubator-nuttx] branch master updated (54dba40f87 -> 179d64d999)

2022-09-06 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 54dba40f87 net/netdev/ioctl: correct the argument length of ioctl 
MII/PHY
 new 3e16b6c9f1 update conditionals to select stm32h7 spi peripherals
 new 179d64d999 stm32h7: SPI is no more experimental

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


Summary of changes:
 arch/arm/src/stm32h7/Kconfig | 13 +
 1 file changed, 5 insertions(+), 8 deletions(-)



[incubator-nuttx] branch master updated (1913163c64 -> 72313301e2)

2022-09-13 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 1913163c64 drivers: Fix some Kconfig help texts
 add 72313301e2 net/w5500: Fix small typo

No new revisions were added by this update.

Summary of changes:
 drivers/net/w5500.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)



[nuttx-website] 01/01: project.yml: Fix typo in value of unix_name

2022-11-25 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a commit to branch typo-unix-name
in repository https://gitbox.apache.org/repos/asf/nuttx-website.git

commit 39f599dff255b79f68d1072e0b8f5211d50e3b15
Author: Nathan Hartman <59230071+hartmannat...@users.noreply.github.com>
AuthorDate: Fri Nov 25 14:23:08 2022 -0500

project.yml: Fix typo in value of unix_name

Although unix_name is not currently utilized (except in a commented
section), fixing this typo to prevent it being used by mistake in the
future.
---
 _data/project.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/_data/project.yml b/_data/project.yml
index 261f1e21..db58a387 100644
--- a/_data/project.yml
+++ b/_data/project.yml
@@ -17,7 +17,7 @@
 #
 name: Apache NuttX
 short_name: NuttX
-unix_name: nuxxt
+unix_name: nuttx
 incubator_name: nuttx
 incubator_slash_name: incubator/nuttx
 description: Apache NuttX is a mature, real-time embedded operating system 
(RTOS).



[nuttx-website] branch typo-unix-name created (now 39f599df)

2022-11-25 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a change to branch typo-unix-name
in repository https://gitbox.apache.org/repos/asf/nuttx-website.git


  at 39f599df project.yml: Fix typo in value of unix_name

This branch includes the following new commits:

 new 39f599df project.yml: Fix typo in value of unix_name

The 1 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.




[nuttx-website] branch https-nav created (now cf38b4d0)

2022-11-25 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan pushed a change to branch https-nav
in repository https://gitbox.apache.org/repos/asf/nuttx-website.git


  at cf38b4d0 Navigation: Use https for user-facing apache.org links

This branch includes the following new commits:

 new cf38b4d0 Navigation: Use https for user-facing apache.org links

The 1 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.




[nuttx-website] 01/01: Navigation: Use https for user-facing apache.org links

2022-11-25 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit cf38b4d0880dbf986db5ad9473999ff4fde3d3db
Author: Nathan Hartman <59230071+hartmannat...@users.noreply.github.com>
AuthorDate: Fri Nov 25 14:28:53 2022 -0500

Navigation: Use https for user-facing apache.org links

* _includes/themes/apache/_navigation.html:
  (dropdown-menu): Change http:// to https:// in navigation links to
   License, Security, and other foundation-wide links.
---
 _includes/themes/apache/_navigation.html | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/_includes/themes/apache/_navigation.html 
b/_includes/themes/apache/_navigation.html
index d06f1f62..1617db1e 100644
--- a/_includes/themes/apache/_navigation.html
+++ b/_includes/themes/apache/_navigation.html
@@ -26,13 +26,13 @@
 
   Apache

-http://www.apache.org/foundation/how-it-works.html";>Apache Software 
Foundation
-http://www.apache.org/licenses/";>License
-http://www.apache.org/security/";>Security
+https://www.apache.org/foundation/how-it-works.html";>Apache Software 
Foundation
+https://www.apache.org/licenses/";>License
+https://www.apache.org/security/";>Security
 https://privacy.apache.org/policies/privacy-policy-public.html";>Privacy
-http://www.apache.org/events/current-event";>Events
-http://www.apache.org/foundation/sponsorship.html";>Sponsorship
-http://www.apache.org/foundation/thanks.html";>Thanks
+https://www.apache.org/events/current-event";>Events
+https://www.apache.org/foundation/sponsorship.html";>Sponsorship
+https://www.apache.org/foundation/thanks.html";>Thanks
 
 
   



[incubator-nuttx] branch master updated: arm/cxd56xx: Beautify the coding style in cxd56_gnss.c

2021-03-01 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 3d24288  arm/cxd56xx: Beautify the coding style in cxd56_gnss.c
3d24288 is described below

commit 3d24288a6632afc119e80629daee866b6fc6e875
Author: Xiang Xiao 
AuthorDate: Tue Feb 23 11:03:17 2021 +0800

arm/cxd56xx: Beautify the coding style in cxd56_gnss.c

Signed-off-by: Xiang Xiao 
---
 arch/arm/src/cxd56xx/cxd56_gnss.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/arm/src/cxd56xx/cxd56_gnss.c 
b/arch/arm/src/cxd56xx/cxd56_gnss.c
index 0cbe789..68aebfd 100644
--- a/arch/arm/src/cxd56xx/cxd56_gnss.c
+++ b/arch/arm/src/cxd56xx/cxd56_gnss.c
@@ -890,10 +890,10 @@ static int cxd56_gnss_set_ephemeris(FAR struct file 
*filep,
 static int cxd56_gnss_save_backup_data(FAR struct file *filep,
unsigned longarg)
 {
-  FAR char *buf;
+  FAR char   *buf;
   struct file file;
-  int   n = 0;
-  int32_t   offset = 0;
+  int n = 0;
+  int32_t offset = 0;
 
   buf = (char *)kmm_malloc(CONFIG_CXD56_GNSS_BACKUP_BUFFER_SIZE);
   if (buf == NULL)
@@ -2207,7 +2207,7 @@ cxd56_gnss_read_cep_file(FAR struct file *fp, int32_t 
offset,
 
 static void cxd56_gnss_read_backup_file(FAR int *retval)
 {
-  FAR char *  buf;
+  FAR char   *buf;
   struct file file;
   int32_t offset = 0;
   size_t  n;



[incubator-nuttx] branch master updated: Move "-nostartfiles -nodefaultlibs" from Make.defs to Toolchian.defs

2022-05-18 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new b30e0a26ef Move "-nostartfiles -nodefaultlibs" from Make.defs to 
Toolchian.defs
b30e0a26ef is described below

commit b30e0a26efae828b3505059ffaa3a75df74236c0
Author: Xiang Xiao 
AuthorDate: Sun May 15 12:32:04 2022 +0800

Move "-nostartfiles -nodefaultlibs" from Make.defs to Toolchian.defs

and replace "-nostartfiles -nodefaultlibs" with "-nostdlib"

Signed-off-by: Xiang Xiao 
---
 Documentation/guides/cpp_cmake.rst   |  2 +-
 arch/arm/src/arm/Toolchain.defs  |  3 ++-
 arch/arm/src/armv7-a/Toolchain.defs  |  3 ++-
 arch/arm/src/armv7-m/Toolchain.defs  |  3 ++-
 arch/arm/src/armv7-r/Toolchain.defs  |  3 ++-
 arch/arm/src/armv8-m/Toolchain.defs  |  3 ++-
 arch/arm/src/rp2040/boot2/Make.defs  |  2 +-
 arch/arm/src/tlsr82/Toolchain.defs   |  2 ++
 arch/avr/src/avr/Toolchain.defs  |  2 ++
 arch/avr/src/avr32/Toolchain.defs|  2 ++
 arch/mips/src/mips32/Toolchain.defs  | 13 ++---
 arch/misoc/src/lm32/Toolchain.defs   |  2 ++
 arch/misoc/src/minerva/Toolchain.defs|  2 ++
 arch/or1k/src/mor1kx/Toolchain.defs  |  3 ++-
 arch/risc-v/src/common/Toolchain.defs|  3 ++-
 arch/sparc/src/sparc_v8/Toolchain.defs   |  4 ++--
 arch/xtensa/src/lx6/Toolchain.defs   |  2 ++
 arch/xtensa/src/lx7/Toolchain.defs   |  2 ++
 arch/z80/src/ez80/Toolchain.defs |  2 ++
 boards/arm/eoss3/quickfeather/scripts/Make.defs  |  6 +-
 boards/arm/stm32/nucleo-f446re/scripts/Make.defs |  6 --
 boards/arm/stm32/nucleo-f4x1re/scripts/Make.defs |  6 --
 boards/arm/stm32/stm32f4discovery/scripts/Make.defs  |  6 +-
 boards/arm/stm32f7/stm32f746g-disco/scripts/Make.defs|  5 -
 boards/mips/pic32mz/chipkit-wifire/scripts/Make.defs |  4 +---
 boards/mips/pic32mz/flipnclick-pic32mz/scripts/Make.defs |  4 +---
 boards/mips/pic32mz/pic32mz-starterkit/scripts/Make.defs |  4 +---
 boards/sparc/bm3803/xx3803/scripts/Make.defs |  6 --
 28 files changed, 41 insertions(+), 64 deletions(-)

diff --git a/Documentation/guides/cpp_cmake.rst 
b/Documentation/guides/cpp_cmake.rst
index 0a6299a935..5ac464ce45 100644
--- a/Documentation/guides/cpp_cmake.rst
+++ b/Documentation/guides/cpp_cmake.rst
@@ -147,7 +147,7 @@ Creating the project
 set(AC_HW_FLAGS "${AC_HW_FLAGS} -isystem ${NUTTX_PATH}/include")
 set(AC_HW_FLAGS "${AC_HW_FLAGS} -pipe")
 
-set(AC_LINKER_FLAGS "--entry=__start -nostartfiles -nodefaultlibs 
-T${MCU_LINKER_SCRIPT}")
+set(AC_LINKER_FLAGS "--entry=__start -nostdlib -T${MCU_LINKER_SCRIPT}")
 
 * hellocpp/src/CMakeLists.txt
 
diff --git a/arch/arm/src/arm/Toolchain.defs b/arch/arm/src/arm/Toolchain.defs
index 73c10a5b3e..595c139fbc 100644
--- a/arch/arm/src/arm/Toolchain.defs
+++ b/arch/arm/src/arm/Toolchain.defs
@@ -113,6 +113,8 @@ ifneq ($(CONFIG_CXX_RTTI),y)
   ARCHCXXFLAGS += -fno-rtti
 endif
 
+LDFLAGS += -nostdlib
+
 # Optimization of unused sections
 
 ifeq ($(CONFIG_DEBUG_OPT_UNUSED_SECTIONS),y)
@@ -153,7 +155,6 @@ ifeq ($(CONFIG_LTO_FULL),y)
 NM := $(CROSSDEV)gcc-nm
 ARCHOPTIMIZATION += -fuse-linker-plugin
 ARCHOPTIMIZATION += -fno-builtin
-ARCHOPTIMIZATION += -nodefaultlibs
   endif
 endif
 
diff --git a/arch/arm/src/armv7-a/Toolchain.defs 
b/arch/arm/src/armv7-a/Toolchain.defs
index 9942b23c61..09eb4cb6c2 100644
--- a/arch/arm/src/armv7-a/Toolchain.defs
+++ b/arch/arm/src/armv7-a/Toolchain.defs
@@ -144,6 +144,8 @@ ifneq ($(CONFIG_CXX_RTTI),y)
   ARCHCXXFLAGS += -fno-rtti
 endif
 
+LDFLAGS += -nostdlib
+
 # Optimization of unused sections
 
 ifeq ($(CONFIG_DEBUG_OPT_UNUSED_SECTIONS),y)
@@ -200,7 +202,6 @@ ifeq ($(CONFIG_LTO_FULL),y)
 NM := $(CROSSDEV)gcc-nm
 ARCHOPTIMIZATION += -fuse-linker-plugin
 ARCHOPTIMIZATION += -fno-builtin
-ARCHOPTIMIZATION += -nodefaultlibs
   endif
 endif
 
diff --git a/arch/arm/src/armv7-m/Toolchain.defs 
b/arch/arm/src/armv7-m/Toolchain.defs
index 592f7a7cbb..deb910df49 100644
--- a/arch/arm/src/armv7-m/Toolchain.defs
+++ b/arch/arm/src/armv7-m/Toolchain.defs
@@ -222,7 +222,6 @@ else
   AR := $(CROSSDEV)gcc-ar rcs
   NM := $(CROSSDEV)gcc-nm
   ARCHOPTIMIZATION += -fno-builtin
-  ARCHOPTIMIZATION += -nodefaultlibs
 endif
   endif
 endif
@@ -243,6 +242,8 @@ ifneq ($(CONFIG_CXX_RTTI),y)
   ARCHCXXFLAGS 

[incubator-nuttx] branch master updated: net_if: add IFF_LOOPBACK/POINTOPOINT/MULTICAST/BROADCAST

2022-07-03 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new c7c5c75451 net_if: add IFF_LOOPBACK/POINTOPOINT/MULTICAST/BROADCAST
c7c5c75451 is described below

commit c7c5c754511c2ce50ab3cd83e104c0ec94477896
Author: zhanghongyu 
AuthorDate: Wed Jun 1 12:47:30 2022 +0800

net_if: add IFF_LOOPBACK/POINTOPOINT/MULTICAST/BROADCAST

Signed-off-by: zhanghongyu 
---
 include/net/if.h | 66 +++-
 include/nuttx/net/netdev.h   |  2 +-
 net/netdev/netdev_register.c | 12 
 3 files changed, 54 insertions(+), 26 deletions(-)

diff --git a/include/net/if.h b/include/net/if.h
index 0dde170c00..15751e744d 100644
--- a/include/net/if.h
+++ b/include/net/if.h
@@ -46,32 +46,48 @@
 
 /* Interface flag bits */
 
-#define IFF_DOWN   (1 << 0) /* Interface is down */
-#define IFF_UP (1 << 1) /* Interface is up */
-#define IFF_RUNNING(1 << 2) /* Carrier is available */
-#define IFF_IPv6   (1 << 3) /* Configured for IPv6 packet (vs ARP or 
IPv4) */
-#define IFF_BOUND  (1 << 4) /* Bound to a socket */
-#define IFF_NOARP  (1 << 7) /* ARP is not required for this packet */
+#define IFF_DOWN   (1 << 0)  /* Interface is down */
+#define IFF_UP (1 << 1)  /* Interface is up */
+#define IFF_RUNNING(1 << 2)  /* Carrier is available */
+#define IFF_IPv6   (1 << 3)  /* Configured for IPv6 packet (vs ARP or 
IPv4) */
+#define IFF_BOUND  (1 << 4)  /* Bound to a socket */
+#define IFF_LOOPBACK   (1 << 5)  /* Is a loopback net */
+#define IFF_POINTOPOINT(1 << 6)  /* Is point-to-point link */
+#define IFF_NOARP  (1 << 7)  /* ARP is not required for this packet */
+#define IFF_MULTICAST  (1 << 12) /* Supports multicast. */
+#define IFF_BROADCAST  (1 << 13) /* Broadcast address valid. */
 
 /* Interface flag helpers */
 
-#define IFF_SET_DOWN(f)do { (f) |= IFF_DOWN; } while (0)
-#define IFF_SET_UP(f)  do { (f) |= IFF_UP; } while (0)
-#define IFF_SET_RUNNING(f) do { (f) |= IFF_RUNNING; } while (0)
-#define IFF_SET_BOUND(f)   do { (f) |= IFF_BOUND; } while (0)
-#define IFF_SET_NOARP(f)   do { (f) |= IFF_NOARP; } while (0)
-
-#define IFF_CLR_DOWN(f)do { (f) &= ~IFF_DOWN; } while (0)
-#define IFF_CLR_UP(f)  do { (f) &= ~IFF_UP; } while (0)
-#define IFF_CLR_RUNNING(f) do { (f) &= ~IFF_RUNNING; } while (0)
-#define IFF_CLR_BOUND(f)   do { (f) &= ~IFF_BOUND; } while (0)
-#define IFF_CLR_NOARP(f)   do { (f) &= ~IFF_NOARP; } while (0)
-
-#define IFF_IS_DOWN(f) (((f) & IFF_DOWN) != 0)
-#define IFF_IS_UP(f)   (((f) & IFF_UP) != 0)
-#define IFF_IS_RUNNING(f)  (((f) & IFF_RUNNING) != 0)
-#define IFF_IS_BOUND(f)(((f) & IFF_BOUND) != 0)
-#define IFF_IS_NOARP(f)(((f) & IFF_NOARP) != 0)
+#define IFF_SET_DOWN(f)do { (f) |= IFF_DOWN; } while (0)
+#define IFF_SET_UP(f)  do { (f) |= IFF_UP; } while (0)
+#define IFF_SET_RUNNING(f) do { (f) |= IFF_RUNNING; } while (0)
+#define IFF_SET_BOUND(f)   do { (f) |= IFF_BOUND; } while (0)
+#define IFF_SET_NOARP(f)   do { (f) |= IFF_NOARP; } while (0)
+#define IFF_SET_LOOPBACK(f)do { (f) |= IFF_LOOPBACK; } while (0)
+#define IFF_SET_POINTOPOINT(f) do { (f) |= IFF_POINTOPOINT; } while (0)
+#define IFF_SET_MULTICAST(f)   do { (f) |= IFF_MULTICAST; } while (0)
+#define IFF_SET_BROADCAST(f)   do { (f) |= IFF_BROADCAST; } while (0)
+
+#define IFF_CLR_DOWN(f)do { (f) &= ~IFF_DOWN; } while (0)
+#define IFF_CLR_UP(f)  do { (f) &= ~IFF_UP; } while (0)
+#define IFF_CLR_RUNNING(f) do { (f) &= ~IFF_RUNNING; } while (0)
+#define IFF_CLR_BOUND(f)   do { (f) &= ~IFF_BOUND; } while (0)
+#define IFF_CLR_NOARP(f)   do { (f) &= ~IFF_NOARP; } while (0)
+#define IFF_CLR_LOOPBACK(f)do { (f) &= ~IFF_LOOPBACK; } while (0)
+#define IFF_CLR_POINTOPOINT(f) do { (f) &= ~IFF_POINTOPOINT; } while (0)
+#define IFF_CLR_MULTICAST(f)   do { (f) &= ~IFF_MULTICAST; } while (0)
+#define IFF_CLR_BROADCAST(f)   do { (f) &= ~IFF_BROADCAST; } while (0)
+
+#define IFF_IS_DOWN(f)(((f) & IFF_DOWN) != 0)
+#define IFF_IS_UP(f)  (((f) & IFF_UP) != 0)
+#define IFF_IS_RUNNING(f) (((f) & IFF_RUNNING) != 0)
+#define IFF_IS_BOUND(f)   (((f) & IFF_BOUND) != 0)
+#define IFF_IS_NOARP(f)   (((f) & IFF_NOARP) != 0)
+#define IFF_IS_LOOPBACK(f)(((f) & IFF_LOOPBACK) != 0)
+#define IFF_IS_POINTOPOINT(f) (((f) & IFF_POINTOPOINT) != 0)
+#define IFF_IS_MULTICAST(f)   (((f) & IFF_MULTICAST) != 0)
+#define IFF_IS_BROADCAST(f)   (((f) & IFF_BROADCAST) != 0)
 
 /* We only need t

[incubator-nuttx] branch master updated: libc/stdio: Enable LIBC_FLOATINGPOINT by default if ARCH_FPU is enabled

2022-07-21 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 1d43b4a4eb libc/stdio: Enable LIBC_FLOATINGPOINT by default if 
ARCH_FPU is enabled
1d43b4a4eb is described below

commit 1d43b4a4ebca44489af7140269733866bd5f37d4
Author: Xiang Xiao 
AuthorDate: Wed Jul 13 04:25:48 2022 +0800

libc/stdio: Enable LIBC_FLOATINGPOINT by default if ARCH_FPU is enabled

and DEFAULT_SMALL is false

Signed-off-by: Xiang Xiao 
---
 boards/arm/imxrt/imxrt1050-evk/configs/libcxxtest/defconfig | 1 -
 boards/arm/imxrt/imxrt1060-evk/configs/libcxxtest/defconfig | 1 -
 boards/arm/imxrt/imxrt1064-evk/configs/libcxxtest/defconfig | 1 -
 boards/arm/imxrt/teensy-4.x/configs/lua-4.1/defconfig   | 1 -
 boards/arm/imxrt/teensy-4.x/configs/pwm-4.1/defconfig   | 1 -
 boards/arm/sama5/sama5d4-ek/configs/nxwm/defconfig  | 1 -
 boards/arm/samv7/samv71-xult/configs/nxwm/defconfig | 1 -
 boards/arm/samv7/samv71-xult/configs/vnxwm/defconfig| 1 -
 boards/arm/stm32/b-g474e-dpow1/configs/nsh/defconfig| 1 -
 boards/arm/stm32/nucleo-f302r8/configs/highpri/defconfig| 1 -
 boards/arm/stm32/nucleo-f334r8/configs/highpri/defconfig| 1 -
 boards/arm/stm32/nucleo-f334r8/configs/spwm1/defconfig  | 1 -
 boards/arm/stm32/nucleo-f334r8/configs/spwm2/defconfig  | 1 -
 boards/arm/stm32/nucleo-g474re/configs/nsh/defconfig| 1 -
 boards/arm/stm32/nucleo-g474re/configs/usbserial/defconfig  | 1 -
 boards/arm/stm32/olimex-stm32-p407/configs/dhtxx/defconfig  | 1 -
 boards/arm/stm32/stm32f334-disco/configs/buckboost/defconfig| 1 -
 boards/arm/stm32/stm32f429i-disco/configs/highpri/defconfig | 1 -
 boards/arm/stm32f7/nucleo-144/configs/f746-pysim/defconfig  | 1 -
 boards/risc-v/mpfs/icicle/configs/hwtest/defconfig  | 1 -
 boards/risc-v/mpfs/icicle/configs/knsh/defconfig| 1 -
 boards/risc-v/mpfs/icicle/configs/nsh/defconfig | 1 -
 boards/risc-v/mpfs/icicle/configs/pnsh/defconfig| 1 -
 boards/risc-v/mpfs/m100pfsevp/configs/nsh/defconfig | 1 -
 boards/xtensa/esp32/esp32-devkitc/configs/autopm/defconfig  | 1 -
 boards/xtensa/esp32/esp32-devkitc/configs/bmp280/defconfig  | 1 -
 .../xtensa/esp32/esp32-devkitc/configs/mcuboot_update_agent/defconfig   | 1 -
 boards/xtensa/esp32/esp32-devkitc/configs/mqttc/defconfig   | 1 -
 boards/xtensa/esp32/esp32-devkitc/configs/ms5611/defconfig  | 1 -
 boards/xtensa/esp32/esp32-devkitc/configs/wifinsh/defconfig | 1 -
 boards/xtensa/esp32/esp32-ethernet-kit/configs/autopm/defconfig | 1 -
 .../esp32/esp32-ethernet-kit/configs/mcuboot_update_agent/defconfig | 1 -
 boards/xtensa/esp32/esp32-ethernet-kit/configs/wapi/defconfig   | 1 -
 boards/xtensa/esp32/esp32-wrover-kit/configs/autopm/defconfig   | 1 -
 .../esp32/esp32-wrover-kit/configs/mcuboot_update_agent/defconfig   | 1 -
 boards/xtensa/esp32/esp32-wrover-kit/configs/wapi/defconfig | 1 -
 libs/libc/stdio/Kconfig | 2 +-
 37 files changed, 1 insertion(+), 37 deletions(-)

diff --git a/boards/arm/imxrt/imxrt1050-evk/configs/libcxxtest/defconfig 
b/boards/arm/imxrt/imxrt1050-evk/configs/libcxxtest/defconfig
index 85d8a2a47f..d6751fb604 100644
--- a/boards/arm/imxrt/imxrt1050-evk/configs/libcxxtest/defconfig
+++ b/boards/arm/imxrt/imxrt1050-evk/configs/libcxxtest/defconfig
@@ -23,7 +23,6 @@ CONFIG_INIT_ENTRYPOINT="nsh_main"
 CONFIG_INTELHEX_BINARY=y
 CONFIG_LIBCXX=y
 CONFIG_LIBCXXABI=y
-CONFIG_LIBC_FLOATINGPOINT=y
 CONFIG_LIBC_LOCALTIME=y
 CONFIG_LIBM=y
 CONFIG_LPUART1_SERIAL_CONSOLE=y
diff --git a/boards/arm/imxrt/imxrt1060-evk/configs/libcxxtest/defconfig 
b/boards/arm/imxrt/imxrt1060-evk/configs/libcxxtest/defconfig
index e0526cd22a..dc26dcfd87 100644
--- a/boards/arm/imxrt/imxrt1060-evk/configs/libcxxtest/defconfig
+++ b/boards/arm/imxrt/imxrt1060-evk/configs/libcxxtest/defconfig
@@ -23,7 +23,6 @@ CONFIG_INIT_ENTRYPOINT="nsh_main"
 CONFIG_INTELHEX_BINARY=y
 CONFIG_LIBCXX=y
 CONFIG_LIBCXXABI=y
-CONFIG_LIBC_FLOATINGPOINT=y
 CONFIG_LIBC_LOCALTIME=y
 CONFIG_LIBM=y
 CONFIG_LPUART1_SERIAL_CONSOLE=y
diff --git a/boards/arm/imxrt/imxrt1064-evk/configs/libcxxtest/defconfig 
b/boards/arm/imxrt/imxrt1064-evk/configs/libcxxtest/defconfig
index 139e75f7d1..817a01d802 100644
--- a/boards/arm/imxrt/imxrt1064-evk/configs/libcxxtest/defconfig
+++ b/boards/arm/imxrt/imxrt1064-evk/configs/libcxxtest/defc

[nuttx] branch master updated (7f27129896 -> 71d7028c4a)

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

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


from 7f27129896 tools: Move Rust relative settings to Rust.defs
 add 71d7028c4a stm32h7/stm32_sdmmc.c: fix compilation

No new revisions were added by this update.

Summary of changes:
 arch/arm/src/stm32h7/stm32_sdmmc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)



[nuttx] branch master updated (12fda1da1c -> d3f659b854)

2023-04-03 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 12fda1da1c boards: Replace open/pread with file_open/file_pread
 add b43ca9fcdb boardctl.h: Move BOARDIOC_SOFTRESETCAUSE_[PANIC|ASSERT] to 
the last
 add d3f659b854 boardctl.h: Add BOARDIOC_SOFTRESETCAUSE_ENTER_BOOTLOADER 
reset cause

No new revisions were added by this update.

Summary of changes:
 include/sys/boardctl.h | 7 ---
 1 file changed, 4 insertions(+), 3 deletions(-)



[nuttx] branch master updated (4fbf5f7a4b -> 84ddfb5455)

2023-04-04 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 4fbf5f7a4b libs/libc: correct config define of arch functions
 add 84ddfb5455 sched/assert: Simplify the fatal detection logic

No new revisions were added by this update.

Summary of changes:
 sched/misc/assert.c | 10 --
 1 file changed, 4 insertions(+), 6 deletions(-)



[nuttx-apps] branch master updated: nshlib/README.md: add uptime command description

2023-04-04 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 f58c87e7e nshlib/README.md: add uptime command description
f58c87e7e is described below

commit f58c87e7edee4ba337a559c16418ea351cb303b8
Author: zhengjunbo1 
AuthorDate: Sun Apr 2 17:06:26 2023 +0800

nshlib/README.md: add uptime command description

Signed-off-by: zhengjunbo1 
---
 nshlib/README.md | 43 ---
 1 file changed, 40 insertions(+), 3 deletions(-)

diff --git a/nshlib/README.md b/nshlib/README.md
index 8a4e6f4aa..d5f0c0215 100644
--- a/nshlib/README.md
+++ b/nshlib/README.md
@@ -1458,6 +1458,41 @@ system image.
   nsh>
   ```
 
+- `uptime [options]`
+
+  Display the current time, how long the system has been running, and the load
+  average of the system over the last 1, 5, and 15 minutes.
+
+  options:
+  - -p, show uptime in pretty format
+  - -h, display this help and exit
+  - -s, system up since
+
+  **Example**:
+
+  ```
+  nsh> uptime
+  19:35:01 up 1:40, load average: 0.00, 0.00, 0.00
+  nsh>
+  nsh>
+  nsh> uptime -s
+  2022-09-16 17:54:26
+  nsh>
+  nsh>
+  nsh> uptime -p
+  up 1 hour, 40 minutes
+  nsh>
+  nsh>
+  nsh> uptime -h
+  Usage:
+  uptime [options]
+  Options:
+  -p, show uptime in pretty format
+  -h, display this help and exit
+  -s, system up since
+  nsh>
+  ```
+
 - `urldecode [-f] `
 
 - `urlencode [-f] `
@@ -1632,6 +1667,7 @@ truncate  | !`CONFIG_DISABLE_MOUNTPOINT`
 umount| !`CONFIG_DISABLE_MOUNTPOINT`
 uname | !`CONFIG_NSH_DISABLE_UNAME`
 unset | `CONFIG_NSH_VARS` || !`CONFIG_DISABLE_ENVIRON`
+uptime| !`CONFIG_NSH_DISABLE_UPTIME`
 urldecode | `CONFIG_NETUTILS_CODECS` && `CONFIG_CODECS_URLCODE`
 urlencode | `CONFIG_NETUTILS_CODECS` && `CONFIG_CODECS_URLCODE`
 useradd   | !`CONFIG_DISABLE_MOUNTPOINT` && `CONFIG_NSH_LOGIN_PASSWD`
@@ -1673,9 +1709,10 @@ CONFIG_NSH_DISABLE_REBOOT,CONFIG_NSH_DISABLE_RM, 
   CONFIG_NSH_DISABLE_R
 CONFIG_NSH_DISABLE_RMDIR, CONFIG_NSH_DISABLE_ROUTE, 
CONFIG_NSH_DISABLE_SET,
 CONFIG_NSH_DISABLE_SHUTDOWN,  CONFIG_NSH_DISABLE_SLEEP, 
CONFIG_NSH_DISABLE_SOURCE,
 CONFIG_NSH_DISABLE_TEST,  CONFIG_NSH_DISABLE_TIME,  
CONFIG_NSH_DISABLE_TRUNCATE,
-CONFIG_NSH_DISABLE_UMOUNT,CONFIG_NSH_DISABLE_UNSET, 
CONFIG_NSH_DISABLE_URLDECODE,
-CONFIG_NSH_DISABLE_URLENCODE, CONFIG_NSH_DISABLE_USERADD,   
CONFIG_NSH_DISABLE_USERDEL,
-CONFIG_NSH_DISABLE_USLEEP,CONFIG_NSH_DISABLE_WGET,  
CONFIG_NSH_DISABLE_XD
+CONFIG_NSH_DISABLE_UMOUNT,CONFIG_NSH_DISABLE_UNSET, 
CONFIG_NSH_DISABLE_UPTIME,
+CONFIG_NSH_DISABLE_URLDECODE, CONFIG_NSH_DISABLE_URLENCODE, 
CONFIG_NSH_DISABLE_USERADD,
+CONFIG_NSH_DISABLE_USERDEL,   CONFIG_NSH_DISABLE_USLEEP,
CONFIG_NSH_DISABLE_WGET,
+CONFIG_NSH_DISABLE_XD
 ```
 
 Verbose help output can be suppressed by defining `CONFIG_NSH_HELP_TERSE`. In



[nuttx] branch master updated: boards: refresh boards that use usbmsc

2023-04-04 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 553fe83abf boards: refresh boards that use usbmsc
553fe83abf is described below

commit 553fe83abf5d8e72e3dbc320421d4b18bf0068a9
Author: raiden00pl 
AuthorDate: Tue Apr 4 14:25:11 2023 +0200

boards: refresh boards that use usbmsc
---
 boards/arm/lc823450/lc823450-xgevk/configs/audio/defconfig | 1 -
 boards/arm/lc823450/lc823450-xgevk/configs/usb/defconfig   | 1 -
 2 files changed, 2 deletions(-)

diff --git a/boards/arm/lc823450/lc823450-xgevk/configs/audio/defconfig 
b/boards/arm/lc823450/lc823450-xgevk/configs/audio/defconfig
index b86645c218..18b541dc79 100644
--- a/boards/arm/lc823450/lc823450-xgevk/configs/audio/defconfig
+++ b/boards/arm/lc823450/lc823450-xgevk/configs/audio/defconfig
@@ -120,7 +120,6 @@ CONFIG_SYSTEM_SYSTEM=y
 CONFIG_SYSTEM_TASKSET=y
 CONFIG_SYSTEM_TIME64=y
 CONFIG_SYSTEM_USBMSC=y
-CONFIG_SYSTEM_USBMSC_CMD_STACKSIZE=2048
 CONFIG_SYSTEM_USBMSC_DEVPATH1="/dev/mtdblock0p10"
 CONFIG_SYSTEM_USBMSC_DEVPATH2="/dev/mtdblock1"
 CONFIG_SYSTEM_USBMSC_NLUNS=2
diff --git a/boards/arm/lc823450/lc823450-xgevk/configs/usb/defconfig 
b/boards/arm/lc823450/lc823450-xgevk/configs/usb/defconfig
index f95e2dcf41..c4031f4773 100644
--- a/boards/arm/lc823450/lc823450-xgevk/configs/usb/defconfig
+++ b/boards/arm/lc823450/lc823450-xgevk/configs/usb/defconfig
@@ -116,7 +116,6 @@ CONFIG_SYSTEM_SYSTEM=y
 CONFIG_SYSTEM_TASKSET=y
 CONFIG_SYSTEM_TIME64=y
 CONFIG_SYSTEM_USBMSC=y
-CONFIG_SYSTEM_USBMSC_CMD_STACKSIZE=2048
 CONFIG_SYSTEM_USBMSC_DEVPATH1="/dev/mtdblock0p10"
 CONFIG_SYSTEM_USBMSC_DEVPATH2="/dev/mtdblock1"
 CONFIG_SYSTEM_USBMSC_NLUNS=2



[incubator-nuttx] branch master updated: fix: nxstyle: detect --, ->, ++ not next to operand

2021-09-19 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new b42d2a7  fix: nxstyle: detect --,->,++ not next to operand
b42d2a7 is described below

commit b42d2a72847914f02a94da48dde99db2e22cff70
Author: liucheng5 
AuthorDate: Fri Sep 10 17:44:41 2021 +0800

fix: nxstyle: detect --,->,++ not next to operand

The nxstyle check tool can't recongnize the style error that --, -> or ++ 
is not next to the operand. For example, "idx ++;", "p ->member" or "(-- idx)", 
which is in incorrect style, is not recongnized. This patch add detection for 
these cases.

Signed-off-by: liucheng5 
---
 tools/nxstyle.c | 81 +++--
 1 file changed, 79 insertions(+), 2 deletions(-)

diff --git a/tools/nxstyle.c b/tools/nxstyle.c
index 978ab78..5f2afca 100644
--- a/tools/nxstyle.c
+++ b/tools/nxstyle.c
@@ -415,6 +415,59 @@ static void check_spaces_leftright(char *line, int lineno, 
int ndx1, int ndx2)
 }
 
 
/
+ * Name: check_nospaces_leftright
+ *
+ * Description:
+ *   Check if there are whitespaces on the left of right. If there is, report
+ *   an error.
+ *
+ 
/
+
+static void check_nospaces_leftright(char *line, int lineno, int ndx1, int 
ndx2)
+{
+  if (ndx1 > 0 && line[ndx1 - 1] == ' ')
+{
+  ERROR("There should be no spaces before the operator/assignment",
+lineno, ndx1);
+}
+
+  if (line[ndx2 + 1] == ' ')
+{
+  ERROR("There should be no spaces after the operator/assignment",
+lineno, ndx2);
+}
+}
+
+/
+ * Name: check_operand_leftright
+ *
+ * Description:
+ *   Check if the operator is next to an operand. If not, report the error.
+ *
+ 
/
+
+static void check_operand_leftright(char *line, int lineno, int ndx1, int ndx2)
+{
+  /* The cases below includes("xx" represents the operator):
+   *   " xx " | " xx(end)" | " xx;" | " xx\n" | " xx)" | " xx]"  - (ndx1 > 0)
+   *   "(xx " | "(xx(end)" | "(xx;" | "(xx\n" | "(xx)" | "(xx]"  - (ndx1 > 0)
+   *   "[xx " | "[xx(end)" | "[xx;" | "[xx\n" | "[xx)" | "[xx]"  - (ndx1 > 0)
+   *   "xx "  | "xx(end)"  | "xx;"  | "xx\n"  | "xx)"  | "xx]"   - (ndx1 = 0)
+   * In these cases, the operators must be not next any operands, thus errors
+   * are reported.
+   */
+
+  if (ndx1 > 0 && (line[ndx1 - 1] == ' ' || line[ndx1 - 1] == '(' ||
+   line[ndx1 - 1] == '[') &&
+  (line[ndx2 + 1] == ' ' || line[ndx2 + 1] == '\0' ||
+   line[ndx2 + 1] == ';' || line[ndx2 + 1] == '\n' ||
+   line[ndx2 + 1] == ')' || line[ndx2 + 1] == ']'))
+{
+  ERROR("Operator must be next to an operand", lineno, ndx2);
+}
+}
+
+/
  * Name: block_comment_width
  *
  * Description:
@@ -2226,10 +2279,27 @@ int main(int argc, char **argv, char **envp)
 
 case '-':
 
-  /* ->, -- */
+  /* -> */
+
+  if (line[n + 1] == '>')
+{
+  /* -> must have no whitespaces on its left or right */
+
+  check_nospaces_leftright(line, lineno, n, n + 1);
+  n++;
+}
+
+  /* -- */
 
-  if (line[n + 1] == '>' || line[n + 1] == '-')
+  else if (line[n + 1] == '-')
 {
+  /* "--" should be next to its operand. If there are
+   * whitespaces or non-operand characters on both left
+   * and right (e.g. "a -- ", “a[i --]”, "(-- i)"),
+   * there's an error.
+   */
+
+  check_operand_leftright(line, lineno, n, n + 1);
   n++;
 }
 
@@ -2270,6 +2340,13 @@ int main(int argc, char **argv, char **envp)
 
   if (line[n + 1] == '+')
 {
+  /* "++" should be next to its operand. If there are
+   * whitespaces or non-operand characters on both left
+   * and right (e.g. "a ++ ", “a[i ++]”, "(++ i)"),
+   * there's an error.
+   */
+
+  check_operand_leftright(line, lineno, n, n + 1);
   n++;
 }
 


(nuttx) branch master updated: rptun/rptun_initialize: add explicit initialization for variable

2024-02-14 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 87ad1196e1 rptun/rptun_initialize: add explicit initialization for 
variable
87ad1196e1 is described below

commit 87ad1196e1411f8cb2affa190bd47dd9d6bc7517
Author: Yanfeng Liu 
AuthorDate: Tue Feb 13 12:37:50 2024 +0800

rptun/rptun_initialize: add explicit initialization for variable

This explicitly initializes variable `onceinit` before use.

Signed-off-by: Yanfeng Liu 
---
 drivers/rptun/rptun.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/rptun/rptun.c b/drivers/rptun/rptun.c
index 16664df123..023b9bfca1 100644
--- a/drivers/rptun/rptun.c
+++ b/drivers/rptun/rptun.c
@@ -849,7 +849,7 @@ int rptun_initialize(FAR struct rptun_dev_s *dev)
 {
   struct metal_init_params params = METAL_INIT_DEFAULTS;
   FAR struct rptun_priv_s *priv;
-  static bool onceinit;
+  static bool onceinit = false;
   FAR char *argv[3];
   char arg1[19];
   char name[32];



(nuttx-apps) branch master updated: examples/rmtchar: Increase initial duration time

2024-02-14 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 9fd1251dc examples/rmtchar: Increase initial duration time
9fd1251dc is described below

commit 9fd1251dcbb44a824fe7d53aa90ca36939f01179
Author: Tiago Medicci Serrano 
AuthorDate: Fri Feb 9 16:14:47 2024 -0300

examples/rmtchar: Increase initial duration time

With higher RMT source clocks, small durations are hard to be
detected. Increasing it makes it easier to enable automated tests.
---
 examples/rmtchar/rmtchar_transmitter.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/examples/rmtchar/rmtchar_transmitter.c 
b/examples/rmtchar/rmtchar_transmitter.c
index e1b2c1a98..249f877ae 100644
--- a/examples/rmtchar/rmtchar_transmitter.c
+++ b/examples/rmtchar/rmtchar_transmitter.c
@@ -78,7 +78,7 @@ pthread_addr_t rmtchar_transmitter(pthread_addr_t arg)
 {
   FAR struct rmtchar_state_s *rmtchar = (FAR struct rmtchar_state_s *)arg;
   struct rmt_item32_s buf[rmtchar->rmtchar_items];
-  int duration = 100;
+  int duration = 1000;
   int nwritten;
   int fd;
   int i;



(nuttx-apps) branch master updated: sensor/lm75: fix C syntax error

2024-02-25 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 0cc42d6e4 sensor/lm75: fix C syntax error
0cc42d6e4 is described below

commit 0cc42d6e457451f4d184d99082e10f5e0b40486d
Author: Jorge Guzman 
AuthorDate: Sun Feb 25 12:15:58 2024 -0300

sensor/lm75: fix C syntax error

Signed-off-by" Jorge Guzman jorge@gmail.com
---
 system/lm75/lm75.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/system/lm75/lm75.c b/system/lm75/lm75.c
index 3414785f2..57595fcbe 100644
--- a/system/lm75/lm75.c
+++ b/system/lm75/lm75.c
@@ -46,7 +46,7 @@
 
 #if !defined(CONFIG_SYSTEM_LM75_FAHRENHEIT) && 
!defined(CONFIG_SYSTEM_LM75_CELSIUS)
 #  warning one of CONFIG_SYSTEM_LM75_FAHRENHEIT or CONFIG_SYSTEM_LM75_CELSIUS 
must be defined
-#  defeind CONFIG_SYSTEM_LM75_FAHRENHEIT 1
+#  define CONFIG_SYSTEM_LM75_FAHRENHEIT 1
 #endif
 
 #if defined(CONFIG_SYSTEM_LM75_FAHRENHEIT) && 
defined(CONFIG_SYSTEM_LM75_CELSIUS)



[incubator-nuttx] branch master updated (d199941 -> ad8c09d)

2021-04-14 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from d199941  nucleo-g431rb: add ADC example
 new 6d69600  stm32/Kconfig: move configuration common for G4 under 
STM32_STM32G4XXX option
 new 7c11397  stm32: add definitions for TIMERS_V3. All credit goes to 
Nathan Hartman (hartmannathan)
 new ad8c09d  stm32: include support for TIMERS_V3

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


Summary of changes:
 arch/arm/src/stm32/Kconfig |   22 +-
 arch/arm/src/stm32/hardware/stm32_tim.h| 1289 +-
 .../hardware/{stm32_tim.h => stm32_tim_v1v2.h} |   24 +-
 arch/arm/src/stm32/hardware/stm32_tim_v3.h | 1436 
 4 files changed, 1459 insertions(+), 1312 deletions(-)
 copy arch/arm/src/stm32/hardware/{stm32_tim.h => stm32_tim_v1v2.h} (99%)
 create mode 100644 arch/arm/src/stm32/hardware/stm32_tim_v3.h


[incubator-nuttx] 01/03: stm32/Kconfig: move configuration common for G4 under STM32_STM32G4XXX option

2021-04-14 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 6d69600905871ee2023a91b5ed18bd8f0fe1bdad
Author: raiden00pl 
AuthorDate: Wed Apr 14 08:03:48 2021 +0200

stm32/Kconfig: move configuration common for G4 under STM32_STM32G4XXX 
option
---
 arch/arm/src/stm32/Kconfig | 18 ++
 1 file changed, 6 insertions(+), 12 deletions(-)

diff --git a/arch/arm/src/stm32/Kconfig b/arch/arm/src/stm32/Kconfig
index 708f35f..7a69614 100644
--- a/arch/arm/src/stm32/Kconfig
+++ b/arch/arm/src/stm32/Kconfig
@@ -1927,8 +1927,14 @@ config STM32_STM32F469
 config STM32_STM32G4XXX
bool
default n
+   select ARCH_CORTEXM4
+   select ARCH_HAVE_FPU
select STM32_HAVE_DMAMUX
select STM32_HAVE_IP_DBGMCU_V3
+   select STM32_HAVE_IP_ADC_V2
+   select STM32_HAVE_IP_DMA_V1
+   select STM32_HAVE_IP_I2C_V2
+   select STM32_HAVE_IP_TIMERS_V2
 
 config STM32_STM32G4_CAT2
bool
@@ -1975,8 +1981,6 @@ config STM32_STM32G43XX
default n
select STM32_STM32G4XXX
select STM32_STM32G4_CAT2
-   select ARCH_CORTEXM4
-   select ARCH_HAVE_FPU
select STM32_HAVE_ADC2
select STM32_HAVE_CCM
select STM32_HAVE_COMP1
@@ -2009,10 +2013,6 @@ config STM32_STM32G43XX
select STM32_HAVE_TIM8
select STM32_HAVE_UCPD
select STM32_HAVE_USBDEV
-   select STM32_HAVE_IP_ADC_V2
-   select STM32_HAVE_IP_DMA_V1
-   select STM32_HAVE_IP_I2C_V2
-   select STM32_HAVE_IP_TIMERS_V2
 
 config STM32_STM32G431K
bool
@@ -2046,8 +2046,6 @@ config STM32_STM32G47XX
default n
select STM32_STM32G4XXX
select STM32_STM32G4_CAT3
-   select ARCH_CORTEXM4
-   select ARCH_HAVE_FPU
select STM32_HAVE_ADC2
select STM32_HAVE_ADC3
select STM32_HAVE_ADC4
@@ -2102,10 +2100,6 @@ config STM32_STM32G47XX
select STM32_HAVE_USART3
select STM32_HAVE_UCPD
select STM32_HAVE_USBDEV
-   select STM32_HAVE_IP_ADC_V2
-   select STM32_HAVE_IP_DMA_V1
-   select STM32_HAVE_IP_I2C_V2
-   select STM32_HAVE_IP_TIMERS_V2
 
 config STM32_STM32G474C
bool


[incubator-nuttx] 02/03: stm32: add definitions for TIMERS_V3. All credit goes to Nathan Hartman (hartmannathan)

2021-04-14 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 7c11397469b24bc1d9925deee702a68a456cbfdc
Author: raiden00pl 
AuthorDate: Wed Apr 14 09:15:18 2021 +0200

stm32: add definitions for TIMERS_V3. All credit goes to Nathan Hartman 
(hartmannathan)
---
 arch/arm/src/stm32/hardware/stm32_tim_v3.h | 1436 
 1 file changed, 1436 insertions(+)

diff --git a/arch/arm/src/stm32/hardware/stm32_tim_v3.h 
b/arch/arm/src/stm32/hardware/stm32_tim_v3.h
new file mode 100644
index 000..61a77c5
--- /dev/null
+++ b/arch/arm/src/stm32/hardware/stm32_tim_v3.h
@@ -0,0 +1,1436 @@
+/
+ * arch/arm/src/stm32/hardware/stm32_tim_v3.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 __ARCH_ARM_SRC_STM32_HARDWARE_STM32_TIM_V3_H
+#define __ARCH_ARM_SRC_STM32_HARDWARE_STM32_TIM_V3_H
+
+/
+ * Included Files
+ /
+
+#include 
+#include "chip.h"
+
+/
+ * Pre-processor Definitions
+ /
+
+/* Register Offsets */
+
+/* BTIM: Basic Timers - TIM6 and TIM7 */
+
+#define STM32_BTIM_CR1_OFFSET  0x  /* Control register 1 (16-bit) */
+#define STM32_BTIM_CR2_OFFSET  0x0004  /* Control register 2 (16-bit) */
+#define STM32_BTIM_DIER_OFFSET 0x000c  /* DMA/Interrupt enable register 
(16-bit) */
+#define STM32_BTIM_SR_OFFSET   0x0010  /* Status register (16-bit) */
+#define STM32_BTIM_EGR_OFFSET  0x0014  /* Event generation register 
(16-bit) */
+#define STM32_BTIM_CNT_OFFSET  0x0024  /* Counter (32-bit register, 16-bit 
counter) */
+#define STM32_BTIM_PSC_OFFSET  0x0028  /* Prescaler (16-bit) */
+#define STM32_BTIM_ARR_OFFSET  0x002c  /* Auto-reload register (32-bit) */
+
+/* GTIM: General Timers
+ * 16-/32-bit General Timers with DMA: TIM2, TM3, TIM4, and TIM5
+ * 16-bit General Timers with DMA: TIM15, TIM16, and TIM17
+ *
+ * Caution! TIM2/5, TIM3/4, TIM15, and TIM16/17 are slightly different and
+ * have different registers, register sizes, and register bitfields!
+ *
+ * Some registers are marked with the following notes:
+ *
+ * Note 1: The register is 32-bit but its contents have different variants
+ * for TIM3/4 and TIM2/5, TIM15
+ * Note 2: This register not available on TIM15
+ * Note 3: This register not available on TIM16/17
+ */
+
+#define STM32_GTIM_CR1_OFFSET  0x  /* Control register 1 (16-bit) */
+#define STM32_GTIM_CR2_OFFSET  0x0004  /* Control register 2 (32-bit 
TIM2-5; 16-bit TIM15-17) */
+#define STM32_GTIM_SMCR_OFFSET 0x0008  /* Slave mode control register 
(32-bit TIM2-5, TIM15, See Note 3) */
+#define STM32_GTIM_DIER_OFFSET 0x000c  /* DMA/Interrupt enable register 
(32-bit TIM2-5; 16-bit TIM15) */
+#define STM32_GTIM_SR_OFFSET   0x0010  /* Status register (32-bit TIM2-5; 
16-bit TIM15-17) */
+#define STM32_GTIM_EGR_OFFSET  0x0014  /* Event generation register 
(16-bit) */
+#define STM32_GTIM_CCMR1_OFFSET0x0018  /* Capture/compare mode register 1 
(32-bit) */
+#define STM32_GTIM_CCMR2_OFFSET0x001c  /* Capture/compare mode register 2 
(32-bit) */
+#define STM32_GTIM_CCER_OFFSET 0x0020  /* Capture/compare enable register 
(16-bit) */
+#define STM32_GTIM_CNT_OFFSET  0x0024  /* Counter (32-bit, See Note 1) */
+#define STM32_GTIM_PSC_OFFSET  0x0028  /* Prescaler (16-bit) */
+#define STM32_GTIM_ARR_OFFSET  0x002c  /* Auto-reload register (32-bit, 
See Note 1) */
+#define STM32_GTIM_RCR_OFFSET  0x0030  /* Repetition counter register 
(16-bit, TIM15 only) */
+#define STM32_GTIM_CCR1_OFFSET 0x0034  /* Capture/compare register 1 
(32-bit, See Note 1) */
+#define STM

[incubator-nuttx] 03/03: stm32: include support for TIMERS_V3

2021-04-14 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit ad8c09d0a1ae14dcbae7dd3167d1ae77f3718d4b
Author: raiden00pl 
AuthorDate: Wed Apr 14 09:29:57 2021 +0200

stm32: include support for TIMERS_V3
---
 arch/arm/src/stm32/Kconfig |6 +-
 arch/arm/src/stm32/hardware/stm32_tim.h| 1289 +---
 .../hardware/{stm32_tim.h => stm32_tim_v1v2.h} |   24 +-
 3 files changed, 18 insertions(+), 1301 deletions(-)

diff --git a/arch/arm/src/stm32/Kconfig b/arch/arm/src/stm32/Kconfig
index 7a69614..070928a 100644
--- a/arch/arm/src/stm32/Kconfig
+++ b/arch/arm/src/stm32/Kconfig
@@ -1934,7 +1934,7 @@ config STM32_STM32G4XXX
select STM32_HAVE_IP_ADC_V2
select STM32_HAVE_IP_DMA_V1
select STM32_HAVE_IP_I2C_V2
-   select STM32_HAVE_IP_TIMERS_V2
+   select STM32_HAVE_IP_TIMERS_V3
 
 config STM32_STM32G4_CAT2
bool
@@ -2594,6 +2594,10 @@ config STM32_HAVE_IP_TIMERS_V2
bool
default n
 
+config STM32_HAVE_IP_TIMERS_V3
+   bool
+   default n
+
 config STM32_HAVE_IP_ADC_V1
bool
default n
diff --git a/arch/arm/src/stm32/hardware/stm32_tim.h 
b/arch/arm/src/stm32/hardware/stm32_tim.h
index bc01408..8277973 100644
--- a/arch/arm/src/stm32/hardware/stm32_tim.h
+++ b/arch/arm/src/stm32/hardware/stm32_tim.h
@@ -22,1293 +22,16 @@
 #define __ARCH_ARM_SRC_STM32_HARDWARE_STM32_TIM_H
 
 /
- * Pre-processor Definitions
+ * Included Files
  /
 
-/* TIM version **/
-
-/* Chip has extended version of ADV Timers (F3/F7/H7/L4/L4+):
- *   - CCMR3, CCR5 and CCR6 registers
- *   - OC5 and OC6
- *   - 32-bit CCMR register
- *   - UIFREMAP bit in CR1 register
- *   - TRGO2 configuration in CR2 register
- *   - OCCS bit and 4-bit SMS in SMCR register
- *
- *  Chip has extended version of General Timers 2-5 (F3/F7/H7/L4/L4+):
- *   - UIFREMAP bit in CR1 register
- *   - 4-bit SMS in SMCR register
- */
-
-#if defined(CONFIG_STM32_HAVE_IP_TIMERS_V2)
-#  define HAVE_IP_TIMERS_V2
-#elif defined(CONFIG_STM32_HAVE_IP_TIMERS_V1)
-#  define HAVE_IP_TIMERS_V1
+#if defined(CONFIG_STM32_HAVE_IP_TIMERS_V1) ||  \
+defined(CONFIG_STM32_HAVE_IP_TIMERS_V2)
+#  include "stm32_tim_v1v2.h"
+#elif defined(CONFIG_STM32_HAVE_IP_TIMERS_V3)
+#  include "stm32_tim_v3.h"
 #else
 #  error "STM32 TIMER IP version not specified"
 #endif
 
-/* TIM16 has OR register (F3/L4) */
-
-#ifdef CONFIG_STM32_STM32F30XX
-#  define HAVE_TIM16_OR
-#endif
-
-/* General Timers have CCxNP bits (not in F1) */
-
-#if defined(CONFIG_STM32_STM32F20XX) || defined(CONFIG_STM32_STM32F30XX) || \
-defined(CONFIG_STM32_STM32F33XX) || defined(CONFIG_STM32_STM32F37XX) || \
-defined(CONFIG_STM32_STM32F4XXX) || defined(CONFIG_STM32_STM32FGXXX)
-#  define HAVE_GTIM_CCXNP
-#endif
-
-/* Register Offsets */
-
-/* Basic Timers - TIM6 and TIM7 */
-
-#define STM32_BTIM_CR1_OFFSET 0x  /* Control register 1 (16-bit) */
-#define STM32_BTIM_CR2_OFFSET 0x0004  /* Control register 2 (16-bit) */
-#define STM32_BTIM_DIER_OFFSET0x000c  /* DMA/Interrupt enable register 
(16-bit) */
-#define STM32_BTIM_SR_OFFSET  0x0010  /* Status register (16-bit) */
-#define STM32_BTIM_EGR_OFFSET 0x0014  /* Event generation register 
(16-bit) */
-#define STM32_BTIM_CNT_OFFSET 0x0024  /* Counter (16-bit) */
-#define STM32_BTIM_PSC_OFFSET 0x0028  /* Prescaler (16-bit) */
-#define STM32_BTIM_ARR_OFFSET 0x002c  /* Auto-reload register (16-bit) */
-
-/* 16-/32-bit General Timers with DMA: TIM2, TM3, TIM4, and TIM5
- * 16-bit General Timers without DMA: TIM9, TIM10, TIM11, TIM12, TIM13,
- *and TIM14
- * For the STM32F10xx all timers are 16-bit.
- * For the STM32F20xx and STM32F40xx, TIM2 and 5 are 32-bit
- * The STM32 F1 Value Line and the STM32 F3 have variant general purpose
- *   registers that are not yet fully covered in this header file.
- * The STM32 G4xx also have variant registers that are not yet covered.
- *   Check whether those are similar to the F1 and F3 mentioned above. In
- *   particular, the DCR and DMAR offsets are 0x3dc and 0x3e0, respectively,
- *   as opposed to the values below:
- */
-
-#define STM32_GTIM_CR1_OFFSET  0x  /* Control register 1 (16-bit) */
-#define STM32_GTIM_CR2_OFFSET  0x0004  /* Control register 2 (16-bit, 
TIM2-5 only) */
-#define STM32_GTIM_SMCR_OFFSET 0x0008  /* Slave mode control register 
(16-bit, TIM2-5 only) */
-#define STM32_GTIM_DIER_OFFSET 0x000c  /* DMA/Interrupt enable register 
(16-bit) */
-#define STM32_GTIM_SR_OFFSET   0

[incubator-nuttx] branch master updated (7259601 -> bf1d587)

2021-06-10 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 7259601  ReleaseNotes: Fix missing Compatibility Concerns for NuttX-9.1
 add bf1d587  Documentation: Update kconfig-frontends install instructions

No new revisions were added by this update.

Summary of changes:
 Documentation/quickstart/install.rst | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)


[incubator-nuttx] branch master updated: stm32: convert all STM32G47X specific code to generic STM32G4 series code.

2020-12-06 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 979a5b7  stm32: convert all STM32G47X specific code to generic STM32G4 
series code.
979a5b7 is described below

commit 979a5b7fd4372e362669c6760ba9d06cf5a3c552
Author: raiden00pl 
AuthorDate: Sat Dec 5 17:14:50 2020 +0100

stm32: convert all STM32G47X specific code to generic STM32G4 series code.

This is an initial step towards supporting other STM32G4 chips.
---
 arch/arm/include/stm32/chip.h  | 10 +++---
 arch/arm/include/stm32/irq.h   |  4 +--
 .../stm32/{stm32g47xxx_irq.h => stm32g4_irq.h} |  8 ++---
 arch/arm/src/stm32/Kconfig | 40 +-
 arch/arm/src/stm32/hardware/stm32_adc_v2.h |  4 +--
 arch/arm/src/stm32/hardware/stm32_dma_v1.h |  2 +-
 arch/arm/src/stm32/hardware/stm32_dmamux.h |  4 +--
 arch/arm/src/stm32/hardware/stm32_flash.h  | 38 ++--
 arch/arm/src/stm32/hardware/stm32_memorymap.h  |  4 +--
 arch/arm/src/stm32/hardware/stm32_pinmap.h |  4 +--
 .../{stm32g474cxx_pinmap.h => stm32g4xxc_pinmap.h} | 10 +++---
 .../{stm32g47xxx_pinmap.h => stm32g4xxk_pinmap.h}  | 36 ++-
 .../{stm32g474mxx_pinmap.h => stm32g4xxm_pinmap.h} | 10 +++---
 .../{stm32g47xxx_pinmap.h => stm32g4xxp_pinmap.h}  | 36 ++-
 .../{stm32g474qxx_pinmap.h => stm32g4xxq_pinmap.h} | 10 +++---
 .../{stm32g474rxx_pinmap.h => stm32g4xxr_pinmap.h} | 10 +++---
 .../{stm32g474vxx_pinmap.h => stm32g4xxv_pinmap.h} | 10 +++---
 .../{stm32g47xxx_dmamux.h => stm32g4_dmamux.h} | 17 +
 .../{stm32g47xxx_gpio.h => stm32g4_gpio.h} |  8 ++---
 ...2g47xxx_memorymap.h => stm32g4_memorymap.h} | 10 +++---
 .../{stm32g47xxx_pinmap.h => stm32g4_pinmap.h} | 34 ++
 .../{stm32g47xxx_pwr.h => stm32g4_pwr.h}   |  8 ++---
 .../{stm32g47xxx_rcc.h => stm32g4_rcc.h}   | 10 +++---
 .../{stm32g47xxx_syscfg.h => stm32g4_syscfg.h} |  8 ++---
 .../{stm32g47xxx_uart.h => stm32g4_uart.h} |  8 ++---
 ...stm32g47xxx_vrefbuf.h => stm32g4_vrefbuf.h} |  8 ++---
 arch/arm/src/stm32/stm32_allocateheap.c| 13 +--
 arch/arm/src/stm32/stm32_dma_v1.c  |  4 +--
 arch/arm/src/stm32/stm32_dumpgpio.c|  2 +-
 arch/arm/src/stm32/stm32_gpio.c| 12 +++
 arch/arm/src/stm32/stm32_gpio.h|  8 ++---
 arch/arm/src/stm32/stm32_lowputc.c | 10 +++---
 arch/arm/src/stm32/stm32_rcc.c |  4 +--
 arch/arm/src/stm32/stm32_rcc.h |  4 +--
 arch/arm/src/stm32/stm32_serial.c  | 12 +++
 arch/arm/src/stm32/stm32_syscfg.h  |  4 +--
 arch/arm/src/stm32/stm32_uart.h|  4 +--
 .../stm32/{stm32g47xxx_rcc.c => stm32g4_rcc.c} |  6 ++--
 38 files changed, 229 insertions(+), 205 deletions(-)

diff --git a/arch/arm/include/stm32/chip.h b/arch/arm/include/stm32/chip.h
index d7b08ec..e77c10c 100644
--- a/arch/arm/include/stm32/chip.h
+++ b/arch/arm/include/stm32/chip.h
@@ -80,10 +80,10 @@
 #else
 #  define __HAVE_F4  0
 #endif
-#ifdef CONFIG_STM32_STM32G47XX
-#  define __HAVE_G47 1
+#ifdef CONFIG_STM32_STM32G4XXX
+#  define __HAVE_G4 1
 #else
-#  define __HAVE_G47 0
+#  define __HAVE_G4 0
 #endif
 #ifdef CONFIG_STM32_STM32L15XX
 #  define __HAVE_L1  1
@@ -92,7 +92,7 @@
 #endif
 
 #if ((__HAVE_F1 + __HAVE_F2 + __HAVE_F30 + __HAVE_F33 + __HAVE_F37 + __HAVE_F4 
+ \
-  __HAVE_G47 + __HAVE_L1) != 1)
+  __HAVE_G4 + __HAVE_L1) != 1)
 #  error "Only one STM32 family must be selected !"
 #endif
 
@@ -2514,7 +2514,7 @@
 #elif defined(CONFIG_STM32_STM32F4XXX)
 #  define STM32_HAVE_IP_SPI_V2
 
-#elif defined(CONFIG_STM32_STM32G47XX)
+#elif defined(CONFIG_STM32_STM32G4XXX)
 #  define STM32_HAVE_IP_SPI_V4
 
 #elif defined(CONFIG_STM32_STM32L15XX)
diff --git a/arch/arm/include/stm32/irq.h b/arch/arm/include/stm32/irq.h
index 892c6f0..818820d 100644
--- a/arch/arm/include/stm32/irq.h
+++ b/arch/arm/include/stm32/irq.h
@@ -95,8 +95,8 @@
 #  include 
 #elif defined(CONFIG_STM32_STM32F4XXX)
 #  include 
-#elif defined(CONFIG_STM32_STM32G47XX)
-#  include 
+#elif defined(CONFIG_STM32_STM32G4XXX)
+#  include 
 #else
 #  error "Unsupported STM32 chip"
 #endif
diff --git a/arch/arm/include/stm32/stm32g47xxx_irq.h 
b/arch/arm/include/stm32/stm32g4_irq.h
similarity index 98%
rename from arch/arm/include/stm32/stm32g47xxx_irq.h
rename to arch/arm/include/stm32/stm32g4_irq.h
index 4daf9d4..d998ab6 100644
--- a/arch/arm/include/stm32/stm

[incubator-nuttx] branch master updated (c162069 -> 8a9f995)

2020-12-07 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from c162069  arch/stm32: Fix nxstyle errors (and one typo)
 add 8a9f995  procfs: make array const to reduce memory use

No new revisions were added by this update.

Summary of changes:
 fs/procfs/fs_procfsproc.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)



[incubator-nuttx] branch master updated: net/: Correct some comments.

2021-01-15 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


The following commit(s) were added to refs/heads/master by this push:
 new 6385408  net/: Correct some comments.
6385408 is described below

commit 638540848322cf77149c11ed5b48525dfd35a0ff
Author: Abdelatif Guettouche 
AuthorDate: Fri Jan 15 10:01:00 2021 +0100

net/: Correct some comments.

Signed-off-by: Abdelatif Guettouche 
---
 net/bluetooth/bluetooth_sockif.c   |  4 ++--
 net/can/can_sockif.c   | 10 +-
 net/devif/devif_poll.c |  4 ++--
 net/ieee802154/ieee802154_sockif.c |  4 ++--
 net/local/local_sockif.c   |  4 ++--
 net/pkt/pkt_send.c |  6 +++---
 net/pkt/pkt_sockif.c   |  8 
 net/utils/net_chksum.c |  5 +++--
 net/utils/net_lock.c   |  8 
 9 files changed, 27 insertions(+), 26 deletions(-)

diff --git a/net/bluetooth/bluetooth_sockif.c b/net/bluetooth/bluetooth_sockif.c
index 9eeb533..bafa80c 100644
--- a/net/bluetooth/bluetooth_sockif.c
+++ b/net/bluetooth/bluetooth_sockif.c
@@ -177,8 +177,8 @@ static int bluetooth_sockif_alloc(FAR struct socket *psock)
 static int bluetooth_setup(FAR struct socket *psock, int protocol)
 {
   /* Allocate the appropriate connection structure.  This reserves the
-   * the connection structure is is unallocated at this point.  It will
-   * not actually be initialized until the socket is connected.
+   * connection structure, it is unallocated at this point.  It will not
+   * actually be initialized until the socket is connected.
*
* Only SOCK_RAW is supported
*/
diff --git a/net/can/can_sockif.c b/net/can/can_sockif.c
index 5571edf..3083ff7 100644
--- a/net/can/can_sockif.c
+++ b/net/can/can_sockif.c
@@ -189,7 +189,7 @@ static uint16_t can_poll_eventhandler(FAR struct 
net_driver_s *dev,
  * Input Parameters:
  *   psock- A pointer to a user allocated socket structure to be
  *  initialized.
- *   protocol - NetLink socket protocol (see sys/socket.h)
+ *   protocol - CAN socket protocol (see sys/socket.h)
  *
  * Returned Value:
  *   Zero (OK) is returned on success.  Otherwise, a negated errno value is
@@ -226,7 +226,7 @@ static int can_setup(FAR struct socket *psock, int protocol)
 
   if (domain == PF_CAN && (type == SOCK_RAW || type == SOCK_DGRAM))
 {
-  /* Allocate the NetLink socket connection structure and save it in the
+  /* Allocate the CAN socket connection structure and save it in the
* new socket instance.
*/
 
@@ -322,7 +322,7 @@ static void can_addref(FAR struct socket *psock)
  *   space (address family) but has no name assigned.
  *
  * Input Parameters:
- *   conn NetLink socket connection structure
+ *   conn CAN socket connection structure
  *   addr Socket local address
  *   addrlen  Length of 'addr'
  *
@@ -384,7 +384,7 @@ static int can_bind(FAR struct socket *psock,
  *   the object pointed to by address is unspecified.
  *
  * Input Parameters:
- *   conn NetLink socket connection structure
+ *   conn CAN socket connection structure
  *   addr sockaddr structure to receive data [out]
  *   addrlen  Length of sockaddr structure [in/out]
  *
@@ -801,7 +801,7 @@ static ssize_t can_sendmsg(FAR struct socket *psock, FAR 
struct msghdr *msg,
  * Name: can_close
  *
  * Description:
- *   Performs the close operation on a NetLink socket instance
+ *   Performs the close operation on a CAN socket instance
  *
  * Input Parameters:
  *   psock   Socket instance
diff --git a/net/devif/devif_poll.c b/net/devif/devif_poll.c
index 15c42c7..c80063d 100644
--- a/net/devif/devif_poll.c
+++ b/net/devif/devif_poll.c
@@ -240,7 +240,7 @@ static int devif_poll_pkt_connections(FAR struct 
net_driver_s *dev,
 #endif /* CONFIG_NET_PKT */
 
 /
- * Name: devif_poll_pkt_connections
+ * Name: devif_poll_can_connections
  *
  * Description:
  *   Poll all packet connections for available packets to send.
@@ -705,7 +705,7 @@ int devif_poll(FAR struct net_driver_s *dev, 
devif_poll_callback_t callback)
 #endif
 #ifdef CONFIG_NET_CAN
 {
-  /* Check for pending packet socket transfer */
+  /* Check for pending CAN socket transfer */
 
   bstop = devif_poll_can_connections(dev, callback);
 }
diff --git a/net/ieee802154/ieee802154_sockif.c 
b/net/ieee802154/ieee802154_sockif.c
index 19661e8..c831ed7 100644
--- a/net/ieee802154/ieee802154_sockif.c
+++ b/net/ieee802154/ieee802154_sockif.c
@@ -178,8 +178,8 @@ static int ieee802154_sockif_alloc(FAR struct socket *psock)
 static int ieee802154_setup(FAR struct socket *psock, int protocol)
 {
   /* Allocate the appropriate connection structure.  This reserves the
-   * the connection structure is is unallocated at this point. 

[incubator-nuttx] branch master updated (b9d4bd0 -> c33040f)

2021-01-27 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from b9d4bd0  arch: esp32: Fix compile errors with CONFIG_SMP=y
 add c33040f  License/authorship handling scripts

No new revisions were added by this update.

Summary of changes:
 tools/licensing/README.md  |  57 
 .../cxd56_uid.h => tools/licensing/apachize.py |  40 +--
 tools/licensing/author_mappings.json   |  11 +
 tools/licensing/check.py   | 287 +
 tools/licensing/log2json.sh|  77 ++
 5 files changed, 456 insertions(+), 16 deletions(-)
 create mode 100644 tools/licensing/README.md
 copy arch/arm/src/cxd56xx/cxd56_uid.h => tools/licensing/apachize.py (54%)
 mode change 100644 => 100755
 create mode 100644 tools/licensing/author_mappings.json
 create mode 100755 tools/licensing/check.py
 create mode 100755 tools/licensing/log2json.sh



(nuttx) branch master updated: Revert "[POSIX][Bug] syslog: Add support for `%m` modifier"

2024-12-24 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 4ada30b8f7 Revert "[POSIX][Bug] syslog: Add support for `%m` modifier"
4ada30b8f7 is described below

commit 4ada30b8f7b5886d472e60288d86ac1c2b8ffee3
Author: Javier Alonso 
AuthorDate: Tue Dec 24 14:54:33 2024 +0100

Revert "[POSIX][Bug] syslog: Add support for `%m` modifier"

This reverts commit badb5c5ac69574aca724a79f5256e8d8b49e8ba8.
---
 libs/libc/stdio/lib_libvsprintf.c | 9 -
 1 file changed, 9 deletions(-)

diff --git a/libs/libc/stdio/lib_libvsprintf.c 
b/libs/libc/stdio/lib_libvsprintf.c
index 4589154d5d..610a6a42d9 100644
--- a/libs/libc/stdio/lib_libvsprintf.c
+++ b/libs/libc/stdio/lib_libvsprintf.c
@@ -163,10 +163,6 @@ static int vsprintf_internal(FAR struct lib_outstream_s 
*stream,
   uint16_t flags;
   int width;
   int prec;
-
-  /* For the %m format we may need the current `errno' value */
-
-  int saved_errno = errno;
   union
   {
 #if defined (CONFIG_LIBC_LONG_LONG) || (ULONG_MAX > 4294967295UL)
@@ -915,11 +911,6 @@ flt_oper:
   size = 1;
   goto str_lpad;
 
-case 'm': /* Print error message (%m) */
-  pnt = strerror(saved_errno);
-  size = strlen(pnt); /* Adjusting the size is not supported by %m */
-  goto str_lpad;
-
 case 's':
 case 'S':
 #ifdef CONFIG_LIBC_NUMBERED_ARGS



(nuttx) branch master updated (10a1d17a85 -> 366c8a5d94)

2024-12-10 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 10a1d17a85 xtensa/esp32s3: add lock for async operation work
 add 366c8a5d94 Documentation: Remove CONFIG_ARMV7M_USEBASEPRI from code 
base

No new revisions were added by this update.

Summary of changes:
 Documentation/guides/renode.rst | 17 +
 Documentation/guides/zerolatencyinterrupts.rst  |  2 --
 .../arm/stm32f3/boards/stm32f3discovery/index.rst   |  3 +--
 .../arm/stm32l1/boards/stm32ldiscovery/index.rst|  3 +--
 4 files changed, 3 insertions(+), 22 deletions(-)



(nuttx) branch master updated: Added comma to fix undefined bits struct member

2024-12-20 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 e039fa039d Added comma to fix undefined bits struct member
e039fa039d is described below

commit e039fa039d7c7d9fcb1c604f5f2542daf0b542b4
Author: Kyle Wilson 
AuthorDate: Fri Dec 20 14:19:31 2024 -0600

Added comma to fix undefined bits struct member
---
 arch/arm/src/imx6/imx_serial.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/src/imx6/imx_serial.c b/arch/arm/src/imx6/imx_serial.c
index 818d8be147..ae2948c90c 100644
--- a/arch/arm/src/imx6/imx_serial.c
+++ b/arch/arm/src/imx6/imx_serial.c
@@ -296,7 +296,7 @@ static struct imx_uart_s g_uart1priv =
   .baud   = CONFIG_UART1_BAUD,
   .irq= IMX_IRQ_UART1,
   .parity = CONFIG_UART1_PARITY,
-  .lock   = SP_UNLOCKED
+  .lock   = SP_UNLOCKED,
   .bits   = CONFIG_UART1_BITS,
   .stopbits2  = CONFIG_UART1_2STOP,
 };



(nuttx) branch master updated: Documentation/guides: Fix typos in port_arm_cm4.rst

2024-12-20 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 02828921db Documentation/guides: Fix typos in port_arm_cm4.rst
02828921db is described below

commit 02828921db433bf412a617b4a81f8d41da6bc0b7
Author: Masanari Iida 
AuthorDate: Sat Dec 21 12:15:04 2024 +0900

Documentation/guides: Fix typos in port_arm_cm4.rst

This patch fixes spelling typos in port_arm_cm4.rst
---
 Documentation/guides/port_arm_cm4.rst | 16 
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/Documentation/guides/port_arm_cm4.rst 
b/Documentation/guides/port_arm_cm4.rst
index 3bbfed2488..2a20541324 100644
--- a/Documentation/guides/port_arm_cm4.rst
+++ b/Documentation/guides/port_arm_cm4.rst
@@ -85,7 +85,7 @@ And you can do distclean by following command.
 Step4 : Compile
 ---
 
-Try to buid with the implementation of Step1-2, you would face the error as 
following
+Try to build with the implementation of Step1-2, you would face the error as 
following
 if you implemented only directory / Kconfig / Make.defs / Makefile / defconfig 
about Step1-2.
 
 .. code-block::
@@ -178,7 +178,7 @@ Step6 : Implement
 -
 
 There are some implementation items, major items are bellow listed. To pass 
the Linking,
-try to implement these symboles.
+try to implement these symbols.
 
 
+-+++
 | Category| Item   | Comment   
 |
@@ -201,7 +201,7 @@ try to implement these symboles.
 .. _apache/nuttx/pull/12441: https://github.com/apache/nuttx/pull/12441
 .. _sched/Kconfig: https://github.com/apache/nuttx/blob/master/sched/Kconfig
 
-If got the pass of Linking, you would see follwoing result.
+If got the pass of Linking, you would see following result.
 
 .. code-block::
 
@@ -216,7 +216,7 @@ If got the pass of Linking, you would see follwoing result.
 Step7 : Verify
 --
 
-To execute and debug on the evalutaion board, add following configurations.
+To execute and debug on the evaluation board, add following configurations.
 
 .. code-block::
 
@@ -232,7 +232,7 @@ If your implementations were good, you would see following 
logs.
   nsh>
   nsh>
 
-After comfirming to boot NuttShell(NSH), try to execute "apps/testing/ostest".
+After confirming to boot NuttShell(NSH), try to execute "apps/testing/ostest".
 The "apps/testing/ostest" needs following configurations.
 
 .. code-block::
@@ -242,7 +242,7 @@ The "apps/testing/ostest" needs following configurations.
   CONFIG_SCHED_WAITPID=y
   CONFIG_TESTING_OSTEST=y
 
-And one more test is recomended to check the timer implementation whether
+And one more test is recommended to check the timer implementation whether
 the kernel could count the time accurately or not.
 I checked it by following code. About the function : cxd32_timerget(),
 see `apache/nuttx/pull/12441`_ 
@@ -406,7 +406,7 @@ Appendix : out-of-tree code
   +string "Program name"
   +default "time"
   +---help---
-  +This apps measures the elasped time of sleep system call to confirm 
the timer implementation.
+  +This apps measures the elapsed time of sleep system call to confirm 
the timer implementation.
   +
   +config CXD32XX_APPS_TIME_PRIORITY
   +int "CXD32XX Time task priority"
@@ -478,7 +478,7 @@ Appendix : out-of-tree code
   +  uint32_t pre;
   +  uint32_t post;
   +
-  +  printf("measures the elasped time of sleep system call to confirm \
+  +  printf("measures the elapsed time of sleep system call to confirm \
   +  the timer implementation.\n");
   +
   +  pre = cxd32_timerget();



(nuttx) branch master updated (954081cdd8 -> 27d5a1b4b7)

2025-02-18 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 954081cdd8 xtensa/esp32s3: use common Espressif wireless source
 add 5a64967ce7 nuttx/compiler: fix build warning on GCC14
 add 27d5a1b4b7 arm/memory_barrier: fix build warning on GCC14

No new revisions were added by this update.

Summary of changes:
 arch/arm/include/spinlock.h   | 32 ++-
 arch/or1k/include/mor1kx/irq.h|  3 +--
 arch/xtensa/src/common/xtensa_backtrace.c |  7 ---
 include/nuttx/compiler.h  |  4 ++--
 4 files changed, 13 insertions(+), 33 deletions(-)



(nuttx) branch master updated (02f55f2c70 -> 825b745408)

2025-03-04 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from 02f55f2c70 boards/sim: enable ADB shell service
 add 76dfa9af57 Documentation/platforms/risc-v/eic7700x: Add support for 
ESWIN EIC7700X SoC
 add 825b745408 arch/risc-v/eic7700x: Add support for ESWIN EIC7700X SoC

No new revisions were added by this update.

Summary of changes:
 Documentation/platforms/risc-v/eic7700x/index.rst  |  16 ++
 arch/risc-v/Kconfig|  23 +++
 arch/risc-v/include/{bl808 => eic7700x}/chip.h |   8 +-
 arch/risc-v/include/{qemu-rv => eic7700x}/irq.h|  16 +-
 arch/risc-v/src/{jh7110 => eic7700x}/Kconfig   |   0
 arch/risc-v/src/{jh7110 => eic7700x}/Make.defs |  10 +-
 arch/risc-v/src/{jh7110 => eic7700x}/chip.h|  26 +++-
 .../eic7700x_allocateheap.c}   |   2 +-
 .../bl808_head.S => eic7700x/eic7700x_head.S}  |  21 +--
 .../sg2000_irq.c => eic7700x/eic7700x_irq.c}   |  46 --
 .../eic7700x_irq_dispatch.c}   |  13 +-
 .../eic7700x_memorymap.h}  |  12 +-
 .../eic7700x_mm_init.c}|  94 +---
 .../k230_mm_init.h => eic7700x/eic7700x_mm_init.h} |  16 +-
 .../eic7700x_pgalloc.c}|   2 +-
 .../sg2000_start.c => eic7700x/eic7700x_start.c}   | 165 +
 .../eic7700x_timerisr.c}   |   4 +-
 .../hardware/eic7700x_memorymap.h} |  10 +-
 .../hardware/eic7700x_plic.h}  |  20 +--
 19 files changed, 338 insertions(+), 166 deletions(-)
 create mode 100644 Documentation/platforms/risc-v/eic7700x/index.rst
 copy arch/risc-v/include/{bl808 => eic7700x}/chip.h (84%)
 copy arch/risc-v/include/{qemu-rv => eic7700x}/irq.h (81%)
 copy arch/risc-v/src/{jh7110 => eic7700x}/Kconfig (100%)
 copy arch/risc-v/src/{jh7110 => eic7700x}/Make.defs (82%)
 copy arch/risc-v/src/{jh7110 => eic7700x}/chip.h (80%)
 copy arch/risc-v/src/{sg2000/sg2000_allocateheap.c => 
eic7700x/eic7700x_allocateheap.c} (98%)
 copy arch/risc-v/src/{bl808/bl808_head.S => eic7700x/eic7700x_head.S} (87%)
 copy arch/risc-v/src/{sg2000/sg2000_irq.c => eic7700x/eic7700x_irq.c} (78%)
 copy arch/risc-v/src/{jh7110/jh7110_irq_dispatch.c => 
eic7700x/eic7700x_irq_dispatch.c} (87%)
 copy arch/risc-v/src/{bl808/bl808_memorymap.h => 
eic7700x/eic7700x_memorymap.h} (82%)
 copy arch/risc-v/src/{jh7110/jh7110_mm_init.c => eic7700x/eic7700x_mm_init.c} 
(75%)
 copy arch/risc-v/src/{k230/k230_mm_init.h => eic7700x/eic7700x_mm_init.h} (85%)
 copy arch/risc-v/src/{sg2000/sg2000_pgalloc.c => eic7700x/eic7700x_pgalloc.c} 
(97%)
 copy arch/risc-v/src/{sg2000/sg2000_start.c => eic7700x/eic7700x_start.c} (69%)
 copy arch/risc-v/src/{sg2000/sg2000_timerisr.c => 
eic7700x/eic7700x_timerisr.c} (96%)
 copy arch/risc-v/src/{sg2000/hardware/sg2000_memorymap.h => 
eic7700x/hardware/eic7700x_memorymap.h} (81%)
 copy arch/risc-v/src/{bl808/hardware/bl808_plic.h => 
eic7700x/hardware/eic7700x_plic.h} (71%)



(nuttx) branch master updated: tools/nxstyle: handle case statement

2025-02-21 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 fd6d804623 tools/nxstyle: handle case statement
fd6d804623 is described below

commit fd6d80462303fc363d885150e49f9c5f175639c5
Author: Luchian Mihai 
AuthorDate: Sat Feb 15 12:27:13 2025 +0200

tools/nxstyle: handle case statement

fix nxstyle so it throw error if case statement is not on new line
---
 tools/nxstyle.c | 61 -
 1 file changed, 43 insertions(+), 18 deletions(-)

diff --git a/tools/nxstyle.c b/tools/nxstyle.c
index 1937976398..8179921c44 100644
--- a/tools/nxstyle.c
+++ b/tools/nxstyle.c
@@ -1133,6 +1133,7 @@ int main(int argc, char **argv, char **envp)
   bool bfor;/* True: This line is beginning of a 'for' statement */
   bool bif; /* True: This line is beginning of a 'if' statement */
   bool bswitch; /* True: Within a switch statement */
+  bool bcase;   /* True: Within a case statement of a switch */
   bool bstring; /* True: Within a string */
   bool bquote;  /* True: Backslash quoted character next */
   bool bblank;  /* Used to verify block comment terminator */
@@ -1269,6 +1270,7 @@ int main(int argc, char **argv, char **envp)
   bcrs   = false;   /* True: Carriage return found on the line */
   bfunctions = false;   /* True: In private or public functions */
   bswitch= false;   /* True: Within a switch statement */
+  bcase  = false;   /* True: Within a case statement of a switch */
   bstring= false;   /* True: Within a string */
   bexternc   = false;   /* True: Within 'extern "C"' */
   bif= false;   /* True: This line is beginning of a 'if' 
statement */
@@ -2004,22 +2006,11 @@ int main(int argc, char **argv, char **envp)
*/
 
   else if (strncmp(&line[indent], "break ", 6) == 0 ||
-   strncmp(&line[indent], "case ", 5) == 0 ||
-#if 0 /* Part of switch */
-   strncmp(&line[indent], "case ", 5) == 0 ||
-#endif
strncmp(&line[indent], "continue ", 9) == 0 ||
-
-#if 0 /* Part of switch */
-   strncmp(&line[indent], "default ", 8) == 0 ||
-#endif
strncmp(&line[indent], "do ", 3) == 0 ||
strncmp(&line[indent], "else ", 5) == 0 ||
strncmp(&line[indent], "goto ", 5) == 0 ||
strncmp(&line[indent], "return ", 7) == 0 ||
-#if 0 /* Doesn't follow pattern */
-   strncmp(&line[indent], "switch ", 7) == 0 ||
-#endif
strncmp(&line[indent], "while ", 6) == 0)
 {
   bstatm = true;
@@ -2042,6 +2033,29 @@ int main(int argc, char **argv, char **envp)
 {
   bswitch = true;
 }
+  else if (strncmp(&line[indent], "switch(", 7) == 0)
+{
+  ERROR("Missing whitespace after keyword", lineno, n);
+  bswitch = true;
+}
+  else if (strncmp(&line[indent], "case ", 5) == 0)
+{
+  bcase = true;
+}
+  else if (strncmp(&line[indent], "case(", 5) == 0)
+{
+  ERROR("Missing whitespace after keyword", lineno, n);
+  bcase = true;
+}
+  else if (strncmp(&line[indent], "default ", 8) == 0)
+{
+  ERROR("Missing whitespace after keyword", lineno, n);
+  bcase = true;
+}
+  else if (strncmp(&line[indent], "default:", 8) == 0)
+{
+  bcase = true;
+}
 
   /* Also check for C keywords with missing white space */
 
@@ -2063,11 +2077,6 @@ int main(int argc, char **argv, char **envp)
   bfor   = true;
   bstatm = true;
 }
-  else if (strncmp(&line[indent], "switch(", 7) == 0)
-{
-  ERROR("Missing whitespace after keyword", lineno, n);
-  bswitch = true;
-}
 }
 
   /* STEP 3: Parse each character on the line */
@@ -2731,9 +2740,26 @@ int main(int argc, char **argv, char **envp)
   }
   }
   break;
+case ':':
+  {
+if (bcase =

(nuttx-apps) branch master updated: [nxstyle] fix Relative file path

2025-02-21 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 4315a1c8c [nxstyle] fix Relative file path
4315a1c8c is described below

commit 4315a1c8ccbb5c29ccc006a809123787e2cc3109
Author: simbit18 
AuthorDate: Fri Feb 21 12:46:19 2025 +0100

[nxstyle] fix Relative file path

fix Relative file path does not match actual file.

Signed-off-by: simbit18 
---
 examples/rust/hello/Make.defs  | 2 +-
 examples/spislv_test/Make.defs | 2 +-
 mlearning/cmsis-nn/Make.defs   | 2 +-
 system/sensorscope/Make.defs   | 2 +-
 testing/cxx/cxxsize/Make.defs  | 2 +-
 testing/cxx/cxxsize/Makefile   | 2 +-
 6 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/examples/rust/hello/Make.defs b/examples/rust/hello/Make.defs
index aaacb0efa..829b1c507 100644
--- a/examples/rust/hello/Make.defs
+++ b/examples/rust/hello/Make.defs
@@ -1,5 +1,5 @@
 
-# apps/examples/hello_rust_cargo/Make.defs
+# apps/examples/rust/hello/Make.defs
 #
 # Licensed to the Apache Software Foundation (ASF) under one or more
 # contributor license agreements.  See the NOTICE file distributed with
diff --git a/examples/spislv_test/Make.defs b/examples/spislv_test/Make.defs
index 14bb4852a..039cba106 100644
--- a/examples/spislv_test/Make.defs
+++ b/examples/spislv_test/Make.defs
@@ -1,5 +1,5 @@
 
-# apps/examples/spislv/Make.defs
+# apps/examples/spislv_test/Make.defs
 #
 # SPDX-License-Identifier: Apache-2.0
 #
diff --git a/mlearning/cmsis-nn/Make.defs b/mlearning/cmsis-nn/Make.defs
index 760173037..1f14dc090 100644
--- a/mlearning/cmsis-nn/Make.defs
+++ b/mlearning/cmsis-nn/Make.defs
@@ -1,5 +1,5 @@
 
-# apps/mlearning/cmsis/Make.defs
+# apps/mlearning/cmsis-nn/Make.defs
 #
 # SPDX-License-Identifier: Apache-2.0
 #
diff --git a/system/sensorscope/Make.defs b/system/sensorscope/Make.defs
index d4b84a721..31ad1d6cf 100644
--- a/system/sensorscope/Make.defs
+++ b/system/sensorscope/Make.defs
@@ -1,5 +1,5 @@
 
-# apps/systen/sensorscope/Make.defs
+# apps/system/sensorscope/Make.defs
 #
 # SPDX-License-Identifier: Apache-2.0
 #
diff --git a/testing/cxx/cxxsize/Make.defs b/testing/cxx/cxxsize/Make.defs
index 73798f275..61f0d9068 100644
--- a/testing/cxx/cxxsize/Make.defs
+++ b/testing/cxx/cxxsize/Make.defs
@@ -1,5 +1,5 @@
 
-# apps/testing/cxx/cxxtest/Make.defs
+# apps/testing/cxx/cxxsize/Make.defs
 #
 # SPDX-License-Identifier: Apache-2.0
 #
diff --git a/testing/cxx/cxxsize/Makefile b/testing/cxx/cxxsize/Makefile
index 59e57fd71..2bdb3d7cf 100644
--- a/testing/cxx/cxxsize/Makefile
+++ b/testing/cxx/cxxsize/Makefile
@@ -1,5 +1,5 @@
 
-# apps/testing/cxx/cxxtest/Makefile
+# apps/testing/cxx/cxxsize/Makefile
 #
 # SPDX-License-Identifier: Apache-2.0
 #



(nuttx) 02/02: esp32[s3]: Add Documentation for esp32s3-lcd-ev board

2025-02-20 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 2d069231c54605ec0907704ae758fcc3acb7cf6f
Author: Eren Terzioglu 
AuthorDate: Mon Feb 17 11:42:21 2025 +0100

esp32[s3]: Add Documentation for esp32s3-lcd-ev board
---
 .../esp32s3-lcd-ev/esp32s3-audio-config-file.png   | Bin 0 -> 21276 bytes
 .../boards/esp32s3-lcd-ev/esp32s3_lcd_ev.png   | Bin 0 -> 338946 bytes
 .../xtensa/esp32s3/boards/esp32s3-lcd-ev/index.rst | 156 +
 3 files changed, 156 insertions(+)

diff --git 
a/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/esp32s3-audio-config-file.png
 
b/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/esp32s3-audio-config-file.png
new file mode 100644
index 00..c51fa32e29
Binary files /dev/null and 
b/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/esp32s3-audio-config-file.png
 differ
diff --git 
a/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/esp32s3_lcd_ev.png
 
b/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/esp32s3_lcd_ev.png
new file mode 100644
index 00..23be064d3a
Binary files /dev/null and 
b/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/esp32s3_lcd_ev.png
 differ
diff --git 
a/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/index.rst 
b/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/index.rst
new file mode 100644
index 00..9b36d11cd7
--- /dev/null
+++ b/Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/index.rst
@@ -0,0 +1,156 @@
+===
+ESP32-S3-LCD-EV
+===
+
+The `ESP32-S3-LCD-EV-Board 
<https://docs.espressif.com/projects/esp-dev-kits/en/latest/esp32s3/esp32-s3-lcd-ev-board/user_guide.html>`_
  is a small-sized AI development board from Espressif featuring the ESP32-S3 
CPU with a touchscreen LCD display, dual microphone, an 16 MB Octal PSRAM and 
an 16 MB flash.
+
+.. list-table::
+   :align: center
+
+   * - .. figure:: esp32s3_lcd_ev.png
+  :align: center
+
+Features
+
+
+  - ESP32-S3 WROOM-1 Module
+  - USB Type-C ports
+  - Power LED
+  - LCD Display
+  - MEMS Microphone
+  - 16MB Octal PSRAM
+  - 16MB SPI Flash
+  - RST and BOOT buttons (BOOT accessible to user)
+
+Serial Console
+==
+
+UART0 is, by default, the serial console.  It connects to the on-board
+CP2102 converter and is available on the USB connector USB CON8 (J1).
+
+It will show up as /dev/ttyUSB[n] where [n] will probably be 0.
+
+Buttons and LEDs
+
+
+Board Buttons
+-
+
+There are two buttons labeled Boot and EN.  The EN button is not available
+to software.  It pulls the chip enable line that doubles as a reset line.
+
+The BOOT button is connected to IO0.  On reset it is used as a strapping
+pin to determine whether the chip boots normally or into the serial
+bootloader.  After reset, however, the BOOT button can be used for software
+input.
+
+Board LEDs
+--
+
+There are several on-board LEDs for that indicate the presence of power
+and USB activity.  None of these are available for use by software.
+Another WS2812 LED is connected to GPIO4.
+
+Configurations
+==
+
+All of the configurations presented below can be tested by running the 
following commands::
+
+$ ./tools/configure.sh esp32s3-lcd-ev:
+$ make flash ESPTOOL_PORT=/dev/ttyUSB0 -j
+
+Where  is the name of board configuration you want to use, i.e.: 
nsh, buttons, wifi...
+Then use a serial console terminal like ``picocom`` configured to 115200 8N1.
+
+audio
+-
+
+This configuration uses the I2S0 peripheral and an externally connected audio
+codec to play an audio file streamed over an HTTP connection while connected
+to a Wi-Fi network.
+
+**Audio Codec Setup**
+
+The CS4344 audio codec is connected to the following pins:
+
+ == 
+ESP32-S3 Pin CS4344 Pin Description
+ == 
+5MCLK   Master Clock
+16   SCLK   Serial Clock
+7LRCK   Left Right Clock (Word Select)
+6SDIN   Serial Data In on CS4344. (DOUT on ESP32-S3)
+ == 
+
+**Simple HTTP server**
+
+Prepare a PCM-encoded (`.wav`) audio file with 16 or 24 bits/sample (sampled at
+16~48kHz). This file must be placed into a folder in a computer that could
+be accessed on the same Wi-Fi network the ESP32 will be connecting to.
+
+Python provides a simple HTTP server. ``cd`` to the audio file folder on the
+PC and run::
+
+$ python3 -m http.server
+Serving HTTP on 0.0.0.0 port 8000 (http://0.0.0.0:8000/)
+
+Look for your PC IP address and test playing the prepared audio on your
+browser:
+
+.. figure:: esp32s3-audio-config-file.png
+  :a

(nuttx) branch master updated (a76d63646f -> 2d069231c5)

2025-02-20 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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


from a76d63646f drivers/sensors/ms56xx: Use nxsig_usleep for long delays.
 new 3170af2fd0 esp32[c6|h2]: Update peripheral support docs
 new 2d069231c5 esp32[s3]: Add Documentation for esp32s3-lcd-ev board

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:
 Documentation/platforms/risc-v/esp32c6/index.rst   |   4 +-
 Documentation/platforms/risc-v/esp32h2/index.rst   |   4 +-
 .../esp32s3-lcd-ev/esp32s3-audio-config-file.png}  | Bin
 .../boards/esp32s3-lcd-ev/esp32s3_lcd_ev.png   | Bin 0 -> 338946 bytes
 .../xtensa/esp32s3/boards/esp32s3-lcd-ev/index.rst | 156 +
 5 files changed, 160 insertions(+), 4 deletions(-)
 copy 
Documentation/platforms/xtensa/{esp32/boards/esp32-audio-kit/esp32-audio-config-file.png
 => esp32s3/boards/esp32s3-lcd-ev/esp32s3-audio-config-file.png} (100%)
 create mode 100644 
Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/esp32s3_lcd_ev.png
 create mode 100644 
Documentation/platforms/xtensa/esp32s3/boards/esp32s3-lcd-ev/index.rst



(nuttx) 01/02: esp32[c6|h2]: Update peripheral support docs

2025-02-20 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

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

commit 3170af2fd0a827fafbf2d5274dbc22e2bd242466
Author: Eren Terzioglu 
AuthorDate: Mon Feb 17 09:53:29 2025 +0100

esp32[c6|h2]: Update peripheral support docs
---
 Documentation/platforms/risc-v/esp32c6/index.rst | 4 ++--
 Documentation/platforms/risc-v/esp32h2/index.rst | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/Documentation/platforms/risc-v/esp32c6/index.rst 
b/Documentation/platforms/risc-v/esp32c6/index.rst
index bd98d966e6..c6049e3719 100644
--- a/Documentation/platforms/risc-v/esp32c6/index.rst
+++ b/Documentation/platforms/risc-v/esp32c6/index.rst
@@ -283,12 +283,12 @@ GPIO Yes
 HMAC No
 I2C  Yes
 I2S  No
-Int. Temp.   No
+Int. Temp.   Yes
 LED  No
 LED_PWM  Yes
 MCPWMYes
 Pulse CounterYes
-RMT  No
+RMT  Yes
 RNG  No
 RSA  No
 RTC  Yes
diff --git a/Documentation/platforms/risc-v/esp32h2/index.rst 
b/Documentation/platforms/risc-v/esp32h2/index.rst
index 95a2d0aef8..7fff0591a0 100644
--- a/Documentation/platforms/risc-v/esp32h2/index.rst
+++ b/Documentation/platforms/risc-v/esp32h2/index.rst
@@ -283,12 +283,12 @@ GPIO Yes
 HMAC No
 I2C  Yes
 I2S  No
-Int. Temp.   No
+Int. Temp.   Yes
 LED  No
 LED_PWM  Yes
 MCPWMNo
 Pulse CounterYes
-RMT  No
+RMT  Yes
 RNG  No
 RSA  No
 RTC  Yes



(nuttx) branch master updated: docs/calib_udelay: Added documentation for the `calib_udelay` example.

2025-09-10 Thread hartmannathan
This is an automated email from the ASF dual-hosted git repository.

hartmannathan 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 71c05b3a2b5 docs/calib_udelay: Added documentation for the 
`calib_udelay` example.
71c05b3a2b5 is described below

commit 71c05b3a2b56ea303253140b30d176f4fb739b38
Author: Matteo Golin 
AuthorDate: Wed Sep 10 10:49:28 2025 -0400

docs/calib_udelay: Added documentation for the `calib_udelay` example.

This commit adds documentation to the almost empty `calib_udelay` page
as part of #11081. It provides reasoning for the example, an explanation
of what it does and why `CONFIG_BOARD_LOOPSPERMSEC` is necessary, and
also shows some example console output of the program.

Signed-off-by: Matteo Golin 
---
 .../applications/examples/calib_udelay/index.rst   | 49 +-
 1 file changed, 48 insertions(+), 1 deletion(-)

diff --git a/Documentation/applications/examples/calib_udelay/index.rst 
b/Documentation/applications/examples/calib_udelay/index.rst
index d5390fbe697..2c5b1e5402e 100644
--- a/Documentation/applications/examples/calib_udelay/index.rst
+++ b/Documentation/applications/examples/calib_udelay/index.rst
@@ -2,4 +2,51 @@
 ``calib_udelay`` Calibration tool for udelay
 =
 
-Calibration tool for udelay.
+This tool is used for calibrating the configuration option
+``CONFIG_BOARD_LOOPSPERMSEC``. This option is used by NuttX to perform
+busy-waiting (i.e., spinning in a loop) when a very basic busy-wait sleep is
+needed in board logic. This is also sometimes used when the timer-based sleep
+functions do not have a low enough resolution for shorter timings (i.e. system
+tick every 1ms but you want to sleep for 100us).
+
+When porting NuttX a new board, this example program is very useful to get a
+calibrated value for ``CONFIG_BOARD_LOOPSPERMSEC``.
+
+.. note::
+
+   If you are testing any drivers and have unexpected issues with them, make
+   sure that this configuration option has been calibrated. It can cause
+   bad/incorrect timings in drivers if not calibrated.
+
+Here is the example output from running the application:
+
+.. code-block:: console
+
+   nsh> calib_udelay
+
+   Calibrating timer for main calibration...
+   Performing main calibration for udelay.This will take approx. 17.280 
seconds.
+   Calibration slope for udelay:
+ Y = m*X + b, where
+   X is loop iterations,
+   Y is time in nanoseconds,
+   b is base overhead,
+   m is nanoseconds per loop iteration.
+
+ m = 5. nsec/iter
+ b = -19.9995 nsec
+
+ Correlation coefficient, R² = 1.
+
+   Without overhead, 0.1875 iterations per nanosecond and 187500.00 
iterations per millis.
+
+   Recommended setting for CONFIG_BOARD_LOOPSPERMSEC:
+  CONFIG_BOARD_LOOPSPERMSEC=187500
+
+You can simply copy paste the value from the console output and use it as the
+value for your board by setting it in the Kconfig menu.
+
+The program is run without any arguments. Configuration options for how the
+program runs (taking more measurements, etc.) can be seen in its Kconfig menu.
+Press ``h`` with the configuration option highlighted under your cursor to read
+the help text about what each option does.