move udev ruls from netbase to udev
PATCH 1/2 move udev ruls from netbase to udev
From: Ting Liu <[email protected]>
---
recipes-append/netbase/netbase_5.0.bbappend | 10 ----------
.../files/71-fsl-dpaa-persistent-networking.rules | 0
recipes-append/udev/udev_182.bbappend | 12 ++++++++++--
3 files changed, 10 insertions(+), 12 deletions(-)
delete mode 100644 recipes-append/netbase/netbase_5.0.bbappend
rename recipes-append/{netbase => udev}/files/71-fsl-dpaa-persistent-networking.rules (100%)recipes-append/netbase/netbase_5.0.bbappend deleted +0 -10
@@ -1,10 +0,0 @@ -FILESEXTRAPATHS_prepend_fsl := "${THISDIR}/files:" - -SRC_URI_append_fsl += "file://71-fsl-dpaa-persistent-networking.rules" - -do_install_append_fsl () { - install -d ${D}${sysconfdir}/udev/rules.d/ - install -m 0644 ${WORKDIR}/71-fsl-dpaa-persistent-networking.rules ${D}${sysconfdir}/udev/rules.d -} - -PR_fsl .= "+${DISTRO}"
recipes-append/udev/files/71-fsl-dpaa-persistent-networking.rules renamed from recipes-append/netbase/files/71-fsl-dpaa-persistent-networking.rules +0 -0
recipes-append/udev/udev_182.bbappend +10 -2
@@ -1,3 +1,11 @@ -FILESEXTRAPATHS_prepend_fsl := "${THISDIR}/files:" +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" + +SRC_URI_append += "file://71-fsl-dpaa-persistent-networking.rules" + +do_install_append () { + install -d ${D}${sysconfdir}/udev/rules.d/ + install -m 0644 ${WORKDIR}/71-fsl-dpaa-persistent-networking.rules ${D}${sysconfdir}/udev/rules.d +} + +PRINC := "${@int(PRINC) + 1}" -PR_fsl .= "+${DISTRO}.1"
Signature · 1 line
1.7.3.4
PATCH 2/2 udev: add rule to rename network interfaces for t4/b4
From: Ting Liu <[email protected]>
Since on FManv3 a MEMAC can be configured either as 1G or 10G, rename all interfaces on T4/B4 to "fmX-macY", with X in the range 1..2 and Y in the range 1..10.
--- .../files/72-fsl-dpaa-persistent-networking.rules | 21 ++++++++++++++++++++ recipes-append/udev/udev_182.bbappend | 7 +++-- 2 files changed, 25 insertions(+), 3 deletions(-) create mode 100644 recipes-append/udev/files/72-fsl-dpaa-persistent-networking.rules
recipes-append/udev/files/72-fsl-dpaa-persistent-networking.rules new file +21 -0
@@ -0,0 +1,21 @@ +# Rules for handling naming the DPAA FMan ethernet ports in a consistent way +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4e0000", NAME="fm1-mac1" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4e2000", NAME="fm1-mac2" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4e4000", NAME="fm1-mac3" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4e6000", NAME="fm1-mac4" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4e8000", NAME="fm1-mac5" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4ea000", NAME="fm1-mac6" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4ec000", NAME="fm1-mac7" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4ee000", NAME="fm1-mac8" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4f0000", NAME="fm1-mac9" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe4f2000", NAME="fm1-mac10" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5e0000", NAME="fm2-mac1" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5e2000", NAME="fm2-mac2" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5e4000", NAME="fm2-mac3" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5e6000", NAME="fm2-mac4" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5e8000", NAME="fm2-mac5" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5ea000", NAME="fm2-mac6" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5ec000", NAME="fm2-mac7" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5ee000", NAME="fm2-mac8" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5f0000", NAME="fm2-mac9" +SUBSYSTEM=="net", DRIVERS=="fsl_dpa", ATTR{device_addr}=="ffe5f2000", NAME="fm2-mac10"
recipes-append/udev/udev_182.bbappend +4 -3
@@ -1,11 +1,12 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/files:" -SRC_URI_append += "file://71-fsl-dpaa-persistent-networking.rules" +SRC_URI_append += " file://${@bb.utils.contains("TUNE_FEATURES", "e6500", \ + "72-fsl-dpaa-persistent-networking.rules", "71-fsl-dpaa-persistent-networking.rules", d)}" do_install_append () { install -d ${D}${sysconfdir}/udev/rules.d/ - install -m 0644 ${WORKDIR}/71-fsl-dpaa-persistent-networking.rules ${D}${sysconfdir}/udev/rules.d + install -m 0644 ${WORKDIR}/*-fsl-dpaa-persistent-networking.rules ${D}${sysconfdir}/udev/rules.d } -PRINC := "${@int(PRINC) + 1}" +PRINC := "${@int(PRINC) + 2}"
Signature · 1 line
1.7.3.4
Re: [PATCH 2/2] udev: add rule to rename network interfaces for t4/b4
Quoted 9 lines · On Thu, Mar 7, 2013 at 6:12 AM, <[email protected]> wrote:
From: Ting Liu <[email protected]>
Since on FManv3 a MEMAC can be configured either as 1G or 10G, rename all interfaces on T4/B4 to "fmX-macY", with X in the range 1..2 and Y in the range 1..10.
Signed-off-by Zhenhua Luo <[email protected]>Signed-off-by Ioana Radulescu <[email protected]>Signed-off-by Ting Liu <[email protected]>
Please do it in udev-extraconf, besides use the '--subject-prefix' option when sending patches to meta-fsl-ppc.
Signature · 3 lines
Otavio Salvador O.S. Systems E-mail: [email protected] http://www.ossystems.com.br Mobile: +55 53 9981-7854 http://projetos.ossystems.com.br
Quoted 17 lines · On Thu, Mar 7, 2013 at 6:12 AM, <[email protected]> wrote:
From: Ting Liu <[email protected]>
Signed-off-by Ting Liu <[email protected]>--- recipes-append/netbase/netbase_5.0.bbappend | 10 ---------- .../files/71-fsl-dpaa-persistent-networking.rules | 0 recipes-append/udev/udev_182.bbappend | 12 ++++++++++-- 3 files changed, 10 insertions(+), 12 deletions(-) delete mode 100644 recipes-append/netbase/netbase_5.0.bbappend rename recipes-append/{netbase => udev}/files/71-fsl-dpaa-persistent-networking.rules (100%)recipes-append/netbase/netbase_5.0.bbappend deleted +0
-0
recipes-append/netbase/netbase_5.0.bbappend line 10
Quoted 10 lines
recipes-append/netbase/netbase_5.0.bbappend deleted +0
-10@@ -1,10 +0,0 @@ -FILESEXTRAPATHS_prepend_fsl := "${THISDIR}/files:" - -SRC_URI_append_fsl += "file://71-fsl-dpaa-persistent-networking.rules" - -do_install_append_fsl () { - install -d ${D}${sysconfdir}/udev/rules.d/ - install -m 0644 ${WORKDIR}/71-fsl-dpaa-persistent-networking.rules ${D}${sysconfdir}/udev/rules.d -} - -PR_fsl .= "+${DISTRO}"
I agree with the change but to preserve the upgrade path please keep a bbappend bumping the PRINC.
Quoted 12 lines
recipes-append/udev/files/71-fsl-dpaa-persistent-networking.rules renamed from recipes-append/netbase/files/71-fsl-dpaa-persistent-networking.rules +0
-0recipes-append/udev/udev_182.bbappend +2
-1@@ -1,3 +1,11 @@ -FILESEXTRAPATHS_prepend_fsl := "${THISDIR}/files:" +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" +
recipes-append/udev/udev_182.bbappend line 3
Quoted 10 lines
recipes-append/udev/udev_182.bbappend +8
-1+SRC_URI_append += "file://71-fsl-dpaa-persistent-networking.rules" + +do_install_append () { + install -d ${D}${sysconfdir}/udev/rules.d/ + install -m 0644 ${WORKDIR}/71-fsl-dpaa-persistent-networking.rules ${D}${sysconfdir}/udev/rules.d +} + +PRINC := "${@int(PRINC) + 1}" -PR_fsl .= "+${DISTRO}.1"
These rules should go to udev-extraconf due following reasons:
* adding it to udev makes it MACHINE_ARCH specific (hurts build time)
* udev-extraconf does fit well for this case
* udev-extraconf is much smaller to build (so fast build time)
Recall to add udev-extraconf in MACHINE_EXTRA_RRECOMMENDS so it ends in the default packagegroup packages and are easy to manage.
Signature · 3 lines
Otavio Salvador O.S. Systems E-mail: [email protected] http://www.ossystems.com.br Mobile: +55 53 9981-7854 http://projetos.ossystems.com.br
Quoted 37 lines
-----Original Message-----
From: [email protected] [mailto:[email protected]] On Behalf Of Otavio Salvador
Sent: Thursday, March 07, 2013 10:47 PM
To: Liu Ting-B28495
Cc: [email protected]
Subject: Re: [meta-freescale] [PATCH 1/2] move udev ruls from netbase to udevQuoted 19 lines · On Thu, Mar 7, 2013 at 6:12 AM, <[email protected]> wrote:
From: Ting Liu <[email protected]>
Signed-off-by Ting Liu <[email protected]>--- recipes-append/netbase/netbase_5.0.bbappend | 10 ---------- .../files/71-fsl-dpaa-persistent-networking.rules | 0 recipes-append/udev/udev_182.bbappend | 12 ++++++++++-- 3 files changed, 10 insertions(+), 12 deletions(-) delete mode 100644 recipes-append/netbase/netbase_5.0.bbappend rename recipes-append/{netbase =>udev}/files/71-fsl-dpaa-persistent-networking.rules (100%)
recipes-append/netbase/netbase_5.0.bbappend deleted +0
-0recipes-append/netbase/netbase_5.0.bbappend line 7
Quoted 7 lines
recipes-append/netbase/netbase_5.0.bbappend deleted +0
-7@@ -1,10 +0,0 @@ -FILESEXTRAPATHS_prepend_fsl := "${THISDIR}/files:" - -SRC_URI_append_fsl += "file://71-fsl-dpaa-persistent-networking.rules" - -do_install_append_fsl () { - install -d ${D}${sysconfdir}/udev/rules.d/ - install -m 0644 ${WORKDIR}/71-fsl-dpaa-persistent-networking.rules ${D}${sysconfdir}/udev/rules.d
Quoted 6 lines
recipes-append/netbase/netbase_5.0.bbappend line 10
Quoted 3 lines
recipes-append/netbase/netbase_5.0.bbappend deleted +0
-3-} - -PR_fsl .= "+${DISTRO}"I agree with the change but to preserve the upgrade path please keep a bbappend bumping the PRINC.
Got it. Thanks.
-Ting
Quoted 32 lines
Quoted 19 lines
diff --git a/recipes-append/netbase/files/71-fsl-dpaa-persistent-networking.rules b/recipes-append/udev/files/71-fsl-dpaa-persistent-networking.rules similarity index 100%
rename from recipes-append/netbase/files/71-fsl-dpaa-persistent-networking.rules rename to recipes-append/udev/files/71-fsl-dpaa-persistent-networking.rulesrecipes-append/udev/udev_182.bbappend +3
-1@@ -1,3 +1,11 @@ -FILESEXTRAPATHS_prepend_fsl := "${THISDIR}/files:" +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" + +SRC_URI_append += "file://71-fsl-dpaa-persistent-networking.rules"recipes-append/udev/udev_182.bbappend line 3
Quoted 10 lines
recipes-append/udev/udev_182.bbappend +8
-1+ +do_install_append () { + install -d ${D}${sysconfdir}/udev/rules.d/ + install -m 0644 +${WORKDIR}/71-fsl-dpaa-persistent-networking.rules +${D}${sysconfdir}/udev/rules.d } + +PRINC := "${@int(PRINC) + 1}" -PR_fsl .= "+${DISTRO}.1"These rules should go to udev-extraconf due following reasons:
Quoted 7 lines
* adding it to udev makes it
MACHINE_ARCHspecific (hurts build time)
* udev-extraconf does fit well for this case
* udev-extraconf is much smaller to build (so fast build time)Recall to add udev-extraconf in
MACHINE_EXTRA_RRECOMMENDSso it ends in the default packagegroup packages and are easy to manage.
Thanks a lot for the sharing. It does make sense. I will send v2 patch after build tests.
-Ting
Quoted 4 lines
--
Otavio SalvadorO.S. Systems
E-mail: [email protected] http://www.ossystems.com.br
Mobile: +55 53 9981-7854 http://projetos.ossystems.com.br