Commit Graph

15738 Commits

Author SHA1 Message Date
YAMAMOTO Takashi
4062727333 negotiate() function extracted from vpnkit
From:
    https://github.com/moby/vpnkit
    commit 2ffc1dd8a84ea7359dd09b1f4b51bb728d4f46a0
    c/vpnkit-tap-vsockd/tap-vsockd.c

With minimum changes to make it build.
2020-03-19 09:13:32 -05:00
YAMAMOTO Takashi
b748fcde0a vpnkit/protocol.c: make this compile 2020-03-19 09:13:32 -05:00
YAMAMOTO Takashi
261249cc99 vpnkit: Add a few files from vpnkit
From:
    https://github.com/moby/vpnkit
    commit 2ffc1dd8a84ea7359dd09b1f4b51bb728d4f46a0
    c/vpnkit-tap-vsockd/protocol.h
    c/vpnkit-tap-vsockd/protocol.c
2020-03-19 09:13:32 -05:00
Andrey Zabolotnyi
73b655f3b2
stm32h7_qspi: support for custom clock (not just HCLK) and support for DUAL/QUAD commands (#582)
* stm32h7_qspi: Board.h now may define the BOARD_QSPI_CLK macro to select one of
RCC_D1CCIPR_QSPISEL_{HCLK,PLL1,PLL2,PER} clocks to use with QUADSPI peripherial.
Defaults to HCLK for backward compatibility.
New macros in qspi.h: QSPICMD_IDUAL and QSPICMD_IQUAD for selecting the bit
width for instruction code (1,2 or 4 bits) of a qspi_cmdinfo_s, and
QSPIMEM_IDUAL and QSPIMEM_IQUAD for selecting the bit width of a qspi_meminfo_s.

* NX style fixes
2020-03-19 05:59:18 -07:00
David Sidrane
4e475cb630 stm32f7:spi nxstyle 2020-03-17 07:42:28 -06:00
David Sidrane
da854ccb99 stm32:spi nxstyle 2020-03-17 07:42:28 -06:00
Daniel Agar
6189b2c8bd stm32:spi Add buffers for DMA 2020-03-17 07:42:28 -06:00
David Sidrane
6f32a6ad8f stm32f7:spi Add buffers for DMA 2020-03-17 07:42:28 -06:00
Nathan Hartman
a5e643b0cd Fix typos in comments and documentation. 2020-03-16 20:01:11 -06:00
YAMAMOTO Takashi
f4e7845b85 esp32: emulate byte access for module text
Tested on ESP-EYE.
2020-03-16 07:54:49 -06:00
YAMAMOTO Takashi
855751b534 Introduce instruction memory allocator
Necessary for dlfcn etc on ESP32, which has separate memory regions
for instruction and data.

known issues/todo
 * consider something similar to dual heaps for PROTOECTED
 * consider to adapt binfmt as well
2020-03-16 07:54:49 -06:00
YAMAMOTO Takashi
03a916acb8 Kconfig: Add kconfig options for module text allocator
Enable it for ESP32.
2020-03-16 07:54:49 -06:00
YAMAMOTO Takashi
e135c938d2 xtensa: Implement a few relocations 2020-03-16 07:54:49 -06:00
YAMAMOTO Takashi
8657305883 arch/xtensa/include/elf.h: Initial version 2020-03-16 07:54:49 -06:00
YAMAMOTO Takashi
5a716b799b xtensa_user_handler: rsync after wsr.ps 2020-03-16 07:31:46 -05:00
YAMAMOTO Takashi
3b528c6010 xtensa_user_handler: Save PS correctly
"EPS" is not a real register. It's just a base value of EPS_{2..7}.
2020-03-16 19:13:33 +09:00
YAMAMOTO Takashi
951cfbd1d5 xtensa_user_handler: Fix registers in comments 2020-03-16 05:08:43 -05:00
YAMAMOTO Takashi
7aebcc4bf6 xtensa_user_handler: Fix registers in comments 2020-03-16 02:24:16 -05:00
YAMAMOTO Takashi
23db3b2a48 ESP32: Use __asm__ __volatile__ for inline assembly 2020-03-13 19:06:15 -06:00
YAMAMOTO Takashi
3a03a307b9 arch/xtensa/src/common/xtensa_abi.h: nxstyle fixes
The remaining errors:

    Operator/assignment must be preceded with whitespace

I didn't fix them because they are in assembly code, which
nxstyle doesn't understand.
2020-03-13 18:58:04 -06:00
YAMAMOTO Takashi
086e8ffb12 arch/xtensa/src/esp32/esp32_cpustart.c: nxstyle fixes
The remaining errors:

    Mixed case identifier found

I didn't fix them because they were on ROM symbols,
which are not supposed to obey NuttX's coding style.
2020-03-13 18:51:26 -06:00
YAMAMOTO Takashi
da57a7d6aa Fix a few nxstyle complaints in arm hostfs
Unfortunately nxstyle is still not happy because it doesn't
like the following construct.  I'm not sure what to do here.

      struct
      {
        const char *pathname;
        long mode;
        size_t len;
      } open =
      {
        .pathname = pathname,
        .mode = host_flags_to_mode(flags),
        .len = strlen(pathname),
      };
2020-03-13 11:28:30 -06:00
David Sidrane
ea81924fce Revert "arch/arm/src/stm32f7/stm32_flash.c: Add flash block mapping support for progmem."
This reverts commit 29164c5706.
2020-03-13 09:31:46 -06:00
anjana-tel
737dcdbe93 Update up_usestack.c 2020-03-13 02:42:34 -05:00
Jari van Ewijk
0a2d005d8a
NXP S32K1XX peripheral clock fixes (#555)
* S32K1XX peripheral clock config. Only apply divider when it is set. + Style fixes

* S32K1XX clock names change mixed case identifiers + style fixes

* S32K1XX - Style fix 1
2020-03-12 10:18:09 -07:00
AlexanderVasiljev
265a54365b
Stm32F7: add external ram config (#529)
* Stm32F7: add external ram config
2020-03-12 08:40:01 -06:00
YAMAMOTO Takashi
9aec40744c xtensa_hostfs.c: Change the license to Apache 2.0
This file is based on arch/arm/src/common/up_hostfs.c.
The license change was ok'ed by the author. (@xiaoxiang781216)
2020-03-12 09:03:31 -05:00
YAMAMOTO Takashi
7a06ff0392 xtensa: hostfs using simcall
Tested on qemu -semihosting
2020-03-12 09:03:31 -05:00
YAMAMOTO Takashi
c18d7dc434 xtensa: Implement simcall 2020-03-12 09:03:31 -05:00
YAMAMOTO Takashi
7774cdd7aa Appease many of nxstyle errors for esp32 related files
I skipped the following files because they were not simple.
I'll create separate PRs.

    arch/xtensa/src/esp32/esp32_cpustart.c
    arch/xtensa/src/common/xtensa_abi.h
    boards/xtensa/esp32/esp32-core/include/board.h

Also, I skipped the following files and directories because
they looked too huge and/or foreign.

    arch/xtensa/include/esp32/tie.h
    arch/xtensa/include/xtensa/xtensa_corebits.h
    arch/xtensa/src/esp32/hardware/
    arch/xtensa/include/esp32/tie-asm.h
    arch/xtensa/include/esp32/core-isa.h
    arch/xtensa/include/xtensa/core.h

I also fixed a few "is is" style typos when unwrapping long lines.
2020-03-12 07:45:44 -06:00
Gregory Nutt
bfc15a6295 z20x: Fixes related to W25 boot configurations.
arch/z80/src/ez80/ez80_timerisr.c:  Correct a mismatch between the programmed reload value and the timer input clock frequency.

arch/z80/src/ez80/ez80f92.h:  Correct error in timer input clock divider:  Bits 2-3, not bits 3-4.

boards/z80/ez80/z20x/src/w25_main.c:  Correct an uninitialized return value; private function was not declard static.
2020-03-11 18:24:43 -03:00
Andrey Zabolotnyi
4e65d543d8
Add OUTTOGGLE mode to STM32H7 timer driver (#541)
* stm32h7: New timer output mode STM32_TIM_CH_OUTTOGGLE.
In this mode timer generates a square waveform on given timer channel.
The maximal waveform freq is timer clock divided by 4 (prescaler 1, period 1 results in 2 clocks '0' and 2 clocks '1').

* stm32_tim.h styling fixes.
2020-03-11 05:18:43 -07:00
Gregory Nutt
2c8d876ab8 eZ80F92: Eliminate Spurious Interrupts
arch/z80/src/ez80/ez80f92_init.asm:  Timer control register was not being cleared and, as a result, timer interrupts may have been already enabled when the CPU was started by the debugger.  This would result in spurious interrupts and Unexpected Interrupt crashes.

arch/z80/src/comming/up_initialize.c:  Fix a trivial typo.

While we are at it, change the license headers in all relevant files in the affected directories to the Apache 2.0 license.  Run all affected files through nxstyle.
2020-03-10 23:44:23 +01:00
Andrey Zabolotnyi
e5f5509054
stm32h7: Added basic support for STM32H753II. (#527)
Co-authored-by: Андрей Заболотный <zapparello@ya.ru>
2020-03-10 07:55:18 -07:00
Ouss4
a506012074 arch/arm/src/stm32/stm32_uart.h: Fix nxstyle complaints. 2020-03-10 06:53:00 -05:00
Markus Bernet
b50aa49953 stm32/stm32f7/stm32h7: Fix bugs in SERIAL_CONSOLE definition 2020-03-10 08:08:20 -03:00
YAMAMOTO Takashi
d4b0590abb Fix some nxstyle complaints in arm addrenv 2020-03-10 03:55:25 -05:00
Gregory Nutt
199b4d6852 z20x: Changes to reduce serial Rx data overrun
boards/z80/ez80/z20x:  Increase RX buffer size to 4Kb, reduce BAUD to 2400 in w25boot configuration
arch/z80/src/ez80/ez80_serial.c:  Reduce Rx FIFO trigger level for eZ80F92 to 1 so that will respond more quickly to incoming data.
2020-03-09 22:51:54 +01:00
Petro Karashchenko
3fa6baec98 spi: change spi_send() interface to support of 32-bit word transfer
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2020-03-09 08:03:35 -06:00
liuhaitao
29be471f58 sama5/serial: correct usage of USE_SERIALDRIVER and USE_EARLYSERIALINIT
Also fix the following build warning:
chip/sam_serialinit.c: In function 'sam_earlyserialinit':
chip/sam_serialinit.c:71:4: warning: implicit declaration of function 'uart_earlyserialinit'; did you mean 'sam_earlyserialinit'? [-Wimplicit-function-declaration]
   71 |    uart_earlyserialinit();
      |    ^~~~~~~~~~~~~~~~~~~~
      |    sam_earlyserialinit

Change-Id: I93adc5be739c222482b552b6e143e44c8c047794
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-03-09 08:00:56 -06:00
Gregory Nutt
4ae9ae9693 z80x: W25 Bootloader Improvements
boards/z80/ez80/z20x/src/w25_main.c:  Improve user interface.

There is still an error occurring while downloading Intex HEX files to FLASH.  That is unrelated to this and appears to be a problem libs/libc/hex2gbin/lib_hex2bin.c
2020-03-08 23:33:04 +01:00
Johanne Schock
757c37fbc9 fixed long line warnings from nxstyle 2020-03-08 08:52:46 -06:00
Johanne Schock
ac1f5d673a Fixed formatting and comments in board.h and kinetis_k28memorymap.h
Fixed clock calculation in board.h
2020-03-08 08:52:46 -06:00
Johanne Schock
050e45bfe7 Changes for Freedom K28 USB device support 2020-03-07 13:07:37 -06:00
Gregory Nutt
faca2f220e z20x: Timer/Spi Fixes
arch/z80/src/ez80/ez80_timerisr.c:  Fix an error that looks the file got damaged by a bad keystroke in the editor while a string was highlighted.
boards/z80/ez80/z20x/src/ez80_spi.c:  Fix some bad conditional compilationi. Prevented W25 chip select from being initialized.
2020-03-07 17:30:02 +01:00
Gregory Nutt
493b8de938 Revert "Change SAMA5 files to have apache license headers:"
This reverts commit f735584514.

These header changes introduce unacceptable errors:

1. The changes alter the width of the initial block comment.  That will cause nxstyle failures on most of the files.

2. The third line of the header is an (optional) short description of content of the the file.  This change erroneously removes that line.

Automated header file changes can screw up a lot of files, very quickly.
2020-03-07 08:47:48 -03:00
Gregory Nutt
78563d555a arch/z80/src/ez80/ez80_spi.c: Correct oversight in previous commit
Commit 797e45d6bf attempted to reduce the frequency of SPI reconfiguration by keeping track of the current frequency and mode settings and changing these settings only when the new settings differ from the old settings.

However, the original commit neglected to save the new frequency setting and, hence, was not effective in what it was trying to do:  Every time the SPI setfrequency() method was called, it still looked like a new frequency and the frequency was still reconfigured, even though it hadn't really changed.
2020-03-07 09:59:23 +01:00
Adam Feuer
2478d12a0a arch/arm/src/sama5/hardware/_sama5d3x_memorymap.h: Restore lines (#464)
Restore lines from bad nxstyle fixes; restore file to previous state
2020-03-06 16:51:15 -06:00
Gregory Nutt
797e45d6bf z20x: SPI and timer fixes
arch/z80/src/ez80/ez80_spi.c:  Add logic checks to eliminate unnecessary SPI reconfiguration.
arch/z80/src/ez80/ez80_timerisr.c and arch/z80/src/ez80/ez80f92.h:  Fix numerous places where configurations began with CONFIGS_ instead of CONFIG_
2020-03-06 23:28:35 +01:00
Gregory Nutt
ee9949a724 z20x: Fix some SPI/W25/Timer issues.
arch/z80/src/ez80/ez80_spi.c:  Do not configure SPI chip select pin.  It is not used by the driver and configuring it just clobbers other usage of that pin.  Add some additional debug outputs; correct some exiting debug outputs.

drivers/mtd/w25.c:  Add some debug output.

boards/z80/ez80/z20x/src/ez80_w25.c:  Correct SPI bus number used in initialization.  Only SPI1 is supported.

arch/z80/src/ez80/ez80_timerisr.c:  Some initial timer configuration fixes.
2020-03-06 21:09:14 +01:00
Juha Niskanen
9f6df9ce62 arch/arm/src/stm32l4/stm32l4_iwdg.c: Do not unconditionally enable debug
The DBGMCU_APB1_FZ bit persists over regular software resets until next POR-reset. It can impact device power consumption and things that persist over resets are a bane for FOTA updates so make it disabled by default.

OpenOCD sets this via DAP when connecting to target so enabling this from Kconfig is only useful for users of some other debug tooling.
2020-03-06 07:09:35 -06:00
Adam Feuer
f735584514 Change SAMA5 files to have apache license headers:
- No code changes
- All files are now utf-8 encoded
- Some non-utf-8 characters in comments were changed or removed
2020-03-06 10:33:08 +00:00
Masayuki Ishikawa
da3fb9c94f arch: xtensa: Call the waiti instruction in up_idle()
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-03-06 01:46:09 -06:00
patacongo
730133d84a SAMA5D27 peripheral support - USB Host working (#444)
* SAMA5D27 peripheral support - USB Host working

    - updated nsh defconfig with vfat for testing USB Host
    - sama5d2_xult: USB Host worked.
    - ported sam_bringup.c code from sama5d3-xplained
    - USB 2.0 HS now working
    - other perpherals may work, but haven't been tested

* update license headers to approve NuttX Apache-2.0
2020-03-05 18:24:11 -06:00
Gregory Nutt
859d694c78 z20x: Correct RAM wait states. 2020-03-05 17:49:58 -03:00
Gregory Nutt
de07abe632 ez80f92: Interrupt improvements.
arch/z80/: include/ez80/irq.h, src/ez80/ez80f92_*.asm:  Correct some comments related to vector address offsets.
boards/z80/ez80/z20x/scripts/z20x_loader.linkcmd:  Fix RAM offset in linker script
2020-03-05 18:54:24 +01:00
Masayuki Ishikawa
a5cb0b3731 arch: xtensa: Fix SMP related logic
NOTE: Applied the same logic as in other SMP architectures
2020-03-04 23:34:43 -06:00
liuhaitao
b27cbf6de1 arch/x86: correct typo error to fix x86 boards build break 2020-03-04 07:03:22 -06:00
Masayuki Ishikawa
e16c3ca25b arch: esp32: Fix compile error with xtensa-esp32-elf-gcc 8.2.0 2020-03-04 03:51:13 -06:00
liuhaitao
923c05f17f arch/x86_64: fix two typo errors to pass build
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-03-04 00:42:32 -06:00
Sonic Yang
b984752aec Flat address x86_64 port of Nuttx (#411)
* arch: x86_64: Pour-in the x86_64 code from cRTOS repository, excluding modifications of NuttX kernel, jailhouse support and linux compatibility layer

* arch: x86_64: Refactor x86_64 loading procedure for better comprehension and included support for multiboot2

* arch: x86_64: Locate the kernel at 4GB~ and modify the page table initializing procedure accordingly

* arch: x86_64: Implemented kconfig option for various x86_64 capabilities, dynamic probe and check capability on lowsetup before enabling

* arch: x86_64: inte64_check_capability: Use Marco to prettify the capability checking procedure

* arch: x86_64: intel64_timerisr.c: Refactor with new frequency calibrating method

* arch: x86_64: Fix C alias of page table and GDT/IST

* arch: x86_64: Reload GTDR with GDT in high address in up_lowsetup

* arch: x86_64: Consolidate MSR definition in arch/arch.h

* arch: x86_64: Edit the way of handling GDT/IST in C into structures

* arch: x86_64: Correct the starting point of isr/irq stack

* arch: x86_64: Update up_initialize.c with the new initializing procedure

* arch: x86_64: up_map_region now take flags instead of assuming WR/PRESENT

* arch: x86_64: Overhual of interrupt initialization procedure

* arch: x86_64: Properly configure the heap to be memory as [_ebss, end of memory]

* arch: x86_64: Try to probe the TSC frequency, fall-back to user specified frequency on failure

* arch: x86_64: Remove debug printing during restore_aux, causing infinite CTX bug

* arch: x86_64: for X86 16500 serial interrupt to work, OUT2 of MCR must be 1. Make it stuck at 1 after boot

* arch: x86_64: Correctly apply license header, comment and format code

* arch: x86_64: properly send a SIGFPE on floating point error

* arch: x86_64: Remove unused variable in up_restore_auxstate

* arch: x86_64: properly trash the processor with an infinite loop

* arch: x86_64: Fix typo in ISR handler causing ISR not handled

* arch: x86_64: Fix possibile race conditions with scheduler debug option on in signal handling path

* arch: x86_64: Fix typo in MSR_X2APIC_LVTT_TSC_DEADLINE

* arch: x86_64: Migrate tickless implementation to the new MSR naming and frequency calibration method

* board: x86_64: qemu: Add guard to exclude up_netinitialize when compiling without net support

* arch: x86_64: update defconfigs

* arch: x86_64: rename qemu as qemu-intel64

* arch: x86_64: update Board readme
2020-03-03 19:02:59 -06:00
GOERLITZ Otmar
9623ffaf6d arch/arm/src/stm32/hardware/stm32f30xxx_rcc.h: Correction to RCC_CFGR3 definitions 2020-03-03 17:23:50 -06:00
Gregory Nutt
2eff5a6c63 z20X: Continued development of the W25 Bootloader.
Kconfig files.  Repartition some functionality.  Bootloader support will need to be provided in logic under arch/z80/src/ez80 so the critical configuration selections were moved the Kconfig file there.

arch/z80/src/ez80/ez80_i2c.h:  Rename arch/z80/src/ez80/ez80f91_i2c.h.  It is sharable by both ez80f91 and ez80f92.

arch/z80/src/ez80/:  Add logic to perform an additional level of interrupt redirection.  This is necessary because the the interrupt handling is part of the loader FLASH-based logic.  In order to share interrupts with the program loaded into RAM by the loader, another layer or redirection is required to get control to the interrupt handlers in the loaded program.  See ez809f2_loader.asm and ez80f92_program.asm

boards/z80/ez80/z20x/scripts:  Reduce size of the interrupt re-direction buffer from 1Kb to 512b.
2020-03-03 19:39:57 -03:00
Gregory Nutt
a21120e3b6 Correct PR424 to coding standard
Run all .c files modified by PR424 through nxstyle and correct most of the complaints (many long line complaints ignored for now).  Update file headers to use Apache 2.0 license.
2020-03-03 13:59:54 -06:00
Daniel Agar
415fc17e98 stm32h7: spi_exchange (no dma) available with CONFIG_STM32H7_SPI_DMATHRESHOLD 2020-03-03 13:30:52 -06:00
Daniel Agar
a0169e4c37 stm32f7: spi_exchange (no dma) available with CONFIG_STM32F7_SPI_DMATHRESHOLD 2020-03-03 13:30:52 -06:00
Daniel Agar
0600d08d1a stm32: spi_exchange (no dma) available with CONFIG_STM32_SPI_DMATHRESHOLD 2020-03-03 13:30:52 -06:00
GAEHWILER Reto
e31f0f37f1 arch/arm/src/stm32h7/stm32_ethernet.c: Fix for network lock downs
Fix for network lock downs due to not freed buffers
2020-03-03 09:33:18 -06:00
GAEHWILER Reto
85e461c59c STM32H7/STM32F30: Typos, register correction and extension
* Correction in stm32h7x3xx_rcc
* Adding GPIO_TIM2_CH1OUT_1 to stm32f30xxx_pinmap
* Comment typo fix in drivers/mmcsd/mmcsd_spi.c
2020-03-03 09:20:58 -06:00
GAEHWILER Reto
7ffb5c11a0 arch/arm/src/stm32h7/stm32_ethernet.c: Re-organization of stm32_phy_boardinitialize
PHY has to be up and running before ethreset call
2020-03-03 09:18:02 -06:00
Juha Niskanen
f3490e42c3 Fix typos in comments 2020-03-03 09:11:57 -06:00
johannes-nivus
a7d783d463 NXP Freedom K28F Board SD-Card support (#423)
* Adds SDHC support for NXP Freedom-K28F
2020-03-03 09:06:17 -06:00
rajeshwaribhat
e671a10b2a RX65N RTC Driver added 2020-03-03 08:30:49 -06:00
Daniel Agar
30a48e4217 arm/stm32h7 add STM32H7_SPI_DMATHRESHOLD 2020-03-02 23:08:12 +01:00
Daniel Agar
c10fbbbb5f stm32f76xx77xx_dma.h fix DMAMAP_SPI2_RX_2/DMAMAP_SPI2_TX_2 2020-03-02 23:08:12 +01:00
Daniel Agar
608b59792e arm/stm32f7 add STM32F7_SPI_DMATHRESHOLD 2020-03-02 23:08:12 +01:00
Daniel Agar
afb2248b7a arm/stm32 add STM32_SPI_DMATHRESHOLD 2020-03-02 23:08:12 +01:00
Augusto Fraga Giachero
0be87af99d arch/arm/src/lpc17xx_40xx/lpc17_40_i2c.c: Cancel timeout on i2c stop
Not canceling the I2C timeout watch dog immediately after finishing
all I2C transactions in interrupt context can lead to a race condition
due to nxsem_wait(&priv->wait) in lpc17_40_i2c_start() not resuming
execution fast enough (this can be easily triggered if another task /
thread is using a lot of cpu time).

Falling to cancel the watchdog up to time will cause the priv->wait
semaphore to be incremented twice (first by lpc17_40_i2c_stop() then
by lpc17_40_i2c_timeout()), so all I2C transactions after that will
return immediately and priv->msgs will hold pointers to memory it
doesn't own anymore.

Canceling the priv->timeout watch dog in lpc17_40_i2c_stop() prevents
this as it is executed from the I2C interrupt handler.

arch/arm/src/lpc17xx_40xx/lpc17_40_i2c.c: Fix timeout calculation

For each byte received / transmitted, an acknowledge bit is also
transmitted / received, requiring effectively 9 bits for each byte.
2020-03-02 22:14:05 +01:00
Gregory Nutt
e814977c0f boards/z80/ez80/z20x/: Add W25 bootloader
The SD boot loader was not satisfactory because 1) the SD slot is on an optional board and, hence, cannot be part of a fundamental solution.  And 2) it is too big.

The only storage on borard is the Winbond W25 SPI-bsed FLASH.  This commit adds support for a bootload to 1) read code in HEX format from a serial port and write it to the W25 FLASH, or 2) read code in binary form from the W25 FLASH into SRAM and execute the loaded program.

boards/z80/ez80/z20x/configs:  Added w25boot configuration
boards/z80/ez80/z20x/src:  Add bootloader logic, w25_main.c.  Add logic to manage shared SRAM memory map so that the loaded program does not clobber the bootloader memory.  Add logic to recover the bootloader memory into the heap after the loaded program as started.
boards/z80/ez80/z20x/scripts:  Rework scripts and configuration to support a bootloader and program build.  The boolloader cannot use all of SRAM; the program must not clobber the SRAM region used by the bootloader.
2020-03-02 14:05:09 -03:00
David Sidrane
fd3148dba6
imxrt: Adds the ability to run from OCRAM (#407)
* imxrt: GPIO make tables const
* imxrt: Call out to board to set up FlexRAM
* imxrt: Add Knob for adding the ROM bootloaders 40Kib of RAM to heap
* imxrt: imxrt1060-evk:Add the ability to run from OCRAM
2020-03-01 06:05:42 -06:00
David Sidrane
4a4b2853c2
Add USB Device support for i.MX RT (#408)
* arch/arm/src/imxrt/imxrt_usbdev.c: Add USB Device support for i.MX RT (USB OTG1)

Based on the LPC43xx USB Device driver.

* imxrt:usbotg Nxstyle fixes

Co-authored-by: thomasactia <61285689+thomasactia@users.noreply.github.com>
2020-02-29 14:03:52 -08:00
Gregory Nutt
41ef33bded eZ80: Fix optimization issues
board/z80/ez80/*/scripts/Make.defs:  Fix optimization definition use in assembly flags.  It was using the compiler optimization settings instead of the assembler optimization settings.  Hence, enabling optimization would could cause assembler command line errors.

arch/z80/src/ez80/Toolchain.defs:  Back out some work arounds.  Now compiler optimization flags can again set set without assembler command line errors.

boards/z80/ez80/z20x/README.txt:  Trivial update to size/optimization discussion.
2020-02-29 12:43:28 -03:00
Joshua Lange
0ce4e15363 Improvements to STM32H7: (i,w)WDG Flash, Ethernet, ADC, etc 2020-02-29 12:33:25 -03:00
Adam Feuer
cbd3e704dc formatting comments 2020-02-28 13:39:36 -06:00
Adam Feuer
6b4f9038d4 fix for SAMA5D2 serial console
authored by Takeyoshi Kikuchi <kikuchi@centurysys.co.jp>
2020-02-28 13:39:36 -06:00
Gregory Nutt
8c00e43c1a arch/z80/src/ez80: Fix eZ80F92 Interrupt Controller
The eZ80F92 interrupt controller is very different from the eZ80F91.  The eZ80F91 has:

1. Four byte interrupt vectors
2. The vector base address register is 16-bit so the vector table can lie in RAM

Whereas the eZ80F92 has:

1. Two byte interrupt vectors
2. An 8-bit vector base address

This means that the vectors must lie in the first 16-bits of FLASH and there must be a "trampoline" to get to interrupt handlers outside of the first 64-Kb of FLASH.
2020-02-28 19:45:28 +00:00
YAMAMOTO Takashi
34b17ec5cb xtensa: Fix up_schedule_sigaction
This fixes various crashes in ostest.
2020-02-28 07:48:16 -06:00
YAMAMOTO Takashi
119a38ce10 xtensa: Fix typos and comments 2020-02-28 11:33:29 +01:00
Gregory Nutt
161104c76a eZ80/z20x: Correct uninitialized stack memory
arch/z80/src/ez80/Toolchain.defs:  Correct some CFLAGS when optimization suppressed.

arch/z80/src/ez80/Kconfig arch/z80/src/ez80/ez80_emac.c:  Remove configuration option for selecting EMAC RAM address.  This is duplicated and possibly conflicting.  The correct address for the RAM is provided in the linker command file.  The RAM should be configured once and using this single definitions.

arch/z80/src/ez80/ez80_startup.asm and arch/z80/src/ez80/ez80f9*_init.asm.  Move RAM and FLAH intialization out of MCU-specific logic to common start-up logic.  We cannot call any functions until SRAM is initialized and the stack is properly initialized because the return address is stored on the stack.  Use internal SRAM for the IDLE stack to avoid the chicken'n'egg problem.

boards/z80/ez80/z20x/configs/sdboot/sdboot.zdsproj:  Discuss build environments.
2020-02-27 22:53:27 +01:00
Masayuki Ishikawa
0cb7dfde79 arch: risc-v: Fix a warning in common/up_exit.c
common/up_exit.c:198:1: warning: 'noreturn' function does return
2020-02-27 08:55:55 +01:00
Masayuki Ishikawa
f6b3e79d61 arch: lc823450: Remove unused variable in lc823450_cpustart.c
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-02-27 08:55:25 +01:00
Gregory Nutt
1521037083 arch/z80/src/Makefile.zdsii*: Correct libraries for eZ80F92
These makefiles set the the ZiLOG runtime libraries for the eZ80 parts.  The setup was, however, conditioned on CONFIG_ARCH_EZ80_EZ80F91 and, so, was not working for the eZ80F92 part (CONFIG_ARCH_EZ80_EZ80F92).

With this change, the z20x board FINALLY builds and links correctly with no errors.
2020-02-26 21:08:20 +00:00
Gregory Nutt
fa5179a51a arch/z80/src/ez80/ez80f92_handlers.asm: Trivial typo fix. 2020-02-26 21:08:20 +00:00
Gregory Nutt
fcee2f5a53 arch/z80/src/ez80/ez80_timerisr.c: Use Kconfig MCU configurations.
Don't use MCU selection from compiler.  It appears that we must compile ez80f92 code as ez80f91 so the comiler MCU selection is incorrect.  Instead, use the selected CPU part from the configuration.
2020-02-26 21:08:20 +00:00
Gregory Nutt
b63024dc7b arch/z80: Make MCU selection menus more like other archs 2020-02-26 21:08:15 +00:00
Gregory Nutt
a9610e16bd boards/z80/ez80/z20x: Update CFLAGS and linker scripts.
arch/z80/src/ez80/Toolchain.defs:  Update some CFLAGS to match CFLAGS from ZDS-II IDE.  Apparently, we must say that the CPU is an eZ80F91 event when compiler for eZ80F92.
boards/z80/ez80/z20x:  Update linker scripts.
2020-02-26 21:12:01 +01:00
YAMAMOTO Takashi
930e2788cc xtensa: Use ar and nm from the toolchain
This fixes build on macOS, where native ar is incompatible.
2020-02-26 10:47:26 -06:00
Adam Feuer
cdc61a08e0
arch/arm/src/sama5/sam_gmac: Prevent txtimeout from always firing and fix txbuffer leak during high-volume sends 2020-02-25 23:10:04 +01:00
YAMAMOTO Takashi
9a8169acdf armv7-m: Fix syscall stack alignment
This fixes "df -h" with PROTECTED build.  Tested on qemu.

Reference:
	aapcs32 "6.2.1 The Stack/Stack constraints at a public interface"
2020-02-25 12:05:53 -06:00
YAMAMOTO Takashi
d52628979a Suppress "'noreturn' function does return" warnings
up_pthread_start and up_task_start.
2020-02-25 04:07:02 -06:00
Gregory Nutt
e6f545beab Extend revised ZDS-II support to z8 and z16f
* tools/zds/zds_Config.mk: Move  boards/z80/ez80/scripts/eZ80_Config.mk to tools/zds/zds_Config.mk where it can be shared by other ZDS-II platforms.
* boards/z16/z16f:  Duplicate changes for new ZDS-II support from ez80
* boards/z80/z8:  Duplicate changes for new ZDS-II support from ez80
* arch/z16/src/z16f/Toolchain.defs:  Create required Toolchain.defs file for Z16f
2020-02-24 22:37:28 +01:00
Xiang Xiao
b9b86fcc63 arch/sim: Handle tap device initializition failure gracefully 2020-02-24 08:42:03 -06:00
Xiang Xiao
96adb827a3 arch/sim: Ensure all host printf end with \r\n
Since simulator switch console to raw mode, we have to add \r manually
2020-02-24 08:41:45 -06:00
Xiang Xiao
cde88cabcc Run codespell -w with the latest dictonary again
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-02-23 22:27:46 +01:00
liuhaitao
b4cf5f5dab arch: refine up_serialinit/up_earlyserialinit/rpmsg_serialinit 2020-02-23 09:11:57 -06:00
liuhaitao
c5eab0dc8f arch: use ifdef USE_EARLYSERIALINIT to include up_earlyserialinit
There are cases that USE_SERIALDRIVER is defined but USE_EARLYSERIALINIT not defined in some configs. So use ifdef USE_EARLYSERIALINIT to include up_earlyserialinit anyway.
2020-02-23 09:11:43 -06:00
liuhaitao
8ca4ca5ae8 arch: undef USE_SERIALDRIVER if CONFIG_CONSOLE_SYSLOG
An error was introduced from:

  commit f982ee43db
  Author: Xiang Xiao <xiaoxiang@xiaomi.com>
  Date:   Tue Feb 18 09:55:04 2020 +0800

    drivers/serial: Remove the lowconsole driver

    Replace with the syslog console driver which has more capability than lowconsole
2020-02-23 09:10:06 -06:00
Xiang Xiao
bd4e8e19d3 Run codespell -w against all files
and fix the wrong correction
2020-02-22 14:45:07 -06:00
Ouss4
ac4049682f arch/mips: Fix the SW0 priority set by commit eb1adca
It must be strictly greater than IPL to get serviced.
2020-02-21 17:00:04 -06:00
Gregory Nutt
7516f76422 boards/z80/ez80: More consolidation of build files.
arch/z80/arc/ez80/Toolchain.sh:  Move more common toolchain definitions from Make.defs.
boards/z80/ez80/scripts/eZ80_Config.mk:  Move common defines that override tools/Config.mk to this new file.

This does not solve the ez80 build problem yet but does assure that when the solution is in place, it will automatically apply to all present and future ez80 configurations.
2020-02-21 16:45:13 +01:00
Ouss4
eb1adcafe3 arch/mips/src/pic32mX/pic32mX-irq.c: Use the defined CS0 irq number. 2020-02-20 19:30:48 -06:00
Gregory Nutt
231720d330 boards/z80/ez80: Consolidate toolchain path definitions 2020-02-21 02:17:35 +00:00
Gregory Nutt
ac8e9ded59 Fix coding standard issues in PR328
Run all .c and .h files modified by PR328 through tools/nxstyle and correct all of the complaints from that tool.
2020-02-20 08:40:17 -06:00
klmchp
ce43f21b33 remove unnecessary irq operation 2020-02-20 08:34:33 -06:00
klmchp
286d8875d5 add eefc driver and read uid 2020-02-20 08:34:33 -06:00
Gregory Nutt
c015e42602 boards/z80/ez80: Update compiler support
boards/z80/ez80:  Update to latest ZDS-II verstion 5.3.3 compiler
arch/z80/src/ez80:  Fix some regressions on ez80f91 build due to ez80f92
changes.
2020-02-20 08:18:39 -06:00
YAMAMOTO Takashi
b363bd0841 Update the comments (the location of trampoline code)
Also, fix typos and copy-and-paste errors.
2020-02-20 14:21:16 +08:00
Masayuki Ishikawa
6ccf08a778 arch: imx6: Add imx_idle.c
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-02-19 20:04:58 -06:00
Masayuki Ishikawa
f38f39d410 arch: arm: Select ARCH_GLOBAL_IRQDISABLE for iMX6
NOTE: SMP related behaviour will be same as armv7-m SMP

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-02-19 20:04:58 -06:00
Masayuki Ishikawa
bbefad449c arch: armv7-a: Apply armv7-m SMP related logic to armv7-a
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-02-19 20:04:58 -06:00
Gregory Nutt
90839b41f9 Revert some changes from a previous PR
I was over-zealous in arch/z80/src/ez80/ez80f91_handlers.asm.  I added space separatros around the '+' operators.  Turns out that the ZDS-II assembler can't handle the spaces in that context.
2020-02-20 01:05:28 +01:00
Gregory Nutt
b403bfecd5 arch/z80/src/ez80/ez80f92.h: Fix some bad copy-paste. 2020-02-20 00:25:19 +01:00
Gregory Nutt
647f2f44df Run arch files through nxstyle. 2020-02-20 00:03:48 +01:00
Gregory Nutt
77b4fa936b New files need Apache 2.0 license. 2020-02-20 00:03:48 +01:00
Gregory Nutt
2fca67c421 arch/z80/src/ez80 and include/ez80: Add ez80f92 support
The ez80f92 is similar to the currently supported ez80f91 except that is:

1. Has no PLL and has a maximum CPU frequency of only 20MHz
2. Has no Ethernet controller
3. Timers are different
4. Has no GPIO Port A
5. Timers are different
6. It comes in a smaller package

and other small differences.

This provided the architecture (only) support for the forthcoming z20x port.
2020-02-20 00:03:48 +01:00
YAMAMOTO Takashi
2cd2a0af5a
arm hostfs: Compile only when enabled by config (#307)
* arch/arm/src/tiva/Make.defs: Compile only when enabled by configuration CONFIG_ARM_SEMIHOSTING_HOSTFS
*  arch/arm/src/common/up_hostfs.c:  Remove the ifdef conditional because it's redundant with the make logic.
2020-02-19 08:13:12 -06:00
YAMAMOTO Takashi
d5fc2458ba boards/arm/tiva/lm3s6965-ek: Add PROTECTED support
Largely copy-and-paste from stm32f4discovery.

Also arch/arm/src/armv7-m/mpu.h: Ensure RBAR alignment

  Fix crashes on init task startup I observed on qemu-system-arm -M lm3s6965evb.
2020-02-19 07:42:14 -06:00
Masayuki Ishikawa
b9682171f4 arch: armv7-a: Fix stack pointer alignment at startup
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-02-19 07:25:31 -06:00
Gregory Nutt
d06d8fbca2 Run all .c and .h files modified by PR301 through nxstyle. 2020-02-19 07:23:41 -06:00
Xiang Xiao
892290f76b syslog: Call syslog_rpmsg_init inside syslog_initialize like other syslog driver 2020-02-19 07:19:34 -06:00
Gregory Nutt
fdf673c5c7 arch/arm/src/kinetis/kinetis_serial.c: Correct build test failure.
Correct error:  'TTS0_DEV' undeclared
2020-02-19 10:31:04 +01:00
Xiang Xiao
bff26dbe3a arch: Cleanup syslog_console_init usage
1. Remove the private declaration
2. Ensure nuttx/syslog/syslog_console.h gets included
3. Remove syslog_console.h inclusion if not really used
2020-02-18 13:06:53 -06:00
Xiang Xiao
51a2171c71 ramlog: Remove g_ramlog_syslog_channel since it's same as g_default_channel
And remove syslog_init_e because all initialization is later now and we don't
distinguish the initialition phase anymore after ramlog don't need special
initialize.
2020-02-18 13:04:45 -06:00
Xiang Xiao
dcaaf2d912 ramlog: Remove all ramlog_consoleinit related code
Because we can get the same function by CONSOLE_SYSLOG/syslog_console_init.
BTW, it isn't a good choice to use g_ramlogfops as /dev/console since nsh
will read back what it send out which will surprise most people.
2020-02-18 12:57:43 -06:00
Xiang Xiao
f982ee43db drivers/serial: Remove the lowconsole driver
Replace with the syslog console driver which has more capability than lowconsole
2020-02-18 12:51:09 -06:00
Xiang Xiao
ad97c044a7 arch/z80: Remove z80_lowserial_initialize()
Since nothings calls the function z80_lowerserial_initialize() at all
2020-02-18 12:45:57 -06:00
Xiang Xiao
6b77f73583 arch: Move iob_initialize into nx_start just after heap initialization
it doesn't make sense that iob initialization is in up_initialize
but other memory components initialization is called in nx_start

Change-Id: Id43aeaa995f340c5943f59a0067a483ff3ac34a2
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-02-18 10:26:19 -03:00
Xiang Xiao
a5c15c1098 arch/misoc: Remove unused lm32/types.h and minerva/types.h 2020-02-18 07:15:32 -06:00
Xiang Xiao
e7d9260014 arch: Customize the typedef of size_t instead of intptr_t
To ensure size_t same as toolchain definition in the first place and rename CXX_NEWLONG to ARCH_SIZET_LONG.  The change also check whether __SIZE_TYPE__ exist before CONFIG_ARCH_SIZET_LONG so our definition can align with toolchain(gcc/clang) definition automatically.
2020-02-18 07:15:19 -06:00
Masayuki Ishikawa
e7d44ee16e arch: armv7-a: Fix heap corruption in SMP mode
Currently up_allocate_heap() assumes that g_idle_topstack points
top of the heap memory. However, g_idle_topstack pointed incorrect
address in SMP mode which resulted in heap corruption. This PR
moves g_idle_topstack at the end of .noinit to avoid this issue.

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-02-18 07:06:12 -06:00
YAMAMOTO Takashi
7513cb6921 CONFIG_ARM_SEMIHOSTING_HOSTFS: mention limited support of directories 2020-02-18 17:11:59 +08:00
YAMAMOTO Takashi
9d4e9ce21e Make this build with CONFIG_ARM_SEMIHOSTING_HOSTFS=y 2020-02-18 13:46:33 +08:00
Nathan Hartman
239537fd9d arch/arm/include/tiva/chip.h: Fix typos 2020-02-17 16:50:03 -06:00
YAMAMOTO Takashi
5ebce26cc7 Fix "unused" warnings with CONFIG_TIVA_WITH_QEMU=y 2020-02-17 13:41:10 +08:00
Xiang Xiao
866a531899 sim/rtc: Don't change the host wall clock in sim_rtc_settime 2020-02-16 09:44:04 -06:00
Gregory Nutt
5d850fb197 arch/sim/src/sim/up_oneshot.c: Eliminate warning from build test. 2020-02-15 19:47:02 +01:00
Gregory Nutt
f5e0bb2d30 Run all files modified by PR274 through nxstyle. 2020-02-15 07:17:22 -06:00
Xiang Xiao
8b5658b918 arch/sim: Implement arch rtc interface on top of rtc driver 2020-02-15 07:17:19 -06:00
Xiang Xiao
d0d4b7a531 Reimplement arch alarm timer on top of oneshot driver framework
The benefit include:

1. Simplify the implementation
2. Support both tick and tickless automatically
3. No time drift in tickless mode
4. Support critmon arch API automatically
2020-02-15 07:17:16 -06:00
Gregory Nutt
10623f65b0 arch/risc-v/src/k210/up_schedulesigaction.c: Fix some long lines. 2020-02-14 09:37:24 -06:00
Masayuki Ishikawa
382cc29c72 arch: risc-v: Add support for PROTECTED build to k210 2020-02-14 09:29:51 -06:00
Masayuki Ishikawa
5fcde14cd1 arch: risc-v: Add up_pthread_start.c and up_task_start.c to common dir 2020-02-14 09:29:51 -06:00
Masayuki Ishikawa
1a4ff4c4cd arch: risc-v: Add support for PROTECTED build to rv64gc 2020-02-14 09:29:51 -06:00
Juha Niskanen
15b78abccf Fix typos in comments 2020-02-14 08:50:45 -06:00
YAMAMOTO Takashi
f79b47ad25 tiva_serial.c: Make this buildable with certain configurations 2020-02-14 15:38:24 +08:00
YAMAMOTO Takashi
1a3f59be58 sim: Make hostfs build for macOS
* Ignore O_DIRECT if the host OS doesn't provide it.
* Use statvfs instead of statfs. The former is in POSIX and
  more widely available these days.
2020-02-13 15:17:36 +08:00
YAMAMOTO Takashi
22d002762b sim: Add more names to nuttx-names.dat 2020-02-12 20:39:08 -06:00
YAMAMOTO Takashi
3d425280b6 simuart: Don't assume a specific endian 2020-02-12 20:38:25 -06:00
Nicholas Chin
e1d35096cf arch/arm/src/imxrt/Kconfig: Fixes IMXRT_HAVE_LCD to only be selected by 1052 and 1062 and misc. typos 2020-02-12 09:42:07 -08:00
Nicholas Chin
8469de724a Fixes build issues with IMXRT Qencoder 2020-02-12 09:42:07 -08:00
Gregory Nutt
cfb7561e77 arch/arm/src/armv7-a/arm_vectors.S: Fix clobbered register in SMP mode. 2020-02-12 16:49:32 +01:00
Gregory Nutt
5f306b0461 Run all .c and .h files modified by PR 249 through nxstyle. 2020-02-12 08:17:03 -06:00
Xiang Xiao
5e99e64d9f sim/net: Replace the busy polling with work
netdriver_loop should check there is data to read before queue the work
2020-02-12 08:16:43 -06:00
Xiang Xiao
5a00657ac4 arch/sim: Change CONFIG_NET_ETHERNET to CONFIG_SIM_NETDEV 2020-02-12 08:16:33 -06:00
Xiang Xiao
6b1187b402 arch/sim: Change the return type of netdriver_setmacaddr to void 2020-02-12 08:16:23 -06:00
Xiang Xiao
582b2af912 arch/sim: Change syslog to printf in up_tapdev.c
since this file is compiled with host environment, can't call NuttX's syslog
2020-02-12 08:16:08 -06:00
Ouss4
2ff43fb8a8 Run files modified by PR239 through nxstyle. 2020-02-11 21:09:12 +00:00
Xiang Xiao
e6c67bdd78 arch/sim: Drive up_x11update by work to simplify up_idle. 2020-02-11 21:07:22 +00:00
Xiang Xiao
14a82f40d2 arch/sim: Make eventloop as an internal variable to simplify up_idle. 2020-02-11 21:07:12 +00:00
Nicholas C
c4c0d05891 arch/arm/src/imxrt; Adds clock config logic and Kconfig menus for FLEXIO on IMXRT 2020-02-10 20:36:22 -06:00
Ouss4
ac4e6618bb arch/mips: Clear the software interrupt through a common function
implemented in the chip specific code.
2020-02-10 12:40:41 -06:00
Ouss4
90043390ff arch/mips/: Fix architectures' references in Kconfigs and Toolchain.defs. 2020-02-10 12:40:41 -06:00
Ouss4
0dc1dc605d arch/mips: When a CPU implements an External Interrupt Controller,
use the IPL bits to control masking interrupts.
2020-02-10 12:40:41 -06:00
Gregory Nutt
d09af3b7f3 Run .c and .h files modified by PR241 through nxstyle. 2020-02-10 08:57:20 -06:00
Xiang Xiao
f2f385902b arch/sim: Remove the unnecessary file guard
since the same protection is already done in Makefile
2020-02-10 08:57:06 -06:00
Xiang Xiao
7fd3a3bcca xarch/sim: Call pm_initialize from up_initialize directly
We don't need the additional flexibility since sim just has one chip.
2020-02-10 08:56:51 -06:00
Xiang Xiao
978575d79a arch/sim: Pass X11 related config to host environment
Remove the hard code CONFIG_SIM_X11NOSHM value from up_x11framebuffer.c
2020-02-10 08:56:37 -06:00
Xiang Xiao
856b62ca09 arch/sim: Fix X11 segmentation fault when CONFIG_SIM_X11NOSHM isn't enabled
up_x11mapsharedmem should assign the share memory to g_framebuffer
2020-02-10 08:56:22 -06:00
Xiang Xiao
406a9adfdd arch/sim: fix up_idle call the wrong pthread_yield version
The logic want the host version but link to NuttX version
2020-02-09 07:44:51 -06:00
Xiang Xiao
e06a4226ed arch/sim: Reuse the main thread as the simulated CPU0 2020-02-09 07:43:47 -06:00
Xiang Xiao
a87271617a arch/sim: Replace pthread mutex with atomic function for up_testset
up_testset may be called from signal hander but it isn't safe to call pthread API in that context
2020-02-09 07:43:10 -06:00
Xiang Xiao
7794dc8821 arch/sim: Set idle thread stack size to zero
To avoid ps generate "Segmentation fault" because do_stackcheck
check the stack color if the stack size doesn't equal zero
BTW, it is better to set idle task stack size to zero since idle
task use the host thread and the stack size from config isn't the
actual value.
2020-02-09 07:42:19 -06:00
Xiang Xiao
bfe1d471ce sim/arch: Fix up_head.c:122:11:implicit declaration of function 'up_cpu_index' 2020-02-09 07:41:42 -06:00
Xiang Xiao
04128b4570 arch/sim/src: Rename board_lcd.c to up_lcd.c like other sim code
Rename board_lcd.c to up_lcd.c like other sim code and compile up_spiflash.c and up_qspiflash.c conditionally
2020-02-08 08:52:34 -06:00
Xiang Xiao
fa3e66fe82 arch/sim/src/: Reimplement sim uart on top of serial driver framework
The benefits include:

1. Simplify the implementation
2. Support Ctrl+C automatically
3. Support poll automatically
4. Call pm_activity automatically
5. Save one polling thread
2020-02-08 07:52:26 -06:00
Xiang Xiao
6d69439f58 Call xxx_timer_initialize from clock subsystem
Call xxx_timer_initialize from clock subsystem to make timer ready for use as soon as possiblei and revert the workaround:

commit 0863e771a9
Author: Gregory Nutt <gnutt@nuttx.org>
Date:   Fri Apr 26 07:24:57 2019 -0600

    Revert "sched/clock/clock_initialize.c:  clock_inittime() needs to be done with CONFIG_SCHED_TICKLESS and clock_initialize should skip clock_inittime() for external RTC case since the RTC isn't ready yet."

    This reverts commit 2bc709d4b9.

    Commit 2bc709d4b9 was intended to handle the case where up_timer_gettime may not start from zero case.  However, this change has the side-effect of breaking every implementation of tickless mode:  After this change the tickless timer structures are used before they are initialized in clock_inittime().  Initialization happens later when up_initialize is called() when arm_timer_initialize().

    Since the tickless mode timer is very special, one solution might be to

    1. Rename xxx_timer_initialize to up_timer_initialize
    2  Move up_timer_initialize to include/nuttx/arch.h
    3.  Call it from clock subsystem instead up_initialize

    Basically, this change make timer initialization almost same as rtc initialization(up_rtc_initialize).

    For now, however, we just need to revert the change.
2020-02-08 07:40:06 -06:00
Xiang Xiao
76bbed07a4 Call up_irqinitialize from irq subsystem
Call up_irqinitialize from irq subsystem to make the irq ready for use as soon as possible
2020-02-08 07:39:22 -06:00
Xiang Xiao
a8de37fbec Ensure all source code end with one and only one newline
by this command:
git ls-files -z | while IFS= read -rd '' f; do tail -c1 < "$f" | read -r _ || echo >> "$f"; done
2020-02-08 07:25:56 -06:00
Masayuki Ishikawa
81f1133174 ELF64 support (#220)
* include: Introduce elf64.h and elf.h

    Added elf64.h for 64bit ELF support and moved common definitions
    from elf32.h to elf.h. Also introduced Elf_xxx to be used in
    common libraries such as binfmt.

  * binfmt, include, modlib, module: Add support for ELF64

    Elf_xxx must be used instead of Elf32_xxx to support ELF64.
    To use ELF64, CONFIG_ELF_64BIT must be enabled.

  * binfmt, modlib: Add support for relocate address

  * arch: risc-v: Add include/elf.h

  * libs: machine: Add risc-v related files.

    NOTE: Currently only supports ELF64

  * boards: maix-bit: Add elf and posix_spawn configurations

  * boards: maix-bit: Add support for module configuration
2020-02-07 17:10:23 -06:00
liuguo09
e21c30cf9d
arch/arm/include/stm32f010g0/chip.h: correct wrong #if defined to fix build break (#227)
/home/jenkins/jenkins-slave/workspace/NuttX-Nightly-Build/nuttx/include/arch/stm32f0l0g0/chip.h:53:42: error: missing ')' after "defined"
   53 | #if defined(CONFIG_ARCH_CHIP_STM32F030RC || CONFIG_ARCH_CHIP_STM32F030CC)
      |                                          ^~
/home/jenkins/jenkins-slave/workspace/NuttX-Nightly-Build/nuttx/include/arch/stm32f0l0g0/chip.h:53:45: error: missing binary operator before token "CONFIG_ARCH_CHIP_STM32F030CC"
   53 | #if defined(CONFIG_ARCH_CHIP_STM32F030RC || CONFIG_ARCH_CHIP_STM32F030CC)

Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-02-07 08:30:58 -08:00
Peter van der Perk
499607d68f
S32K add support for Nxp drone boards (#224)
* S32K add support for Nxp drone boards

* Update arch/arm/src/s32k1xx/hardware/s32k1xx_rtc.h codestyle

Co-Authored-By: David Sidrane <David.Sidrane@Nscdg.com>

Co-authored-by: Jari van Ewijk <jari.vanewijk@nxp.com>
Co-authored-by: David Sidrane <David.Sidrane@Nscdg.com>
2020-02-07 04:53:40 -08:00
David Sidrane
2d5141baf8
Merge pull request #222 from han1raaijmakers/imxrtI2C
imxrt added missing i2c prescale mask
2020-02-07 04:09:24 -08:00
David Sidrane
cabd6927bc
Merge pull request #223 from han1raaijmakers/KinetisTJA110X
Kinetis renamed TJA1100 to TJA110X registers
2020-02-07 04:08:41 -08:00
Peter van der Perk
d79e673468 imxrt added missing i2c prescale mask 2020-02-07 10:09:43 +01:00
Peter van der Perk
513475c11c Kinetis renamed TJA1100 to TJA110X registers 2020-02-07 10:04:48 +01:00
Alan Carvalho de Assis
7f91a737ea arch/arm/include/stm32f010g0/chip.h: Add support for STM32F030CC 2020-02-06 17:40:05 +00:00
David Sidrane
4c0bc308cc
Merge pull request #212 from bkueng/stm32_spibus_initialize_fix
fix stm32_spibus_initialize: add missing leave_critical_section
2020-02-06 01:33:43 -08:00
Beat Küng
729af004c0
fix stm32_spibus_initialize: ensure leave_critical_section is called
in case the requested SPI bus is invalid or not configured.
2020-02-06 08:05:21 +01:00
Alan Carvalho de Assis
bc00f6e444 arch/arm/src/stm32f010g0: Add memorymap and pimmap support for the
STM32F030RC
2020-02-05 22:38:04 +00:00
Alan Carvalho de Assis
af68c22a2e arch/arm/src/kinetis/kinetis_spi.c: Clear the MDIS bit before trying to
disable TX or RX.
2020-02-04 20:45:00 +00:00
Xiang Xiao
c5b1554d84 Remove NETDEV_LOOPBACK option, NET_LOOPBACK is enough 2020-02-02 08:25:06 -06:00
Xiang Xiao
5c80b94820 Replace #include <semaphore.h> to #include <nuttx/semaphore.h>
Since the kernel side should call nxsem_xxx instead and remove the unused inclusion
2020-02-01 08:27:30 -06:00
Xiang Xiao
80277d1630
Refine the preprocessor conditional guard style (#190) 2020-01-31 19:07:39 +01:00
Xiang Xiao
68951e8d72 Remove exra whitespace from files (#189)
* Remove multiple newlines at the end of files
* Remove the whitespace from the end of lines
2020-01-31 09:24:49 -06:00
Gregory Nutt
960c26491c Run tools/nxstyle against all files modified by PR187 and correct complaints 2020-01-30 19:06:13 -06:00
Ouss4
73bdb433bb arch/mips/pic32mz/pic32mz-lowconsole.c: Wait for transfer complete.
Wait for the transfer to complete when using up_lowputc.
2020-01-30 19:03:54 -06:00
Ouss4
701b6897d7 arch/mips/src/pic32mz/pic32mz-head.S: Add showprogress macro 2020-01-30 19:03:01 -06:00
Ouss4
300fe5e354 arch/mips/src/Common and mips32: Access g_current_regs through the macro CURRENT_REGS. 2020-01-30 19:01:47 -06:00
YAMAMOTO Takashi
2983fcdeb7 Fix an inverted logic in the following commit.
commit 39bd9ff670
	Author: YAMAMOTO Takashi <yamamoto@midokura.com>
	Date:   Wed Jan 29 00:17:05 2020 +0900

		sim: Prefix symbols with _ for non-ELF

		Namely for Mach-O.  Leave __CYGWIN__ case as it is.
2020-01-29 10:02:39 -08:00
David Sidrane
04a7ccdc68 imxrt - interrupt serial storm, add DTCM and set up I and D cache (#175)
* Serial Fixed interrupt storm

  The target would randomly hang in the serial isr.
  The priv->ie and the hardware were inconsistent.
  The isr used the priv->ie to gate offloading
  the RX data. Bang! Hung.

                  imxrt_disableuartint(priv, &ie);
                  ret = imxrt_setup(dev);

                  /* Restore the interrupt state */

                  imxrt_restoreuartint(priv, ie);
       interrupt->  Of no return
                  priv->ie = ie;

   On a fast cpu with FIFO, this will not work
   with out proper protections.

* Serial: Conditionally enable 9 bit mode

* armv7-mi/mpu.hi: Restructure API

   Preserve the existing API and enabled better granualriy on
   setting.

* Enable MPU for non protected builds to set cache

* mpuinit use symbolic values for addresses

* Allow DTCM on HEAP

* allocateheap Fix Coding style
2020-01-29 07:33:19 -06:00
YAMAMOTO Takashi
4174c818df sim: Don't bother to remove nuttx.rel after consuming
We usually don't remove input files like $OBJS.
2020-01-29 09:03:48 +01:00
YAMAMOTO Takashi
b5573c5b51 sim: Fix nuttx.rel for macOS
* ld doesn't have --start-groupi/--end-group things.  As far as I know,
  it works that way by default.

* objcopy with Mach-O support is not widely available.
  (GNU binutils seem to claim the support but it didn't actually work
  for me.  llvm-objcopy --redefine-syms explicitly rejects Mach-O.)
  Instead, use -unexported_symbols_list linker flag to hide symbols
  to avoid conflicts with host symbols.
2020-01-29 09:03:48 +01:00
YAMAMOTO Takashi
298c2e5e4f sim: Fix stack alignment
The recent x86-64 convention requires 16-byte alignment before
(not after) calling a function.

This fixes snprintf crash I observed on macOS while saving XMM registers.
2020-01-29 09:03:48 +01:00
YAMAMOTO Takashi
39bd9ff670 sim: Prefix symbols with _ for non-ELF
Namely for Mach-O.  Leave __CYGWIN__ case as it is.
2020-01-29 09:03:48 +01:00
YAMAMOTO Takashi
69a8b9721c sim: Check __ELF__ for .type/.size directives
Mach-O assembler doesn't have them either.
2020-01-29 09:03:48 +01:00
Dave Marples
e99a8d192d Generic SPI interface for controlling an LCD display 2020-01-28 11:32:35 -03:00
taikoyaP
4813b9d751 arch/arm/src/stm32l4/stm32l4_flash.c: Fix flash_erase(page) when page >= 256 (#170)
All STM32L4 MPUs have FLASH_CR_PNB bits (8 bits), and some MPUs have FLASH_CR_BKER bit to change bank if page >= 256.
The code wasn't setting or clearing FLASH_CR_BKER correctly.
2020-01-27 14:56:17 +00:00
YAMAMOTO Takashi
5515e09e8d Fix some "from from" in code comments 2020-01-27 08:46:46 +01:00
Satoshi Togawa
705ac84432 STM32L4: Add workaround of data cache corruption on RWW.
Author: Gregory Nutt <gnutt@nuttx.org>

    Run .c modified by the PR through tools/nxstyle and correct all reporting coding style problems noted in the file.

Author: Satoshi Togawa <togawa@develcb210.centurysys.co.jp>

    STM32L4: Add workaround of data cache corruption on RWW.

    Some STM32L4 chips has eratta "Data cache might be corrupted during Flash Read While Write operation". This is also in STM32, and arch/arm/src/stm32/stm32f20xxf40xx_flash.c has workaround.

    To enable this workaround, define CONFIG_STM32L4_FLASH_WORKAROUND_DATA_CACHE_CORRUPTION_ON_RWW.
2020-01-26 08:57:12 -06:00
y-sugino
cf756061f4 arch: fe310: Fix comments 2020-01-26 07:18:47 -06:00
Satoshi Togawa
50223920a8 arch/arm/src/stm32l4/hardware/stm32l4_flash.h: Add flash register bit in stm32l4x5
STM32L4x5 MPUs have flash bank register bits similar to STM32L4x6.  But it is not defined on these MPUs in stm32l4_flash.h.  So I define these bits.
2020-01-25 17:46:06 -06:00
patacongo
b46b76c956 Fix implicit definition warnings do to missing inclusion of nuttx/time.h (#162)
Recent changes removed CONFIG_TIME_ENHANCED and unmasked some warnings.  These warnings were caused by nuttx/time.h not being included by files that now referenced clock_daysbeforemonth() and clock_isleapyear().

This commit adds those missing inclusions and eliminates the warnings.

Co-authored-by: Gregory Nutt <gnutt@nuttx.org>
2020-01-24 23:06:19 +01:00
Gregory Nutt
d644b759b2 arch/arm/src/lpc17_40/lpc17_49_ethernet.c: Fix build failure.
Fix these build errors which occurred if there was no PHY:

chip/lpc17_40_ethernet.c:1643:31: error: expected expression before ';' token
  ret lpc17_40_phyinit();

chip/lpc17_40_ethernet.c:3941:1: error: expected identifier or '(' before '{' token
  {

chip/lpc17_40_ethernet.c:448:13: warning: 'lpc17_40_macmode' used but never defined
  static void lpc17_40_macmode(uint8_t mode);
2020-01-23 19:45:41 -03:00
Xiang Xiao
ac4735cf58 Many fixes on Kconfigs and defconfigs do SDIO, NETDEV, USBHOST
Author: Xiang Xiao <xiaoxiang@xiaomi.com>

    Fix warning: selects SDIO_DMA or SDIO_BLOCKSETUP which has unmet direct dependencies (MMCSD)

    Fix warning: selects NETDEV_TELNET which has unmet direct dependencies (NETDEVICES && NET && NET_TCP)

    Fix warning: selects ARCH_PHY_INTERRUPT which has unmet direct dependencies (NETDEVICES && ARCH_HAVE_PHY)

    Fix warning: selects USBHOST_HAVE_ASYNCH which has unmet direct dependencies (USBHOST)

    Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-01-23 11:41:12 -03:00
Xiang Xiao
1e3f457c9e Remove TIME_EXTENDED option to more conform C standard
Gregory Nutt <gnutt@nuttx.org>

    Run all .c and .h files modified in this PR through nxstyle and correct all coding standard problems.

Xiang Xiao <xiaoxiang@xiaomi.com>

    Remove TIME_EXTENDED option to more conform C standard

    Note: the code/data size increment is small
2020-01-23 08:17:22 -06:00
patacongo
1658d75005 arch/arm/src/stm32/stm32_dac.c: Fix warning (#148)
Fix warning found in build testing:  "warning:  'dac_interrupt' defined but not used [-Wunused-function].  The compiler is right, dac_interrupt is not used.  It is, apparently, a placeholder for future interrupt support.  Now conditioned out with #if 0 to suppress build test warnings.

Co-authored-by: Gregory Nutt <gnutt@nuttx.org>
2020-01-22 18:35:38 +01:00
Gregory Nutt
c1f75af084 Fix SAMA5D* warnings
sama5d3-xplained:ethernet-over-phy configuration found in build testing:

  arch/arm/src/sama5/sam_irq.c:  Fix "Control reaches end of non-void function " warning
  arch/arm/src/sama5/sam_udphs.c:  Fix "unused variable 'epno'" warning
  boards/arm/sama5/sama5d*-*/src/sam_usb.c:  Fix "warning 'HAVE_USBHOST' not defined" warnings
2020-01-22 16:42:46 +01:00
Masayuki Ishikawa
a218953082 arch: cxd56xx: Fix hardfault when accessing to uSD card
The bug had been introduced in recent refactoring.

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-01-21 08:13:20 -03:00
chao.an
4d74aa6ec9 sim/netdev: dependens on LPWORK by default
Change-Id: Ic2d42d29fc84bef1cc279ef443897d5191888e72
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-01-21 14:17:24 +08:00
Daniel P. Carvalho
3054ade4cf Fix some build issues when CONFIG_PWM_PULSECOUNT is enabled. 2020-01-20 16:23:37 -03:00
Juha Niskanen
a762c06ed9 Fix typos and some incorrect comments
Author: Alan Carvalho de Assis <acassis@gmail.com>

    Run nxstyle against .c and .h files and fix it

Author: Juha Niskanen <juha.niskanen@haltian.com>

    Fix typos and some incorrect comments
2020-01-20 09:32:36 -03:00
raiden00pl
e0cd10b7d5 Nrf52 imrpovements (#119)
* arch/arm/src/nrf52/hardware/nrf52_twi.h: fix typo

  * arch/arm/src/nrf52/nrf52_i2c.c: add interrupts support and some debug messages

  * boards/arm/nrf52/nrf52840-dk: add support for hts221 and lsm303agr; boards/arm/nrf52/nrf52840-dk: fix issues noted by nxstyle
2020-01-17 14:30:34 +00:00
chao.an
1ff410957f sim/net: do not do any critical operations in idle
Change-Id: Ia9011b62ea61d15bd66aa063e4165d9d3baacb51
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-01-16 11:01:47 -06:00
Nathan Hartman
d1dd2841c5 Fix typos in comments and README.txt.
No functional changes.
2020-01-15 10:09:34 -06:00
Mateusz Szafoni
58c3ee65e7 nrf52 improvements
Author: Alan Carvalho de Assis <acassis@gmail.com>

    Run nxstyle on .c and .h files and fix it

Author: raiden00pl <raiden00pl@gmail.com>

    arch/arm/src/nrf52: use the same naming convention for register defs

    arch/arm/src/nrf52/hardware/nrf52_ficr.h: remove invalid defs

    arch/arm/src/nrf52/hardware: add TIMER register defs
2020-01-15 11:43:36 -03:00
chao.an
5c5b4cc3c9 fix warning: passing argument 4 of up_x11initialize from incompatible pointer type
Change-Id: I8fbb506d104dd6a0c41c86ca977e28097694910b
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-01-14 18:30:48 -06:00
Nathan Hartman
72a0934bcc arch/arm/include/cxd56xx/audio.h: Fix minor typos 2020-01-14 20:57:29 -03:00
Daniel P. Carvalho
bf5d48acac Add SPWM example to test STM32L4 PWM driver low level operations
Author: Alan Carvalho de Assis <acassis@gmail.com>

    Run nxstyle again .c file and fix error message

Author: Daniel P. Carvalho <danieloak@gmail.com>

    Add SPWM example to test STM32L4 PWM driver low level operations.

    Fix BUGs.
2020-01-14 11:53:26 -03:00
patacongo
f00569816f Fix a few errors concerning use of section block comments in .c files: (#95)
1. No .c file should include a "Public Types" section.  Only a header file can define a public type.  A .c file can only define a private type.  Several files contained private type definitions.  The section that they were defined in, however, was incorrectly named "Public Types."  Those were easilty changed to "Private Types" which is what they are.

2. No .c file should include a "Public Function Prototypes" section.  All global function prototypes should be provided via a header file and never declared with a .c file.

For No. 2, I corrected as many cases as was reasonable for the time that I had available.  But there are still a dozen or so .c files that declare "Public Function Prototypes" within a .c file.  This is bad programming style.  These declarations should all be moved to the proper header files.
2020-01-14 00:37:54 +01:00
Ouss4
84153ad1a5 arch/mips/src/pic32mz/pic32mz-timer.c: Eliminate a warning found during
testing.
2020-01-13 16:39:54 -06:00
Daniel P. Carvalho
bd0fe25418 Fix small typo error. (#91) 2020-01-13 18:39:56 +01:00
Xiang Xiao
b96d0bfb70 arch/stm32 ensure all spi dma handler check the result
Author: Alan Carvalho de Assis <acassis@gmail.com>

    Run nxstyle on .c files and fix the issues

Author: Xiang Xiao <xiaoxiang@xiaomi.com>

    arch/stm32 ensure all spi dma handler check the result

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-01-11 09:56:52 -03:00
Masayuki Ishikawa
29d3ed2ec1 Feature k210 smp (#71)
* arch: risc-v: Remove unused typedef for irqstate_t

    NOTE: irqstate_t is defined in arch/risc-v/include/types.h

  * arch: risc-v: Add typedef irqstate_t for __LP64__
  * arch: risc-v: Add SMP support to K210 (RV64GC) processor
  * boards: maxi-bit: Update READMEs and add smp/defconfig
2020-01-10 08:04:41 -06:00
Adam Feuer
237c0cca09 CDC ECM Ethernet over USB High Speed for SAMA5D36-Xplained #68
Author: Alan Carvalho de Assis <acassis@gmail.com>

    Run nxstyle against .c .h files and fix it

Author: Adam Feuer <adam@starcat.io>

Summary

    Adds CDC ECM Ethernet over USB High Speed for SAMA5D36-Xplained
      (and maybe other boards) (most of the code was there already,
      but didn't work out of the box for the SAMA5D36-Xplained)
    Only SAMA5D36-Xplained has been tested so far

Impact

    None if you don't use the CDC ECM Ethernet driver
    On SAMA5D36-Xplained, this adds high-speed Internet connectivity
      over USB 2.0 High Speed. via the USB CDC ECM Gadget driver.
    It may work on other boards too.
    This also fixed full-speed (low-speed) mode for the board too.

Limitations

    Hasn't been tested on anything other than SAMA5D36-Xplained board.

TODO

    Ideally this would include a composite RNDIS device so it would
      also work seamlessly on Windows. That is for a future PR
    Ideally this would include software to help configuration via
      mDNS/DNS-SD for plug and play compatibility with Linux and macOS.
      That is for a future PR.

Detail

    Only a few lines of C driver code needed to be changed, since the
      capability was there already. The rest is config and documentation.
    Changes the SAMA5D3-Xplained board bringup to match the SAMA5D3-EK
      board bringup
    A helper script to configure Linux routing and iptables NAT is also
      provided, along with documentation on how to use it.

Testing

    Manual, on a Ubuntu Linux 19.10 system and MacOS 10.14.6 Mojave
      MacBook Pro.

How To Verify

    Follow the new CDC ECM Ethernet over USB instructions in the board
      README.txt file

Commits:

    remove non-UTF-8 chars in comment and reformat

    removed unneeded comment markers

    instructions for using the defconfigs

    removed EMAC from config

    - to prove this example only needs the CDC ECM Ethernet over USB to work

    added CDC-ECM Ethernet over USB info to README

    added U-Boot image

    added netusb helper script

    - this can configure the Linux network interface and routes
      so you can ping or access the NuttX system via TCP/IP.

    renamed defconfig dirs to be ethernet-over-usb

    - was usb-over-ethernet which is not right

    added USB DMA to defconfigs

    updated readme with autoboot and debugging info

    bringing ethernet-over-usb examples into parity

    added cdc ecm ethernet over usb with telnetd config

    added defconfig

    only use phy interrupt if netdevices is ethernet

    - because now netdevice could be CDC ECM ethernet over usb
      which has no PHY interrupt

    add bringup to Makefile

    add bringup

    app init cleanup

    init cdc ecm driver and rndis driver; some cleanup

    fixed some typos and odd characters

    usb over ethernet working over usb 2.0 hs
2020-01-10 07:13:37 -03:00
Daniel P. Carvalho
bac282ecbf boards/arm/stm32l4/nucleo-l432kc/: Remove LPTIM1/2 duplicated entrys on Timer Configuration Menu. Timers TIM3, TIM4, TIM5, TIM8 and TIM17 are not available on STM32L432KC. Added support for timers LPTIM1/2. 2020-01-09 15:22:48 -06:00
Masayuki Ishikawa
255f3008cf arch: k210: Applied changes doned for fe310 recently.
NOTE: In the future, these code should be moved under common code
once they support both RV32 & RV64 architectures.
2020-01-09 09:33:10 -03:00
liuzhao
dc5d8f7c44 Add Quectel EC20 4G LTE Module USB CDC/ACM support
Author: Alan Carvalho de Assis <acassis@gmail.com>

    Run nxstyle to check .c and .h files and fix reported issues

Author: liuzhao <happypapa@yeah.net>

    Add Quectel EC20 4G LTE Module USB CDC/ACM support
2020-01-09 08:00:05 -03:00
Gregory Nutt
8803f5e784 arch/arm/src/cxd56xx/cxd56_sdhci.c: Fix errors found in build testing. Aggressive changes to conform to coding standard introduce compilation errors. More would be requires to fix the CamelCase naming in this case. 2020-01-08 14:04:54 -03:00
raiden00pl
f51e478ad8 nrf52: add support for SPI
nrf52: add support for GPIO interrupts

nrf52: add macros to decode GPIO PIN and GPIO PORT

nrf52: various cosmetic changes

nrf52: fix GPIO P1 memory address

boards/nrf52840-dk: add support for SPI

boards/nrf52840-dk: add support for LSM6DSL sensor

boards/nrf52840-dk: add support for SX127X radio
2020-01-08 09:05:03 -06:00
Masayuki Ishikawa
d76ba14d58 arch: fe310: Fix mstatus handling
In previous commit, mstatus.mie was set when creating a new task
    but this change was incorrect and had a side effect such that
    a machine interrupt would be enabled just before returning from
    interrupt handling routine to switch context.

    Also, mstatus.mpp is set to machine mode in up_get_newintctx()
    instead of fe310_dispatch_irq().
2020-01-08 10:39:00 -03:00