Commit Graph

37394 Commits

Author SHA1 Message Date
vau
20615a9f65 Do not rewrite the root directory if it has not changed 2020-05-31 09:08:22 -06:00
Gregory Nutt
18e4ab99cb Makefile: Build the tools/incdir binary immediately.
Before any other Make logic can be used, we must immediately build the tools/incdir binary.  It will be used as soon as Make.defs is included and will generate errors otherwise.

Remove the other locations in the tools/incdir binary was being build from tools/Makefile.unix and tools/Makefile.win
2020-05-31 15:05:23 +01:00
Ouss4
e018309e47 tools/Makefile*: Clean tools binaries at the end of distclean. 2020-05-31 15:05:23 +01:00
Gregory Nutt
8190041472 boards/mips: Leverage PR 1150 to MIPS make.defs. 2020-05-31 10:15:22 -03:00
Gregory Nutt
1414c55c45 boards/arm: Leverage PR 1150 to other ARM Make.defs 2020-05-30 20:09:02 +01:00
Gregory Nutt
5d540f45da boards/arm/stm32/stm32f4discovery/scripts/Make.defs: Pre-calculate include paths
This is a change suggested by Xiao Xiang in an email thread.  Some make variables with depend on forking and shell and running a script to get the value of the variable.  Using := we can force the calculation to occur only once.  This leads to a small but consistent improvement in build performance.

This change really applies to ALL Make.defs files but is applied only to one here so that it can be thoroughly verified and possbily leveraged to other Make.defs files in the future.
2020-05-30 17:17:23 +01:00
Gregory Nutt
e92c91cf09 tools/incdir.c: Various fixes to get a clean build
1. If config.c is compiled on any platform other than Cygwin, then the variable wintools is not used.
2. Add more debug output so we can see what is going on in the PR checks.
2020-05-30 01:05:34 +01:00
Gregory Nutt
5555070fc3 tools/: Hook incdir.c into build system.
incdir.c was added in PR 1148.  This PR hooks it into the build system.
2020-05-30 01:05:34 +01:00
Gregory Nutt
981734e577 tools/Makefile.host: Add incdir binary to Makefile.host
This was missed in PR 1148
2020-05-30 01:05:34 +01:00
Gregory Nutt
b111e135e0 tools/incdir.c: Add faster, C version of incdir.sh 2020-05-29 17:16:42 -03:00
David Sidrane
1b8c072802 stm32h7:stm32_spi Restores internal DMA buffer broken in 574b25
574b25 broke the internal DMA buffers usage that solved
   the following problem: The DMA capable interface does
   not know the buffers extent. It calulates it from size.
   The user may need to transfer less than a cachline bytes,
   but STILL have a DMA cabable buffer. The user is therefore
   foreced to transfer more data then needed to "trick" the
   DMA cabable function. This is a wast of bus bandwith and
   may not work will all devices. The internal buffer, solve
   this issue.

stm32h7:stm32_spi review changes

   Added sugestion from jlaitine to support RX only.
2020-05-29 13:08:18 -07:00
RB
f47151f8a7 Updated Rx65n rtc for non CONFIG_RTC_HIRES
Added support for non CONFIG_RTC_HIRES
2020-05-28 16:16:25 -06:00
Gregory Nutt
738f3c61f7 drivers/usbhost/usbhost_ft232r.c: Cosmetic
Cosmetic changes to alignment.  Also fixes some C89 non-compliance.  Sorry to be so OCD.
2020-05-28 21:17:58 +01:00
Gregory Nutt
5a9f7927ee nxstyle fixes 2020-05-28 12:22:46 -06:00
Nicholas Chin
560ba3adcd usbhost: adds a driver for the FTDI FT232R USB to serial converter 2020-05-28 12:22:46 -06:00
Erdem Meydanli
20ef084712 Fix the indentation and spacing that don't conform to the coding standard. 2020-05-28 12:22:23 -06:00
Erdem Meydanli
7f018e7898 fs/nfs/nfs_proto.h: Use of uint64_t in the data types breaks NFS functionality.
The use of uint64_t primitive type in NFS structures forces the compiler to align data on an 8-byte boundary.
As a result of this, unwanted gaps being created, which causes NFS to fail. (e.g., nfs_read/initialize the request)
Using nfsuint64 instead of uint64_t fixes this issue.
2020-05-28 12:22:23 -06:00
Gregory Nutt
1c002e1049 fs/vfs/fs_fstat: Correct fstat() for proxied block and MTD drivers.
Block and MTD drivers may be opened and managed as though they were character drivers.  But this is really sleight of hand; there is a hidden character driver proxy that mediates the interface to the block and MTD drivers in this case.

