Commit Graph

38550 Commits

Author SHA1 Message Date
Masayuki Ishikawa
2be53a9335 arch: cxd56xx: Add interrupt stack for SMP
Summary:
- This commit adds interrupt stack for SMP

Impact:
- Affects SMP only

Testing:
- Tested with spresense:wifi_smp with CONFIG_ARCH_INTERRUPTSTACK=2048

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-10-06 12:42:01 +02:00
Masayuki Ishikawa
4c0602f52c arch: cxd56xx: Introduce cxd56_cpuindex.h
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-10-06 12:42:01 +02:00
Masayuki Ishikawa
822497d021 drivers: note: Fix compile errors in noteram_driver.c
Summary:
- This commit fixes compile errors if CONFIG_DEBUG_ASSERTIONS=y

Impact:
- Affects noteram_driver only

Testing:
- Tested with spresense:wifi_smp with CONFIG_DEBUG_ASSERTIONS=y

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-10-06 16:42:40 +08:00
Nathan Hartman
ab4ca67b91 tiva/lm4f: Fix nxstyle warnings
arch/arm/src/tiva/lm/lm4f_gpio.c:

    * Fix nxstyle warnings. No functional changes.
2020-10-06 10:44:21 +08:00
Nakamura, Yuuichi
89ea234af8 Add on-boot instrumentation support for note filter 2020-10-06 03:26:46 +08:00
Nakamura, Yuuichi
a373079a94 Fix /dev/note driver for task trace support 2020-10-06 03:26:46 +08:00
Nakamura, Yuuichi
6efecd2105 Add notectl driver 2020-10-06 03:26:46 +08:00
Nakamura, Yuuichi
6b54377476 Add note filter functions 2020-10-06 03:26:46 +08:00
Gregory Nutt
32b0562375 Add some comments to inet_ntop()
Endian-ness issues are mind boggling sometimes.  I have been confused by the logic in inet_ntop() a few times so I thought I would add some comments so that I (and others) will understand the endian-ness issues in the future.  No change to logic, only comments changed.
2020-10-05 03:00:22 +08:00
Yoshinori Sugino
e4094eff12 sched/signal: Cosmetic changes 2020-10-05 01:05:45 +08:00
saramonteiro
a562fba971 ESP32: Fixed the type of cpuint variables in esp32_emac.c esp32_i2c.c esp32_spi.c esp32_spi_slave.c 2020-10-02 09:57:56 -07:00
Nathan Hartman
8a1f4db2e1 tiva/cc13xx: Fix nxstyle warnings
arch/arm/src/tiva/cc13xx/cc13xx_start.c:

    * Fix nxstyle warnings. No functional changes.
2020-10-02 13:20:42 -03:00
Abdelatif Guettouche
62732dd6b8 arch/xtensa/src/esp32/esp32_gpio.c: ESP32_NIRQ_GPIO was used instead of
ESP32_NGPIOS

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2020-10-02 11:42:49 -03:00
Abdelatif Guettouche
844f39fc67 arch/xtensa/src/esp32/esp32_gpio.c: Change the logic of setting the ENA
bits so that the call to up_cpu_index is only performed when SMP is
enabled.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2020-10-02 11:42:49 -03:00
Nathan Hartman
80ce7800a9 Sources and Docs: Fix typos and nxstyle issues
Documentation/contributing/coding_style.rst:

    * Fix repeated words: ("this this").
    * Remove trailing spaces.

boards/z80/z80/z80sim/README.txt:

    * Fix repeated words: ("this this") and rewrap lines.

graphics/Kconfig,
libs/libc/math/Kconfig:

    * Fix repeated words: ("this this").

