base-files: fix ucidef_set_interface() protocol selection
authorJo-Philipp Wich <jo@mein.io>
Fri, 25 May 2018 05:28:28 +0000 (07:28 +0200)
committerJo-Philipp Wich <jo@mein.io>
Fri, 25 May 2018 05:48:25 +0000 (07:48 +0200)
commit7e664b7c2dc00006ba29bf947cf177b5bccdc47d
tree5cd37f5cc1a9c816e810bda584f9239fc3ed2306
parent69f544937f8498e856690f9809a016f0d7f5f68b
base-files: fix ucidef_set_interface() protocol selection

The previous refactoring of ucidef_set_interface() removed the protocol
selection heuristic which breaks the networking defaults for the majority
of boards.

Re-add the protocol selection and rename two bad "proto" references to
the expected "protocol" value.

Fixes: 85048a9c1f ("base-files: rework _ucidef_set_interface to be more generic")
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
package/base-files/files/lib/functions/uci-defaults.sh