Commit Graph

15909 Commits

Author SHA1 Message Date
Yang Chung-Fan
6b1f94ee49 arch: x86_64: real-mode bootstrap code should jump to 1M 2020-05-06 08:35:09 -07:00
Yang Chung-Fan
ffa2027226 arch: x86_64: Add option to disable interrupt controller initialization 2020-05-06 08:35:09 -07:00
Yang Chung-Fan
c63c8a3841 arch: x86_64: Add real-mode bootstrap stub 2020-05-06 08:35:09 -07:00
Yang Chung-Fan
9ab6b92ad7 arch: x86_64: move the disable multiboot2 marco around to retain labels 2020-05-06 08:35:09 -07:00
Yang Chung-Fan
235d905001 arch: x86_64: remove leftover debug output 2020-05-06 23:33:46 +08:00
Masayuki Ishikawa
4ca19e7e74 arch: k210: Set CPU clock based on PLL0 settings 2020-05-05 17:21:32 -07:00
Gregory Nutt
bda24f09c2 libs/libc/tls/tls_getinfo.c: Add tls_get_info()
Move the logic to get TLS information from an inline function to a normal function.  For the unaligned case, it is probably too large to be inlined.

Also fixes some minor things from review of previous commits.
2020-05-05 18:56:33 +01:00
Abdelatif Guettouche
b7e7fba732 TLS_UNALIGNED (#2)
* Implement the TLS_UNALIGNED
2020-05-05 18:56:33 +01:00
Pierre-Olivier Vauboin
8d763d37ab arch/arm/src/stm32h7/stm32_oneshot: fix style issues 2020-05-05 11:53:58 -06:00
Pierre-Olivier Vauboin
d96565a765 arch/arm/src/stm32h7: add support for oneshot timer
The code is ported from arch/arm/src/stm32
2020-05-05 11:53:58 -06:00
Brennan Ashton
093aa040eb x86_64: Fix /dev/random rdrand implementation
rdrand was checking the wrong return value for the intrinsics
so it would block forever.  The read function was also not returning
the actual number of bytes read.

This was tested by running the rand example application
NuttShell (NSH) NuttX-9.0.0
nsh>rand
Reading 8 random numbers
Random values (0x101584f70):
0000: 019a172df7d539f2df8550362e2d3f74 9b467c51ebe30b9f6510e540e34fabcc ...-..9...P6.-?t .F|Q....e..@.O..

Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-05-05 18:54:47 +08:00
Yang Chung-Fan
521e6354b6 arch: x86_64: fix style of intel64_lowsetup.c 2020-05-05 02:03:34 -07:00
Yang Chung-Fan
8b86fae8d3 arch: x86_64: Check only XSAVE and rename __eanble_sse3 to __enable_sse_avx 2020-05-05 02:03:34 -07:00
Yang Chung-Fan
2936f72651 arch: x86_64: revoke lower 128MB mapping later, ldmxcsr require 32-bit address 2020-05-05 02:03:34 -07:00
Brennan Ashton
aea90e7cf0 Clean code to match nxstyle requirements
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-05-04 08:32:22 -06:00
Brennan Ashton
2405901bf2 Use mempy to perform type punning for setting gdt entry
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-05-04 08:32:22 -06:00
Brennan Ashton
4c24d91b4a Surpress unused rtcb variable
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-05-04 08:32:22 -06:00
Brennan Ashton
19afc57eef Fix null pointer reference in x86_64 rng
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-05-04 08:32:22 -06:00
Brennan Ashton
a9871f584a Resolve linking issues with x86_64 port
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-05-04 08:32:22 -06:00
Masayuki Ishikawa
11bbe3997e arch: x86: Add hlt instruction to save power in qemu_idle.c 2020-05-04 07:13:30 -06:00
raiden00pl
f03ed73f91 arch/arm/src/stm32/stm32_adc.c: remove obsolete warnings 2020-05-03 15:57:49 -03:00
raiden00pl
534ba2cc18 arch/arm/src/stm32/stm32_adc: add setup and shutdown operations to the low-level interface 2020-05-03 15:57:49 -03:00
raiden00pl
b3a1aef773 arch/arm/src/stm32/stm32_adc.c: cosmetics 2020-05-03 15:57:49 -03:00
raiden00pl
5857c48b2e arch/arm/src/stm32/stm32_adc.c: setup/shutdown ADC instance only once 2020-05-03 15:57:49 -03:00
raiden00pl
e2a3266857 arch/arm/src/stm32/stm32_adc: add interface to configure EXTSEL/JEXTSEL from low-level ops 2020-05-03 15:57:49 -03:00
Gregory Nutt
1bab5b6813 arch/arm/: Rename up_intstack_* to arm_intstack_*
The naming standard at https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ requires that all architecture-private functions begin with the name of the arch, not up_.

This PR addresses only these name changes for the ARM-private functions up_instack_base() and up_instack_top() which should be called arm_instack_base() and arm_instack_top().

There should be no impact of this change (other that one step toward more consistent naming).

Normal PR checks are sufficient
2020-05-03 14:48:40 -03:00
Gregory Nutt
da4c597b5f Run all .c and .h files modified by this PR through nxstyle. 2020-05-03 16:42:19 +01:00
Gregory Nutt
01d32a2b22 arch/arm/stm32, stm32f7, stm32l4: Rename up_waste to stm32_waste
The naming standard at https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ requires that all MCU-private functions begin with the name of the MCU, not up_.

This PR addresses only these name changes for the STM32-private functions up_waste() which should be called stm32_waste.

There should be no impact of this change (other that one step toward more consistent naming).

Normal PR checks are sufficient
2020-05-03 16:42:19 +01:00
Gregory Nutt
cbc931b590 arch/arm: Rename up_savestate and up_restorestate
Summary

The naming standard at https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ requires that all MCU-private functions begin with the name of the architecture, not up_.

This PR addresses function-like macro naming that was missing in previous PRs:  up_savestate() and up_restorestate() which must be named arm_savestate() and arm_restorestate().

Impact

There should be no impact of this change (other that one step toward more consistent naming).

Testing

stm32f103-minimum:nsh
2020-05-02 18:35:30 -03:00
Alan Carvalho de Assis
54d0256b9a Remove the not existent CONFIG_XXX_CMNVECTOR 2020-05-02 09:55:35 -06:00
Gregory Nutt
bb29541e3c Remove garbage file accidentally added 2020-05-01 21:05:22 -03:00
Xiang Xiao
f2aba8d9b7 build: Remove 'u' prefix from userspace library
so user needn't link the different library because the build type change

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-01 15:56:55 -06:00
Gregory Nutt
673640b313 Run all .c and .h modified by this PR through nxstyle
The are remaining nxstyle complaints due to the use of mixed case identifiers in arch/arm/src/lc823450/lc823450_irq.c This, cannot be easily fixed since it depends on register definitions in header files that have implications to section other lc823450 files.
2020-05-01 16:55:33 -03:00
Gregory Nutt
b0dbdd7c10 arch/arm, board/arm: Rename all up_ramvec_* functions to arm_ramvec_*
Summary

The naming standard at https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ requires that all MCU-private functions begin with the name of the architecture, not up_.

This PR addresses only these name changes for the ARM-private functions up_ramvec_initialize() and up_ramvec_attch().

Impact

There should be no impact of this change (other that one step toward more consistent naming).

Testing

stm32f4discovery:netnsh
2020-05-01 16:55:33 -03:00
Xiang Xiao
2476aad5b4 sim: Fix librt can't find on macOS
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-01 13:09:44 -06:00
Gregory Nutt
2aa85fd17e arch/arm, board/arm: Rename all up_* functions to arm_*
Summary

The naming standard at https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ requires that all MCU-private functions begin with the name of the architecture, not up_.

This PR addresses only these name changes for the ARM-private functions prototyped in arm_internal.h

This change to the files only modifies the name of called functions.  nxstyle fixes were made for all core architecture files.  However, there are well over 5000 additional complaints from MCU drivers and board logic that are unrelated to to this change but were affected by the name change.  It is not humanly possible to fix all of these.   I ask that this change be treated like other cosmetic changes that we have done which do not require full nxstyle compliance.

Impact

There should be not impact of this change (other that one step toward more consistent naming).
Testing

stm32f4discovery:netnsh
2020-05-01 18:28:13 +01:00
Gregory Nutt
542b684f73 arch/arm: Rename all up_*.S files to arm_*.S
Summary

The naming standard at https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ requires that all MCU-private files begin with the name of the architecture, not up_.

This PR addresses only these name changes for the up_*.S files.

The entire job required to be compatible with that Naming Convention will also require changing the naming of the up_() functions that are used only within arch/arm and board/arm.

Impact

There should be not impact of this change (other that one step toward more consistent naming).
Testing

stm32f4discovery:netnsh
2020-05-01 11:29:11 -03:00
Xiang Xiao
f8a809eb5b Fix nxstyle issue
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-01 10:43:47 -03:00
Xiang Xiao
eca7059785 Refine __KERNEL__ and CONFIG_BUILD_xxx usage in the code base
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-01 10:43:47 -03:00
YAMAMOTO Takashi
8b054dba98 sim: Update hostfs after the recent struct stat timespec changes
Fix it after the following change:

    commit bb4458b63f
    Author: Ouss4 <abdelatif.guettouche@gmail.com>
    Date:   Thu Apr 30 19:05:12 2020 +0100

        include/sys/stat.h: Per the POSIX standard, the atime, ctime and mtime field
    s
        have changed their type from time_t to struct timespec.
2020-05-01 17:42:46 +08:00
Ouss4
21302fcdae arch/risc-v/src: Rename files starting by up_ to risc_ to conform to the
naming standard.
2020-04-30 20:48:32 -06:00
Gregory Nutt
037c9ea0a4 arch/arm: Rename all up_*.h files to arm_*.h
Summary

The naming standard at https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ requires that all MCU-private files begin with the name of the architecture, not up_.

This PR addresses only these name changes for the up_*.h files.  There are only three, but almost 1680 files that include them:

    up_arch.h
    up_internal.h
    up_vfork.h

The only change to the files is from including up_arch.h to arm_arch.h (for example).

The entire job required to be compatible with that Naming Convention will also require changing the naming of the up_() functions that are used only within arch/arm and board/arm.

Impact

There should be not impact of this change (other that one step toward more consistent naming).

Testing

stm32f4discovery:netnsh
2020-05-01 03:43:44 +01:00
Gregory Nutt
ee05672434 Run all .c and .h files modified by this PR through nxstyle. 2020-05-01 02:11:01 +01:00
Gregory Nutt
c6c712b2fc arch/arm: Rename all up_*.c files to arm_*.c 2020-05-01 02:11:01 +01:00
Gregory Nutt
a86884c615 Run all .c and .h files modifed in this PR through nxstyle. 2020-04-30 22:09:51 +01:00
Gregory Nutt
84ccee4d34 Rename up_switchcontext to arm_switchcontext 2020-04-30 22:09:51 +01:00
Gregory Nutt
6398a64e26 Rename up_saveusercontext to arm_saveusercontext 2020-04-30 22:09:51 +01:00
Gregory Nutt
3a82a20c90 Rename up_copyarmstate to arm_copyarmstate 2020-04-30 22:09:51 +01:00
Gregory Nutt
3d2cd1493f Rename up_copyfullstate to arm_copyfullstate 2020-04-30 22:09:51 +01:00
Xiang Xiao
b1e661e7db sama5/sam_tsd: Fix error: 'ret' may be used uninitialized
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-30 11:43:29 -06:00
Gregory Nutt
a7558cf9b9 Run all .c and .h modified by the PR through nxstyle. 2020-04-30 18:38:32 +01:00
Gregory Nutt
e2a65ceb5f Rename up_fullcontextrestore to arm_fullcontextrestore 2020-04-30 18:38:32 +01:00
Gregory Nutt
317a8a8942 arch/z16: Build update
Verfy build.  Update to latest 2.2.2 toolchain.
2020-04-30 16:58:06 +01:00
liuhaitao
55ff12ad66 arch/arm/src/common/up_exit.c: _exit should call arm_fullcontextrestore for armv8-m
Since armv8-m now uses arm_fullcontextrestore instead of up_fullcontextrestore, _exit
should call arm_fullcontextrestore for armv8-m accordingly.

Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-04-30 08:47:10 -06:00
liuhaitao
bab61180db sim: Add host mmap and perror support
Change-Id: I20bb8cba7ed6ab3e06c91f275fa2be6a633efe9e
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-04-30 20:20:32 +08:00
Gregory Nutt
1aa9ff8af2 Run .c and .h files in this PR through nxstyle and fix complaints 2020-04-29 22:30:54 -03:00
Gregory Nutt
f23a756349 arch/z16: Correct file naming for coding standard
Rename all up_* files to conform to the name conventions of https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ

Rename all internal functions from up_* z16_
2020-04-29 22:30:54 -03:00
Xiang Xiao
5d12735f34 sama5d3x-ek/nxwm: Fix error: 'g_adcdev' undeclared
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-29 14:04:14 -06:00
Yang Chung-Fan
bebc8875fb arch: x86_64: add no-relax to the linker flags 2020-04-29 09:29:03 -07:00
Xiang Xiao
1c483d8ed4 arm/up_allocpage: fix warning: "PG_POOL_MAXL1NDX" is not defined
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-29 10:26:29 -06:00
Xiang Xiao
d2a262672c tiva/cc13x0: fix error 'TIVA_GPIO_BASE' undeclared
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-29 07:10:44 -06:00
Nathan Hartman
1b03a42bc0 arch/arm/src/stm32/Kconfig - Remove redundant ARCH_CHIP configs
* Remove redundant configs:
  - ARCH_CHIP_STM32F303RD, and
  - ARCH_CHIP_STM32F303RE.
2020-04-27 17:46:31 -06:00
Ouss4
e5443a4718 Remove a duplicate file introduced by the previous PR. 2020-04-26 22:12:42 -06:00
Ouss4
32597a763a arch/mips: Fix file naming. 2020-04-26 20:56:30 -06:00
zhongan
ef9735febd arch/sim: initialize 'rxbuf_size' and 'txbuf_size' instead of 'buf_size'.
Change-Id: I5442f022cafef6c0f636614ba739e11249713134
Signed-off-by: zhongan <zhongan@xiaomi.com>
2020-04-26 19:59:16 -06:00
zhongan
4ec8fd521f arch/sim: change 'VIRTIO_RPMSG_F_BIND' to 'VIRTIO_RPMSG_F_ACK'
Change-Id: I4d6b6b700130e264199f490ab4e922f699955113
Signed-off-by: zhongan <zhongan@xiaomi.com>
2020-04-26 19:59:16 -06:00
Gregory Nutt
dcd50db5d1 Run files in previous commit through nxstyle, fixing issues. 2020-04-26 22:14:25 +01:00
Gregory Nutt
a0fdda698c arch/z80: Fix z80 file naming
Modify file naming to conform on the Naming conventions of https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ

This commit only address the file naming convention.  There is still nonconformant function naming.
2020-04-26 22:14:25 +01:00
raiden00pl
f837bfecdb arch/arm/src/stm32/stm32_adc.h: add prefix STM32 to low-level ops macros 2020-04-26 11:35:11 -06:00
raiden00pl
1b4e0fddb8 arch/arm/src/stm32/stm32_adc.h: move generalized ADC definitions to the header file 2020-04-26 11:35:11 -06:00
raiden00pl
0e09d162e2 arch/arm/src/stm32/stm32_adc.c: fix injected channels configuration for ADC IPv1 2020-04-26 11:35:11 -06:00
raiden00pl
a85ffd0fbd arch/arm/src/stm32/stm32_adc.c: enable callback logic if DMA enabled 2020-04-26 11:35:11 -06:00
raiden00pl
4cb8be9608 arch/arm/src/stm32/stm32_adc.c: move adc_offset_set to llops section 2020-04-26 11:35:11 -06:00
Gregory Nutt
010603329b More compliance to the naming standard.
1) Rename all up_*.S file to arm_*.S
2) Rename all functions used only by armv8_m logic from up_* to arm_*
2020-04-26 14:12:47 -03:00
Gregory Nutt
15f003d01c arch/arm/src/armv8-m: Rename files to correspond to naming conventions.
This files in the arch/arm/src/armv8-m directory were cloned from arch/arm/src/armv7-m.  Naming standards were created for the architecture files, function, and variable names:  https://cwiki.apache.org/confluence/display/NUTTX/Naming+FAQ