arch/arm/src/armv7-a/arm_assert.c,
arch/arm/src/armv7-r/arm_assert.c,
arch/arm/src/imxrt/imxrt_enet.c,
arch/arm/src/kinetis/kinetis_enet.c,
arch/arm/src/kinetis/kinetis_flexcan.c,
arch/arm/src/s32k1xx/s32k1xx_enet.c,
arch/arm/src/s32k1xx/s32k1xx_flexcan.c,
arch/arm/src/stm32/stm32_pwm.c,
arch/arm/src/stm32h7/stm32_pwm.c,
arch/arm/src/stm32l4/stm32l4_pwm.c,
arch/renesas/src/rx65n/rx65n_usbdev.c,
binfmt/libnxflat/libnxflat_bind.c,
drivers/pipes/pipe_common.c,
net/igmp/igmp_input.c,
net/tcp/tcp_conn.c,
sched/sched/sched_roundrobin.c:

    * Fix typo in comment ("this this").

arch/arm/src/cxd56xx/cxd56_usbdev.c,
arch/arm/src/lc823450/lc823450_usbdev.c:

    * Fix typo in comment and rewrap lines.

arch/arm/src/imxrt/imxrt_usbdev.c,
arch/arm/src/stm32/stm32_dac.c,
arch/arm/src/stm32f0l0g0/stm32_pwm.c,
arch/arm/src/stm32f7/stm32_pwm.c,
arch/arm/src/tiva/lm/lm4f_gpio.h,
fs/nxffs/nxffs_write.c,
include/nuttx/analog/pga11x.h,
include/nuttx/usb/usbdev.h,
net/mld/mld_join.c:

    * Fix typo in comment ("this this").
    * Fix nxstyle issues.
2020-10-02 04:54:52 +02:00
Masayuki Ishikawa
3f461f59ba arch: cxd56xx: Fix handle_irqreq() in cxd56_cpupause.c
Summary:
- The handle_irqreq() is used for remote IRQ control.
- The logic is called via IPI (Inter-Processor Interrupt)
- And the handler should handle only one request
- However, I noticed that the handler handles up to two requests
- This commit fixes this issue

Impact:
- Affects SMP cases only

