Commit Graph

16 Commits

Author SHA1 Message Date
Zhe Weng 8819eeaf15 net: Implement shutdown() interface and tcp shutdown
Signed-off-by: Zhe Weng <wengzhe@xiaomi.com>
2023-01-31 11:15:01 +08:00
Xiang Xiao 695f42f8d2 net: Move accept to libc after https://github.com/apache/nuttx/pull/8083
since accept can simply forward to kernel accept4 function

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2023-01-13 11:23:42 +02:00
zhanghongyu e019b0d0b8 libc/net: add inet_network function
Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-01-06 22:20:19 +08:00
Xiang Xiao cc1a1b5781 net: Implement getifaddrs and freeifaddrs
specify here:
https://man7.org/linux/man-pages/man3/getifaddrs.3.html

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-12-21 11:01:33 -03:00
Xiang Xiao c562263205 net: Move if_nametoindex and if_indextoname to libc
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-12-19 10:08:57 -06:00
chao.an 940a07e1e5 net/socketpair: move socketpair implement into socket internal
Signed-off-by: chao.an <anchao@xiaomi.com>
2021-07-08 03:05:43 -05:00
Xiang Xiao 20f5a28e49 net: Add if_nameindex and if_freenameindex API
Specified here:
https://man7.org/linux/man-pages/man3/if_nameindex.3.html

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ia5daed775bd11fa5978d54860632554da8f7b416
2021-06-26 22:37:12 +01:00
Peter Bee e223f60c09 net/socket: move si_send/recv into sendmsg/recvmsg
Implement si_send/sendto/recvfrom with si_sendmsg/recvmsg, instead of
the other way round.

Change-Id: I7b858556996e0862df22807a6edf6d7cfe6518fc
Signed-off-by: Peter Bee <bijunda1@xiaomi.com>
2021-03-05 04:46:13 -08:00
Alin Jerpelea b5d4a01821 libs: Author Gregory Nutt: update licenses to Apache
Gregory Nutt has submitted the SGA and we can migrate the licenses
 to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-03-03 18:52:53 -08: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
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
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
Xiang Xiao c85fe67ebc net/loopback: Move g_lo_* global variable to libc/net/
so netdb could reuse these global variable directly

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Iaa26ddbdaf416f64d43c6e8888a14bbe0c3405eb
2020-03-30 09:47:28 -06:00
ligd 4a8b750ecd ibs/libc/net: Add basic implementation for recvmsg and sendmsg per OpenGroup.org specification. 2018-11-09 11:39:05 -06:00
Juha Niskanen 5c8a975d79 libs/libc/net: Add inet_aton() 2018-06-08 07:06:27 -06:00
Gregory Nutt cf99fb40c9 This commit moves all of the libraries under a common directory called libs/. This most certainly break libcxx and uClibc++ for now.
Squashed commit of the following:

    libs/libxx:  Fix some confusing in naming.  If the directory is called libxx, then the library must be libxx.a (unless perhaps LIBCXX is selected).
    libs/:  Fix paths in moved library directories.
    libs:  Brute force move of libc, libnx, and libxx to libs.  Cannot yet build it in that configuration.
2018-05-29 13:21:26 -06:00