Many upstream fixes (more to come)

Change-Id: I53a206aa4dadbc7c5b65f4e0486a22bd7c9cb08d

Conflicts:

	include/net/ip.h