All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
@ 2015-07-23 15:32 Herve Jourdain
  2015-07-23 16:00 ` Mauro Carvalho Chehab
  2015-07-23 16:38 ` Andreas Müller
  0 siblings, 2 replies; 12+ messages in thread
From: Herve Jourdain @ 2015-07-23 15:32 UTC (permalink / raw)
  To: 'Andrei Gherzan', 'Petter Mabäcker'; +Cc: yocto

[-- Attachment #1: Type: text/plain, Size: 1769 bytes --]

This patch adds systemd-networkd for RaspberryPi in the meta-raspberrypi
layer, in order to have Ethernet and Networking work out of the box.

 

This said, I’m not 100% sure if it should be enabled in meta-raspberrypi,
instead of another custom layer.

But something similar needs to be added somewhere, and with the current
version of Yocto on RaspberryPi, without this patch, network just doesn’t
start…

 

Signed-off-by: Herve Jourdain <herve.jourdain@neuf.fr
<mailto:herve.jourdain@neuf.fr> >

---

diff -Naur meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
meta-raspberrypi/recipes-core/systemd/files/eth.network

--- meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
1970-01-01 08:00:00.000000000 +0800

+++ meta-raspberrypi/recipes-core/systemd/files/eth.network    2015-07-22
12:01:53.587830690 +0800

@@ -0,0 +1,6 @@

+[Match]

+Name=eth*

+

+[Network]

+DHCP=v4

+

diff -Naur meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend

--- meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
1970-01-01 08:00:00.000000000 +0800

+++ meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
2015-07-22 12:05:07.307838546 +0800

@@ -0,0 +1,17 @@

+FILESEXTRAPATHS_prepend := "${THISDIR}/files:"

+

+EXTRA_OECONF += "--disable-ldconfig"

+

+PACKAGECONFIG += "networkd resolved"

+

+CFLAGS_append_arm = " -fno-lto"

+

+SRC_URI += "file://eth.network"

+

+FILES_${PN} += "{sysconfdir}/systemd/network/*"

+

+do_install_append() {

+    install -d ${D}${sysconfdir}/systemd/network/

+    install -m 0644 ${WORKDIR}/*.network ${D}${sysconfdir}/systemd/network/

+}

+

 


[-- Attachment #2: Type: text/html, Size: 6051 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 15:32 [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi Herve Jourdain
@ 2015-07-23 16:00 ` Mauro Carvalho Chehab
  2015-07-23 16:25   ` Herve Jourdain
  2015-07-23 16:38 ` Andreas Müller
  1 sibling, 1 reply; 12+ messages in thread
From: Mauro Carvalho Chehab @ 2015-07-23 16:00 UTC (permalink / raw)
  To: Herve Jourdain; +Cc: yocto

Em Thu, 23 Jul 2015 17:32:35 +0200
Herve Jourdain <herve.jourdain@neuf.fr> escreveu:

> This patch adds systemd-networkd for RaspberryPi in the meta-raspberrypi
> layer, in order to have Ethernet and Networking work out of the box.
> 
>  
> 
> This said, I’m not 100% sure if it should be enabled in meta-raspberrypi,
> instead of another custom layer.
> 
> But something similar needs to be added somewhere, and with the current
> version of Yocto on RaspberryPi, without this patch, network just doesn’t
> start…

I guess putting it at BSP is not right. Ethernet network does work on Tizen
on Yocto:
	http://blogs.s-osg.org/tizen-rpi2-now-supporting-3d-acceleration/

Regards,
Mauro


> 
>  
> 
> Signed-off-by: Herve Jourdain <herve.jourdain@neuf.fr
> <mailto:herve.jourdain@neuf.fr> >
> 
> ---
> 
> diff -Naur meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> meta-raspberrypi/recipes-core/systemd/files/eth.network
> 
> --- meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> 1970-01-01 08:00:00.000000000 +0800
> 
> +++ meta-raspberrypi/recipes-core/systemd/files/eth.network    2015-07-22
> 12:01:53.587830690 +0800
> 
> @@ -0,0 +1,6 @@
> 
> +[Match]
> 
> +Name=eth*
> 
> +
> 
> +[Network]
> 
> +DHCP=v4
> 
> +
> 
> diff -Naur meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> 
> --- meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> 1970-01-01 08:00:00.000000000 +0800
> 
> +++ meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> 2015-07-22 12:05:07.307838546 +0800
> 
> @@ -0,0 +1,17 @@
> 
> +FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
> 
> +
> 
> +EXTRA_OECONF += "--disable-ldconfig"
> 
> +
> 
> +PACKAGECONFIG += "networkd resolved"
> 
> +
> 
> +CFLAGS_append_arm = " -fno-lto"
> 
> +
> 
> +SRC_URI += "file://eth.network"
> 
> +
> 
> +FILES_${PN} += "{sysconfdir}/systemd/network/*"
> 
> +
> 
> +do_install_append() {
> 
> +    install -d ${D}${sysconfdir}/systemd/network/
> 
> +    install -m 0644 ${WORKDIR}/*.network ${D}${sysconfdir}/systemd/network/
> 
> +}
> 
> +
> 
>  
> 


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 16:00 ` Mauro Carvalho Chehab
@ 2015-07-23 16:25   ` Herve Jourdain
  2015-07-23 18:28     ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 12+ messages in thread
From: Herve Jourdain @ 2015-07-23 16:25 UTC (permalink / raw)
  To: 'Mauro Carvalho Chehab'; +Cc: yocto

Hi Mauro,

Well, that's precisely one of my concerns. I believe that one of the Tizen layers might do just that. Maybe it should be at the Yocto layer.
But it seems not to be with the one I'm using. And just enabling system - which can be done at distro level - is not enough, there is a need for a bbappend and a config file.
So honestly, since I was experimenting with system, I stumbled on this one, and I had initially put that patch in another layer - custom one.

The question that remains is how do we make sure that Poky on raspberry pi has network enabled by default when people switch to system? Since I don't know where else to put it, I decided to propose the patch for the raspberrypi layer, knowing it probably makes more sense to put it somewhere else.

BR,

Herve

-----Original Message-----
From: Mauro Carvalho Chehab [mailto:mchehab@osg.samsung.com] 
Sent: jeudi 23 juillet 2015 18:00
To: Herve Jourdain
Cc: 'Andrei Gherzan'; 'Petter Mabäcker'; yocto@yoctoproject.org
Subject: Re: [yocto] [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi

Em Thu, 23 Jul 2015 17:32:35 +0200
Herve Jourdain <herve.jourdain@neuf.fr> escreveu:

> This patch adds systemd-networkd for RaspberryPi in the 
> meta-raspberrypi layer, in order to have Ethernet and Networking work out of the box.
> 
>  
> 
> This said, I’m not 100% sure if it should be enabled in 
> meta-raspberrypi, instead of another custom layer.
> 
> But something similar needs to be added somewhere, and with the 
> current version of Yocto on RaspberryPi, without this patch, network 
> just doesn’t start…

I guess putting it at BSP is not right. Ethernet network does work on Tizen on Yocto:
	http://blogs.s-osg.org/tizen-rpi2-now-supporting-3d-acceleration/

Regards,
Mauro


> 
>  
> 
> Signed-off-by: Herve Jourdain <herve.jourdain@neuf.fr 
> <mailto:herve.jourdain@neuf.fr> >
> 
> ---
> 
> diff -Naur 
> meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> meta-raspberrypi/recipes-core/systemd/files/eth.network
> 
> --- meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> 1970-01-01 08:00:00.000000000 +0800
> 
> +++ meta-raspberrypi/recipes-core/systemd/files/eth.network    2015-07-22
> 12:01:53.587830690 +0800
> 
> @@ -0,0 +1,6 @@
> 
> +[Match]
> 
> +Name=eth*
> 
> +
> 
> +[Network]
> 
> +DHCP=v4
> 
> +
> 
> diff -Naur 
> meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> 
> --- meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> 1970-01-01 08:00:00.000000000 +0800
> 
> +++ meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> 2015-07-22 12:05:07.307838546 +0800
> 
> @@ -0,0 +1,17 @@
> 
> +FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
> 
> +
> 
> +EXTRA_OECONF += "--disable-ldconfig"
> 
> +
> 
> +PACKAGECONFIG += "networkd resolved"
> 
> +
> 
> +CFLAGS_append_arm = " -fno-lto"
> 
> +
> 
> +SRC_URI += "file://eth.network"
> 
> +
> 
> +FILES_${PN} += "{sysconfdir}/systemd/network/*"
> 
> +
> 
> +do_install_append() {
> 
> +    install -d ${D}${sysconfdir}/systemd/network/
> 
> +    install -m 0644 ${WORKDIR}/*.network 
> + ${D}${sysconfdir}/systemd/network/
> 
> +}
> 
> +
> 
>  
> 



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 15:32 [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi Herve Jourdain
  2015-07-23 16:00 ` Mauro Carvalho Chehab
@ 2015-07-23 16:38 ` Andreas Müller
  2015-07-23 22:50   ` Herve Jourdain
  1 sibling, 1 reply; 12+ messages in thread
From: Andreas Müller @ 2015-07-23 16:38 UTC (permalink / raw)
  To: Herve Jourdain; +Cc: Yocto Project

On Thu, Jul 23, 2015 at 5:32 PM, Herve Jourdain <herve.jourdain@neuf.fr> wrote:
> This patch adds systemd-networkd for RaspberryPi in the meta-raspberrypi
> layer, in order to have Ethernet and Networking work out of the box.
>
>
>
> This said, I’m not 100% sure if it should be enabled in meta-raspberrypi,
> instead of another custom layer.
>
> But something similar needs to be added somewhere, and with the current
> version of Yocto on RaspberryPi, without this patch, network just doesn’t
> start…
>
>
>
> Signed-off-by: Herve Jourdain <herve.jourdain@neuf.fr>
>
> ---
>
> diff -Naur meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> meta-raspberrypi/recipes-core/systemd/files/eth.network
>
> --- meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> 1970-01-01 08:00:00.000000000 +0800
>
> +++ meta-raspberrypi/recipes-core/systemd/files/eth.network    2015-07-22
> 12:01:53.587830690 +0800
>
> @@ -0,0 +1,6 @@
>
> +[Match]
>
> +Name=eth*
>
> +
>
> +[Network]
>
> +DHCP=v4
>
> +
>
> diff -Naur meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
>
> --- meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> 1970-01-01 08:00:00.000000000 +0800
>
> +++ meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> 2015-07-22 12:05:07.307838546 +0800
>
> @@ -0,0 +1,17 @@
>
> +FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
>
> +
>
> +EXTRA_OECONF += "--disable-ldconfig"
>
> +
>
> +PACKAGECONFIG += "networkd resolved"
>
> +
>
> +CFLAGS_append_arm = " -fno-lto"
>
> +
>
> +SRC_URI += "file://eth.network"
>
> +
>
> +FILES_${PN} += "{sysconfdir}/systemd/network/*"
>
> +
>
> +do_install_append() {
>
> +    install -d ${D}${sysconfdir}/systemd/network/
>
> +    install -m 0644 ${WORKDIR}/*.network ${D}${sysconfdir}/systemd/network/
>
> +}
>
> +
Please don't modify these kind of settings in a BSP. Even worse by
doing it as suggested all machines will get this modification. This
for sake that you have no network. Why not add networkmanager or
whatever and being fine?

Andreas


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 16:25   ` Herve Jourdain
@ 2015-07-23 18:28     ` Mauro Carvalho Chehab
  2015-07-23 22:45       ` Herve Jourdain
  0 siblings, 1 reply; 12+ messages in thread
From: Mauro Carvalho Chehab @ 2015-07-23 18:28 UTC (permalink / raw)
  To: Herve Jourdain; +Cc: yocto

Em Thu, 23 Jul 2015 18:25:29 +0200
Herve Jourdain <herve.jourdain@neuf.fr> escreveu:

> Hi Mauro,
> 
> Well, that's precisely one of my concerns. I believe that one of the Tizen layers might do just that. 

Yes, it does. It is at the meta-tizen layer.

> Maybe it should be at the Yocto layer.
>
> But it seems not to be with the one I'm using. And just enabling system - which can be done at distro level - is not enough, there is a need for a bbappend and a config file.
> So honestly, since I was experimenting with system, I stumbled on this one, and I had initially put that patch in another layer - custom one.
> 
> The question that remains is how do we make sure that Poky on raspberry pi has network enabled by default when people switch to system? Since I don't know where else to put it, I decided to propose the patch for the raspberrypi layer, knowing it probably makes more sense to put it somewhere else.

I'd say that it should not be at the Yocto layer, but at the layer specific for your distribution.

> 
> BR,
> 
> Herve
> 
> -----Original Message-----
> From: Mauro Carvalho Chehab [mailto:mchehab@osg.samsung.com] 
> Sent: jeudi 23 juillet 2015 18:00
> To: Herve Jourdain
> Cc: 'Andrei Gherzan'; 'Petter Mabäcker'; yocto@yoctoproject.org
> Subject: Re: [yocto] [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
> 
> Em Thu, 23 Jul 2015 17:32:35 +0200
> Herve Jourdain <herve.jourdain@neuf.fr> escreveu:
> 
> > This patch adds systemd-networkd for RaspberryPi in the 
> > meta-raspberrypi layer, in order to have Ethernet and Networking work out of the box.
> > 
> >  
> > 
> > This said, I’m not 100% sure if it should be enabled in 
> > meta-raspberrypi, instead of another custom layer.
> > 
> > But something similar needs to be added somewhere, and with the 
> > current version of Yocto on RaspberryPi, without this patch, network 
> > just doesn’t start…
> 
> I guess putting it at BSP is not right. Ethernet network does work on Tizen on Yocto:
> 	http://blogs.s-osg.org/tizen-rpi2-now-supporting-3d-acceleration/
> 
> Regards,
> Mauro
> 
> 
> > 
> >  
> > 
> > Signed-off-by: Herve Jourdain <herve.jourdain@neuf.fr 
> > <mailto:herve.jourdain@neuf.fr> >
> > 
> > ---
> > 
> > diff -Naur 
> > meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> > meta-raspberrypi/recipes-core/systemd/files/eth.network
> > 
> > --- meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> > 1970-01-01 08:00:00.000000000 +0800
> > 
> > +++ meta-raspberrypi/recipes-core/systemd/files/eth.network    2015-07-22
> > 12:01:53.587830690 +0800
> > 
> > @@ -0,0 +1,6 @@
> > 
> > +[Match]
> > 
> > +Name=eth*
> > 
> > +
> > 
> > +[Network]
> > 
> > +DHCP=v4
> > 
> > +
> > 
> > diff -Naur 
> > meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> > meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> > 
> > --- meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> > 1970-01-01 08:00:00.000000000 +0800
> > 
> > +++ meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> > 2015-07-22 12:05:07.307838546 +0800
> > 
> > @@ -0,0 +1,17 @@
> > 
> > +FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
> > 
> > +
> > 
> > +EXTRA_OECONF += "--disable-ldconfig"
> > 
> > +
> > 
> > +PACKAGECONFIG += "networkd resolved"
> > 
> > +
> > 
> > +CFLAGS_append_arm = " -fno-lto"
> > 
> > +
> > 
> > +SRC_URI += "file://eth.network"
> > 
> > +
> > 
> > +FILES_${PN} += "{sysconfdir}/systemd/network/*"
> > 
> > +
> > 
> > +do_install_append() {
> > 
> > +    install -d ${D}${sysconfdir}/systemd/network/
> > 
> > +    install -m 0644 ${WORKDIR}/*.network 
> > + ${D}${sysconfdir}/systemd/network/
> > 
> > +}
> > 
> > +
> > 
> >  
> > 
> 


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 18:28     ` Mauro Carvalho Chehab
@ 2015-07-23 22:45       ` Herve Jourdain
  2015-07-23 22:52         ` Burton, Ross
  0 siblings, 1 reply; 12+ messages in thread
From: Herve Jourdain @ 2015-07-23 22:45 UTC (permalink / raw)
  To: 'Mauro Carvalho Chehab'; +Cc: yocto

Well, I'm using Poky as a "distribution", at least for my tests...
But there might be a reason why it's not included there, I believe.
The problem to include it at the distribution level is you need to make assumptions as to what kind of network/network interfaces will be found.
On a raspberrypi, we know there will be at least an Ethernet available, so starting networkd and resolved makes sense.
But at the Poky distribution level, it can run on any kind of hardware, including those without any network capability.
So I believe it can't really be easily done at the distribution layer itself either, unless there is some kind of understanding networking will be required.

Therefore, my problem: if we want raspberrypi to start network out of the box, because we know it has the HW to support it, then we should do something at the raspberrypi layer, if it can not be supported at the distribution layer.

As I mentioned, I had initially kept that in a custom layer of mine.
But if it stays there, that means anyone starting poky on a raspberrypi using system will have to do its own layer with the bbappend, similar to that.
So I'm trying to find a way to make this work out of the box, with systemd, on raspberrypi, for everyone, and I'm not sure what's the best way to achieve this indeed.

BR,

Herve

-----Original Message-----
From: Mauro Carvalho Chehab [mailto:mchehab@osg.samsung.com] 
Sent: jeudi 23 juillet 2015 20:28
To: Herve Jourdain
Cc: 'Andrei Gherzan'; 'Petter Mabäcker'; yocto@yoctoproject.org
Subject: Re: [yocto] [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi

Em Thu, 23 Jul 2015 18:25:29 +0200
Herve Jourdain <herve.jourdain@neuf.fr> escreveu:

> Hi Mauro,
> 
> Well, that's precisely one of my concerns. I believe that one of the Tizen layers might do just that. 

Yes, it does. It is at the meta-tizen layer.

> Maybe it should be at the Yocto layer.
>
> But it seems not to be with the one I'm using. And just enabling system - which can be done at distro level - is not enough, there is a need for a bbappend and a config file.
> So honestly, since I was experimenting with system, I stumbled on this one, and I had initially put that patch in another layer - custom one.
> 
> The question that remains is how do we make sure that Poky on raspberry pi has network enabled by default when people switch to system? Since I don't know where else to put it, I decided to propose the patch for the raspberrypi layer, knowing it probably makes more sense to put it somewhere else.

I'd say that it should not be at the Yocto layer, but at the layer specific for your distribution.

> 
> BR,
> 
> Herve
> 
> -----Original Message-----
> From: Mauro Carvalho Chehab [mailto:mchehab@osg.samsung.com]
> Sent: jeudi 23 juillet 2015 18:00
> To: Herve Jourdain
> Cc: 'Andrei Gherzan'; 'Petter Mabäcker'; yocto@yoctoproject.org
> Subject: Re: [yocto] [meta-raspberrypi][PATCH] Add networkd as default 
> for RaspberryPi
> 
> Em Thu, 23 Jul 2015 17:32:35 +0200
> Herve Jourdain <herve.jourdain@neuf.fr> escreveu:
> 
> > This patch adds systemd-networkd for RaspberryPi in the 
> > meta-raspberrypi layer, in order to have Ethernet and Networking work out of the box.
> > 
> >  
> > 
> > This said, I’m not 100% sure if it should be enabled in 
> > meta-raspberrypi, instead of another custom layer.
> > 
> > But something similar needs to be added somewhere, and with the 
> > current version of Yocto on RaspberryPi, without this patch, network 
> > just doesn’t start…
> 
> I guess putting it at BSP is not right. Ethernet network does work on Tizen on Yocto:
> 	http://blogs.s-osg.org/tizen-rpi2-now-supporting-3d-acceleration/
> 
> Regards,
> Mauro
> 
> 
> > 
> >  
> > 
> > Signed-off-by: Herve Jourdain <herve.jourdain@neuf.fr 
> > <mailto:herve.jourdain@neuf.fr> >
> > 
> > ---
> > 
> > diff -Naur
> > meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> > meta-raspberrypi/recipes-core/systemd/files/eth.network
> > 
> > --- meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> > 1970-01-01 08:00:00.000000000 +0800
> > 
> > +++ meta-raspberrypi/recipes-core/systemd/files/eth.network    2015-07-22
> > 12:01:53.587830690 +0800
> > 
> > @@ -0,0 +1,6 @@
> > 
> > +[Match]
> > 
> > +Name=eth*
> > 
> > +
> > 
> > +[Network]
> > 
> > +DHCP=v4
> > 
> > +
> > 
> > diff -Naur
> > meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> > meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> > 
> > --- meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> > 1970-01-01 08:00:00.000000000 +0800
> > 
> > +++ meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> > 2015-07-22 12:05:07.307838546 +0800
> > 
> > @@ -0,0 +1,17 @@
> > 
> > +FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
> > 
> > +
> > 
> > +EXTRA_OECONF += "--disable-ldconfig"
> > 
> > +
> > 
> > +PACKAGECONFIG += "networkd resolved"
> > 
> > +
> > 
> > +CFLAGS_append_arm = " -fno-lto"
> > 
> > +
> > 
> > +SRC_URI += "file://eth.network"
> > 
> > +
> > 
> > +FILES_${PN} += "{sysconfdir}/systemd/network/*"
> > 
> > +
> > 
> > +do_install_append() {
> > 
> > +    install -d ${D}${sysconfdir}/systemd/network/
> > 
> > +    install -m 0644 ${WORKDIR}/*.network 
> > + ${D}${sysconfdir}/systemd/network/
> > 
> > +}
> > 
> > +
> > 
> >  
> > 
> 



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 16:38 ` Andreas Müller
@ 2015-07-23 22:50   ` Herve Jourdain
  2015-07-23 22:53     ` Burton, Ross
  0 siblings, 1 reply; 12+ messages in thread
From: Herve Jourdain @ 2015-07-23 22:50 UTC (permalink / raw)
  To: 'Andreas Müller'; +Cc: 'Yocto Project'

Indeed, it's a valid point, and I should probably be more cautious in the naming of the bbappend.
This said, I - maybe wrongfully - assumed that anyone including the meta-raspberrypi layer would actually want to run on a raspberrypi, which does have an Ethernet interface I believe on all machines - I only have a RaspberryPi 2, so I didn't check all other devices, so might assumption might be wrong there.
Is there any version of raspberrypi without an Ethernet interface?

BR,

Herve

-----Original Message-----
From: Andreas Müller [mailto:schnitzeltony@googlemail.com] 
Sent: jeudi 23 juillet 2015 18:39
To: Herve Jourdain
Cc: Andrei Gherzan; Petter Mabäcker; Yocto Project
Subject: Re: [yocto] [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi

On Thu, Jul 23, 2015 at 5:32 PM, Herve Jourdain <herve.jourdain@neuf.fr> wrote:
> This patch adds systemd-networkd for RaspberryPi in the 
> meta-raspberrypi layer, in order to have Ethernet and Networking work out of the box.
>
>
>
> This said, I’m not 100% sure if it should be enabled in 
> meta-raspberrypi, instead of another custom layer.
>
> But something similar needs to be added somewhere, and with the 
> current version of Yocto on RaspberryPi, without this patch, network 
> just doesn’t start…
>
>
>
> Signed-off-by: Herve Jourdain <herve.jourdain@neuf.fr>
>
> ---
>
> diff -Naur 
> meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> meta-raspberrypi/recipes-core/systemd/files/eth.network
>
> --- meta-raspberrypi.orig/recipes-core/systemd/files/eth.network
> 1970-01-01 08:00:00.000000000 +0800
>
> +++ meta-raspberrypi/recipes-core/systemd/files/eth.network    2015-07-22
> 12:01:53.587830690 +0800
>
> @@ -0,0 +1,6 @@
>
> +[Match]
>
> +Name=eth*
>
> +
>
> +[Network]
>
> +DHCP=v4
>
> +
>
> diff -Naur 
> meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
>
> --- meta-raspberrypi.orig/recipes-core/systemd/systemd_%.bbappend
> 1970-01-01 08:00:00.000000000 +0800
>
> +++ meta-raspberrypi/recipes-core/systemd/systemd_%.bbappend
> 2015-07-22 12:05:07.307838546 +0800
>
> @@ -0,0 +1,17 @@
>
> +FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
>
> +
>
> +EXTRA_OECONF += "--disable-ldconfig"
>
> +
>
> +PACKAGECONFIG += "networkd resolved"
>
> +
>
> +CFLAGS_append_arm = " -fno-lto"
>
> +
>
> +SRC_URI += "file://eth.network"
>
> +
>
> +FILES_${PN} += "{sysconfdir}/systemd/network/*"
>
> +
>
> +do_install_append() {
>
> +    install -d ${D}${sysconfdir}/systemd/network/
>
> +    install -m 0644 ${WORKDIR}/*.network 
> + ${D}${sysconfdir}/systemd/network/
>
> +}
>
> +
Please don't modify these kind of settings in a BSP. Even worse by doing it as suggested all machines will get this modification. This for sake that you have no network. Why not add networkmanager or whatever and being fine?

Andreas



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 22:45       ` Herve Jourdain
@ 2015-07-23 22:52         ` Burton, Ross
  2015-07-23 23:06           ` Herve Jourdain
  0 siblings, 1 reply; 12+ messages in thread
From: Burton, Ross @ 2015-07-23 22:52 UTC (permalink / raw)
  To: Herve Jourdain; +Cc: yocto@yoctoproject.org, Mauro Carvalho Chehab

[-- Attachment #1: Type: text/plain, Size: 484 bytes --]

On 23 July 2015 at 23:45, Herve Jourdain <herve.jourdain@neuf.fr> wrote:

> But there might be a reason why it's not included there, I believe.
>

Because Poky is a reference distribution, primarily for QA, that doesn't
explicitly support the Raspberry Pi and certainly doesn't expect to be used
outside of QA purposes.

Inventing your own distribution is trivial (in fact, you don't even need
one) and is exactly the sort of place that this sort of logic belongs.

Ross

[-- Attachment #2: Type: text/html, Size: 967 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 22:50   ` Herve Jourdain
@ 2015-07-23 22:53     ` Burton, Ross
  2015-07-23 22:59       ` Herve Jourdain
  0 siblings, 1 reply; 12+ messages in thread
From: Burton, Ross @ 2015-07-23 22:53 UTC (permalink / raw)
  To: Herve Jourdain; +Cc: Yocto Project

[-- Attachment #1: Type: text/plain, Size: 716 bytes --]

On 23 July 2015 at 23:50, Herve Jourdain <herve.jourdain@neuf.fr> wrote:

> This said, I - maybe wrongfully - assumed that anyone including the
> meta-raspberrypi layer would actually want to run on a raspberrypi, which
> does have an Ethernet interface I believe on all machines - I only have a
> RaspberryPi 2, so I didn't check all other devices, so might assumption
> might be wrong there.
> Is there any version of raspberrypi without an Ethernet interface?
>

Certainly wrongly.  For example the Guacamayo distro includes BSP layers
from meta-yocto-bsp, meta-ti, meta-raspberrypi, and meta-intel.  BSP layers
should always scope their changes to impact only the machines they care
about.

Ross

[-- Attachment #2: Type: text/html, Size: 1100 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 22:53     ` Burton, Ross
@ 2015-07-23 22:59       ` Herve Jourdain
  0 siblings, 0 replies; 12+ messages in thread
From: Herve Jourdain @ 2015-07-23 22:59 UTC (permalink / raw)
  To: 'Burton, Ross'; +Cc: 'Yocto Project'

[-- Attachment #1: Type: text/plain, Size: 1166 bytes --]

Hi Ross,

 

OK, I get it. I will be more careful in correctly restricting patches to the machine targeted, if there are machine dependencies.

 

BR,

 

Herve

 

From: Burton, Ross [mailto:ross.burton@intel.com] 
Sent: vendredi 24 juillet 2015 00:54
To: Herve Jourdain
Cc: Andreas Müller; Yocto Project
Subject: Re: [yocto] [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi

 

 

On 23 July 2015 at 23:50, Herve Jourdain <herve.jourdain@neuf.fr <mailto:herve.jourdain@neuf.fr> > wrote:

This said, I - maybe wrongfully - assumed that anyone including the meta-raspberrypi layer would actually want to run on a raspberrypi, which does have an Ethernet interface I believe on all machines - I only have a RaspberryPi 2, so I didn't check all other devices, so might assumption might be wrong there.
Is there any version of raspberrypi without an Ethernet interface?

 

Certainly wrongly.  For example the Guacamayo distro includes BSP layers from meta-yocto-bsp, meta-ti, meta-raspberrypi, and meta-intel.  BSP layers should always scope their changes to impact only the machines they care about.

 

Ross


[-- Attachment #2: Type: text/html, Size: 4795 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 22:52         ` Burton, Ross
@ 2015-07-23 23:06           ` Herve Jourdain
  2015-07-29  9:58             ` Burton, Ross
  0 siblings, 1 reply; 12+ messages in thread
From: Herve Jourdain @ 2015-07-23 23:06 UTC (permalink / raw)
  To: 'Burton, Ross'; +Cc: yocto, 'Mauro Carvalho Chehab'

[-- Attachment #1: Type: text/plain, Size: 1569 bytes --]

Hi Ross,

 

Yes, this is exactly what I assumed – I know, too many assumptions…

The point is that many people are turning to Poky for generating their first Yocto-based distribution for RaspberryPi. And out of the box, if using system, the network part doesn’t work.

That’s why I was trying to “solve” that at the meta-raspberrypi layer, instead of having each and everyone do it again at a personal level.

And I definitely understand meta-raspberrypi might not be perfect for that – but where else to put it, with the goal of having everyone using meta-raspberrypi have network enabled out of the box when using system on a Poky distribution?

 

Maybe it’s just not possible, that could be a valid answer as well.

 

BR,

 

Hervé

 

From: Burton, Ross [mailto:ross.burton@intel.com] 
Sent: vendredi 24 juillet 2015 00:52
To: Herve Jourdain
Cc: Mauro Carvalho Chehab; yocto@yoctoproject.org
Subject: Re: [yocto] [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi

 

 

On 23 July 2015 at 23:45, Herve Jourdain <herve.jourdain@neuf.fr <mailto:herve.jourdain@neuf.fr> > wrote:

But there might be a reason why it's not included there, I believe.


Because Poky is a reference distribution, primarily for QA, that doesn't explicitly support the Raspberry Pi and certainly doesn't expect to be used outside of QA purposes.

 

Inventing your own distribution is trivial (in fact, you don't even need one) and is exactly the sort of place that this sort of logic belongs.

 

Ross


[-- Attachment #2: Type: text/html, Size: 5965 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi
  2015-07-23 23:06           ` Herve Jourdain
@ 2015-07-29  9:58             ` Burton, Ross
  0 siblings, 0 replies; 12+ messages in thread
From: Burton, Ross @ 2015-07-29  9:58 UTC (permalink / raw)
  To: Herve Jourdain; +Cc: yocto@yoctoproject.org, Mauro Carvalho Chehab

[-- Attachment #1: Type: text/plain, Size: 451 bytes --]

On 24 July 2015 at 00:06, Herve Jourdain <herve.jourdain@neuf.fr> wrote:

> The point is that many people are turning to Poky for generating their
> first Yocto-based distribution for RaspberryPi. And out of the box, if
> using system, the network part doesn’t work.
>
>
Are these users building images that contain connman?  If that doesn't work
out of the box on RPi, that's a bug (and the last time I tried it, it
worked fine).

Ross

[-- Attachment #2: Type: text/html, Size: 1002 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2015-07-29  9:58 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-23 15:32 [meta-raspberrypi][PATCH] Add networkd as default for RaspberryPi Herve Jourdain
2015-07-23 16:00 ` Mauro Carvalho Chehab
2015-07-23 16:25   ` Herve Jourdain
2015-07-23 18:28     ` Mauro Carvalho Chehab
2015-07-23 22:45       ` Herve Jourdain
2015-07-23 22:52         ` Burton, Ross
2015-07-23 23:06           ` Herve Jourdain
2015-07-29  9:58             ` Burton, Ross
2015-07-23 16:38 ` Andreas Müller
2015-07-23 22:50   ` Herve Jourdain
2015-07-23 22:53     ` Burton, Ross
2015-07-23 22:59       ` Herve Jourdain

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.