fstat(), however, did not account for this.  It would report the characteristics of the proxy character driver, not of the underlying block or MTD driver.

This change corrects that.  fstat now checks if the character driver is such a proxy and, if so, reports the characteristics of the underlying block or MTD driver, not the proxy character driver.
2020-05-28 17:34:09 +01:00
Jukka Laitinen
48c88f2af3 arch/arm/src/stm32h7: Add the spi slave bus control driver
This is a work in progress, and now only serves as
DMA enabled simplex RX-only mode bus controller

Signed-off-by: Jukka Laitinen <jukka.laitinen@intel.com>
2020-05-28 05:14:38 -07:00
Jukka Laitinen
b2a9a8cf81 arch/arm/src/samv7/sam_spi_slave.c: Change for modified spi slave interface
Signed-off-by: Jukka Laitinen <jukka.laitinen@intel.com>
2020-05-28 05:14:38 -07:00
Jukka Laitinen
e030047f45 update to SPI slave intefaces
Make it possible to enqueue and receive full buffers of data with
single call, to avoid call overhead when sending / receiving large amounts
of data.

Also make it possible for the slave device to leave received data in the
controller receive buffers and retrieve it from there by polling

Signed-off-by: Jukka Laitinen <jukka.laitinen@intel.com>
2020-05-28 05:14:38 -07:00
Jukka Laitinen
8d3c9a8773 arch/arm/src/stm32h7/stm32_spi.h: Split long lines
Signed-off-by: Jukka Laitinen <jukka.laitinen@intel.com>
2020-05-28 05:14:38 -07:00
liuhaitao
102c4c25e2 tools/testbuild.sh: Call makefunc with JOPTION directly
Also call configure.sh with JOPTION to enable parallel build

Change-Id: I32c4e77fb30c40d8d424159cc0871b8c3e3f10b6
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-05-28 20:01:45 +08:00
liuhaitao
b5dc83748c build: Update make dependency to enable 'configure.sh config' parallel build
Note that 'configure.sh config -jn' with parallel build could reduce configure stage
time.

Change-Id: I3d63f1e316a7bc3437fc6c6c2da13c5313e69694
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-05-28 20:01:45 +08:00
Gregory Nutt
124e6ee53d sched/sched/sched_releasetcb.c: Handle custom stack allocations.
sched_releasetcb() will normally free the stack allocated for a task.  However, a task with a custom, user-managed stack may be created using nxtask_init() followed by nxtask_activer.  If such a custom stack is used then it must not be free in this many or a crash will most likely result.

This chagne addes a flag call TCB_FLAG_CUSTOM_STACK that may be passed in the the pre-allocted TCB to nxtask_init().  This flag is not used internally anywhere in the OS except that if set, it will prevent sched_releasetcb() from freeing that custom stack.
2020-05-27 20:00:14 +01:00
Gregory Nutt
b9042f5900 sched/task/task_init.c: Add nxtask_uninit()
Add trivial function nxtask_uninit().  This function will undo all operations on a TCB performed by task_init() and release the TCB by calling kmm_free().  This is intended primarily to support error recovery operations after a successful call to task_init() such was when a subsequent call to task_activate fails.

That error recovery is trivial but not obvious.  This helper function should eliminate confusion about what to do to recover after calling nxtask_init()
2020-05-27 17:53:46 +01:00
Gregory Nutt
d2f10e7386 sched/task/task_create.c: Correct logic in error handling
After nxtask_setup_arguments() is called, the task must be removed from the active task list in order to properly recover from any error condition.
2020-05-27 17:53:46 +01:00
liuhaitao
2aa1f5c765 Remove the copied locked.r file in clean stage
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-05-27 07:22:19 -06:00
liuhaitao
954d251dfe build: make sure nuttx bins generated after both pass1 and pass2 built done
Create the final NuttX executables after pass1 user libs and pass2 nuttx
libs built finished.

Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-05-27 06:28:05 -06:00
Xiang Xiao
f90968ace4 stddef.h: Add max_align_t typedef
defined by C11:
https://en.cppreference.com/w/c/types/max_align_t

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I6f6094d054c475031ff83f648aa43f482d86b930
2020-05-27 05:40:37 -06:00
Masayuki Ishikawa
3f88f57666 arch: imxrt: Fix style violations in imxrt_clockconfig.c 2020-05-26 16:30:04 +02:00
Masayuki Ishikawa
8dda796e6a arch: imxrt: Set the low power mode to 'remain in run mode'
NOTE: now imxrt can wake up from wfi
2020-05-26 16:30:04 +02:00
liuhaitao
6a9b3de0bb tools/testbuild.sh: fix testbuild.sh called without -e option fail issue
As in https://github.com/apache/incubator-nuttx/issues/1114 discuss, let
EXTRA_FLAGS="EXTRAFLAGS=" defaultly to avoid testbuild.sh called without
-e option fail issue. It also works well with -e "-Wno-cpp -Werror".

Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-05-26 07:03:21 -06:00
JacobCrabill
a4012bffa8 stm32h7:stm32h7x3xx_rcc Select FDCAN clock source 2020-05-26 03:57:34 -07:00
Oleg Evseev
3b75201447 fs/vfs/fs_stat.c: correct style 2020-05-26 16:56:10 +08:00
liuhaitao
56e7a906e5 build: exit normaly once catch 'make depend' and 'make context' failure case
To be strict in check build, once any 'make depend' or 'make context' fails, exit normally.

Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-05-26 15:39:34 +08:00
Kazuya Hioki
075334cfcc drivers: wireless: Fix buffer overrun in gs2200m.c
Warning ID: 85719.12039200

