Commit Graph

17 Commits

Author SHA1 Message Date
WangQixiang
c9c8633cba add the definition of MAXNAMLEN in sys/dirent.h 2021-05-12 16:07:19 +08:00
KonstantinKondrashov
aec5776091 newlib: Fix a case in FD_ISSET macro when n==-1 2021-01-06 20:54:24 +00:00
Ivan Grokhotkov
b7b9ea4361 newlib: add _RETARGETABLE_LOCKING support
This adds support for the retargetable locking implementation in
newlib 3. This feature will be enabled in the future toolchain builds.
With the present version of the toolchain, this code doesn't get used.

When _RETARGETABLE_LOCKING gets enabled, newlib locking implementation
will be modified as follows:

- Legacy ESP-specific _lock_xxx functions are preserved. This is done
  because ROM copies of newlib in ESP32 and ESP32-S2 rely on these
  functions through the function pointer table. Also there is some
  code in IDF which still uses these locking functions.

- New __retarget_lock_xxx functions are introduced. Newlib expects
  these functions to be provided by the system. These functions work
  pretty much the same way as the ESP-specific _lock_xxx functions,
  except one major difference: _lock_acquire receives the lock pointer
  by value, and as such doesn't support lazy initialization.

- Static locks used by newlib are now explicitly initialized at
  startup. Since it is unlikely that these static locks are used at
  the same time, all compatible locks are set to point to the same
  mutex. This saves a bit of RAM. Note that there are still many locks
  not initialized statically, in particular those inside FILE
  structures.
2020-12-29 16:18:04 +01:00
Angus Gratton
420aef1ffe Updates for riscv support
* Target components pull in xtensa component directly
* Use CPU HAL where applicable
* Remove unnecessary xtensa headers
* Compilation changes necessary to support non-xtensa gcc types (ie int32_t/uint32_t is no
  longer signed/unsigned int).

Changes come from internal branch commit a6723fc
2020-11-13 07:49:11 +11:00
Angus Gratton
66fb5a29bb Whitespace: Automated whitespace fixes (large commit)
Apply the pre-commit hook whitespace fixes to all files in the repo.

(Line endings, blank lines at end of file, trailing whitespace)
2020-11-11 07:36:35 +00:00
Ivan Grokhotkov
45e50f1f2a newlib: move dirent.h, ioctl.h headers from VFS 2020-03-20 13:43:42 +01:00
Roland Dobai
43eb58da99 VFS: Fix Kconfig prefix 2019-07-02 17:17:18 +02:00
Ivan Grokhotkov
d15e18aa5d newlib: fixes for compatibility with newlib 3.0 2019-04-10 13:48:57 +08:00
Ivan Grokhotkov
068b700786 newlib: remove usage of pre-ANSI defines 2019-03-19 22:15:26 +08:00
Ivan Grokhotkov
ac612b5422 newlib: enable timeradd, timersub, and similar macros
This uses a hack (temporarily defining __rtems__ from a wrapper header
file) to include timeradd, timersub, and similar macros, without
modifying newlib headers.
2019-03-19 22:15:12 +08:00
Roland Dobai
aa9d302814 VFS: Implement poll() based on select()
Closes https://github.com/espressif/esp-idf/issues/2945
2019-02-25 10:34:27 +01:00
Roland Dobai
fb334baa7c VFS: Implement utime() 2018-11-05 09:54:01 +01:00
Roland Dobai
5395435816 Add basic support for termios.h
Closes https://github.com/espressif/esp-idf/issues/2063
2018-08-30 14:29:20 +02:00
Roland Dobai
ce3cb5c3aa expat: add source of entropy 2018-08-02 11:02:45 +02:00
David Cermak
1ef13c524c asio: initial idf port of asio library without ssl 2018-07-30 06:28:43 +00:00
Renz Bagaporo
ea711f2ee9 vfs, fatfs: Add file truncate for fatfs 2018-06-14 06:37:21 +08:00
Roland Dobai
e86738205d Fix redefinition of select() on platforms where ESP_PLATFORM is discarded
Ref: https://github.com/espressif/esp-idf/issues/1987
2018-05-25 13:37:43 +00:00