Commit Graph

35 Commits

Author SHA1 Message Date
chao an
a1ea7f9df7 netinit: associate wlan if DRIVERS_IEEE80211 enabled
Signed-off-by: chao an <anchao@xiaomi.com>
2022-09-27 12:20:25 +08:00
Xiang Xiao
8361990261 netutils: Check lo by CONFIG_NET_LOOPBACK not CONFIG_NET_LOCAL
CONFIG_NET_LOCAL is used to enable Unix Domain Socket

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-02-09 12:13:31 +08:00
Xiang Xiao
66dbaa4539 Replace self defined macros with NET_SOCK_[FAMILY|TYPE|PROTOCOL]
NET_SOCK_* is defined by nuttx/net/netconfig.h and then can be shared

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-12-20 16:04:29 -03:00
Alin Jerpelea
0a6b1f55ab netutils: update licenses to Apache
Gregory Nutt is has submitted the SGA

Sebastien Lorquet has submitted the ICLA

as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-11 05:05:27 -05:00
Alin Jerpelea
ec339bc49a Makefiles: Gregory Nutt: update licenses to Apache
Gregory Nutt is the copyright holder for those files and he has submitted the
SGA as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-07 21:35:33 -05:00
YAMAMOTO Takashi
f6f99c43aa netinit: Make the default SSID and passphrase empty
* It doesn't make much sense to have the default values for
  these highly environment-dependent settings.

* netutils/netinit/netinit_associate.c calls wpa_driver_wext_associate
  if the SSID is not empty. Depending on the environment, it can take
  long to fail. It slows down the boot of some configurations
  considerably. eg. esp32-devkitc:wapi
2020-12-22 01:23:55 -06:00
David Sidrane
cb111c0ee8 netinit:Fix typo IPCFG_USE_DHCPC->IPCFG_USE_DHCP 2020-10-16 10:11:21 +08:00
Gregory Nutt
f65b16bb2e Incorporate IP configuration files into netinit.
Uses logic from apps/fsutils/ipcfg to obtain the IP address configuration from a file, if available.  This only effects the behavior of netinit if CONFIG_FSUTILS_IPCFG is selected and if an IP configuration file is available on a file system. Otherwise, it reverts to the preceding behavior.

Also adds definitions to apps/include/fsutils/ipcfg.h to formalize a bit encoding of the prototype which was already in use, but not documented.

