Alin Jerpelea
861c0071bd
include: nuttx: fix nxstyle errors
...
Fix nxstyle errors to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-02-04 03:33:58 -08:00
Alin Jerpelea
a8a1308240
include: nuttx: update licenses to Apache 2.0
...
The SGA from Gregory Nutt had been submitted and we can replace
the licenses to Apache 2.0
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-02-01 11:21:57 -03:00
Alin Jerpelea
88a48bbde3
include: nuttx: sensors: max31855.h: fix nxstyle errors
...
Nxstyle errors fix to pass CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-02-01 11:21:57 -03:00
Alin Jerpelea
d49e0f56c6
include: nuttx: net: telnet.h: fix nxstyle errors
...
Nxstyle errors fix to pass CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-02-01 11:21:57 -03:00
Alin Jerpelea
3a566af4bb
include: nuttx: addrenv.h: fix nxstyle errors
...
Nxstyle errors fix to pass CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-02-01 11:21:57 -03:00
Alin Jerpelea
b288986ccd
include: nuttx: usb: nxstyle error fix
...
Nxstyle error fix to silence the CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-29 10:40:46 -08:00
Alin Jerpelea
30a5a3edad
include: nuttx: timers: nxstyle error fix
...
Nxstyle error fix to silence the CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-29 10:40:46 -08:00
Alin Jerpelea
3bdf98cc33
include: nuttx: syslog: nxstyle error fix
...
Nxstyle error fix to silence the CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-29 10:40:46 -08:00
Alin Jerpelea
419bcb05d5
include: nuttx: spi: nxstyle error fix
...
Nxstyle error fix to silence the CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-29 10:40:46 -08:00
Alin Jerpelea
83ebb6448c
include: nuttx: serial: nxstyle error fix
...
Nxstyle error fix to silence the CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-29 10:40:46 -08:00
Alin Jerpelea
fa10244ccb
include: nuttx: power: nxstyle error fix
...
Nxstyle error fix to silence the CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-29 10:40:46 -08:00
Alin Jerpelea
2b6cad5178
include: nuttx: net: nxstyle error fix
...
Nxstyle error fix to silence the CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-29 10:40:46 -08:00
Alin Jerpelea
fe4be428f5
include :nuttx: nxstyle error fix
...
Nxstyle error fix to silence the CI.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-29 10:40:46 -08:00
Alin Jerpelea
822fbe5c10
drivers: mtd: mtd_nandscheme: mix case identifier fix
...
nxstyle fix for mix case identifier.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-27 18:40:00 -08:00
Alan C. Assis
f63e1e277f
Add generic support to LWL Console
2021-01-26 18:21:28 -08:00
Alin Jerpelea
90ffb03903
include: nuttx: nx: nxstyle fixes
...
Nxstyle fixes to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
95ed9fc576
include: nuttx: lib: nxstyle fixes
...
Nxstyle fixes to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
785cb0dffe
include: nuttx: lcd: nxstyle fixes
...
Nxstyle fixes to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
647adf9fcc
include: nuttx: mtd: nxstyle fixes
...
Nxstyle fixes to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
8c5044fa4a
include: nuttx: mm: nxstyle fixes
...
Nxstyle fixes to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
9491f4a9f1
include: nuttx: video: nxstyle fixes
...
Nxstyle fixes to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
f29beab982
include: nuttx: leds: nxstyle fixes
...
Nxstyle fixes to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
408e612353
include: nuttx: ioexpander: nxstyle fixes
...
Nxstyle fixes to pass CI
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
1824894feb
include: nuttx: replace licenses with Apache 2.0
...
This change is a license change to Apache 2.0 license.
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-26 05:11:58 -08:00
Alin Jerpelea
b11b27d177
include: nuttx: input: fix nxstyle errors
...
Fix nxstyle violations for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
2b3ad7c405
include: nuttx: i2c: fix nxstyle errors
...
Fix nxstyle violations for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
0157f9cc6d
include: nuttx: sensors: nxstyle fixes
...
Fix nxstyle violations for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
4c2920e760
include: nuttx: fs: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
265f758f57
include: nuttx: eeprom: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
0aa932a062
include: nuttx: drivers: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
47141edb27
include: nuttx: crypto: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
cb92444802
include: nuttx: contactless: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
2901b8d1cf
include: nuttx: can: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
186c2bbe44
include: nuttx: binfmt: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
36da2e2bc3
include: nuttx: analog: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Alin Jerpelea
59f4e27a67
include: nuttx: 1wire: fix nxstyle errors
...
Fix nxstyle errors for headers
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-01-25 08:26:44 -08:00
Matias N
0fa34a0b64
drivers: add generic i2c bitbang driver
2021-01-24 19:03:56 -08:00
Matias N
76cc5c36e4
bmp280: convert to common sensor interface
2021-01-18 21:08:34 -03:00
Matias N
42b6c665da
sensor: change set_interval to use a value, not a pointer to value
2021-01-18 21:08:34 -03:00
Xiang Xiao
9103184722
bluetooth: Rename *bt_uart_shim_getdevice to btuart_shim_getdevice
...
follow other bluetooth driver convention(e.g. btuart_register)
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-01-17 20:49:19 -08:00
chao.an
92259cb194
netpacket/if_addr: add interface address header
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-16 22:52:39 -08:00
chao.an
c8a6f31a33
wireless/bluetooth: move H4_* definition to external
...
Reference the define from board or arch driver
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-16 11:18:26 -08:00
chao.an
f308ac1583
wireless/bluetooth: add more hci event definitions
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-16 11:18:26 -08:00
chao.an
605cd77a23
wireless/bluetooth: remove the host dependency
...
HCI driver should not depend on the bluetooth host
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-16 11:18:26 -08:00
Alan C. Assis
154949403c
Add generic efuse driver for NuttX
...
Squashed commits:
Fix small typos on efuse driver
Fix nxstyle issues
Fix aligment and missing FAR
Improvements to efuse driver
Fix: don't free 'lower' on efuse_unregister
Describe the efuse_param
Remove upper pointer from lowerhalt
Fix blank line at end of function
Co-authored-by: saramonteiro <saramonteirosouza44@gmail.com>
Co-authored-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-01-15 10:34:12 -06:00
Xiang Xiao
e49bae1300
fs: Remove fs_dupfd and fs_dupfd2 internal functions
...
let's call either nx_dup/nx_dup2 or file_dup/file_dup2
instead just like other fs api: xxx->nx_xxx->file_xxx
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I1aacfb9e25dc7b3fcb0345ff7b269b1953a01e5b
2021-01-13 16:39:45 +08:00
Xiang Xiao
985f33e42c
time.h: Sprinkle strftime format attribute
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-01-13 16:39:24 +08:00
Xiang Xiao
0dc6990166
Fix nxstyle warning
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-01-13 08:57:58 +01:00
Xiang Xiao
0536953ded
Kernel module should prefer functions with nx/kmm prefix
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-01-13 08:57:58 +01:00
Matthew Trescott
301ba3a5cd
can: fix RTR ioctl and support timeout
2021-01-12 11:57:22 -06:00
Xiang Xiao
fe96250c40
fs: Make nx_vxxx and file_vxxx as internal functions
...
these functions are the implementation detail and then
don't need expose to external
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ief832391d5b42d1f1645907eb465631650490234
2021-01-12 17:08:22 +01:00
Xiang Xiao
1604fe0b4b
fs: Remove file_detach since it is unefficient to call open and file_detach
...
the kernel user should call file_open directly instead
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I5bf7f661006f5d43739bc8618abfb4b983fde78d
2021-01-11 23:47:57 +01:00
Xiang Xiao
0032ddb8bf
fs: Reimplement file_open to not depend on nx_open
...
on the other hand, open/nx_open call file_open instead
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I66990a77cdeb6ff18f7bf48a65bbc7b701dad552
2021-01-11 23:47:57 +01:00
Xiang Xiao
1aa69f4c73
fs: Remove the special hack for pty in nx_vopen
...
let's replace the content of file in place instead
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I538910d55815c7aec656c05dba4eab2fa1d6d964
2021-01-08 11:04:24 +08:00
Xiang Xiao
a24ff44ae6
fs: Add file_pipe function
...
so pty don't need call nx_pipe and then file_detach
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ibb8d108abd76bafe53897e5fca35babcf3e1bae9
2021-01-08 11:03:19 +08:00
Xiang Xiao
4d4cba41f6
Move the declaration of nx_mkfifo/nx_pipe to nuttx/fs/fs.h
...
the new location is better than nuttx/drivers/drivers.h
since they are part of the file system api.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-01-08 11:03:19 +08:00
Xiang Xiao
86fab49c46
fs: Fix the race condition in file_dup
...
NULL inode passed to files_allocate doesn't mark file struct in the
allocated state, so other threads which invovle in file allocation
(e.g. open or dup) may allocate the same file struct again.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I53ff876eae3c7a1e311e7f671686b73a4b4ef891
2021-01-08 11:01:46 +08:00
Xiang Xiao
98382dd8db
sched: Add include/sys/poll.h
...
since many libc implementation(e.g. glibc, freebsd) provide this header file
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-01-06 14:23:50 +08:00
ligd
f63db66382
mqueue: add file_mq_xx for kernel use
...
Change-Id: Ida12f5938388cca2f233a4cde90277a218033645
Signed-off-by: ligd <liguiding1@xiaomi.com>
2021-01-05 02:40:43 -06:00
ligd
3bc33572e3
mqueue: simplify the mqueue reailize
...
1. remove descript management in mqueue, save code size
2. use i_ops instead of i_mqueue to remove the dup logic
Change-Id: Ie88960e50ddcae9c87977c9ad65a45297c663291
Signed-off-by: ligd <liguiding1@xiaomi.com>
2021-01-05 02:40:43 -06:00
chao.an
c8784faf3c
ctype/iscntrl: correct the control character function
...
all the characters placed before the space on the ASCII table
and the 0x7F character (DEL) are control characters.
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-05 01:34:36 -06:00
danguanghua
7d33f73e27
libs/libc/net: implement socketpair
...
N/A
Reference here:
https://www.freebsd.org/cgi/man.cgi?apropos=0&sektion=2&query=socketpair&manpath=FreeBSD+7.0-current&format=html
Change-Id: I959b4d661cd436f5d5050baf9e821db84139d482
Signed-off-by: danguanghua <danguanghua@xiaomi.com>
2021-01-03 20:56:27 -06:00
chao.an
1241f910ce
arch/spinlock: implement the default test-and-set semantics
...
use the default testset implement on single core platform
that does not support test-and-set, more flexibility for
SMP drivers(using spinlock) if configured in a single-core mode.
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-01-01 15:03:55 -06:00
ligd
3386941a10
fs: remove INODE_IS_SPECIAL() use others instead
...
Change-Id: I949f1ad012836e6cb233d5362fe2542732b5ecf4
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-12-30 12:21:02 -06:00
ligd
f5b59e287a
fs/vfs: add nx_unlink support
...
Change-Id: If9009cb7301bb4e49bdce3aea2d56c243256f5a2
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-12-30 12:21:02 -06:00
Virus.V
7e84874cb1
Reconstruct bl602 readme; move up_irq_save/restore declaration to common place
2020-12-29 01:52:09 -08:00
Xiang Xiao
10adf76209
libc: Add b64_ntop and b64_pton implementation
...
implemented by many libc(e.g. freebsd, glibc, newlib)
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-12-28 13:53:20 -03:00
Xiang Xiao
aec3220fae
bt_uart_shim: Correct the prototype of bt_uart_shim_getdevice
...
1.Add const to the path argument
2.Return the explicit type(struct btuart_lowerhalf_s *)
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-12-28 10:38:42 +01:00
Xiang Xiao
f992ff37c3
Fix nxstyle warning
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-12-28 08:50:16 +01:00
Xiang Xiao
b06067aa23
bluetooth: Fix the typo error in BT_GETUINT16 and BT_PUTUINT16
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-12-28 08:50:16 +01:00
Xiang Xiao
3dfb897ed1
bluetooth: Remove the unnecessary forward reference
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-12-28 08:50:16 +01:00
Xiang Xiao
d1dc0bf848
bluetooth: Fix typos in comment
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-12-28 08:50:16 +01:00
Masayuki Ishikawa
32ad989c03
include: wireless: Replace license header with Apache License 2.0
...
Summary:
- This commit replaces SHES related headers in gs2200m.h
Impact:
- No impact
Testing:
- Build check only
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-12-28 08:43:35 +01:00
dongjiuzhu
f508d80c3d
signal: fix compile break in c++
...
nuttx.rel: In function `__metal_sleep_usec':
nuttx/include/metal/system/nuttx/sleep.h:27: undefined reference to `nxsig_usleep(unsigned int)'
collect2: error: ld returned 1 exit status
Change-Id: I9dd2ed0a72d144bb152dc3753e7f9a6695dfb2d4
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-12-25 21:07:04 +01:00
Michal Lenc
b11bfefff5
drivers/lcd: Added support for ST7789 controller based on ST7735
...
Signed-off-by: Michal Lenc <lencmich@fel.cvut.cz>
2020-12-23 11:19:53 -03:00
chao.an
2980792efd
libs/libc: add lib_dumpvbuffer support
...
e.g: Encapsulation Type: Bluetooth H4: add packet type dump support
From:
lib_dumpvbuffer(NULL, data, len);
[ 1.567100] 0000 03 0c 00 ...
[ 1.890100] 0000 0e 04 01 03 0c 00 ......
[ 1.890100] 0000 03 10 00 ...
[ 1.892900] 0000 0e 0c 01 03 10 00 ff ff 8f fe db ff 5b 87 ............[.
[ 1.892900] 0000 01 10 00 ...
[ 1.894900] 0000 0e 0c 01 01 10 00 06 bb 22 06 0a 00 bb 22 ........"...."
[ 1.894900] 0000 02 10 00 ...
[ 1.901900] 0000 0e 44 01 02 10 00 ff ff ff 03 fe ff ff ff ff ff .D..............
[ 1.901900] 0010 ff ff f3 0f e8 fe 3f f7 83 ff 1c 00 00 00 61 f7 ......?.......a.
[ 1.901900] 0020 ff ff 7f 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
[ 1.901900] 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
[ 1.901900] 0040 00 00 00 00 00 00 ......
To:
struct iovec bufs[2];
bufs[0].iov_base = &type;
bufs[0].iov_len = 1;
bufs[1].iov_base = data;
bufs[1].iov_len = len;
lib_dumpvbuffer(NULL, bufs, 2);
[ 3.711400] 0000 01 03 0c 00 ....
[ 4.035400] 0000 04 0e 04 01 03 0c 00 .......
[ 4.035400] 0000 01 03 10 00 ....
[ 4.037400] 0000 04 0e 0c 01 03 10 00 ff ff 8f fe db ff 5b 87 .............[.
[ 4.037400] 0000 01 01 10 00 ....
[ 4.039400] 0000 04 0e 0c 01 01 10 00 06 bb 22 06 0a 00 bb 22 ........."...."
[ 4.039400] 0000 01 02 10 00 ....
[ 4.046400] 0000 04 0e 44 01 02 10 00 ff ff ff 03 fe ff ff ff ff ..D.............
[ 4.046400] 0010 ff ff ff f3 0f e8 fe 3f f7 83 ff 1c 00 00 00 61 .......?.......a
[ 4.046400] 0020 f7 ff ff 7f 00 00 00 00 00 00 00 00 00 00 00 00 ................
[ 4.046400] 0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
[ 4.046400] 0040 00 00 00 00 00 00 00 .......
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-12-23 00:11:38 -08:00
Xiang Xiao
085619d395
libc: Implement getppid
...
as specified here:
https://pubs.opengroup.org/onlinepubs/009695399/functions/getppid.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-12-20 16:40:14 -03:00
Xiang Xiao
98be50a9bc
libc: Implement posix_fallocate
...
as specified here:
https://pubs.opengroup.org/onlinepubs/007904875/functions/posix_fallocate.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-12-14 09:20:15 +01:00
Juha Niskanen
de1ad1fdb3
net: fix typos, incorrect comments, nxstyle
...
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2020-12-13 09:06:28 -06:00
chao.an
859e1ce63a
crypto/arc4random: rename getrandom to arc4random_buf
...
Change-Id: I5c9f0c9acf5af71f01beceaf06ebe0a2c87676bc
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-12-13 08:49:51 -06:00
Masayuki Ishikawa
6158b6b77b
spinlock: Introduce SP_WFE() and SP_SEV()
...
Summary:
- This commit introduces SP_WFE() and SP_SEV() to be used for spinlock
- Also, use wfe/sev instructions for ARMV7-A to reduce power consumption
Impact:
- ARMV7-a SMP only
Testing:
- sabre-6quad:smp (QEMU, dev board)
- maix-bit:smp, esp32-devkitc:smp, spresense:smp sim:smp (compile only)
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-12-11 05:58:35 -06:00
Masayuki Ishikawa
21cb7935c5
include: nuttx: Fix style warnings in spinlock.h
...
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-12-11 05:58:35 -06:00
chao.an
866bb35d2d
libs/libc/net: implement ether_aton/ether_aton_r
...
Reference here:
https://www.unix.com/man-page/linux/3/ether_aton
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-12-10 20:37:32 -06:00
chao.an
8ac184633b
clock/time: add CLOCK_BOOTTIME definition
...
Change-Id: I1adc0445dcdd8284d11aec44bd67b447b2b0490f
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-12-10 06:40:47 -06:00
Masayuki Ishikawa
a24905059e
sched: irq: Change irq_waitlock() from private to public
...
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-12-10 08:33:42 +01:00
Brennan Ashton
68b526b335
tcp: Remove incomplete support for TCP reassembly
2020-12-09 07:25:26 -08:00
YAMAMOTO Takashi
48c7fee534
include/debug.h: Apply sysloglike to _none
2020-12-06 09:03:09 -06:00
YAMAMOTO Takashi
8d16fe7cfd
include/nuttx/compiler.h: Use __syslog__ if available
2020-12-06 09:03:09 -06:00
YAMAMOTO Takashi
ed1a2584f0
include/syslog.h: Sprinkle sysloglike
2020-12-06 09:03:09 -06:00
YAMAMOTO Takashi
7b39e612db
include/nuttx/compiler.h: Add sysloglike macro
...
Right now, same as printflike.
Introduce a separate macro because syslog takes
a bit different format from printf. (ie. %m)
If it turns out that a compiler is not happy with
the difference, we can disable this selectively.
2020-12-06 09:03:09 -06:00
Yoshinori Sugino
a5e00ac3f0
include/sys/wait.h: Modify P_GID to P_PGID
...
Summary:
- Follow the POSIX description.
Impact:
- No impact as P_GID and P_PGID are not used.
Testing:
- Built with hifive1-revb:nsh
2020-12-04 11:40:46 -06:00
Abdelatif Guettouche
064de6e140
include/nuttx/sensors/hts221.h: Fix nxstyle errors.
...
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2020-12-04 14:34:22 -03:00
Abdelatif Guettouche
4eb2b32310
include/nuttx/sensors/hts221.h: Forward reference i2c_master to avoid
...
any warning.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2020-12-04 14:34:22 -03:00
Xiang Xiao
bb8c4485a2
libc: Change OK/ERROR macro to enum
...
to avoid the conflict with 3rd party c++ library(e.g. protobuf):
fdc35840b9/src/google/protobuf/stubs/status.h (L47)
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ie8bb9008a8375c729f8b947c9f10baa80104d157
2020-11-30 09:43:18 +01:00
Xiang Xiao
87dff7c69a
Fix nxstyle warning
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-11-29 18:40:40 +09:00
Bernd Walter
68ff96c242
fix comment to match with #define
2020-11-28 23:50:50 -06:00
Chaochao Cui
fbb3cd660b
add simple wm8994 codec driver
2020-11-28 10:23:40 -03:00
chao.an
946f99791b
net/wireless: add country code control support
...
Change-Id: Ie3917815e9004bae9c1116916bc4eadb752f6e44
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-27 20:37:44 -03:00
Augusto Fraga Giachero
ffcedfd971
Remove copyright from headers
2020-11-25 05:13:46 -08:00
Augusto Fraga Giachero
558dfa28fb
nxstyle fix
2020-11-25 05:13:46 -08:00
Augusto Fraga Giachero
6a43daa67e
Update licenses to Apache 2.0
2020-11-25 05:13:46 -08:00
dongjiuzhu
148afd9548
driver/sensors: support custom type of sensor.
...
For examples, the custom sensor could define:
struct custem_event_s
{
uint64_t timestamp;
int16_t adc[8];
};
struct sensor_lowerhalf_s g_lower =
{
.buffer_size = 1024,
};
sensor_custom_register(lower, "/dev/sensor/custom0", sizeof(struct custem_event_s));
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-11-24 13:23:15 -03:00
Huang Qi
0a2873a37f
spi/qspi.h: Fix data type of buflen
...
Summary:
- This patch change the data type of buflen in qspi_meminfo_s
- from uint16_t to uint32_t to allow data size greater than 64KB.
Impact:
- QSPI & some flash like s25fl1 etc
Testing:
- Tested with rm69330 oled controller on custom board
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2020-11-22 19:02:11 -08:00
Nathan Hartman
f13ee2848d
include/nuttx/clock.h: Fix wrong comment
...
include/nuttx/clock.h:
* USEC_PER_TICK: The docstring for this define mistakenly said
that the default value of USEC_PER_TICK, 10000, corresponded
to 100 KHz. However, it is actually 100 Hz. Corrected the
comment. No functional changes.
2020-11-22 18:33:50 -08:00
Nathan Hartman
8e8ead3224
sched/signal/sig_timedwait.c: Fix typo in comment
...
sched/signal/sig_timedwait.c:
* nxsig_timedwait(): Fix typo in comment:
"is store din" -> "is stored in"
include/nuttx/signal.h:
* Fix same typo in extern declaration of nxsig_timedwait().
2020-11-22 18:31:49 -08:00
Xiang Xiao
759b63d4be
libc: implement getopt_long partially
...
only the short option is supported now
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-11-21 07:01:08 -06:00
Xiang Xiao
af53bdb048
libc: Add opterr global variable
...
defined here:
https://pubs.opengroup.org/onlinepubs/9699919799/functions/getopt.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-11-21 07:01:08 -06:00
Michal Lenc
8cf6cfda1a
imxrt: Added support for DP83825I PHY
...
Signed-off-by: Michal Lenc <lencmich@fel.cvut.cz>
2020-11-20 20:34:57 -03:00
dongjiuzhu
23ddeaf3be
mm/circbuf: support circular buffer managerment
...
N/A
Change-Id: Ib1fc009b9ce3af5815920f22221fe8a7262299ef
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-11-20 05:33:03 -08:00
dongjiuzhu
60d1755e04
drivers: l3gd20 supports the sensor driver model
...
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-11-19 18:13:17 -08:00
YAMAMOTO Takashi
f1aab27c92
include/nuttx/streams.h: Sprinkle scanflike
2020-11-19 18:03:04 -08:00
YAMAMOTO Takashi
b90809d5f0
stdio.h: Sprinkle scanflike
2020-11-19 18:03:04 -08:00
YAMAMOTO Takashi
d167ec6038
compiler.h: Add scanflike macro
2020-11-19 18:03:04 -08:00
YAMAMOTO Takashi
1f6d54fde4
include/nuttx/streams.h: Add printflike
2020-11-19 18:03:04 -08:00
YAMAMOTO Takashi
7e702817c1
stdio.h: Sprinkle printflike attribute
2020-11-19 18:03:04 -08:00
YAMAMOTO Takashi
eb406a8394
compiler.h: Add printflike macro
...
The name was inspired from NetBSD's __printflike.
We can add similar macros for __syslog__, __scanf__, __format_arg__
later.
2020-11-19 18:03:04 -08:00
YAMAMOTO Takashi
6ee7fdf874
include/inttypes.h: Provide PRIdMAX and friends using 'j' modifier
...
Replace definitions in other places.
2020-11-19 00:49:56 -08:00
YAMAMOTO Takashi
c10a8dc73b
include/stdint.h: Use _uintmax_t and _intmax_t from arch types.h
...
As we do for other intXX_t types.
2020-11-19 00:49:56 -08:00
Alan C. Assis
e7c99480ea
Fix nxstyle issue existing on fs/ioctl.h
2020-11-18 22:21:53 +01:00
Alan C. Assis
f09d103528
xtensa/esp32: Add high memory support to work with PSRAM
2020-11-18 22:21:53 +01:00
liuhaitao
55deefdb30
Add debug.h selection choice to support include chip debug.h
...
Select debug.h which may be under include/arch or include/arch/chip.
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
Change-Id: I5f465c41ba27d040e5e24b2eef2918cfbc18a0bd
2020-11-18 05:22:13 -08:00
liuhaitao
fd94a32468
sysconf: add _SC_PAGESIZE sysconf support
...
Also implement getpagesize() based on sysconf(_SC_PAGESIZE).
Change-Id: I812eb8f34ed602f7bc12c4cafafcebc0d98fd136
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
2020-11-17 02:03:23 -08:00
YAMAMOTO Takashi
18b3b3f5c1
include/nuttx/streams.h: Appease nxstyle
2020-11-16 05:46:53 -08:00
Frank-Christian Kruegel
bf5fa5557d
Support for MAX1161X family of I2C 12 bit ADC chips:
...
MAX11612: 4 channels VCC=5V0 Int VRef=4.096V
MAX11613: 4 channels VCC=3V3 Int VRef=2.048V
MAX11614: 8 channels VCC=5V0 Int VRef=4.096V
MAX11615: 8 channels VCC=3V3 Int VRef=2.048V
MAX11616: 12 channels VCC=5V0 Int VRef=4.096V
MAX11617: 12 channels VCC=3V3 Int VRef=2.048V
Note: The chips' auto-scanning feature is not supported in this revision.
2020-11-15 05:59:01 -08:00
Matias N
14d14bce05
pm.h: nxstyle fixes; change License to Apache (Greg and myself authors)
2020-11-12 08:01:25 +01:00
Matias N
13619ea0df
nrf52: add SPI PM support (disable/enable SPI peripheral on sleep)
2020-11-12 08:01:25 +01:00
dongjiuzhu
089b1c17f6
driver/sensor: add fetch api to read sensor data directly
...
1.use userspace buffer rather than intermediate buffer of upperhalf driver
2.support block and non-block ways.
Change-Id: I1d0cecfaa20ce54961c58713d8f2f8857e349791
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-11-11 18:25:22 -08:00
dongjiuzhu
2cda16b606
driver/sensor: add new feature about sensor driver
...
1.support for multi-user access
2.support special cmd to control sensor
3.support userspace to set size of intermediate buffer
by ioctl: SNOIC_SET_BUFFER_SIZE
Change-Id: I9ce3a65b88b12c28388ec397431f1a277b120c2a
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-11-11 18:25:22 -08:00
dongjiuzhu
2482052228
driver/sensor: user specifies device register number
...
N/A
Change-Id: Idd11461f933dd21b7271cd3ca87a2e33127a9d34
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-11-11 18:25:22 -08:00
Xiang Xiao
84b90e00f0
libc/stdio: Preallocate the stdin, stdout and stderr
...
to handle the uninitialized stdin/stdout/stderr gracefully
report here:
https://github.com/apache/incubator-nuttx/issues/2203
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-11-11 09:56:10 -08:00
chao.an
27932faf1a
sys/epoll: sync the epoll define with linux
...
Change-Id: If876e0c0b44de73cf2847a9d3c21ac138dd4f879
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-09 18:53:48 -08:00
chao.an
8b42e6abd2
pthread/spinlock: move the structure prototype out of the definition
...
pthread/pthread_spinlock.c: In function ‘pthread_spin_init’:
pthread/pthread_spinlock.c:114:11: error: dereferencing pointer to incomplete type ‘pthread_spinlock_t’ {aka ‘struct pthread_spinlock_s’}
114 | lock->sp_lock = SP_UNLOCKED;
| ^~
Change-Id: I49dbb2682e36a17bb25a647c6468b7fb511e4a76
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-09 18:45:48 -08:00
Nathan Hartman
616b3e7436
include/nuttx/spi/spi.h: Fix typos in comments
2020-11-09 18:20:15 -08:00
chao.an
8604e98196
unistd/sched_sporadic: correct the disable value
...
Reference here:
https://github.com/openbsd/src/blob/master/include/unistd.h
Change-Id: Ifb08a69c9a2a2b68179bcfd716fb180ec3577e54
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-09 09:11:51 -03:00
chao.an
54d0c1c296
sys/uio: fix nxstyle warning
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-09 02:33:52 -08:00
chao.an
176d850445
sys/uio: include-able from C++ files
...
Change-Id: I4b512851fa96e1d696dbc886b25af4ab043da8dd
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-09 02:33:52 -08:00
chao.an
06d93828af
sys/resource: fix nxstyle warning
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-09 02:22:34 -08:00
chao.an
82f1263db9
sys/resource: include-able from C++ files
...
Change-Id: I914ab40495a25da184d0b7f8f8b1fa0d376c66a4
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-11-09 02:22:34 -08:00
Juha Niskanen
70cbb7e537
include/nuttx/net/netconfig.h: fix typos and nxstyle
...
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2020-11-08 18:58:20 +01:00
Juha Niskanen
62d38c32e8
drivers/lcd/memlcd.c: fix typos and nxstyle
...
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2020-11-08 18:58:20 +01:00
Subhra Sankha Sarkar
6d32ad04dd
Minor fixes & NuttX coding standards compliance
2020-11-07 06:41:40 -03:00
Daniel P. Carvalho
a5d340a5df
Add injected channel support.
2020-11-06 18:31:32 -03:00
YAMAMOTO Takashi
4c33d608d2
include/inttypes.h: Appease nxstyle
2020-11-05 18:49:22 -08:00
YAMAMOTO Takashi
6e3551866c
include/inttypes.h: Provide PRI/SCN macros for least and fast types
...
* To be consistent with stdint.h
* To reduce arch-dependent code
2020-11-05 18:49:22 -08:00
dongjiuzhu
8562e17ef1
rc/dummy: add dummy driver to test driver skeleton
...
N/A
Change-Id: Iae3c22587f9939f6923b102bf4c51bb7f88a6429
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-11-05 11:38:28 -03:00
dongjiuzhu
2ed6e13241
driver/rc: support IR remote control
...
N/A
guide link: https://www.kernel.org/doc/html/v4.14/media/uapi/rc/lirc-dev.html
Change-Id: I84abfc12578d444d72c8c0df31d06d1a85ce0725
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-11-05 11:38:28 -03:00
ligd
2dfd7a4e8f
signal.h: fix compile failed when open TTY_SIGINT
...
In file included from string/lib_strsignal.c:40:0:
string/lib_strsignal.c: In function ‘strsignal’:
string/lib_strsignal.c:142:12: error: ‘CONFIG_SIG_STOP’ undeclared (first use in this function); did you mean ‘CONFIG_SIG_PIPE’?
case SIGSTOP:
^
string/lib_strsignal.c:142:12: note: each undeclared identifier is reported only once for each function it appears in
string/lib_strsignal.c:147:12: error: ‘CONFIG_SIG_STP’ undeclared (first use in this function); did you mean ‘CONFIG_SIG_STOP’?
case SIGSTP:
Esnure all standard signal number is always defined
Change-Id: I3abce86079ebeba7bab038d7c770efc90b9cffd7
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-11-05 08:28:53 +01:00
Matias N
9266c54bc2
lcd: add optional putarea()/getarea() operations
2020-11-04 04:00:22 -08:00
Nakamura, Yuuichi
7905ee17d4
Add task name recording for note RAM driver
2020-11-02 01:12:08 -08:00
YAMAMOTO Takashi
e99e185712
Don't typedef wchar_t for C++
...
wchar_t is a builtin type in C++.
clang complains like the following even with -fshort-wchar:
error: cannot combine with previous 'type-name' declaration specifier
my clang version if it matters:
spacetanuki% clang++ --version
Apple clang version 11.0.0 (clang-1100.0.33.17)
Target: x86_64-apple-darwin18.7.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
spacetanuki% clang++ -dM -E - < /dev/null | grep WCHAR
#define __CLANG_ATOMIC_WCHAR_T_LOCK_FREE 2
#define __GCC_ATOMIC_WCHAR_T_LOCK_FREE 2
#define __SIZEOF_WCHAR_T__ 4
#define __WCHAR_MAX__ 2147483647
#define __WCHAR_TYPE__ int
#define __WCHAR_WIDTH__ 32
spacetanuki% clang++ -fshort-wchar -dM -E - < /dev/null | grep WCHAR
#define __CLANG_ATOMIC_WCHAR_T_LOCK_FREE 2
#define __GCC_ATOMIC_WCHAR_T_LOCK_FREE 2
#define __SIZEOF_WCHAR_T__ 2
#define __WCHAR_MAX__ 65535
#define __WCHAR_TYPE__ unsigned short
#define __WCHAR_UNSIGNED__ 1
#define __WCHAR_WIDTH__ 16
spacetanuki%
2020-11-01 18:19:13 -08:00
Matias N
f97f1bbd1a
lcd_dev: put header in correct location; fix missing const
2020-10-31 13:26:30 -07:00
Yoshinori Sugino
51af06243f
include/nuttx/serial/serial.h: Fix nxstyle errors
2020-10-29 01:12:43 -07:00
Yoshinori Sugino
c13f869432
Modify SIGSTP to SIGTSTP
...
Follow the POSIX description.
SIGTSTP should be sent when the Ctrl-Z characters is encountered, not SIGSTP.
Testing:
Built with hifive1-revb:nsh (CONFIG_SERIAL_TERMIOS=y, CONFIG_SIG_DEFAULT=y and CONFIG_TTY_SIGTSTP=y)
2020-10-29 01:12:43 -07:00
Matias N
9833256406
bt_hci: add various definitions, better expose some fields
2020-10-28 22:02:09 -07:00
Juha Niskanen
75c332e008
include/nuttx/lcd/ssd1306.h: cleanup for non-existent configs, nxstyle
...
Correct typo LCD_SSD1306_SPI to CONFIG_LCD_SSD1306_SPI, remove
references to non-existent config variable names in comments.
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2020-10-28 19:28:30 -07:00
Yoshinori Sugino
04c0055355
Fix typos
2020-10-28 19:15:04 -07:00
Juha Niskanen
1115452061
drivers/pipes: nx_pipe syscall takes three params, also use nx_close on error path
...
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2020-10-28 09:11:05 -07:00
GAEHWILER Reto
83745652c4
TCP-stack fix for stalled tcp sockets due to broken keepalive
...
Fixes an issue where tcp sockets with activated keepalives stalled and
were not properly closed. Poll would not indicate a POLLHUP and therefore
locks down the application.
* tcp_conn_s.tcp_conn_s & tcp_conn_s.keepintvl changed to uint32_t
According RFC1122 keepidle MUST have a default of 2 hours.
2020-10-27 11:21:56 -07:00
ligd
d0966b800f
usrsock.h: add reserved value to usrsock struct
...
N/A
access (struct usrsock_message_req_ack_s)->result can caused
unaligend-access, add reserved value to avoid this
Change-Id: I6c7d49c57bf898fbf8459b5db9a219122494e254
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-10-27 01:20:52 -07:00
ligd
b69c587dc9
stdio: remove depends on setbuf setvbuf
...
N/A
Cause the function realize will handle this
Change-Id: I154c21c7a40667afae423bb0ebb67de8f5fc42fd
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-10-26 22:12:02 -07:00
Simon Piriou
b405722276
usbdev: add Android Debug Bridge driver
2020-10-26 08:28:48 -03:00
Masayuki Ishikawa
f12d49076c
drivers: wireless: Fix to handle address info in accept() in gs2200m.c
...
Summary:
- This commit fixes to handle address info in accept() in gs2200m.c
Impact:
- All use cases which use accept() with gs2200m
- Need to update apps/wireless/gs2200m as well
Testing:
- Tested with spresene:wifi
- Tested with telnet daemon
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>>
2020-10-26 10:53:34 +01:00
Masayuki Ishikawa
02b08590a1
drivers: wireless: Fix to handle UDP connect() with bind() in gs2200m.c
...
Summary:
- This commit fixes to handle UDP connect() with bind() to a local port.
Impact:
- All UDP cases which use connect() with gs2200m
- Need to update apps/wireless/gs2200m as well
Testing:
- Tested with spresense:wifi
- Create a UDP socket and bind() to a local port.
- Then connect() to remote address with port and send()
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-10-26 10:53:34 +01:00
YAMAMOTO Takashi
6a2bd9a75b
Change the default value of SIGPIPE
...
To avoid the conflicting default with SIGQUIT.
2020-10-25 20:35:41 -07:00
YAMAMOTO Takashi
ad5c168b30
signalh.h: Use the right config for SIGPIPE
2020-10-25 20:35:41 -07:00
Matias N
5386f972fa
bluetooth: Add support for HCI RAW channel; make host layer optional
2020-10-25 17:04:25 -07:00
Brennan Ashton
1080d3f411
Bluetooth: Start implementing BTPROTO_HCI socket support
...
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-10-25 17:04:25 -07:00
YAMAMOTO Takashi
df812d09a2
math: Make this friendly with libcxx
...
- Turn some macros into functions
- Implement some type-agnostic functions.
(Just use __builtin_xxx)
- Add some missing function prototypes
(Just prototypes, not actually implemented in this commit)
2020-10-25 07:30:14 -07:00
Yoshinori Sugino
3ac90fca79
Remove tabs and spaces at the end of lines
2020-10-24 09:38:21 +01:00
dongjiuzhu
a3f978da02
sensor/driver: wtgahrs2 by serial interface follow sensor.c/sensor.h
...
Wtgahrs2 integrates multiple sensor: accel, gyro, mag, baro and gps.
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-10-22 10:17:36 -03:00
dongjiuzhu
fa09c6a8bc
driver/sensor: add unified management for sensor
...
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-10-22 10:17:36 -03:00
dongjiuzhu
2b5be56bd0
serial/termios: support custom baud rate setting
...
N/A
Change-Id: I0cc00f6d0fda852533bd4a38ea6fc39e0d0059da
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-10-21 10:11:21 -07:00
Nakamura, Yuuichi
d8d19911ef
Add SCHED_INSTRUMENTATION_HIRES support
2020-10-21 00:33:10 +08:00
Nakamura, Yuuichi
87a7c0317e
Add note_syscall args support
2020-10-21 00:31:51 +08:00
Xiang Xiao
2956b8516b
Fix nxstyle warning
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-10-20 01:45:06 -07:00
Xiang Xiao
eb4121ce38
Change all 'Nuttx' to 'NuttX'
...
Unify the naming convention
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-10-20 01:45:06 -07:00
Nakamura, Yuuichi
9e470ad73e
Fix note_syscall_leave_s to avoid unaligned access
2020-10-17 23:48:43 +08:00
Yoshinori Sugino
296eff3d40
Fix typos
2020-10-17 09:04:37 +01:00
Philippe Coval
cafe24528c
sensors: Support fxos8700cq motion I2C sensor
...
Device is composed of
3-axis, linear accelerometer and 3-axis, magnetometer
It is onboarded in NXP FRDM-K64F SBC.
Change-Id: I405a12cbf2c9994f3bd66e108d2eb8faeee00e18
Bug: https://github.com/apache/incubator-nuttx/issues/1988
Relate-to: https://www.nxp.com/docs/en/data-sheet/FXOS8700CQ.pdf
Forwarded: https://github.com/apache/incubator-nuttx/pull/1989
Signed-off-by: Philippe Coval <rzr@users.sf.net>
2020-10-16 10:10:35 +08:00
YAMAMOTO Takashi
f9475df13d
include/nuttx/lib/math.h: Add signbit
2020-10-13 08:09:30 +02:00
raiden00pl
33901969fe
Fix nxstyle warnings
2020-10-10 12:24:28 -06:00
raiden00pl
24e17910b2
libdsp: Changed headers for apache 2.0 license
2020-10-10 12:24:28 -06:00
raiden00pl
1621305e79
drivers: Changed headers for apache 2.0 license
2020-10-10 12:24:28 -06:00
Sara Souza
0faf861256
xtensa/esp32: Added Timer Support
2020-10-07 14:12:22 -03:00
Nakamura, Yuuichi
a373079a94
Fix /dev/note driver for task trace support
2020-10-06 03:26:46 +08:00
Nakamura, Yuuichi
6efecd2105
Add notectl driver
2020-10-06 03:26:46 +08:00
Nakamura, Yuuichi
6b54377476
Add note filter functions
2020-10-06 03:26:46 +08:00
Nathan Hartman
80ce7800a9
Sources and Docs: Fix typos and nxstyle issues
...
Documentation/contributing/coding_style.rst:
* Fix repeated words: ("this this").
* Remove trailing spaces.
boards/z80/z80/z80sim/README.txt:
* Fix repeated words: ("this this") and rewrap lines.
graphics/Kconfig,
libs/libc/math/Kconfig:
* Fix repeated words: ("this this").
arch/arm/src/armv7-a/arm_assert.c,
arch/arm/src/armv7-r/arm_assert.c,
arch/arm/src/imxrt/imxrt_enet.c,
arch/arm/src/kinetis/kinetis_enet.c,
arch/arm/src/kinetis/kinetis_flexcan.c,
arch/arm/src/s32k1xx/s32k1xx_enet.c,
arch/arm/src/s32k1xx/s32k1xx_flexcan.c,
arch/arm/src/stm32/stm32_pwm.c,
arch/arm/src/stm32h7/stm32_pwm.c,
arch/arm/src/stm32l4/stm32l4_pwm.c,
arch/renesas/src/rx65n/rx65n_usbdev.c,
binfmt/libnxflat/libnxflat_bind.c,
drivers/pipes/pipe_common.c,
net/igmp/igmp_input.c,
net/tcp/tcp_conn.c,
sched/sched/sched_roundrobin.c:
* Fix typo in comment ("this this").
arch/arm/src/cxd56xx/cxd56_usbdev.c,
arch/arm/src/lc823450/lc823450_usbdev.c:
* Fix typo in comment and rewrap lines.
arch/arm/src/imxrt/imxrt_usbdev.c,
arch/arm/src/stm32/stm32_dac.c,
arch/arm/src/stm32f0l0g0/stm32_pwm.c,
arch/arm/src/stm32f7/stm32_pwm.c,
arch/arm/src/tiva/lm/lm4f_gpio.h,
fs/nxffs/nxffs_write.c,
include/nuttx/analog/pga11x.h,
include/nuttx/usb/usbdev.h,
net/mld/mld_join.c:
* Fix typo in comment ("this this").
* Fix nxstyle issues.
2020-10-02 04:54:52 +02:00
Yoshinori Sugino
698008d1e5
Fix typos
2020-09-28 13:54:43 +08:00
ligd
b54e9ffccc
nuttx/audio/audio.h: add ac_chmap support for both input & output
...
Change-Id: Ic582868fa3099943c4c28ccca7e33f7b3a2afbf7
2020-09-25 00:54:26 -07:00
David Sidrane
4665a3d648
cstdio:Fixed compile error with CONFIG_STDIO_DISABLE_BUFFERING lit.
...
Resolves compiler error introduced by 57dfb9 when
using cpp with CONFIG_STDIO_DISABLE_BUFFERING lit.
NuttX/nuttx/include/cxx/cstdio:79:11: error: '::setbuf' has not been declared
using ::setbuf;
2020-09-24 13:56:10 +02:00
Gregory Nutt
ebdfd16f0f
Move gettid() implementation to /libs/libc/unistd
...
Move sched/task/task/task_gettid.c to libs/libc/unistd/lib_gettid.c. gettid() is a dumb wrapper around getpid(). It is wasteful of resources to support TWO systme calls, one for getpid() and one for gettid(). Instead, move gettid() in the C library where it calls the single sysgtem call, getpid(). Much cleaner.
2020-09-22 19:40:56 -07:00
Xiang Xiao
411f5d591a
sched: Fix undefined reference to 'sched_cpu_count'
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-09-21 07:37:04 -07:00
Xiang Xiao
ba3f12c93f
libc: Implement popcount/popcountl/popcountll
...
specified here:
https://www.unix.com/man-page/netbsd/3/popcountll/
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-09-21 07:37:04 -07:00
Brennan Ashton
5498f72fa5
input: Q10 BlackBerry Keyboard from Solder Party
...
This adds support for the Q10 BlackBerry based keyboard
from Solder Party. https://www.solder.party/docs/keyboard-pmod/
They keyboard device registered at /dev/kbdN is fully compatible
with hidkbd and has been testing with the Keyboard FeatherWing
on the nRF52 platform.
The buttons are added as a standard discrete joystick if
optionally enabled. The PMOD variant of this does not
include these buttons, but the Keyboard FeatherWing does.
This joystick is usually defined at /dev/djoyN and
can be used with the djoy example application.
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-09-21 07:40:42 -06:00
licheng
29030557ff
sched: Fix nuttx typo
2020-09-20 02:32:25 -07:00
chao.an
b2b7541d59
nuttx/wireless: fix nxstyle warning
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 11:39:13 -07:00
chao.an
9e45d6e88e
nuttx/wireless: add wireless event member length helper
...
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 11:39:13 -07:00
chao.an
216c33a5c7
libs/libc/stdlib: Implement mkdtemp(3) syscall
...
See the reference here:
https://pubs.opengroup.org/onlinepubs/9699919799/functions/mkdtemp.html
Change-Id: I49081ecafc011a843e6067b1118b53bf65d4418b
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 04:16:14 -07:00
chao.an
4067a9f057
libs/libc/stdio: correct the prototype of mktemp(3)
...
From: int mktemp(FAR char *path_template);
To: FAR char *mktemp(FAR char *path_template);
See the reference here:
https://pubs.opengroup.org/onlinepubs/009695399/functions/mktemp.html
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 04:16:14 -07:00
chao.an
7816b5ec8c
include/stdlib: alignment function definitions
...
Change-Id: Id12ed4241698c8d4426907ca72eef334894ee1f3
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 04:16:14 -07:00
chao.an
0826b827ee
libs/libc/time: add stub for futimes/ns(2)
...
Change-Id: I231817d10b9e2071b1f642e8694839b2a64b1c4c
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 03:20:09 -07:00
chao.an
9db2e9e393
libs/unistd: add system variables of physical pages
...
Change-Id: If739b25d358c35de90115ae51e0c1bfbe7bd7a88
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 01:08:39 -07:00
chao.an
06e78dc883
libc/time: redirect timegm(3) to mktime(3)
...
See the reference here:
https://man7.org/linux/man-pages/man3/timegm.3.html
Change-Id: Ic583b1bd5c7da02086aef7ff043003e402faa4d4
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 01:04:17 -07:00
liuhaitao
e0aa7c6d81
syscall: update syscall_lookup.h with gettid to fix build break
...
proxies/PROXY_gettid.c: In function 'gettid':
proxies/PROXY_gettid.c:12:41: error: 'SYS_gettid' undeclared (first use in this function); did you mean 'SYS_getpid'?
12 | return (pid_t)sys_call0((unsigned int)SYS_gettid);
| ^~~~~~~~~~
| SYS_getpid
proxies/PROXY_gettid.c:12:41: note: each undeclared identifier is reported only once for each function it appears in
proxies/PROXY_gettid.c:13:1: warning: control reaches end of non-void function [-Wreturn-type]
13 | }
| ^
CC: proxies/PROXY_mmap.c
Makefile:83: recipe for target 'PROXY_gettid.o' failed
Signed-off-by: liuhaitao <liuhaitao@xiaomi.com>
Change-Id: Ib4d6e315aa7f17235292dd2d6550458a53bc1596
2020-09-18 20:07:00 -07:00
chao.an
bf8446e235
sched/task: Implement gettid(2) syscall
...
See the reference here:
https://man7.org/linux/man-pages/man2/gettid.2.html
Change-Id: Ia814d0ccc3b20d8dfc36c809682ddf6e21811d20
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-18 20:07:00 -07:00
chao.an
9241725312
fs/munmap: export the symbols to avoid build break on C++ syntax
...
base/metrics/persistent_memory_allocator.cc:1009:18: error: expected id-expression before ‘-’ token
1009 | int result = ::munmap(memory, size);
| ^~~~~~
Change-Id: I24e55c18d09553d3acc341a27063d01489d905ec
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-18 20:05:10 -07:00
chao.an
b8fa1e51d8
time/tm: add "tm_zone" member into tm
...
base/time/time_exploded_posix.cc:190:14: error: ‘struct tm’ has no member named ‘tm_zone’; did you mean ‘tm_mon’?
190 | timestruct.tm_zone = nullptr; // not a POSIX field, so mktime/timegm ignore
| ^~~~~~~
| tm_mon
Change-Id: I9f93e63b50c0692a7a2bfc47abd9d07aa2c8e8db
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-18 20:03:05 -07:00
chao.an
614ac5b0f2
libs/libc/unistd: Implement pipe2(2) syscall
...
See the reference here:
https://www.man7.org/linux/man-pages/man2/pipe2.2.html
Change-Id: Ife19b9bdbde73c7421be381a094da67017819e63
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-18 20:01:26 -07:00
chao.an
78005a4ba0
sys/epoll: include-able from C++ files
...
Change-Id: Icc73be9de7a9217e33903243b0ecf1a9a596b381
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-18 19:51:55 -07:00
dongjiuzhu
45a8de8fa0
include/poll: add POLLPRI for exceptional event
...
Change-Id: I40d566e2c6f0d1fd7232148918635fa8d336ce28
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-09-18 19:49:51 -07:00
Gregory Nutt
415d83cf19
STMPE811: Fix name collision in include/nuttx/input/stmpe811.h
...
The macro name GPIO_PIN collides with naming used by many architectures:
$ find . -name "*.h" | xargs grep "define GPIO_PIN[(]"
./arch/arm/src/am335x/hardware/am335x_gpio.h:#define GPIO_PIN(n) (1 << ((n) & 0x1f)) /* Bit n: Pin n, n=0-31 */
./arch/arm/src/imx6/hardware/imx_gpio.h:#define GPIO_PIN(n) (1 << (n)) /* Bit n: Pin n, n=0-31 */
./arch/arm/src/imxrt/hardware/imxrt_gpio.h:#define GPIO_PIN(n) (1 << (n)) /* Bit n: Pin n, n=0-31 */
./arch/arm/src/lpc43xx/hardware/lpc43_gpio.h:#define GPIO_PIN(p) (1 << (p)) /* Bits 0-31: Read/write pin state */
./arch/arm/src/nrf52/nrf52_gpio.h:# define GPIO_PIN(n) ((n) << GPIO_PIN_SHIFT)
./arch/arm/src/nuc1xx/hardware/nuc_gpio.h:#define GPIO_PIN(n) (1 << (n)) /* Bit n: GPIOx Pin[n] pin value */
./arch/avr/src/at32uc3/at32uc3_gpio.h:#define GPIO_PIN(n) (1 << (n))
./include/nuttx/input/stmpe811.h:#define GPIO_PIN(n) (1 << (n))
This commit changes the name used by the STMPE811 driver to STMPE11_GPIO_PIN
2020-09-17 12:10:29 -07:00
Brennan Ashton
e2fd1fdd84
LED: Support for WS2812 led controller (aka Adafruit NeoPixel)
...
The WS2812 is very common in LED strips as it is an integrated
controller and LED. It is driven by a single data line, but
the timing requirements can be met by using most SPI controllers
and the use of DMA.
This driver has been validated on the nRF52 arch both with a
single LED and a strip of 144.
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-09-16 10:35:56 -07:00
Yoshinori Sugino
d4ec1ababd
fs/vfs/fs_ioctl.c: Add FIOCLEX/FIONCLEX support
2020-09-16 02:31:33 -07:00
ligd
57dfb98713
include: add dependence to setvbuf & isatty, undefine symbols when !CONFIG_SERIAL_TERMIOS
...
Change-Id: I053504fcfc90d926e6f529bfd7badedc71596313
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-09-15 10:28:21 -03:00
ligd
c38c821fc2
libs/libc/time: add gethrtime() support
...
Change-Id: I8882207d3a7e5062f70c7b4b95205361c71f8744
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-09-15 10:28:21 -03:00
Xiang Xiao
77ae03788a
note: Rename note driver to noteram driver
...
to reflect this is just a normal note driver with ram buffer
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-09-15 14:55:22 +08:00
Xiang Xiao
027e2eed28
libc: Implement umask function
...
Here is the spec:
https://pubs.opengroup.org/onlinepubs/009695399/functions/umask.html
Note: The simple implementaton is enough since
NuttX doesn't really support the permission
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-09-14 12:16:58 -03:00
dongjiuzhu
03c7951cbd
libc/termios: modify termios setting follow linux and posix
...
Change-Id: Id323b3169e74f4153fd8d132d20926b7fb8336a3
Signed-off-by: dongjiuzhu <dongjiuzhu1@xiaomi.com>
2020-09-14 09:23:46 -03:00
Xiang Xiao
0c3930ba11
sched: Rename note_add to sched_note_add
...
to better match other sched_note_* function
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-09-12 08:42:30 -07:00
Xiang Xiao
b0797263ca
libc/stdio: Allocate file_struct dynamically
...
1.Reduce the default size of task_group_s(~512B each task)
2.Scale better between simple and complex application
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ia872137504fddcf64d89c48d6f0593d76d582710
2020-09-11 17:58:17 +08:00
ligd
f428160dcc
signal: add SIGQUIT & SIGTERM support
...
SIGQUIT SIGTERM are equal with SIGINT now
Change-Id: Iefc084d58db28003dc40a17f1ff3fbd7a0b716ed
2020-09-11 10:41:24 +08:00
ligd
c8c2745fa7
include/sys/types.h: add u_intXX_t support
...
like u_int8_t u_int16_t u_in32_t...
Change-Id: Ieee5014bddb1cf1a6e769af7258ff524263f67fb
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-09-11 10:41:24 +08:00
Xiang Xiao
952af92690
sched/note: Move the circle buffer code to driver
...
so the format code can be shared by different transport
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-09-07 11:54:10 +08:00
Xiang Xiao
f99719e260
Move note driver from drivers/syslog to drivers/note
...
it's better to put the note transport layer into a common folder
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-09-07 11:54:10 +08:00
Masayuki Ishikawa
08c4376606
arch, include, sched : Refactor ARCH_GLOBAL_IRQDISABLE related code
...
Summary:
- ARCH_GLOBAL_IRQDISABLE was initially introduced for LC823450 SMP
- At that time, i.MX6 (quad Cortex-A9) did not use this config
- However, this option is now used for all CPUs which support SMP
- So it's good timing for refactoring the code
Impact:
- Should have no impact because the logic is the same for SMP
Testing:
- Tested with board: spresense:smp, spresense:wifi_smp
- Tested with qemu: esp32-core:smp, maix-bit:smp, sabre-6quad:smp
- Build only: lc823450-xgevk:rndis, sam4cmp-db:nsh
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-09-03 10:20:20 +08:00
Ouss4
c98ec2ad3e
drivers/sensors/mpu60x0.c: Correct comments.
2020-09-01 18:18:24 -03:00
Brennan Ashton
797bf447d1
net: For Bluetooth sockets use the Linux sockaddr types
...
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
2020-08-29 14:04:54 -06:00
Xiang Xiao
73723dd31c
drivers/rwbuffer: Avoid ftl driver allocate the temporary erase buffer
...
If the buffer to be flushed isn't multipled by the erase size,
let's pad the buffer proactively to avoid the allocation in ftl.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I6d7904aafab93a7886a594319d65826b81cd3cd1
3Change-Id: I88276149cc7826e7416929ca60b06314e96079a6
2020-08-29 02:57:36 -07:00
leomarradke
8a2c480a48
arch: samd5e5:
...
- Add MTD progmem support.
- NVM USER PAGE IOCTLs support.
boards: metro-m4 Add support for:
- SmartFS inicialization.
- AT24 EEPROM.
- GPIO dev support.
- BQ27426 gauge inicialization.
drives: power
- Add BQ27426 fuel gauge support.
Testing:
- Build check only.
Signed-off-by: Leomar Mateus Radke <leomar@falker.com.br>
2020-08-27 11:46:50 -03:00
Xiang Xiao
389b45359d
epoll: Don't save fd into the field of epoll_data_t
...
since epoll_data_t is reserved to the caller and
then shouldn't be touched by the implementation
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-08-25 21:06:48 +01:00
Xiang Xiao
a354b9a9d1
fs/vfs: Implement EPOLLONESHOT flag
...
https://linux.die.net/man/2/epoll_ctl :
EPOLLONESHOT (since Linux 2.6.2)
Sets the one-shot behavior for the associated file descriptor.
This means that after an event is pulled out with epoll_wait(2)
the associated file descriptor is internally disabled and
no other events will be reported by the epoll interface.
The user must call epoll_ctl() with EPOLL_CTL_MOD to
rearm the file descriptor with a new event mask.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I6c0dc93e1cdae0e8cea5b487c7005de2da2c2ec3
2020-08-25 21:06:48 +01:00
Xiang Xiao
6c9ff72b9a
fs/vfs: Implement epoll_pwait API
...
specified here:
https://linux.die.net/man/2/epoll_pwait
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I20106fdbe4f403ded7eab43f3523edd262e1d9a3
2020-08-25 21:06:48 +01:00
David Sidrane
34b21a4990
nuttx:board.h add extern C under cpp
2020-08-26 00:36:14 +08:00
Xiang Xiao
3ea8d574fe
mm: Implement malloc_usable_size
...
defined here:
https://man7.org/linux/man-pages/man3/malloc_usable_size.3.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I5988bb28375626188312bd0a0ba3fc12db66f644
2020-08-24 03:36:44 -07:00
Xiang Xiao
b5f429c88b
Fix nxstyle warning
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-08-22 17:37:21 -06:00
Xiang Xiao
ae356001cf
Change all files come from Xiaomi/Pinecone to Apache License 2.0
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-08-22 17:37:21 -06:00
Xiang Xiao
6670bc2b27
libc/time: Implement tm::tm_gmtoff field
...
defined by BSD and GNU library extension:
https://www.gnu.org/software/libc/manual/html_node/Broken_002ddown-Time.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I33113bc322f038a3602880db4fb9cf93001947ac
2020-08-21 07:48:52 -03:00
Xiang Xiao
b3e01168db
sched/signal: Add sighandler_t typedef
...
improve the compatibility for glibc
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I925e8cbea18848dfc75c97aa72a12b91810aa9e8
2020-08-21 09:59:46 +01:00
Xiang Xiao
297c294c0f
libc: Change ctype macro to normal function
...
to avoid the argument evaluation more than once
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ib59c9bc8d259731bc6e7ff542379b74ba22d6e33
2020-08-21 16:56:00 +08:00
spiriou
0ddefd7c69
fs/vfs/fs_epoll: fix epoll_wait function
2020-08-20 11:49:20 -05:00
Xiang Xiao
beb745ef92
sched/pthread: Implement pthread_attr_[get|set]detachstate
...
specified here:
https://pubs.opengroup.org/onlinepubs/009695399/functions/pthread_attr_getdetachstate.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I84ec2d14f14cb7118aac3f7f356f83a5f9af4e18
2020-08-20 10:46:14 +01:00
Xiang Xiao
8db91a7974
timers/timer.c:397:19: Fix warning: implicit declaration of function 'timer_setcallback'
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-08-18 13:42:05 +01:00
chao.an
b89737395b
vfs/epoll: add epoll_create1(2) implement
...
Linux Programmer's Manual
NAME
epoll_create, epoll_create1 - open an epoll file descriptor
...
SYNOPSIS
#include <sys/epoll.h>
int epoll_create1(int flags);
...
epoll_create1()
If flags is 0, then, other than the fact that the obsolete
size argument is dropped, epoll_create1() is the same as
epoll_create(). The following value can be included in flags
to obtain different behavior:
EPOLL_CLOEXEC
Set the close-on-exec (FD_CLOEXEC) flag on the new file
descriptor. See the description of the O_CLOEXEC flag in
open(2) for reasons why this may be useful.
https://man7.org/linux/man-pages/man7/epoll.7.html
2020-08-17 23:41:13 -05:00
chao.an
2e2ebb95ca
sys/poll/epoll: sync the epoll_event struct layout with pollfd
...
epoll(2) call broken caused by 94fe5c8349
Change-Id: I0811bb7a756797651819d46236e26869559b1767
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-08-17 23:41:13 -05:00
chao.an
155860ad15
sys/epoll: move the private handle to epoll_data_t
...
sync the struct epoll_event define with linux:
Linux Programmer's Manual:
DESCRIPTION
EPOLL_CTL_DEL
...
The event argument describes the object linked to the file descriptor
fd. The struct epoll_event is defined as:
typedef union epoll_data {
void *ptr;
int fd;
uint32_t u32;
uint64_t u64;
} epoll_data_t;
struct epoll_event {
uint32_t events; /* Epoll events */
epoll_data_t data; /* User data variable */
};
https: //man7.org/linux/man-pages/man2/epoll_ctl.2.html
Change-Id: I3ad447b485fd331190e461a198ef7c39301eb1bb
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-08-17 23:41:13 -05:00
chao.an
e5f6dafe1f
net/socket: add SOCK_CLOEXEC/SOCK_NONBLOCK support
...
Reference here:
https://github.com/torvalds/linux/blob/master/include/linux/net.h
Change-Id: I9fd0170bcd1ae7e778e951d454ada76f63854de5
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-08-17 23:38:18 -05:00
chao.an
7ce2b3fa74
libc/pthread: Implement pthread_condattr_[g|s]etclock
...
Reference:
https: //pubs.opengroup.org/onlinepubs/009695399/functions/pthread_condattr_setclock.html
Change-Id: I19c15d5f219fcf28dbfeb2e5a1e3fc7b38ba2259
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-08-17 19:17:08 +01:00
Xiang Xiao
acca9fcc3b
sched/wdog: Remove MAX_WDOGPARMS and related stuff
...
since the variable arguments are error prone and seldom used.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-08-14 08:19:50 -06:00
Huang Qi
57e1211ed6
math: Implement cbrt
...
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2020-08-14 07:27:55 -05:00
chao.an
7356b5a2ed
libc: Implement strlcpy function
...
Reference:
http://www.delorie.com/djgpp/doc/libc/libc_763.html
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-08-14 03:44:26 -07:00
Xiang Xiao
a0ce81d659
sched/wdog: Don't dynamically allocate wdog_s
...
to save the preserved space(1KB) and also avoid the heap overhead
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I694073f68e1bd63960cedeea1ddec441437be025
2020-08-11 12:28:55 -06:00
zhongan
e0ad381abc
drivers/rptun: add null-check for 'RPTUN_*' macro.
...
Change-Id: I203e90f03e66791afe4c65aef4367f5a626cb15b
Signed-off-by: zhongan <zhongan@xiaomi.com>
2020-08-11 15:58:27 +01:00
zhongan
2818b6b2c0
drivers/rptun: Add 'RPTUN_CONFIG' interface.
...
Change-Id: I1c6177ffe0c49c385f0d784b1ff0dbb69b6432f8
Signed-off-by: zhongan <zhongan@xiaomi.com>
2020-08-11 15:58:27 +01:00
Xiang Xiao
b13f3212ad
libc: Implement ftw and nftw function
...
see the reference here:
https://pubs.opengroup.org/onlinepubs/009695399/basedefs/ftw.h.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I3b368106a56b0e9d4c653f3ae16304b0a9d55fbc
2020-08-11 16:44:42 +09:00
Huang Qi
fd78f83e02
drivers/video: Refine the update region notification mechanism
...
1.Expose the notification through fb_vtable_s::updatearea
2.Incorporate old nx_notify_rectangle into the new updatearea callback
3.Migrate the calle of nx_notify_rectangle to fb_vtable_s::updatearea
Change-Id: Ia3d1f73e8757b2d381586d76ec6adc16c810018d
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2020-08-10 08:08:33 +02:00
Johannes Schock
02a9228c1f
Added USB MSC state change notifier in notifier work queue.
...
Added USB MSC automount for Freedom K28 using the above.
2020-08-09 11:54:04 -06:00
Xiang Xiao
f618de9c97
Fix nxstyle warning
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-08-08 17:30:26 -03:00
David Sidrane
bca0f3e275
sys/stat:Make comment match code
2020-08-06 08:36:03 -05:00
SPRESENSE
385e555da8
wireless: gs2200m: Add flags member
...
Add flags member to take recv() flags from daemon.
2020-08-06 16:57:18 +09:00
David Sidrane
5a76767cd7
tioctl:Define SINGLEWIRE PUSHPULL option
2020-08-06 01:03:34 -05:00
Xiang Xiao
5c67eac27f
libc: Change index/rindex from macro to function
...
to avoid the confliction with the same name variable
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-08-05 04:39:03 -07:00
David Sidrane
ed5d00edd8
board_crashdump:use consistent type from outer function for file name
2020-08-04 21:20:05 -05:00
spiriou
a4a9eb2f5a
fs/vfs: Add file descriptor based events support
2020-07-31 15:09:35 -06:00
SPRESENSE
45e9c2c8f5
drivers/video: Add 3A parameter control
...
Provide functions which get and set the 3A (Auto white balance/Auto
exposure/Auto
focus) parameters.
These are achieved by the ioctl request codes VIDIOC_G_EXT_CTRLS and
VIDIOC_S_EXT_CTRLS which have the following settings:
1. ctrl_class = V4L2_CTRL_CLASS_CAMERA
2. id = V4L2_CID_3A_PARAMETER
Also, provide function which get the 3A adjustment status.
This is achieved by the ioctl request codes VIDIOC_G_EXT_CTRLS which has the
following settings:
1. ctrl_class = V4L2_CTRL_CLASS_CAMERA
2. id = V4L2_CID_3A_STATUS
2020-07-31 09:37:20 +02:00
SPRESENSE
28ba7f4a1e
boards: cxd56xx: Fix bugs about ON/OFF control of AWB and AE
...
Fix the following three bugs about ON/OFF control of auto white balance and auto
exposure:
- The returned value of VIDIOC_G_CTRL with id = V4L2_CID_AUTO_WHITE_BALANCE is
different from V4L2 specification.
- Auto exposure is locked if auto white balance lock is requested.
- Auto exposure and auto white balance are locked if auto exposure lock is
requested.
2020-07-31 09:37:20 +02:00
Xiang Xiao
3cff139b85
libc: Make gethostname as syscall instead of uname
...
simplify and symmetry the implementation in KERNEL/PROTECTED build
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Iefdeea5f6ef6348c774b2ca9f7e45fe89c0c22dd
2020-07-30 10:33:08 +09:00
SPRESENSE
d2f75467b5
net/usrsock: Add flags to sendto/recvfrom in usrsock
...
Add flags argument into sendto() and recvfrom() APIs for MSG_* flags can
handling in the daemon.
However, MSG_DONTWAIT should process in usrsock, so it unnecessary to pass to
the daemon like O_NONBLOCK.
2020-07-29 09:40:51 +02:00
SPRESENSE
500ead8101
drivers/modem/altair: Update altair modem driver
...
- Add board specific logic to altair modem dirver
- Fix issue that SPI4 RX frequency violated AC Spec
- Remove dummy buffer in altair driver
- Fix priority of SPI transfer task is too low
- Remove unnecessary configuration
- Modify timeout value for RX ready
- Fix minor bugs
2020-07-28 09:09:18 +02:00
Masayuki Ishikawa
41e6ce2beb
include: audio: Replace license header with Apache License 2.0
...
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2020-07-28 00:47:39 -05:00
Xiang Xiao
33ec242caf
Implement proposed POSIX _clockwait variants of existing _timedwait functions
...
Here is the related glibc patchset:
https://patchwork.ozlabs.org/project/glibc/cover/cover.b0c66849a87ca79889a49f2f1f2563b1a8a15d8b.1551291557.git-series.mac@mcrowe.com/
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I0095cb34cef3d0d88a100255053da79266b73ff2
2020-07-27 20:39:59 -03:00
Nakamura, Yuuichi
ac34ac9f5c
Add g_funcnames declaration in syscall.h
2020-07-22 12:01:40 -05:00
Nakamura, Yuuichi
2b4d2cd4a3
Fix note structure members types
2020-07-22 11:55:21 -05:00
Xiang Xiao
6c03a4e4d5
libc: Add uuid implemenation
...
specified by OpenGroup here:
https://pubs.opengroup.org/onlinepubs/009629399/toc.htm
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I3bc585e7f4d41f6c2ea70e170276ab0d0399b088
2020-07-21 21:48:18 -07:00
Xiang Xiao
e1ecb3e27c
libc: Don't define localtime[_r] to macro when CONFIG_LIBC_LOCALTIME not define
...
since libc++ declare these function in ctime by:
using ::localtime[_r];
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ic0bb68b44c0cab838ab7cc34baee2aaa3ca8a9b5
2020-07-19 19:35:21 -07:00
Xiang Xiao
aa57174eb9
rwbuffer: Optimize the buffer algorithm
...
avoid the buffer flush as much as possible
Change-Id: I902f374e9540b36bd0b0c77a34cab5014a2c24fc
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-07-19 13:13:50 -07:00
Xiang Xiao
4f22f746f8
syscall: Remove g_funclookup and g_funcnparms
...
since nobody use them
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-07-19 13:07:31 -07:00
Xiang Xiao
d6827cab60
arch: up_assert shouldn't call exit directly
...
since exit will be only callable from userspace and change
the 1st argument from "const uint8_t *" to "const char *"
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I86487d57210ab63109148232da71dbc4d60a563b
2020-07-19 01:21:36 +01:00
Xiang Xiao
6f6d61eec4
fs/vfs: Implement statvfs and fstatvfs
...
specified here:
https://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/statvfs.h.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-07-13 20:25:03 +01:00
Nakamura, Yuuichi
1f7e91d217
Move note_register() declaration into the separate header
2020-07-13 00:46:55 -05:00
Oleg Evseev
b6ed3392a4
drivers/can: base readers checks on cd_readers list itself
...
Get rid of several useless dev vars
2020-07-11 15:06:56 -03:00
Xiang Xiao
9dff16e0e4
fix nxstyle warning
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ieaf325c899d1c349d64dfa15bddcc32afd1fce42
2020-07-10 21:30:02 +01:00
Xiang Xiao
c3e256e018
libxx: Make __dso_handle weak
...
since sim arch has to use other instance provided by host glibc
also initialize __dso_handle to self as glibc:
https://github.com/bminor/glibc/blob/master/csu/dso_handle.c#L21
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I7531ae58fc4dbe4600bcb2c2c3a6cac021378bc1
2020-07-10 13:51:26 +09:00
Ouss4
81d814b86e
include/nuttx/arch.h: Trivial typo fixes.
2020-07-09 11:17:41 -03:00
Xiang Xiao
1bca457b28
libc: Always declare getenv, link/symlink and atexit/on_exit
...
since many c++ library implementation reference these symbols by using ::xxx but never
really use them, the declaration avoid the unused code is pulled into the final binary
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Idd7bf9a1e09b77a6b21f900cd3ede08a1cc82d86
2020-07-08 12:07:22 +01:00
Beat Küng
a349595316
gpio: extend gpio_pintype_e for pulldown/up and opendrain
...
- fix code style
- fix bool conversion when calling go_read()
2020-07-07 08:34:25 -05:00
Xiang Xiao
67ef70d460
vfs/dirread: Should return the same file type as lstat
...
by extend the possible value of d_type for the special file
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-07-07 13:41:10 +01:00
Xiang Xiao
91ed14c631
vfs/stat: Make the flag defintion more confirm POSIX standard
...
specified here:
https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/sys_stat.h.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-07-07 13:41:10 +01:00
Xiang Xiao
3472de3500
Revert "sched/sched/sched_releasetcb.c: Handle custom stack allocations."
...
Since up_release_stack auto detect whether the memory come from builtin heap
if (ttype == TCB_FLAG_TTYPE_KERNEL)
{
if (kmm_heapmember(dtcb->stack_alloc_ptr))
{
kmm_free(dtcb->stack_alloc_ptr);
}
}
else
{
/* Use the user-space allocator if this is a task or pthread */
if (umm_heapmember(dtcb->stack_alloc_ptr))
{
kumm_free(dtcb->stack_alloc_ptr);
}
}
This reverts commit 124e6ee53d
.
2020-07-07 00:21:46 +01:00
Xiang Xiao
60fe0a0f96
libc: Refine the inline handling
...
1.Remove CONFIG_HAVE_INLINE macro
2.Change the ANSI C function to normal function
3.Other simple non ANSI function to macro
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-07-04 11:10:29 +09:00
Xiang Xiao
b984534255
lib/math: Remove float32 and float64 definition
...
since they aren't defined by standard and never supported by other POSIX OS
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-07-02 10:53:34 -03:00
chao.an
d938e2cd46
CI check: fix nxstyle warning
...
nxstyle fixes to reduce the CI warnings
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-07-02 01:53:23 -05:00
chao.an
3fbdc213b7
syscall/prctl: fix PR_SET_NAME failure if without <pid> arg
...
add PR_SET_NAME_EXT/PR_GET_NAME_EXT extension to avoid semantic
conflicts, use extened version for pthread_setname_np/pthread_getname_np
Change-Id: I40404c737977a623130dcd37feb4061b5526e466
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-07-01 21:52:18 -05:00
Xiang Xiao
8153e31753
sched: Call c++ global variables constructor inside nxtask_startup
...
to avoid the similar code spread around each application
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I8967d647eaf2ecae47f29f83e7fa322ef1b42a02
2020-07-01 07:55:33 -06:00
Xiang Xiao
e9c7df4769
sched: Rename task_startup to nxtask_startup
...
to follow the naming convention
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I3594d12a65e8cacea99bc295d622628304c3f9f8
2020-07-01 07:55:33 -06:00
Xiang Xiao
651eefc8f7
fs: Rename link to symlink
...
since the current implementation is really a symoblic link not hard link
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I59d30d0a620b0b5714fe91bbe90d4405cf53d187
2020-07-01 11:58:12 +02:00
Xiang Xiao
a102922e12
libc: Implement realpath
...
specified here:
https://pubs.opengroup.org/onlinepubs/9699919799/functions/realpath.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ie52dcd1c5c5faa4b033901eedd7182bbb9473f7a
2020-06-30 13:09:58 -06:00
Xiang Xiao
0b891d60f9
vfs: Define symlink as link
...
specified here:
https://pubs.opengroup.org/onlinepubs/009695399/functions/symlink.html
yes, symlink is different from link:
1.symlink create the soft(symbolic) link
2.link create the hard link
but it is suitable to make them same now since vfs doesn't support the
hard link and the soft link in file system level yet.
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I3b6e311cc1c826542165c9d93cbe5e078f113684
2020-06-30 13:09:58 -06:00
Xiang Xiao
b598ab43d7
fs: Implement lstat function
...
specified here:
https://pubs.opengroup.org/onlinepubs/009695399/functions/lstat.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Iefc23a02d425ff84fa4027aea7da1181b01eced7
2020-06-30 13:09:58 -06:00
Xiang Xiao
14ecb8723a
sched: Change tcb_s to task_tcb_s for nxtask_[un]init
...
since these functions can just work with task not thread
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-06-30 10:54:42 -06:00
Xiang Xiao
a81a260490
vfs: Add chmod/fchmod/utimes function prototype
...
but skip the implemenation because VFS layer doesn't support the time/mode change yet:
https://pubs.opengroup.org/onlinepubs/009695399/functions/chmod.html
https://pubs.opengroup.org/onlinepubs/009696699/functions/fchmod.html
https://pubs.opengroup.org/onlinepubs/009695399/functions/utimes.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ie4a2d3bb4eb5f5aaa0aeb794a4012b096aa94e4f
2020-06-30 09:20:33 +01:00
chao.an
2fc02ec4a4
sched/task_init: change the stack pointer type to (void *)
...
change the stack pointer type from (uint32_t *) to (void *)
Change-Id: I90bb7d6a9cb0184c133578a1a2ae9a19c233ad30
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-06-30 08:26:38 +02:00
chao.an
b296adc3bb
socket/SOL: sync the SOL index with linux
...
Change-Id: I32b9eb7cc3bc1428f0ff7bf5e60d7fff52621db2
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-06-29 11:34:43 -05:00
Xiang Xiao
d17b963bca
libc: Move double_t typedef from sys/types.h to math.h
...
specified here:
https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/math.h.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I3497a73908301d999cf1cfc4a66552a7ca4868c6
2020-06-29 13:37:41 +01:00
Xiang Xiao
771f532dcb
cxx: Remove CONFIG_NET guard from [get|set]hostname
...
since these two functions is always implemented now
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Iae46fa4d38b680a5d1ce5c314ffcb71af4a3dc95
2020-06-29 09:06:36 -03:00
Beat Küng
f6039bbfa7
stm32f7: add CANIOC_SET_NART and CANIOC_SET_ABOM ioctl's to can driver
2020-06-29 09:05:44 -03:00
Xiang Xiao
676a2b77f8
stdio.h: Implement fseeko and ftello function
...
specified here:
https://pubs.opengroup.org/onlinepubs/9699919799/functions/fseek.html
https://pubs.opengroup.org/onlinepubs/9699919799/functions/ftell.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-06-29 14:26:19 +09:00
Xiang Xiao
977f04a2b1
libc: sysconf support _SC_NPROCESSORS_CONF/_SC_NPROCESSORS_ONLN
...
specified here:
https://www.man7.org/linux/man-pages/man3/sysconf.3.html
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I87fba8476221797e59c69c1953974bebc8d0d7b3
2020-06-27 22:43:13 +01:00
chao.an
b83b83bf51
pthread/mutex: add PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP support
...
Note: the _NP suffix indicates a non-portable extension to the POSIX specification.
Library Functions Manual
PTHREAD_MUTEX(3)
...
SYNOPSIS
...
pthread_mutex_t recmutex = PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP;
...
DESCRIPTION
PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP (for recursive mutexes).
Change-Id: I58320421ee8dc9a90dca4f593b5d3908be3932db
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-06-26 09:52:56 -03:00
Ouss4
701100f6f9
drivers/sensors/mpu60x0: Add I2C support.
2020-06-24 23:30:34 -03:00
YAMAMOTO Takashi
ef5d204fd2
rewind: clear the error indicator
...
Make rewind() clear the error indicator of the stream
as it's specified by the standards.
2020-06-24 16:56:44 +08:00
Xiang Xiao
d24bd782a9
libc: Implement pathconf and fpathconf
...
specified here:
https://pubs.opengroup.org/onlinepubs/009695399/functions/fpathconf.html
note: only _PC_PATH_MAX is handled now
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Idd323dc10e8f31f10dd1fc64f467227808c11dbd
2020-06-23 17:34:54 +01:00
Xiang Xiao
1e166f7ecb
sysconf: Implement _SC_ATEXIT_MAX query
...
and remove the incorrect macro ATEXIT_MAX
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ia5d7dafc50e942f62f95137313c34741c6dd60ba
2020-06-23 17:34:54 +01:00
Gregory Nutt
f24c71be32
include/ftw.h: Add header file
...
Add the ftw.h header file as specified at OpenGroup.org:
https://pubs.opengroup.org/onlinepubs/009695399/basedefs/ftw.h.html
2020-06-23 17:34:28 +01:00
Ouss4
530cad304f
drivers/spi/spi_bitbang.c: Fix typos and nxstyle complaints.
2020-06-21 14:13:32 -06:00
Ouss4
bd82486f1c
drivers/lcd: Add support for the ST7735 TFT controller.
2020-06-21 14:13:32 -06:00
Ouss4
a09f88c4a6
include/nuttx/video/fb.h: Several parentheses were missing in macros.
2020-06-21 14:13:32 -06:00
David Sidrane
c91a81149d
cstdlib:Add missing atox to std namespace
2020-06-18 10:23:47 +08:00
Gregory Nutt
69e97c19ea
sched/sched/sched_note.c: Implement interrupt/syscall support
...
A previous PR added interrupt and system call scheduler notes. This addess buffering support for those notes.
2020-06-16 20:42:22 +01:00
Gregory Nutt
4fd506efaa
include/nuttx/sched_note.h: nxstyle fixes.
2020-06-16 14:04:53 -03:00
Yuuichi Nakamura
df2bc1e4c3
Add syscall and irqhandler hooks in sched_note.h
2020-06-16 14:04:53 -03:00
Matias Nitsche
53387b53c6
style fixes
2020-06-16 01:01:14 +01:00
Matias Nitsche
6c333d7cbf
bmp280: support getting temperature via ioctl()
2020-06-16 01:01:14 +01:00
Gregory Nutt
ff0161000f
cstdlib: mallinfo is no longer in stdlib.h
2020-06-15 08:35:44 -06:00
Peter van der Perk
b5c5948e1c
NXStyle fixes
2020-06-15 08:07:19 -06:00
Peter van der Perk
55d9e5f7af
net: Add SocketCAN support
2020-06-15 08:07:19 -06:00
YAMAMOTO Takashi
a607e6257f
Include malloc.h instead of stdlib.h for mallinfo()
...
This change also removes the malloc.h inclusion in stdlib.h
to break the build if there are still users of mallinfo() with stdlib.h.
2020-06-15 07:21:19 -06:00
YAMAMOTO Takashi
f1814dfca8
Move mallinfo from stdlib.h to malloc.h
...
mallinfo is meant to be API compatible with Linux,
where it's provided by malloc.h.
Make stdlib.h include malloc.h for now. It can be removed
once all users are updated to include malloc.h instead of
stdlib.h.
I have some app code which uses mallinfo(). I want to share
it between platforms. This commit allows me to reduce
platform-ifdefs.
(I think the API actually originated with System V. I don't
remember how it was there though. Anyway, I guess the
compatibility with Linux is more important than System V
these days.)
2020-06-15 07:21:19 -06:00
Xiang Xiao
5fbf52788f
libc/locale: Add the mininal support for locale_t operation
...
include duplocale, freelocale, newlocale and uselocale
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I9912003847dec660ae5c62836d4d56ebe0718869
2020-06-15 07:20:19 -06:00
Xiang Xiao
fd5fc2ab07
sched: Check the mutex consistent in main thread too
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I2d91154572805699237cfc028202021c8f8eee40
2020-06-15 07:16:21 -06:00
Xiang Xiao
309dda3ef8
sched: pthread_cleanup_[push|pop] should be callable from main thread
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ifefccda6cb7e2335e11976dcec74e308d64c7f5e
2020-06-15 07:16:21 -06:00
Alan C. Assis
7609b67496
Fix issues reported on PR #1233
2020-06-15 07:13:21 -06:00
Alan C. Assis
e1be7ace4b
Fix netdev and add Apache license to the file
2020-06-15 07:13:21 -06:00
Adam Porter
07c0faff59
Add support to CDC-MBIM USB host driver
...
This driver was created by Adam Porter and posted on NuttX
mailing list at Google Group on Nov 14 2019
2020-06-15 07:13:21 -06:00
Alin Jerpelea
c6c0214f9a
boards: arm: cxd56: initilize the video stream driver from the board
...
The video stream driver must be intialized from the board to comply with NuttX
NOTE:
Please remove the initalization from any camera example
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2020-06-15 08:10:49 +09:00
Ouss4
02ad0e9094
drivers/leds/ncp5623c&pca9635pw: Fix nxstyle issues.
2020-06-12 17:51:23 -03:00
Ouss4
0acf6da4d8
drivers/analog/ and include/nuttx/analog: Fix typos and nxstyle issues.
2020-06-12 16:04:02 -03:00
Ouss4
fe7dfec37d
include/nuttx/input/djoystick.h: Fix some trivial typos and nxstyle
...
issues.
2020-06-11 17:05:13 -06:00
Xiang Xiao
43d7c1e807
libc: Add IPTR for puts/fputs
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I2a83afb4d934a44ad1b56ec6dd72e654f4e112a3
2020-06-10 00:03:53 -07:00
Xiang Xiao
4fbbd2e3bf
arch: Move PRIxMAX and SCNxMAX definition to include/stdint.h
...
like other related macro(e.g. INTMAX_MIN, INTMAX_MAX...)
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I8863599960b1a9b1c22ae9c35735a379a4c745b0
2020-06-10 08:24:47 +02:00
Xiang Xiao
7758eb8658
arch: Define INTx_C and UINTx_C macro
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ia50ea8764880fabd3d878c95328632c761be6b43
2020-06-10 08:24:47 +02:00
Xiang Xiao
6f3cef856d
libc: Add the remaining wscanf series declaration
...
The function isn't implemented like other wide printf/scanf
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I0b26bb5174d1a9295fe2454d0e33f8227b8cbf8a
2020-06-08 11:42:56 +01:00
Xiang Xiao
7a18ebe459
drivers/led: Extend userled_set_t from 8bits to 32bits
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I5701b42ff930998198b1d915316cc4f2d085d4eb
2020-06-07 19:28:10 +01:00
Xiang Xiao
76965474ac
drivers/led: Let board_userled_initialize return the led number
...
so the lower half driver don't need include the specific board.h
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Icf6638a6865bac42150b5957376e55909f041d40
2020-06-07 19:28:10 +01:00
Xiang Xiao
1ba1c34b01
drivers/led: Decopule USERLED from ARCH_HAVE_LEDS
...
and let USERLED_LOWER depends on ARCH_HAVE_LEDS instead
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ie03e76d90b61a3d8d3457ccdd319a247b6075fa8
2020-06-07 19:28:10 +01:00
Xiang Xiao
a61b8a13c6
Fix nxstyle issue
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-06-07 19:28:10 +01:00
Xiang Xiao
1b47aa1cb2
drivers/button: Let board_button_initialize return the button number
...
so the lower half driver don't need include the specific board.h
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I2ff5c30049a5c5e8ee90baea56e9f4cb1a8a4f87
2020-06-07 19:28:10 +01:00
Ouss4
8da4b02350
drivers/audio: Add CS4344 driver.
2020-06-05 15:54:17 -03:00
Xiang Xiao
3409c989bd
sched/task: Simplify atexit and onexit implementation
...
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: I3028b74fe4872ae5cb376fa160e3cff79d5ad449
2020-06-05 13:29:22 +01:00
David Sidrane
b7ab9aa8f2
nuttx compiler.h: Add location directive for code and data
...
The ability to locate data and code in different sections
is becomming critical and common place in cores with multiple
bus matrices and power domains, where DMA can be limited to
a specific memory.
2020-06-05 15:21:42 +08:00