There however were never appliced to arch/arm/src/armv7-m and so this bad naming was inherited by arch/arm/src/armv8-m.  This commit corrects the file naming only and makes it compliant with the Naming FAQ.
2020-04-26 14:12:47 -03:00
Gregory Nutt
6766aa0ed5 Mea Culpa. Fix nxstyle problems from PR879
In a fit of confusion, I accidentally committed PR 879 before it passed its nxstyle check (it did pass all of its build tests, but not the style check).  It was really my intention to merge PR878, but I screwed that up and merged 879 instead.

This PR makes amends by passing all of the .c and .h files modified by PR879 through nxstyle and correcting all reported style problems.
2020-04-26 11:56:15 -03:00
Nathan Hartman
d6f7821b15 Docs and comments: Change OSX -> macOS
Mac OS X was renamed to macOS at some point. Update references to
OSX, OS X, Mac OS X, Mac OSX, and other permutations, to macOS,
in README files and in comments of other files.
2020-04-26 07:48:33 -06:00
qiaowei
2376d8a266 Porting arch/armv8-m support
1. Add dsp extension; float point based on hardware and software.
2. Delete folder "iar"
3. Add tool chain for cortex-M23 and cortex-M35p

Signed-off-by: qiaowei <qiaowei@xiaomi.com>
Change-Id: I5bfc78abb025adb0ad4fae37e2b444915f477fe7
2020-04-26 07:43:37 -06:00
Matias Nitsche
a0d4e61d54 STM32L4 PWM: nxstyle 2020-04-24 12:38:47 -06:00
Matias Nitsche
436979baed STM32L4 PWM: nxstyle 2020-04-24 12:38:47 -06:00
Matias Nitsche
ff85335b71 fix use of undefined CONFIG_STM32L4_LPTIM1_CH1POL 2020-04-24 12:38:47 -06:00
Matias Nitsche
3fcb441ef8 STM32L4 PWR/RCC: nxstyle 2020-04-24 12:34:17 -06:00
Matias Nitsche
a0d4370163 STM32L4 RCC/PWR: nxstyle fixes 2020-04-24 12:34:17 -06:00
Matias Nitsche
e9319fa9a0 stm32l4x6 RCC: allow choosing HSI, MSI or HSE as SYSCLK instead of PLL to reduce power 2020-04-24 12:34:17 -06:00
Matias Nitsche
34bf9b26e0 stm32l4x6 RCC: set CORE regulator range according to CPU clock 2020-04-24 12:34:17 -06:00
Matias Nitsche
891acc5fa3 stm32l4x6 RCC: fix MSI clock speed setting 2020-04-24 12:34:17 -06:00
Matias Nitsche
2a76451185 stm32l4 PWR: add VOS setting function 2020-04-24 12:34:17 -06:00
Matias Nitsche
977f3194de stm32l4_lptim: nxstyle fix 2020-04-24 14:47:07 -03:00
Matias Nitsche
f0033f783e stm32l4_lptim: nxstyle fix 2020-04-24 14:47:07 -03:00
Matias Nitsche
d5eaa68b50 stm32l4_lptim: nxstyle fixes 2020-04-24 14:47:07 -03:00
Matias Nitsche
38bd0364bf stm32l4_lptim: add various functions 2020-04-24 14:47:07 -03:00
anjana-tel
0a673d759d Corrected build error
Corrected build error in rx65n_sbram_open()
2020-04-23 18:33:09 +08:00
Gregory Nutt
e6af32c88f Run nxstyle against all files modified by PR 848 2020-04-22 21:36:41 +01:00
Gregory Nutt
2f7e003ef8 arch/arm/src/armv7-m: Use Apache 2.0 license
Change license header on all files under arch/arm/src for which I am the sole author and the only person claiming to hold a coyright on the file.
2020-04-22 21:36:41 +01:00
Nathan Hartman
02ab0cd149 stm32: Fix typos, wrong comments, and nxstyle.
arch/arm/include/stm32/chip.h:

    * Fix 2 typos.

    * Fix 1 wrong comment (No LCD -> LCD)

    * Fix nxstyle errors regarding comment positions, blank lines
      before/after comments, and C++ style comments.
