Simon Kuenzer [Thu, 7 Feb 2019 23:00:35 +0000 (00:00 +0100)]
Netif status print callback
Introduce a status print hook to all netifs operated by the lwIP
stack. State changes (e.g., assigning of an IP, bringing device up or
down) are printed to the standard console. Because the stack is not
printing any message to the console with the default configuration, we
enable this print hook as default.
Signed-off-by: Simon Kuenzer <simon.kuenzer@neclab.eu> Reviewed-by: Sharan Santhanam <sharan.santhanam@neclab.eu>
Simon Kuenzer [Thu, 7 Feb 2019 23:00:34 +0000 (00:00 +0100)]
Attach uknetdev netifs during boot
Scan for uknetdev devices and attach them automatically to the lwIP
stack during initialization. If DHCP support is enabled, the stack
will query for an address on the interfaces.
Signed-off-by: Simon Kuenzer <simon.kuenzer@neclab.eu> Reviewed-by: Sharan Santhanam <sharan.santhanam@neclab.eu>
Simon Kuenzer [Thu, 7 Feb 2019 23:00:33 +0000 (00:00 +0100)]
Netif driver for libuknetdev devices
Introduces a netif driver for libuknetdev devices. Packet buffers are
allocated on the heap for now. Receive interrupts are supported and
enabled when lwIP is operated in "threaded" mode. Zero-copy receive is
implemented with packet buffers having two personalities: pbuf and netbuf.
Signed-off-by: Simon Kuenzer <simon.kuenzer@neclab.eu> Reviewed-by: Sharan Santhanam <sharan.santhanam@neclab.eu>
Simon Kuenzer [Thu, 7 Feb 2019 23:00:32 +0000 (00:00 +0100)]
Update to lwIP 2.1.2
Update lwIP from 2.0.3 to the latest relase 2.1.2 from Dec 2018. We
transform the rather beta state of our glue library to a more stable
implementation based on the latest staging branch of Unikraft towards
release 0.3.
This commit provides the following features as selectable options from
lwIP:
- Two operation modes: "threaded" or as (part of a) "mainloop"
- IPv4 support
- Experimental IPv6 support (incomplete)
- Protocols: UDP, TCP, ICMP, IGMP, SNMP
- DNS resolver
- DHCPv4 client
- Socket API
Sharan Santhanam [Fri, 15 Jun 2018 20:53:48 +0000 (22:53 +0200)]
Expose socket header & disable socket polling
In this patch, we expose the socket API through lwIP. In its current
implementation, we do disable support for select()/poll() on a file
descriptor since an implementation is missing in vfscore.
We are going to add this feature again in the near future.
Simon Kuenzer [Thu, 14 Jun 2018 23:13:10 +0000 (01:13 +0200)]
Adopt to new configuration variable name scheme of Unikraft
Adopts to the new configuration variable name scheme introduced
with latest Unikraft build system (see patch de27b01: "build:
add prefix CONFIG_ to every kconfig symbol")
Sharan Santhanam [Wed, 13 Jun 2018 13:41:46 +0000 (15:41 +0200)]
Adhering to uksched API for thread creation
sys_thread_new was unnecessarily using a static allocated variable for
creating a thread. On failure, uk_printd() was called without specifying
a level which fails. Additonally the code style of this function is updated.