Commit Graph

37 Commits

Author SHA1 Message Date
Xiang Xiao
893387b2c5 Fix the minor style issue
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 19:07:16 +02:00
Xiang Xiao
4941182cc6 Make.defs: Change "ifeq ($(XXX),y)" to "ifneq ($(XXX),)
to support the tristate option correctly and unify the usage

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-16 14:59:08 +02:00
zhanghongyu
6e8ea78d70 usrsock_server: combine response and events when socket setup case
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-10-14 11:39:41 +09:00
zhanghongyu
8a2f29c9b5 usrsock_server: fix unblock socket connect error
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-10-14 11:39:41 +09:00
Xiang Xiao
9291d07a87 Fix the coding style issue
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-06 12:20:32 +02:00
Xiang Xiao
a86790c367 poll: Don't need monitor POLLERR or POLLHUP explicitly
since spec require the implementation always report POLLERR/POLLHUP:
https://pubs.opengroup.org/onlinepubs/9699919799/functions/poll.html

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-10-05 05:58:02 +02:00
weizihan
e1ed558543 apps: Fix the bug that didn't initialize structure
Signed-off-by: weizihan <weizihan@xiaomi.com>
2022-08-16 23:18:18 +08:00
zhanghongyu
26892be894 usrsock: fix usrsock close hang when net not ready
reason: ept NULL when close request and poll event occur simultaneously

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-08-15 16:41:17 +03:00
zhanghongyu
451243accb usrsock_server: Reduce unnecessary poll prepare
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-08-15 16:41:17 +03:00
zhanghongyu
707b7be4da usrsock: ioctl Remove bad copy operations
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-08-15 16:41:17 +03:00
ligd
1345fa13b1 usrsock: adjust rptun API
Signed-off-by: ligd <liguiding1@xiaomi.com>
2022-07-27 20:36:59 +08:00
zhanghongyu
b80ef1df87 usrsock: Don't clear recv and send available flag
Don't clear available flag if the response indicate there is more data

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-04-16 14:07:48 +08:00
songlinzhang
460f631fa3 netutils/usrsock_rpmsg: broadcast the client DNS server to server
Signed-off-by: songlinzhang <songlinzhang@xiaomi.com>
2022-04-15 16:05:38 +08:00
zhanghongyu
a6c986d516 rpmsg_usrsock: Support the wireless ioctl which contain pointer 2/2
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-04-14 02:47:53 +08:00
zhanghongyu
3a42d849f5 Revert "rpmsg: pointer of netdev ioctl support cross-core memory access"
This reverts commit bd539651cdf1e5067dc5d21349ef835e98e262eb.

Reason for revert: Change the implementation method

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-04-14 02:47:53 +08:00
Xiang Xiao
0c7adf4567 usrsock/rpmsg: Change the dependence from OPENAMP to RPTUN
since all rpmsg driver need the extension api exposed by rptun driver

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-04-05 10:05:47 +03:00
zhanghongyu
16c1fec99d usrsock: Move event field to usrsock_message_common_s
Zero the events field for all response message

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-04-03 11:39:19 +09:00
zhanghongyu
f1d5d6e671 fix: ap socket can not accept twice
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-03-15 18:01:04 +08:00
zhanghongyu
6c2a487f85 feature: pointer of netdev ioctl support cross-core access via clean dcache
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2022-03-15 18:01:04 +08:00
Xiang Xiao
f31cc67da8 netutils/usrsock_rpmsg: Switch the nonblocking mode by psock_ioctl instead
since it's more simpler than psock_ioctl

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-03-04 14:00:29 +02:00
Petro Karashchenko
9480c0ec12 include: fix double include pre-processor guards
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2022-01-16 17:36:21 +08:00
chao.an
df53de1d68 net/usrsock: replace usrsock xid type to uint64_t
Signed-off-by: chao.an <anchao@xiaomi.com>
2022-01-05 13:25:21 +08:00
chao.an
c7f28f5f9e usrsock/rpmsg/server: select eventfd by default
Change-Id: I8e3bb4f035781e045ccf85c515b6480c7f9317bc
Signed-off-by: chao.an <anchao@xiaomi.com>
(cherry picked from commit abbad446b77b5703e582f529271918fcee0e920e)
2021-06-22 10:31:35 -03:00
chao.an
084cc55064 usrsock/server: replace the wakeup source to eventfd
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-04-21 09:53:40 -05:00
chao.an
2214e51457 netutls/usrsock_rpmsg_server: add support for send reassemble
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-04-21 09:53:40 -05:00
Xiang Xiao
0ee6f0e5e0 netutils/rpmsg: Prepare poll fds only when error with EINTR
to improve the performance

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Id88df8618473b56236821b9e0f6399dfef2c958d
2021-04-13 08:32:12 +01:00
Jiuzhu Dong
4c6ded2661 app: delete NFILE_DESCRIPTORS limits
Change-Id: I3ced2b2b7440a2c79a712cfc97b4cd15d2bddd4c
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-03-12 21:12:07 -08:00
Jiuzhu Dong
3708b6e478 net/socket: recover POLLSOCK and keep polling directly by socket
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-03-01 09:20:04 -08:00
Jiuzhu Dong
0e1148cf1d usrsock: delete sock->s_crefs to fix compile break
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-02-25 01:44:45 -08:00
Jiuzhu Dong
459916f81c net/socket: delete config CONFIG_NSOCKET_DESCRIPTORS
N/A

Change-Id: I50376600292a853652af76e2236bb428d1037313
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-02-24 05:53:14 -08:00
ligd
0781dbf9e9 usrsock_rpmsg: fix can't wake ppoll when no ACTION
N/A

no matter open/close CONFIG_SIGUSR1_ACTION, usrsock always do,
unmask SIGUSR1, set action to NULL.

Change-Id: I39ba51db8e4c77b4923c97598b3cb73c12473a2c
Signed-off-by: ligd <liguiding1@xiaomi.com>
2020-10-27 10:16:55 -07:00
Xiang Xiao
837b405624 Change all files come from Xiaomi/Pinecone to Apache License 2.0
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-08-23 15:44:32 -06:00
SPRESENSE
c1bf012211 netutils/usrsock_rpmsg: Change to pass the flags to the psock interface
Pass the sendto/recvfrom flags argument to the psock interface.
2020-08-06 20:52:09 +09:00
Xiang Xiao
deaa6c5b7b build: Replace $(TOPDIR)/Make.defs with $(APPDIR)/Make.defs
and move NUTTXLIB defintion to the common place

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-07-09 15:17:37 -03:00
Xiang Xiao
ead498a788 build: Remove the workaround for the inexistence of .config/Make.defs
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-21 17:43:42 +01:00
Gregory Nutt
779635afa6 netutils/usrsock_rpmsg: Fix build failures
Not all files were correctly modified when usrsock_rpmsg was moved from apps/system to apps/netutils.  Changes were overlooked in the Makefile and Make.defs file.
2020-05-07 03:00:27 +01:00
Xiang Xiao
4389885cf6 Move usrsock_rpmsg from system to netutils folder
This is a more suitable location

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-06 08:59:53 -06:00