2020-04-22 16:14:57 +01:00
rajeshwaribhat
31332904dd Added support to crashdump for rx65n on sbram 2020-04-22 07:32:37 -06:00
raiden00pl
c2162365fc arch/arm/src/stm32h7/stm32_pwm: nxstyle fixes 2020-04-22 01:37:42 +08:00
raiden00pl
d89b9102cc arch/arm/src/stm32h7/stm32_pwm: fix PWM_DUMP_REGS macro
arch/arm/src/stm32h7/stm32_pwm: prevent the PA0 pin configuration from being overwritten
2020-04-22 01:37:42 +08:00
raiden00pl
655bb2e391 arch/arm/src/stm32/stm32_pwm: fix PWM_DUMP_REGS macro
arch/arm/src/stm32/stm32_pwm: prevent the PA0 pin configuration from being overwritten
2020-04-22 01:37:42 +08:00
raiden00pl
23c1efa164 arch/arm/src/stm32/hardware/stm32f30xxx_pinmap.h: add missing TIM2_CH1 pins 2020-04-22 01:35:10 +08:00
Alin Jerpelea
afead9c9da arch: arm: a1x: nxstyle fixes for a1x arch
nxstyle fixes for a1x arch

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2020-04-21 13:46:07 +08:00
Xiang Xiao
090a4d1690 Update .gitignore per testbuild.sh report
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-20 07:07:32 -06:00
Xiang Xiao
3d10f8cf8f Fix nxstyle warning
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-19 07:51:18 -06:00
Xiang Xiao
2a7029dd52 arch/sim: All cpu core need conform to CONFIG_SIM_WALLTIME behaviour
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-19 07:51:18 -06:00
Nakamura, Yuuichi
00049aa482 Fix saved %esp value in up_saveusercontext() for qemu-i486 2020-04-18 19:33:39 +08:00
Nathan Hartman
1d394535cb arch/README.txt: Various improvements to the text
* Added missing architectures and directories.

