This patch gets the newlib standard stream descriptors playing well with the
lwip socket descriptors and the spiffs file descriptors. The LWIP_SOCKET_OFFSET
is now defined to be 3, rather than zero, to avoid clashing with the standard
stream descriptors, and the SPIFFS_FILEHDL_OFFSET is bumped up to start after
the lwip descriptors.
It now accounts for the number of rx pool buffers used and the
available memory when deciding the number of ooseq buffers to retain.
Enable the TCP Selective ACK support which appears to help a lot on
lossy wifi when using the OOSEQ option.
With this option enabled some lwip input processing occurs in the pp task which
works well for some uses but some code uses a lot of stack (e.g. mdns) and will
overflow the pp task stask, or might unnecessarily slow the critical pp task,
so disable this by default and if not already defined.