Testing:
- Tested with spresense:wifi_smp

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-10-02 04:53:53 +02:00
Matias N
2cda47272a nrf52_ppi: fix group disable and add group clear operation 2020-10-01 21:31:58 -03:00
YAMAMOTO Takashi
83f1f2bc42 sim: Restore some symbols in nuttx-names.in
Used by arch/sim/src/sim/vpnkit/*.c
2020-10-01 15:33:22 +08:00
David Sidrane
f6aa845080 stm32f7:Allow the use of the Network Monitor via polling
Not all boards have an interrupt line from the phy to
   the Soc. This commit allows the phy to be polled for
   link status.

   This may not work on all MAC/PHY combination that
   have mutually exclusive link management and operating
   modes. The STM32F7 and LAN8742AI do not have such a
   limitation.
2020-10-01 15:28:51 +08:00
David Sidrane
e254083a7d net:Add ARCH_PHY_POLLED option 2020-10-01 15:28:51 +08:00
Masayuki Ishikawa
8d1dc11a36 boards: spresense: Add CONFIG_USERMAIN_STACKSIZE=3072 to wifi/defconfig
Summary:
- I noticed that stack for the init task was filled almost 100%
- This commit fixes this issue

Impact:
- Affects spresense:wifi configuration only

Testing:
- Tested with renew/mount/wget/nxplayer commands

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-10-01 08:45:48 +02:00
Nathan Hartman
4ac2c73d82 tiva: Fix nxstyle warnings
arch/arm/src/tiva/tm4c/tm4c129_sysctrl.c:

    * Fix nxstyle warnings. No functional changes.

arch/arm/src/tiva/tm4c/tm4c_gpio.c:

    * Fix nxstyle warnings. No functional changes.

arch/arm/src/tiva/tm4c/tm4c_gpio.h:

    * Fix nxstyle warnings. No functional changes.
2020-10-01 12:14:27 +08:00
Sebastian Ene
d6210fcd84 arch/sim: Make the SIGUSR1 host signal to use the NuttX irq logic
Signed-off-by: Sebastian Ene <sene@apache.org>
2020-10-01 12:11:31 +08:00
Abdelatif Guettouche
769d68a762 arch/xtensa: Fix some typos and correct some comments.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2020-09-30 13:55:28 -03:00
patacongo
9142deeb10 Update arch/arm/src/common/arm_interruptcontext.c
Add a comment discussing the limitation of this solution for the case of the ARMv7-A with the GIC
2020-09-30 08:32:25 -06:00
Masayuki Ishikawa
68f102055a arch: xtensa: Fix up_interrupt_context() for SMP
Summary:
- Apply the same fix for Arm SMP

Impact:
- Affects SMP only

Testing:
- Tested with esp32-core:smp (qemu)

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-09-30 08:32:25 -06:00
Masayuki Ishikawa
e8ec8fb4b4 arch: risc-v: Fix up_interrupt_context() for SMP
Summary:
- Apply the same fix for Arm SMP

Impact:
- Affects SMP only

Testing:
- Tested with maix-bit:smp (qemu)

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-09-30 08:32:25 -06:00
Masayuki Ishikawa
bbc6571b28 arch: arm: Fix up_interrupt_context() for SMP
Summary:
- I found an issue with up_interrupt_context() when testing.
- And finally found that up_interrupt_context() is not atomic.
- This commit fixes the issue

Impact:
- Affects SMP only

Testing:
- Tested with spresense:wifi_smp and sabre-6quad:smp (qemu)

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-09-30 08:32:25 -06:00
ligd
22b837f440 arch/sim/src/nuttx-names.in: fix sim crash in Cygwin platform
Change-Id: I966e626eee03ce0b2c01afa905272194028e64f1
2020-09-30 08:07:17 -06:00
raiden00pl
c18e7bb422 nrf52_lowputc.c: fix compilation error for nrf52832 which has limited baud rate support 2020-09-30 09:09:04 -03:00
raiden00pl
4da122b8d4 nrf52_serial.c: fix unused wariable warning 2020-09-30 09:09:04 -03:00
raiden00pl
35a5036e32 nrf52: add serial termios support 2020-09-30 09:09:04 -03:00
Xiang Xiao
b422f49fa7 fs: Skip the enumeration of root directory in foreach_inode
ensure the behaviour same before:
commit b76c4672d6 (origin/root)
Author: Xiang Xiao <xiaoxiang@xiaomi.com>
Date:   Tue Sep 15 17:42:42 2020 +0800

    vfs: Create a node as the root of pseudo file system

    to remove the special process for root

    Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-09-30 12:26:57 +02:00
Bhindhiya
73f0530912 Add Renesas pre-check 2020-09-30 18:22:16 +08:00
Bhindhiya
cdd111a1fa Update to avoid divide by zero issue for RX65N 2020-09-29 21:40:04 +01:00
Nathan Hartman
fc404e15da tiva: Fix nxstyle warnings
arch/arm/src/tiva/hardware/tiva_eeprom.h:

    * Fix nxstyle warnings. No functional changes.

arch/arm/src/tiva/hardware/tiva_sysctrl.h:

    * Fix nxstyle warnings. No functional changes.

arch/arm/src/tiva/hardware/tiva_uart.h:

    * Fix nxstyle warnings. No functional changes.

arch/arm/src/tiva/hardware/tiva_wdt.h:

    * Fix nxstyle warnings. No functional changes.
2020-09-29 16:59:17 +01:00
Dong Heng
a266dc9629 arch/xtensa: Fix task signal process preemption A0 modification error 2020-09-29 09:10:53 -03:00
Bhindhiya
9369ce6488 Add RX65N SPI (RSPI) driver support 2020-09-29 09:09:55 -03:00
Abdelatif Guettouche
70c1170c2e Revert "arch/xtensa/src/esp32/esp32_gpio.c: Enable input mode only when"
This reverts commit b5d3ba64e0.
2020-09-29 09:07:41 -03:00
Yoshinori Sugino
3de85be15a arch/risc-v/src: Branch to up_sigdeliver() with interrupts disabled
When executing an MRET instruction, MIE is set to MPIE.
In order to branch to up_sigdeliver() with interrupts disabled,
we need to change MPIE, not MIE.
2020-09-28 22:41:46 -07:00
Yoshinori Sugino
2adec1f366 arch/risc-v/src/fe310: Branch to up_sigdeliver() with interrupts disabled
When executing an MRET instruction, MIE is set to MPIE.
In order to branch to up_sigdeliver() with interrupts disabled,
we need to change MPIE, not MIE.
2020-09-28 22:41:46 -07:00
David Sidrane
0e98dc306b risc-v:k210: Add KEEP on init_section 2020-09-29 10:26:59 +08:00
David Sidrane
02ffe7da32 mor1kx:or1k Add KEEP on init_section 2020-09-29 10:26:59 +08:00
David Sidrane
c720f221c2 s32k1xx:boards Add KEEP on init_section 2020-09-29 10:26:59 +08:00
David Sidrane
06d1ea1a67 imxrt:imxrt10x0-evk Add KEEP on init_section 2020-09-29 10:26:59 +08:00
Brennan Ashton
bbf16b27d9 nRF52: Add basic error handling for i2c in polling mode
There was no error handling before and it would block on common
cases like NACK which meant that you could not use the i2ctool
to perform a scan of the bus.

This does not handle the interrupt flow which also has incomplete
error handling.
2020-09-28 09:34:08 -03:00
Brennan Ashton
f41b9a10b3 ws2812: moved SPI_LOCK and forgot to change spi drv var name
This snuck in durring a slight PR fixup.
2020-09-28 08:25:43 +01:00
Yoshinori Sugino
5bb4eb39f2 Fix nxstyle warnings 2020-09-28 13:54:43 +08:00
Yoshinori Sugino
698008d1e5 Fix typos 2020-09-28 13:54:43 +08:00
Gregory Nutt
fe0a88c838 Correct compilation of arch/sim/src/sim/up_wpcap.c
This commit corrects the following compilation error:

    /usr/include/cygwin/socket.h:27:8: error: redefinition of 'struct sockaddr'
       27 | struct sockaddr {
          |        ^~~~~~~~
    In file included from /usr/include/w32api/winsock2.h:57,
                     from sim/up_wpcap.c:48:
    /usr/include/w32api/psdk_inc/_ip_types.h:70:8: note: originally defined here
       70 | struct sockaddr {
          |        ^~~~~~~~
    In file included from /usr/include/sys/socket.h:13,
                     from /usr/include/cygwin/in.h:21,
                     from /usr/include/netinet/in.h:12,
                     from sim/up_wpcap.c:57:
    /usr/include/cygwin/socket.h:39:8: error: redefinition of 'struct sockaddr_storage'
       39 | struct sockaddr_storage {
          |        ^~~~~~~~~~~~~~~~
    In file included from sim/up_wpcap.c:48:
    /usr/include/w32api/winsock2.h:269:10: note: originally defined here
      269 |   struct sockaddr_storage {
          |          ^~~~~~~~~~~~~

The compilation was broken by a couple of recent blind, unverified changes to up_wpcap.c.  Most were introduced with commit: 8ce0ff5ce4 with this change:

    diff --git a/arch/sim/src/sim/up_wpcap.c b/arch/sim/src/sim/up_wpcap.c
    index ef7b4b3a0c..a15421e80c 100644
    --- a/arch/sim/src/sim/up_wpcap.c
    +++ b/arch/sim/src/sim/up_wpcap.c
    @@ -55,6 +55,8 @@

     #include <netinet/in.h>

    +#include "up_internal.h"
    +
     /****************************************************************************
      * Pre-processor Definitions
      ****************************************************************************/

up_internal.h includes:

     47 #  include <sys/types.h>
     48 #  include <stdbool.h>
     49 #  include <netinet/in.h>

And netinet/in.h includes:

     46 #include <sys/types.h>
     47 #include <sys/socket.h>
     48 #include <stdint.h>

Which is where the collision error is introduced since up_wpcap.c includes winsock2.h already.  There were additional problems introduced to the file by other changes:

- A malformed syslog() call was added
- Some issues with netdriver_setmacaddr()
2020-09-27 18:22:02 -07:00