* Corrected a few mistakes.

* Rewrapped some text for consistency.
2020-04-17 15:16:43 -06:00
Nathan Hartman
120de788d4 kinetis: Fix typos
arch/arm/include/kinetis/kinetis_pmc.h:

    * Fix several typos in comments.
    * Rewrap some comment lines.
    * Fix define KINETIS_PMC_VERSION_UKN: Put -1 in
      parenthesis for safety.
    * Fix nxstyle complaint regarding long line.
2020-04-16 14:43:54 -06:00
Nathan Hartman
9b9d1fc7ca arch/stm32h7: Extend support to all STM32H7x3xx
All parts in the STM32H7x3xx family have the same pinmap, etc.,
so extending support to all members of the family required only
minimal changes: Adding them to Kconfig, extending some
preprocessor logic, and minor code changes.

arch/arm/src/stm32h7/Kconfig:

    * Add explicit support for all microcontrollers in the
      STM32H7x3xx family by adding support for:
        - STM32H743AG
        - STM32H743AI
        - STM32H743BG
        - STM32H743BI
        - STM32H743IG
        - STM32H743II
        - STM32H743VG
        - STM32H743VI
        - STM32H743XG
        - STM32H743XI
        - STM32H743ZG
        - STM32H753AI
        - STM32H753BI
        - STM32H753VI
        - STM32H753XI
        - STM32H753ZI

    * Fix TODO items for IO_CONFIG (all STM32H7X3XX).

    * Because 100-pin parts lack GPIO ports F and G, but have
      port H, create the new hidden configs STM32H7_HAVE_GPIOF
      and STM32H7_HAVE_GPIOG.

    * STM32H7_STM32H7X3XX:
      - Select STM32H7_HAVE_GPIOF and STM32H7_HAVE_GPIOG only
        when not STM32H7_IO_CONFIG_V (100-pin part).
      - STM32H7_STM32H7X3XX: select STM32H7_HAVE_SPI5 for all
        IO configs except V (100-pin part), which doesn't expose
        SPI5 due to pin count.

    * STM32H7_STM32H7X7XX: Always select STM32H7_HAVE_GPIOF and
      STM32H7_HAVE_GPIOG because we aren't adding more part
      numbers in this family.

    * Remove extraneous (duplicate) "bool" and "default n"
      lines.

    * config STM32H7_FMC: Fix indent (contents were indented
      with spaces while rest of file uses tabs).

arch/arm/include/stm32h7/chip.h:

    * Extend preprocessor logic to add support for the new
      MCU part numbers.

    * Expand table of differences between family members.

    * Define STM32H7_NGPIO based on IO_CONFIGs decided in Kconfig.

    * If IO config is not known, issue compile-time #error
      with grep-friendly "CONFIG_STM32H7_IO_CONFIG_x Not Set."
      Suggested by davids5.

arch/arm/src/stm32h7/hardware/stm32h7x3xx_gpio.h:
arch/arm/src/stm32h7/stm32h7x3xx_rcc.c:
arch/arm/src/stm32h7/stm32h7x7xx_rcc.c:

    * When checking STM32H7_NGPIO > 5 or 6, check also
      CONFIG_STM32H7_HAVE_GPIOF or CONFIG_STM32H7_HAVE_GPIOG.

arch/arm/src/stm32h7/stm32_gpio.c:

    * stm32_configgpio(): When applicable, make sure we're not
      trying to configure one of the missing ports.

    * Fix nxstyle complains (wrong end of line comment position
      and several long lines). No functional changes.

    * g_gpiobase[]: Init base address for ports F and G according to
      CONFIG_STM32H7_HAVE_GPIOF and CONFIG_STM32H7_HAVE_GPIOG.

    * stm32_configgpio(): Replace complicated check with g_gpiobase[]
      null check. Suggested by davids5.

    * stm32_gpiowrite() and stm32_gpioread(): Add previously missing
      null check of g_gpiobase[].

arch/arm/src/stm32h7/stm32_gpio.h:

    * Wrap the defines GPIO_PORTA, GPIO_PORTB, GPIO_PORTC, GPIO_PORTD,
      GPIO_PORTE, GPIO_PORTF, GPIO_PORTG, GPIO_PORTH, GPIO_PORTI,
      GPIO_PORTJ, and GPIO_PORTK in conditional logic so that the
      compiler will prevent use of ports that do not exist on the
      target MCU.

    * Fix nxstyle complaints.

Documentation/NuttX.html:

    * Remove copy-and-pasted anchor for stm32f76xx77xx.

    * Correct link to README.txt for Nucleo-H743ZI board,
      formerly on BitBucket, now on GitHub.

    * Add list item for STMicro STM32H747I-DISCO board.

Co-Authored-By: David Sidrane <David.Sidrane@Nscdg.com>
2020-04-16 13:23:12 -06:00
Nathan Hartman
3c829226f9 Fix typos and nxstyle complaints.
arch/x86_64/src/intel64/intel64_tickless.c:
boards/x86_64/intel64/qemu-intel64/src/qemu_freq.c:
drivers/modem/altair/altmdm.c:

    * Fix typos and nxstyle complaints.
2020-04-15 17:04:58 +01:00
zhongan
b4a50a9192 fix nxstyle warning.
Signed-off-by: zhongan <zhongan@xiaomi.com>
2020-04-15 12:30:50 -03:00
zhongan
4ff0edce25 arch/sim: add implemntation of 'host_sleep'.
Change-Id: Ib82343565ca9541499dec52c753c3f15923f7d1c
Signed-off-by: zhongan <zhongan@xiaomi.com>
2020-04-15 12:30:50 -03:00
zhongan
a41c5e01e1 arch/sim: add header to remove warning when build with 'CONFIG_SYSLOG_RPMSG_SERVER'.
Change-Id: I58ebe25434aaebce3812abb52caf3c670118cb66
Signed-off-by: zhongan <zhongan@xiaomi.com>
2020-04-15 12:30:50 -03:00
zhongan
648a76b3c1 risc-v: add pm initialization functions.
Signed-off-by: zhongan <zhongan@xiaomi.com>
2020-04-15 10:07:30 -03:00
Nathan Hartman
9b86305ad3 Fix copy/paste typo in various Kconfigs 2020-04-14 22:42:21 +01:00
Xiang Xiao
11705ffc71 Fix nxstyle issue 2020-04-14 13:02:00 -06:00
zhongan
0d3691a460 Add fpu support. 2020-04-14 13:01:47 -06:00
zhongan
957c14d95e Add initialization for idle task. 2020-04-14 13:01:34 -06:00
zhongan
38b4933e88 Change --start-group and '--end-group' as args. 2020-04-14 13:01:20 -06:00
zhongan
7262af219f rv32im/Toolchain.defs: when 'CONFIG_ARCH_FPU' enabled, add 'f' to match and mabi. 2020-04-14 13:01:08 -06:00
zhongan
bf21c1b947 Risc-v: Fix the not supported options in the latest 'RISCV_TOOLCHAIN' in rv32im's Toolchain.defs. 2020-04-14 13:00:53 -06:00
Juha Niskanen
88971a15a5 arch/arm/src/stm32f7/stm32_flash.c: Fix return value of stm32_flash_lock 2020-04-14 17:34:45 +01:00
Gregory Nutt
61f6fa769a nxstyle fixes for previous commit. 2020-04-14 17:19:11 +01:00
Juha Niskanen
552ca28d22 arch/arm/src/stm32l4/stm32l4_1wire.c: fix build error, fix typo 2020-04-14 17:19:11 +01:00
Juha Niskanen
e1138e35e0 arch/arm/src/stm32l4/stm32l4_spi.c: add missing ret declaration 2020-04-14 16:32:10 +01:00
Alin Jerpelea
222a3b9fe8 arch: arm: cxd56xx: nxstyle fixes
nxstyle fixes for cxd56xx

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2020-04-14 13:20:21 +01:00
Alin Jerpelea
dd2f3deaaf arch: arm: cxd56xx: nxstyle fixes
nxstyle fixes for cxd56 arch

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2020-04-14 17:31:18 +08:00
Xiang Xiao
df57cacd61 nuttx: Fix the nightly build warning again
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-14 11:22:22 +02:00
Xiang Xiao
d3c4879113 Fix nxstyle warning
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-04-13 12:01:39 -06:00
Xiang Xiao
b22e3b9e28 nuttx: Fix the nightly build warning
lpc2148_spi1.c:142:24: warning: initialization of 'uint32_t (*)(struct spi_dev_s *, uint32_t)' {aka 'unsigned int (*)(struct spi_dev_s *, unsigned int)'} from incompatible pointer type 'uint16_t (*)(struct spi_dev_s *, uint16_t)' {aka 'short unsigned int (*)(struct spi_dev_s *, short unsigned int)'} [-Wincompatible-pointer-types]
  142 |   .send              = spi_send,
      |                        ^~~~~~~~