Reviewed-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
Signed-off-by: Kazuya Hioki <Kazuya.Hioki@sony.com>
2020-05-26 15:38:43 +08:00
YAMAMOTO Takashi
4f1258f727 sama5: Disable CONFIG_NETUTILS_NETLIB_GENERICURLPARSER for a config
There is no clear reason why this option is enabled here.

This is a preparation for
https://github.com/apache/incubator-nuttx-apps/pull/278
2020-05-26 10:37:48 +08:00
Gregory Nutt
82debdc213 Make task_init() and task_activate() internal OS functions.
-Move task_init() and task_activate() prototypes from include/sched.h to include/nuttx/sched.h.  These are internal OS functions and should not be exposed to the user.
-Remove references to task_init() and task_activate() from the User Manual.
-Rename task_init() to nxtask_init() since since it is an OS internal function
-Rename task_activate() to nxtask_activate since it is an OS internal function
2020-05-25 23:54:45 +01:00
Oleg
dd9d9878ad fs/vfs/fs_stat.c: fill file size for mtd inode
Now when stat() is calling for mtd device it also set size of file as number of bytes of all sectors related to this mtd device.
2020-05-25 13:53:50 -06:00
Gregory Nutt
fefd893b65 fs/nfs/nfs_util.c: Fix compilation error
The build gets broken when both the NFS and DEBUG_FS_ERROR configurations enabled. This tiny change fixes the compilation error.

Run file through nxstyle and correct issues.

NOTE:  This line:

    /* This logic just supports "//" sequences in the path name */

generates the false alarm error:

    fs/nfs/nfs_util.c:84:39: error: C++ style comment
2020-05-25 13:45:28 -06:00
Nathan Hartman
8188171a1b b-g474e-dpow1: Apply recent build script changes
boards/arm/stm32/b-g474e-dpow1/scripts/Make.defs:

    * Apply the recent build script changes introduced in the
      following git commits:
      - 7e5b0f81e9 and
      - e83c1400b6
      to this board. Namely, factor the definitions of ARCHINCLUDES
      and ARCHXXINCLUDES out of CONFIG_CYGWIN_WINTOOL conditional,
      and use new build variable BOARD_DIR to simplify ARCHSCRIPT.
2020-05-25 12:35:03 -06:00
Yang Chung-Fan
9345cb5553 arch: x86: Set the idle task stack to prevent get/set errno on idle task resulting NULL reference 2020-05-25 11:18:03 -06:00
Oleg
e1dbb6b2a9 Update fs/vfs/fs_stat.c
Co-authored-by: patacongo <spudarnia@yahoo.com>
2020-05-25 10:10:52 -06:00
Oleg
f6c3296f76 fs/vfs/fs_stat.c: fill file size for block inode 2020-05-25 10:10:52 -06:00
Xiang Xiao
37685110cb arch/sim: Fix hostfs.h No such file or directory in makedep
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-25 09:34:47 -06:00
raiden00pl
d66cb505a5 nrf52: add workaround to SPI Master 1 Byte transfer anomaly 2020-05-25 08:12:14 -06:00
Xiang Xiao
8b20b97d26 build: Remove the dummy drivers folder under boards
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-24 20:20:12 +01:00
Xiang Xiao
e83c1400b6 build: Move BOARD_DIR definition to common place
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-24 20:20:12 +01:00
Xiang Xiao
7e5b0f81e9 build: Replace -I with INCDIR
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-24 20:20:12 +01:00