Also fixes some bad assertions (duplication of PR #420) and makes use of variable names consistent in ipcfg.h comments and in ipcfg_text implementation.
2020-10-06 10:42:35 -07:00
chao.an
3061dbf2f8 wireless/wapi: add option to associate with bssid
Change-Id: I68ef42edfc50ef5baf0f02a570d0e7f79669659f
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-09-19 04:20:43 -07: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
Peter van der Perk
839b3530d4 netlib: add AF_CAN family and CONFIG_NET_CAN support 2020-06-15 07:23:37 -06:00
Xiang Xiao
69f013e74e build: Remve the unnecessary .gitignore
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-05-23 15:56:35 +01: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
chao.an
6ab29d4ffb wapi: skip associate if ssid is invalid
Signed-off-by: chao.an <anchao@xiaomi.com>
2020-04-03 13:29:19 +01:00
YAMAMOTO Takashi
c9c1d2bbc6 Change the default of stack size configs to DEFAULT_TASK_STACKSIZE
Where:
 * Under examples and testing
 * And the default value is less than 2048

Using a bit more memory for examples and tests should not
be a critical problem.
2020-03-27 02:43:11 -05:00
Xiang Xiao
1511403fdf Revert "Don't generate .depend anymore"
This reverts commit cc5ad09caa.
2020-03-22 23:09:40 -05:00
Xiang Xiao
cc5ad09caa
Don't generate .depend anymore 2020-03-22 18:15:21 +00:00
Xiang Xiao
d96bc5a4fb netinit: Unregister notification at the end in netinit_monitor 2020-03-07 13:13:55 -06:00
chao.an
52ad01f0bf netutils: save wapi config to file system
save and reload the wapi config from file system
2020-02-26 16:11:46 +00:00
chao.an
ee615f0568 net/wapi: remove unnecessary cast 2020-02-26 16:11:39 +00:00
Xiang Xiao
41d88f06e7 Run codespell -w with the latest dictonary again 2020-02-23 07:10:14 -06:00
Xiang Xiao
e0dcfa0c55 Remove extra whitespace from files (#43)
* Remove multiple newlines at the end of file
* Remove the white space from the end of line
2020-01-31 08:29:24 -06:00
Xiang Xiao
db61c92100 Fix dhcpd #17
apps/netutils/dhcpd/dhcpd.c:  Fix unused const variable

dhcpd.c:273:29: warning: 'g_anyipaddr' defined but not used [-Wunused-const-variable=]
 static const uint8_t        g_anyipaddr[4] = {0, 0, 0, 0};

apps/netutils/dhcpd:  Make dhcpd interface configurable

apps/netutils/dhcpd:  Lease address directly if hit in address range

apps/netutils/netinit: Initialize dhcpc_state

update the addresses only on request success
2020-01-16 12:06:25 -06:00
Xiang Xiao
857158451b Unify the void cast usage
1.Remove void cast for function because many place ignore the returned value witout cast
2.Replace void cast for variable with UNUSED macro

Change-Id: Ie644129a563244a6397036789c4c3ea83c4e9b09
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2020-01-02 23:21:01 +08:00
Gregory Nutt
1859f56380 apps/netutils/netinit, apps/netutils/netlib/, and apps/include/netutils/netlib.h: Extend a few definitions to permit building netutils and netinit with only Netlink sockets enabled. 2019-11-19 09:49:36 -06:00
Xiang Xiao
7808eb62d2 apps/: In all Make.def files, append to CONFIGURED_APPS patch with the absolute path. 2019-10-17 11:33:59 -06:00
Gregory Nutt
3a23523147 Makefiles: This reverts part of commit cf0365ea9. It restores 'conditional' inclusion of TOPDIR/Make.defs. Otherwise all make targets fail if the board has not been configured. That is okay most of the time, but not for things like clean and distclean which should not depend on being configured. 2019-10-15 09:25:48 +08:00
Xiang Xiao
cf0365ea92 Clean up Makefile under apps folder no functional changes. 2019-10-04 08:35:46 -06:00
Nathan Hartman
4fd1058200 apps/netutils/netinit/netinit.c: Improve cleanup, removing 1 of 2 warnings. Unhook PHY notification signal handler when cleaning up, if an error occurs after the signal handler is put into place. 2019-07-26 10:59:28 -06:00
Nathan Hartman
44a8d7c80e netutils/netinit/Kconfig: Fix some typos. 2019-07-23 16:09:31 -06:00
Gregory Nutt
8f0b299e82 Trivially cosmetic 2019-07-11 12:15:08 -06:00
Gregory Nutt
87c1083357 apps/netutils/netinit: MAC address configuration was represented by type long long. That is a problem for architectures that do not support typle long long. Replaces by two long configuration items. 2019-06-03 10:04:44 -06:00
Gregory Nutt
8f5944c4a8 Squashed commit of the following:
include/ and netutils/:  Remove references to CONFIG_DISABLE_SIGNALS.  Signals can no longer be disabled.
    nshlib/:  Remove references to CONFIG_DISABLE_SIGNALS.  Signals can no longer be disabled.
    system/:  Remove references to CONFIG_DISABLE_SIGNALS.  Signals can no longer be disabled.
    testing/:  Remove references to CONFIG_DISABLE_SIGNALS.  Signals can no longer be disabled.
    examples/:  Remove references to CONFIG_DISABLE_SIGNALS.  Signals can no longer be disabled.
2019-04-29 14:53:38 -06:00
Gregory Nutt
ad57b3de4d apps/graphics/twm4nx: Add options to initialize the system via boardctl() and to bring up the network using the new apps/netutils/netinit. This latter is only necessary because VNC is being used to provide graphics. 2019-04-29 11:49:15 -06:00
Gregory Nutt
94a0d92b54 This commit removes the private network initialization logic from NSH and puts in a common location at apps/netutils/netinit. Now that netork initialization logic can be used by applications that do not include NSH.
Squashed commit of the following:

    apps/nshlib:  Remove NSH initialization.  Now uses the common apps/netutils/netinit logic (which was cloned from nshlib to begin with).

    apps/netutils/netinit:  Clone network initialization logic from NSH to this directory so that it can be available for general use.
2019-04-29 10:22:56 -06:00