lpc2148_spi1.c:142:24: note: (near initialization for 'g_spiops.send')

In file included from ieee802154/mac802154_bind.c:49:
ieee802154/mac802154_internal.h: In function 'mac802154_setdevmode':
ieee802154/mac802154_internal.h:788:42: warning: converting a packed 'enum ieee802154_devmode_e' pointer (alignment 1) to a 'const union ieee802154_attr_u' pointer (alignment 4) may result in an unaligned pointer value [-Waddress-of-packed-member]
  788 |                         (FAR const union ieee802154_attr_u *)&mode);
      |                                          ^~~~~~~~~~~~~~~~~

chip/stm32_hciuart.c: In function 'hciuart_read':
chip/stm32_hciuart.c:2104:30: warning: statement with no effect [-Wunused-value]
 2104 |                       ntotal == (ssize_t)ret;
      |                       ~~~~~~~^~~~~~~~~~~~~~~

wireless/ieee80211/bcm43xxx/bcmf_driver.c: In function 'bcmf_wl_auth_event_handler':
wireless/ieee80211/bcm43xxx/bcmf_driver.c:579:23: warning: taking address of packed member of 'struct bcmf_event_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
  579 |   type = bcmf_getle32(&event->type);
      |                       ^~~~~~~~~~~~
wireless/ieee80211/bcm43xxx/bcmf_driver.c:580:25: warning: taking address of packed member of 'struct bcmf_event_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
  580 |   status = bcmf_getle32(&event->status);
      |                         ^~~~~~~~~~~~~~
wireless/ieee80211/bcm43xxx/bcmf_driver.c: In function 'bcmf_wl_scan_event_handler':
wireless/ieee80211/bcm43xxx/bcmf_driver.c:619:25: warning: taking address of packed member of 'struct bcmf_event_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
  619 |   status = bcmf_getle32(&event->status);
      |                         ^~~~~~~~~~~~~~
wireless/ieee80211/bcm43xxx/bcmf_driver.c:620:35: warning: taking address of packed member of 'struct bcmf_event_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
  620 |   escan_result_len = bcmf_getle32(&event->len);
      |                                   ^~~~~~~~~~~
wireless/ieee80211/bcm43xxx/bcmf_bdc.c: In function 'bcmf_bdc_process_event_frame':
wireless/ieee80211/bcm43xxx/bcmf_bdc.c:166:27: warning: taking address of packed member of 'struct bcmf_event_s' may result in an unaligned pointer value [-Waddress-of-packed-member]
  166 |   event_id = bcmf_getle32(&event_msg->event.type);
      |                           ^~~~~~~~~~~~~~~~~~~~~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c: In function 'sdio_io_rw_direct':
wireless/ieee80211/bcm43xxx/mmc_sdio.c:157:3: warning: converting a packed 'struct sdio_resp_R5' pointer (alignment 1) to a 'uint32_t' {aka 'unsigned int'} pointer (alignment 4) may result in an unaligned pointer value [-Waddress-of-packed-member]
  157 |   ret = SDIO_RECVR5(dev, SD_ACMD52, (uint32_t *)&resp);
      |   ^~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c:79:28: note: defined here
   79 | begin_packed_struct struct sdio_resp_R5
      |                            ^~~~~~~~~~~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c: In function 'sdio_io_rw_extended':
wireless/ieee80211/bcm43xxx/mmc_sdio.c:239:11: warning: converting a packed 'struct sdio_resp_R5' pointer (alignment 1) to a 'uint32_t' {aka 'unsigned int'} pointer (alignment 4) may result in an unaligned pointer value [-Waddress-of-packed-member]
  239 |           ret = SDIO_RECVR5(dev, SD_ACMD53, (uint32_t *)&resp);
      |           ^~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c:79:28: note: defined here
   79 | begin_packed_struct struct sdio_resp_R5
      |                            ^~~~~~~~~~~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c:244:11: warning: converting a packed 'struct sdio_resp_R5' pointer (alignment 1) to a 'uint32_t' {aka 'unsigned int'} pointer (alignment 4) may result in an unaligned pointer value [-Waddress-of-packed-member]
  244 |           ret = SDIO_RECVR5(dev, SD_ACMD53, (uint32_t *)&resp);
      |           ^~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c:79:28: note: defined here
   79 | begin_packed_struct struct sdio_resp_R5
      |                            ^~~~~~~~~~~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c:257:7: warning: converting a packed 'struct sdio_resp_R5' pointer (alignment 1) to a 'uint32_t' {aka 'unsigned int'} pointer (alignment 4) may result in an unaligned pointer value [-Waddress-of-packed-member]
  257 |       ret = SDIO_RECVR5(dev, SD_ACMD53, (uint32_t *)&resp);
      |       ^~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c:79:28: note: defined here
   79 | begin_packed_struct struct sdio_resp_R5
      |                            ^~~~~~~~~~~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c:265:3: warning: converting a packed 'struct sdio_resp_R5' pointer (alignment 1) to a 'uint32_t' {aka 'unsigned int'} pointer (alignment 4) may result in an unaligned pointer value [-Waddress-of-packed-member]
  265 |   SDIO_RECVR1(dev, SD_ACMD52ABRT, (uint32_t *)&resp);
      |   ^~~~~~~~~~~
wireless/ieee80211/bcm43xxx/mmc_sdio.c:79:28: note: defined here
   79 | begin_packed_struct struct sdio_resp_R5
      |                            ^~~~~~~~~~~~

chip/stm32_adc.c: In function 'adc_reset':
chip/stm32_adc.c:2860:7: warning: unused variable 'ret' [-Wunused-variable]
 2860 |   int ret;
      |       ^~~
