diff options
author | Cristian Iorga <cristian.iorga@intel.com> | 2013-03-04 19:17:50 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-03-07 11:14:36 +0000 |
commit | 6159ad1063f4be518d8f0a1c024f12fc16d13592 (patch) | |
tree | 1656a2325cfa420009af076c160752079981e9f9 /meta/recipes-connectivity/connman/connman-conf | |
parent | 3ab5908c4ee70f1dbdbbc58ac667a5b080518f1a (diff) | |
download | poky-6159ad1063f4be518d8f0a1c024f12fc16d13592.tar.gz |
connman: Wired inteface provisioned via qemu
- connman-conf package re-implemented
- connman 1.12 introduces provisioning for
wired interfaces also;
- wired interface settings are read from
kernel cmdline if present;
- after that are passed to connman as a
config file
- for BA, this is not needed, as BA will
have a network infrastructure to work with.
Fixes [YOCTO #3227];
Fixes [YOCTO #3804];
Fixes [YOCTO #3843].
(From OE-Core rev: 5711e0cf88fac0de8a5317b16a287b335c827c8f)
Signed-off-by: Cristian Iorga <cristian.iorga@intel.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-connectivity/connman/connman-conf')
3 files changed, 24 insertions, 3 deletions
diff --git a/meta/recipes-connectivity/connman/connman-conf/qemuall/main.conf b/meta/recipes-connectivity/connman/connman-conf/qemuall/main.conf deleted file mode 100644 index 01973e7f71..0000000000 --- a/meta/recipes-connectivity/connman/connman-conf/qemuall/main.conf +++ /dev/null | |||
@@ -1,3 +0,0 @@ | |||
1 | [General] | ||
2 | |||
3 | NetworkInterfaceBlacklist = eth | ||
diff --git a/meta/recipes-connectivity/connman/connman-conf/qemuall/wired-setup b/meta/recipes-connectivity/connman/connman-conf/qemuall/wired-setup new file mode 100644 index 0000000000..135a6c19ac --- /dev/null +++ b/meta/recipes-connectivity/connman/connman-conf/qemuall/wired-setup | |||
@@ -0,0 +1,16 @@ | |||
1 | #!/bin/sh | ||
2 | |||
3 | CONFIGF=/var/lib/connman/wired.config | ||
4 | |||
5 | # Extract wired network config from /proc/cmdline | ||
6 | NET_CONF=`cat /proc/cmdline |sed -ne 's/^.*ip=\([^ ]*\):\([^ ]*\):\([^ ]*\):\([^ ]*\).*$/\1\/\4\/\3/p'` | ||
7 | |||
8 | # Check if eth0 is already set via kernel cmdline | ||
9 | if [ "x$NET_CONF" = "x" ]; then | ||
10 | # Wired interface is not configured via kernel cmdline | ||
11 | # Remove connman config file template | ||
12 | rm ${CONFIGF} | ||
13 | else | ||
14 | # Setup a connman config accordingly | ||
15 | sed -i -e "s|^\(IPv4 =\)|\1 ${NET_CONF}|" ${CONFIGF} | ||
16 | fi | ||
diff --git a/meta/recipes-connectivity/connman/connman-conf/qemuall/wired.config b/meta/recipes-connectivity/connman/connman-conf/qemuall/wired.config new file mode 100644 index 0000000000..996e429e72 --- /dev/null +++ b/meta/recipes-connectivity/connman/connman-conf/qemuall/wired.config | |||
@@ -0,0 +1,8 @@ | |||
1 | [global] | ||
2 | Name = Wired | ||
3 | Description = Wired network configuration | ||
4 | |||
5 | [service_ethernet] | ||
6 | Type = ethernet | ||
7 | IPv4 = | ||
8 | MAC = 52:54:00:12:34:56 | ||