chip/stm32_adc.c: In function 'adc_shutdown':
chip/stm32_adc.c:3044:7: warning: unused variable 'ret' [-Wunused-variable]
 3044 |   int ret;
      |       ^~~

chip/stm32_i2c.c:722:12: warning: 'stm32_i2c_sem_wait_noncancelable' defined but not used [-Wunused-function]
  722 | static int stm32_i2c_sem_wait_noncancelable(FAR struct i2c_master_s *dev)
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

wireless/gs2200m.c: In function 'gs2200m_read':
wireless/gs2200m.c:727:20: warning: passing argument 1 of 'nxsem_wait' from incompatible pointer type [-Wincompatible-pointer-types]
  727 |   ret = nxsem_wait(dev);
      |                    ^~~
      |                    |
      |                    struct gs2200m_dev_s *

.config:1207:warning: symbol value '' invalid for TESTING_OSTEST_FPUSIZE

platform/audio/cxd56_audio_analog.c:69:13: warning: inline function 'cxd56_audio_clock_is_enabled' declared but never defined
   69 | inline bool cxd56_audio_clock_is_enabled(void);
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
platform/audio/cxd56_audio_analog.c:68:13: warning: inline function 'cxd56_audio_clock_disable' declared but never defined
   68 | inline void cxd56_audio_clock_disable(void);
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~
platform/audio/cxd56_audio_analog.c:67:13: warning: inline function 'cxd56_audio_clock_enable' declared but never defined
   67 | inline void cxd56_audio_clock_enable(uint32_t clk, uint32_t div);
      |             ^~~~~~~~~~~~~~~~~~~~~~~~

chip/stm32_adc.c: In function 'adc_reset':
chip/stm32_adc.c:1348:7: warning: unused variable 'ret' [-Wunused-variable]
 1348 |   int ret;
      |       ^~~
chip/stm32_adc.c: In function 'adc_shutdown':
chip/stm32_adc.c:1496:7: warning: unused variable 'ret' [-Wunused-variable]
 1496 |   int ret;
      |       ^~~

chip/stm32_i2c.c:729:12: warning: 'stm32_i2c_sem_wait_uninterruptble' defined but not used [-Wunused-function]
  729 | static int stm32_i2c_sem_wait_uninterruptble(FAR struct i2c_master_s *dev)
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

wireless/lpwan/sx127x/sx127x.c:147:52: warning: missing terminating ' character
  147 | #  warning OOK support is not complete, RX+TX doesn't work yet!
      |                                                    ^

str71_spi.c:435:24: warning: initialization of 'uint32_t (*)(struct spi_dev_s *, uint32_t)' {aka 'unsigned int (*)(struct spi_dev_s *, unsigned int)'} from incompatible pointer type
                                               'uint16_t (*)(struct spi_dev_s *, uint16_t)' {aka 'short unsigned int (*)(struct spi_dev_s *, short unsigned int)'} [-Wincompatible-pointer-types]
  435 |   .send              = spi_send,
      |                        ^~~~~~~~
str71_spi.c:435:24: note: (near initialization for 'g_spiops.send')

chip/pic32mx-lowconsole.c:147:24: warning: 'pic32mx_getreg' defined but not used [-Wunused-function]
 static inline uint32_t pic32mx_getreg(uintptr_t uart_base,
                        ^
chip/pic32mx-gpio.c:113:20: warning: 'pic32mx_value' defined but not used [-Wunused-function]
 static inline bool pic32mx_value(uint16_t pinset)
                    ^
chip/pic32mz-gpio.c:124:20: warning: 'pic32mz_value' defined but not used [-Wunused-function]
 static inline bool pic32mz_value(pinset_t pinset)
                    ^
chip/pic32mx-usbdev.c:3065:1: warning: 'pic32mx_epreserved' defined but not used [-Wunused-function]
 pic32mx_epreserved(struct pic32mx_usbdev_s *priv, int epno)
 ^

mmcsd/mmcsd_spi.c: In function 'mmcsd_mediachanged':
mmcsd/mmcsd_spi.c:1938:7: warning: 'return' with a value, in function returning void
       return ret;
       ^

In file included from partition/fs_partition.c:42:0:
partition/partition.h:66:19: warning: 'read_partition_block' defined but not used [-Wunused-function]
 static inline int read_partition_block(FAR struct partition_state_s *state,
                   ^

local/local_netpoll.c: In function 'local_pollsetup':
local/local_netpoll.c:305:1: warning: label 'pollerr' defined but not used [-Wunused-label]
 pollerr:
 ^~~~~~~

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: If3ea8f32b878aa218072130f7c3018f0d3c1aca5
2020-04-13 12:01:39 -06:00
Nathan Hartman
34113810bd Fix nxstyle errors in previous commit. 2020-04-12 15:49:35 -06:00
Nathan Hartman
743dcd8acf Fix suspect DEBUGASSERT() like PR765
As pointed out by Şükrü Bahadır Arslan in PR765, function calls
inside DEBUGASSERT() will not be executed if DEBUGASSERT is
disabled. Following that PR, I searched for other instances of
similar errors and found four. As there are many thousands of
DEBUGASSERT in the code, this is *not* an exhaustive fix.

arch/arm/src/tms570/tms570_boot.c:
* In function arm_boot(), call tms570_memtest_complete()
  outside of the DEBUGASSERT(). Otherwise, if DEBUGASSERT is
  disabled, we will never rendezvous with completion of the
  test. (Two instances of this fix.)

arch/arm/src/tms570/tms570_clockconfig.c:
* In function tms570_clockconfig(), call
  tms570_efc_selftest_complete() outside of the DEBUGASSERT()
  for the same reason as above.

boards/arm/sam34/sam4s-xplained-pro/src/sam_boot.c:
* In function board_late_initialize(), call
  sam_watchdog_initialize() outside of the DEBUGASSERT() for
  the same reason as above.
2020-04-12 15:49:35 -06:00
Gregory Nutt
72104c182c nxstyle fixes
Run all files modified by PR 766 through nxstyle and fix any resulting complaints.

NOTE:  Numerous "Mixed case identifier" errors in arch/arm/src/cxd56xx/cxd56_gnss.c were not fixed because this problem is of much larger scope than this file.
2020-04-11 21:19:47 +01:00
Gregory Nutt
67ec3d7926 Remove CONFIG_CAN_PASS_STRUCT
This commit resolves issue #620:

Remove CONFIG_CAN_PASS_STRUCTS #620

The configuration option CONFIG_CAN_PASS_STRUCTS was added many years ago to support an old version of the SDCC compiler. That compiler is currently used only with the Z80 and Z180 targets. The limitation of that old compiler was that it could not pass structures or unions as either inputs or outputs. For example:

    #ifdef CONFIG_CAN_PASS_STRUCTS
    struct mallinfo mallinfo(void);
    #else
    int      mallinfo(FAR struct mallinfo *info);
    #endif

And even leads to violation of a few POSIX interfaces like:

    #ifdef CONFIG_CAN_PASS_STRUCTS
    int  sigqueue(int pid, int signo, union sigval value);
    #else
    int  sigqueue(int pid, int signo, FAR void *sival_ptr);
    #endif

This breaks the 1st INVIOLABLES rule:

Strict POSIX compliance
-----------------------

  o Strict conformance to the portable standard OS interface as defined at
    OpenGroup.org.
  o A deeply embedded system requires some special support.  Special
    support must be minimized.
  o The portable interface must never be compromised only for the sake of
    expediency.
  o Expediency or even improved performance are not justifications for
   violation of the strict POSIX interface

Also, it appears that the current SDCC compilers have resolve this issue and so, perhaps, this is no longer a problem: z88dk/z88dk#1132

NOTE:  This commit cannot pass the PR checks because it depends on matching changes to the apps/ directory.
2020-04-11 21:19:47 +01:00
liuhaitao
459ad99373 Use EXTRAFLAGS instead of EXTRADEFINES to be used by make via command line
So call 'make EXTRAFLAGS=-Wno-cpp' could suppress the warnings with pre-processor
directive #warning in GCC.

Change-Id: Iaa618238924c9969bf91db22117b39e6d2fc9bb6
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-04-11 08:31:08 -06:00
John Rippetoe
2f54204035 Fixed some nxstyle errors 2020-04-11 13:53:20 +08:00
John Rippetoe
acb16e087a Fixes build issues associated with ARMv7-m mpu support files.
- inline functions within mpu.h converted to macros or moved to up_mpu.c
- mpu.h and up_mpu.c are now conditionally included in build via CONFIG_ARM_MPU

Chips affected by these changes
- imxrt
- kinetis
- lpc17xx
- lpc43xx
- lpc54xx
- sam34
- stm32
- stm32f7
- stm32h7
- stm32l4
- tiva
- xmc4
2020-04-11 13:53:20 +08:00
ligd
cbf31bca5c global change: fix tools/checkpatch.sh warnnings
Change-Id: I88cfa979c44bcaf3a8f6e036c6bfccd3402ca85a
Signed-off-by: ligd <liguiding@fishsemi.com>
2020-04-09 10:29:28 -06:00
ligd
231ad202ee global change: repace sched_xfree() to kxmm_free()
Changes:
sched_xfree() => kxmm_free()
remove garbage related APIs
remove ARCH_HAVE_GARBAGE

Cause garbage feature move to mm_heap, then don't need
garbage anymore.

Change-Id: If310790a3208155ca8ab319e8d038cb6ff92c518
Signed-off-by: ligd <liguiding@fishsemi.com>
2020-04-09 10:29:28 -06:00
Alin Jerpelea
425e6c28dc
arch: xtensa: esp32: nxstyle fixes (#753)
esp32 nxstyle fixes

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2020-04-08 08:28:17 -06:00
hartmannathan
bfc153ca27
Fix typos in comments and documentation (#750)
* Fix typos in comments and documentation
2020-04-08 06:45:35 -06:00
Alin Jerpelea
402fb16a77 arch: arm: cxd56xx: nxstyle fixes
nxstyle fixes for cxd56xx

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2020-04-07 07:27:41 -06:00
Nakamura, Yuuichi
9029e4daee Fix nxstyle issues 2020-04-07 06:23:15 -06:00
Nakamura, Yuuichi
e264484c16 Remove type casting to wdentry_t (arch/) 2020-04-07 06:23:15 -06:00
Gregory Nutt
81b286d375 Fix some long single line comments.
This commit fixes some long single line comments.  This effort was primarily intended to verify the change to tools/nxstyle of PR #743 further.  This took the files changed with 1501d284c3 and ran them through nxstyle again.  The files in the commit previously passed the old nxstyle test with no complaints.  The current nxstyle, on the other hand, reported 49 long single line comments.  Each of those were verified and the file was updated.  The nxstyle change appears completely reliable.
2020-04-06 22:04:38 +01:00
Alin Jerpelea
c78bd930b5 arch: arm: sxd56xx: nxstyle fixes
Fix nxstyle complains

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2020-04-06 20:49:54 +08:00
Nathan Hartman
679b4fbee2 arch: Fix included directed -> included directly
This typo had been copied and pasted into numerous irq and syscall
headers.
2020-04-05 22:31:15 +01:00
Ouss4
a5c619c207 arch/arm/src/cxd56xx/cxd56_emmc.c: Don't wait for the semaphore if the
task was canceled.
2020-04-05 15:02:23 -06:00
Ouss4
dda47dd4a9 Check return from nxsem_wait_uninterruptible()
This commits is for the remaining files in arch/arm/src/cxd56xx
  arch/arm/src/imxrt and arch/arm/src/stm32l4
2020-04-05 12:26:45 -06:00
Gregory Nutt
5d123098b8 Check return from nxsem_wait_uninterruptible()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is for all remaining drivers in the LC823450 architectures.
2020-04-05 18:18:25 +01:00
Gregory Nutt
e19246fe94 Correct the naming of some new functions.
Serval private functions were added with a name ending with _uninterruptible.  That is not correct.  These new functions should be named _noncancelable.
2020-04-05 12:32:04 -03:00
Gregory Nutt
6a43282197 Check return from nxsem_wait_uninterruptible()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is for all remaining drivers in the Atmel SAM architectures.
2020-04-05 12:32:04 -03:00
Gregory Nutt
7837eec33f Fix style problems noted by nxstyle for this PR
NOTES:
- arch/arm/src/sama5/sam_can.c:  Generates several "Mixed case identifier" complaints because definitions provided by header files that are not part of the change.
- arch/arm/src/sama5/sam_pmecc.c:  Has two cases of "Mixed case identifies" result within commented out code.  There are references to undefined types that might be provided by Atmel logic (Pmecc and Pmerrloc) if it were ever integrated.
2020-04-05 12:32:04 -03:00
Gregory Nutt
d95d641597 Check return from nxsem_wait_uninterruptible()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is for all HCI UART drivers under arch/.
2020-04-04 23:55:45 +01:00
Ouss4
8f85a57941 Check the return of nxsem_wait_unterruptible()
This commit is for all tc drivers under arch/.
2020-04-04 16:50:20 -06:00
Ouss4
dc96287d27 Check the return of nxsem_wait_uninterruptible()
This commit is for all bbsram drivers under arch/.
2020-04-04 15:37:12 -06:00
Gregory Nutt
42790f1412 Check return from nxsem_wait_uninterruptible()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is for all I2S/SSC drivers under arch/.
2020-04-04 22:36:49 +01:00
Ouss4
d910a71981 Check the return of nxsem_wait_uninterruptible() (#724)
This commit is for all flash/progmem drivers under arch/.
2020-04-04 14:57:22 -06:00
Alan Carvalho de Assis
bcbe5646eb
Fix nxstyle stm32l4 (#726)
* Fix nxstyle to stm32l4 dma and rcc
* Fix nxstyle for usbhost, userspace, wdg, rcc, etc
* Fix nxstyle reported errors on stm32l4_usbdev.[ch]
2020-04-04 14:41:34 -06:00
Gregory Nutt
6009d213a4 samd2l1/samd5e5: Eliminate warnings.
In the sam_usb.c file for these two architectures, the USB suspend() operation is implemented, but never called from anywhere.  This logic might be valuable in the future for for now it just causes errors due to the unused static function.

This commit just disables the suspend() logic with #if 0 to eliminate the error.  The suspend logic is, however, still preserved in case it is needed in the future.
2020-04-04 20:52:08 +01:00
Gregory Nutt
1501d284c3 Check return from nxsem_wait_uninterruptible()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is for all SDIO card drivers under arch/.
2020-04-04 20:00:04 +01:00
Gregory Nutt
a6e69a82ad SDIO: Make interface field names conform to standard.
The SDIO interface structure includes fields with names like recvR1 and others.  These cause "Mixed case identifier" errors from nxstyle in all places they are uses.
This change performs a mass substition of recvR with recv_r to correct this coding standard violation.
2020-04-04 18:15:25 +01:00
Alan Carvalho de Assis
de188fbe85
Fix nxstyle to stm32l4 files (#721)
* Fix nxstyle for usbhost, userspace, wdg, rcc, dma, rcc etc
2020-04-04 09:50:33 -06:00
Alan Carvalho de Assis
460124629c Kinetis lpc sdcard (#719)
* Check return of nxsem_wait_uninterruptible
* Fix nxstyle reported errors

Note: It will not pass on CI tests because of it:

    .recvR1           = lpc17_40_recvshortcrc,
    .recvR2           = lpc17_40_recvlong,
    .recvR3           = lpc17_40_recvshort,
    .recvR4           = lpc17_40_recvnotimpl,
    .recvR5           = lpc17_40_recvnotimpl,
    .recvR6           = lpc17_40_recvshortcrc,
    .recvR7           = lpc17_40_recvshort,
2020-04-03 20:29:31 -06:00
raiden00pl
df1eeb8e3f arch/arm/src/nrf52: add initial interface to work with on-chip radio 2020-04-03 18:22:55 -06:00
Ouss4
952e7f6e17 Check the return of nxsem_wait_uninterruptible().
This commit is for the DMA files under arch/ that were missing from an
earlier PR.
2020-04-03 17:56:59 -06:00
Gregory Nutt
7dbcc71e0d Check return from nxsem_wait_uninterruptible()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is for all USB host drivers under arch/.
2020-04-03 23:45:33 +01:00
raiden00pl
8876bd8ebc arch/arm/src/stm32/stm32_pwm.c: fix nxstyle issues 2020-04-03 15:29:14 -06:00
raiden00pl
ae31b1f926 arch/arm/src/stm32/stm32_pwm.h: fix nxstyle issues 2020-04-03 15:29:14 -06:00
raiden00pl
8988251814 arch/arm/src/stm32/stm32_adc.h: fix nxstyle issues 2020-04-03 15:29:14 -06:00
Daniel Agar
4fa26d34d6 stm32f7/h7 spi add missing ret declaration 2020-04-03 15:25:49 -06:00
David Sidrane
fc3ab3e085 stm32h7:Fix DMA Overrun error 2020-04-03 10:50:25 -06:00
David Sidrane
c191787ba4 stm32h7:spi Add buffers for DMA 2020-04-03 10:50:25 -06:00
Alan Carvalho de Assis
96dc3308f4 Fix nxstyle reported errors 2020-04-03 10:45:14 -06:00
Alan Carvalho de Assis
4017dbfdd3 Check return of nxsem_wait_uninterruptible 2020-04-03 10:45:14 -06:00
Ouss4
428131efd0 arch/mips/src/pic32mz/pic32mz-ethernet.c: Fix style issues. 2020-04-03 10:42:43 -06:00
Alin Jerpelea
06910819e5 arch: arm: cxd56xx: nxstyle updates
Fix nxstyle complains

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2020-04-03 11:49:35 +01:00
Ouss4
a447ec616d Check return from nxsem_wait_uninterruptible()
This commits is for all 1wire drivers under arch/
2020-04-02 19:42:07 -06:00
Ouss4
13b229a9eb Check return from nxsem_wait_uninterruptible()
This commit is for all ADC/DAC drivers under arch/.
2020-04-02 17:37:46 -06:00
Gregory Nutt
4892c27b4a Check return from nxsem_wait_uninterruptible()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is for all SPI drivers under arch/.
2020-04-02 16:26:15 +01:00
Ouss4
4d771c2bcf Check return from nxsem_wait_uninterruptible()
This commit is for all DMA drivers under arch/.
2020-04-02 09:06:09 -06:00
Gregory Nutt
fc467021cf Check return from nxsem_wait_initialize()
Resolution of Issue 619 will require multiple steps, this part of the first step in that resolution:  Every call to nxsem_wait_uninterruptible() must handle the return value from nxsem_wait_uninterruptible properly.  This commit is for all I2C drivers under arch/.
2020-04-02 00:46:06 +01:00
Alan Carvalho de Assis
30ca00c0a9
Check for return of nxsem_wait_uninterruptible. This commit is for files under arch/sim 2020-04-01 19:50:39 +01:00
Xiang Xiao
836fef358b
arch/arm: include chip.h in up_checkstack.c/up_initialize.c (#668) 2020-03-31 21:33:45 +01:00
YAMAMOTO Takashi
c009927deb Appease nxstyle complaints 2020-04-01 00:03:31 +08:00
YAMAMOTO Takashi
4ddb457c3e Fix a typo in comments 2020-04-01 00:03:31 +08:00
YAMAMOTO Takashi
f8f5830410 xtensa: Implement CONFIG_ARCH_IDLE_CUSTOM 2020-03-31 15:50:04 +08:00
YAMAMOTO Takashi
123b3d92df xtensa: Check XCHAL_HAVE_INTERRUPTS for waiti 2020-03-31 14:32:07 +08:00
YAMAMOTO Takashi
b9bf9c9a2b xtensa: Save PS correctly in coproc handler
"EPS" is not a real register. It's just a base value of EPS_{2..7}.
2020-03-31 14:31:31 +08:00
YAMAMOTO Takashi
d2a6e56308 xtensa: Save PS correctly in double exception handler
"EPS" is not a real register. It's just a base value of EPS_{2..7}.
2020-03-31 14:31:31 +08:00
YAMAMOTO Takashi
18d3fa9eea xtensa: Save PS correctly in syscall handler
"EPS" is not a real register. It's just a base value of EPS_{2..7}.
2020-03-31 14:31:31 +08:00
YAMAMOTO Takashi
40d7f83e31 sim: Appease a few prototype warnings 2020-03-28 12:08:57 +01:00
raiden00pl
d217b3a889 arch/arm/src/nrf52: fix coding standard issues 2020-03-27 12:51:54 -06:00
raiden00pl
fef7abb598 arch/arm/src/nrf52/nrf52_i2c.c: protect the I2C transfer with a semaphore 2020-03-27 12:51:54 -06:00
YAMAMOTO Takashi
a493c92826 sim: Use executable memory for the heap
On modern environments, bss is not executable.

Alternatively we can use the ARCH_HAVE_MODULE_TEXT mechanism.
But it's considered overkill for the sim, which is mainly
for development.
2020-03-27 00:04:36 -05:00
YAMAMOTO Takashi
d6d03d64d5 sim: Hide strerror/strerror_r 2020-03-25 21:35:17 -06:00
YAMAMOTO Takashi
27aa16111c sim: hostfs: Stop assuming CONFIG_NAME_MAX=32 2020-03-25 20:31:32 -06:00
YAMAMOTO Takashi
f89ccf873e sim: host_readdir: Ensure NUL termination when truncating d_name 2020-03-25 20:31:32 -06:00
Andrey Zabolotnyi
3ff956dc00
stm32h7: support SDRAM via FMC peripherial (#459)
* stm32h7: Add support for SDRAM connected to FMC

* stm32h7: nxstyle fixes in stm32_fmc.h and stm32h7x3xx_rcc.{c,h}
2020-03-25 08:34:15 -07:00
YAMAMOTO Takashi
2991836ee8 sim: Appease nxstyle errors 2020-03-25 00:09:21 -05:00
Xiang Xiao
3f860280e5 arm/common: Fix nxstyle issue in arch/arm/src/common/up_checkstack.c
and arch/arm/src/common/up_initialize.c
2020-03-24 10:50:02 +00:00