* [meta-networking][PATCH 1/2] mctp: upgrade to 18e45b42
@ 2021-12-16 8:31 Jeremy Kerr
2021-12-16 8:31 ` [meta-networking][PATCH 2/2] mctp: install dbus service configuration Jeremy Kerr
0 siblings, 1 reply; 5+ messages in thread
From: Jeremy Kerr @ 2021-12-16 8:31 UTC (permalink / raw)
To: openembedded-devel
We now have better handling of local stack configuration at runtime, and
the 5.15 kernel header change has been integrated.
Signed-off-by: Jeremy Kerr <jk@codeconstruct.com.au>
---
.../0001-build-Adjust-for-kernel-mctp.h.patch | 84 -------------------
.../recipes-support/mctp/mctp_git.bb | 6 +-
2 files changed, 2 insertions(+), 88 deletions(-)
delete mode 100644 meta-networking/recipes-support/mctp/mctp/0001-build-Adjust-for-kernel-mctp.h.patch
diff --git a/meta-networking/recipes-support/mctp/mctp/0001-build-Adjust-for-kernel-mctp.h.patch b/meta-networking/recipes-support/mctp/mctp/0001-build-Adjust-for-kernel-mctp.h.patch
deleted file mode 100644
index 83bf19770..000000000
--- a/meta-networking/recipes-support/mctp/mctp/0001-build-Adjust-for-kernel-mctp.h.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From 653eccc918ef993186c312694c288b2a5b39248e Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Fri, 5 Nov 2021 13:14:55 -0700
-Subject: [PATCH] build: Adjust for kernel mctp.h
-
-Starting 5.15 kernel has mctp.h as well and provides some of the
-defintions, therefore move the ones we need to provide in this header
-outside the conditional check so its always provided regardless of
-header coming from kernel or not.
-
-Include linux/if_link.h so it can pre-define IFLA_MCTP_UNSPEC and other
-defines and there is a check for conditionally providing them here but
-kernel does not have such a check, so if linux/if_link.h is included
-after this header then we end up with duplicate defines
-
-linux/if_link.h:1267:2: error: redefinition of enumerator 'IFLA_MCTP_UNSPEC'
- IFLA_MCTP_UNSPEC,
- ^
-../git/src/mctp.h:74:2: note: previous definition is here
- IFLA_MCTP_UNSPEC,
- ^
-
-Upstream-Status: Submitted [https://github.com/CodeConstruct/mctp/pull/2]
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- src/mctp.h | 21 +++++++++++----------
- 1 file changed, 11 insertions(+), 10 deletions(-)
-
-diff --git a/src/mctp.h b/src/mctp.h
-index 4f73def..e602168 100644
---- a/src/mctp.h
-+++ b/src/mctp.h
-@@ -19,6 +19,7 @@
- #if HAVE_LINUX_MCTP_H
- #include <linux/mctp.h>
- #endif
-+#include <linux/if_link.h>
-
- #ifndef AF_MCTP
- #define AF_MCTP 45
-@@ -33,10 +34,6 @@
-
- #ifndef MCTP_NET_ANY
-
--#ifndef MAX_ADDR_LEN
--#define MAX_ADDR_LEN 32
--#endif
--
- typedef uint8_t mctp_eid_t;
-
- struct mctp_addr {
-@@ -53,6 +50,16 @@ struct sockaddr_mctp {
- uint8_t __smctp_pad1;
- };
-
-+#define MCTP_NET_ANY 0
-+#define MCTP_ADDR_ANY 0xff
-+#define MCTP_TAG_OWNER 0x08
-+
-+#endif /* MCTP_NET_ANY */
-+
-+#ifndef MAX_ADDR_LEN
-+#define MAX_ADDR_LEN 32
-+#endif
-+
- struct sockaddr_mctp_ext {
- struct sockaddr_mctp smctp_base;
- int smctp_ifindex;
-@@ -61,12 +68,6 @@ struct sockaddr_mctp_ext {
- unsigned char smctp_haddr[MAX_ADDR_LEN];
- };
-
--#define MCTP_NET_ANY 0
--#define MCTP_ADDR_ANY 0xff
--#define MCTP_TAG_OWNER 0x08
--
--#endif /* MCTP_NET_ANY */
--
- #ifndef IFLA_MCTP_MAX
-
- /* From if_link.h */
---
-2.33.1
-
diff --git a/meta-networking/recipes-support/mctp/mctp_git.bb b/meta-networking/recipes-support/mctp/mctp_git.bb
index 50d84d204..6cc5b1480 100644
--- a/meta-networking/recipes-support/mctp/mctp_git.bb
+++ b/meta-networking/recipes-support/mctp/mctp_git.bb
@@ -7,11 +7,9 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=4cc91856b08b094b4f406a29dc61db21"
PV = "0.1+git${SRCPV}"
-SRCREV = "072bafe725c50329f99cf9d3b2624e8799e8163a"
+SRCREV = "18e45b42e672a652c067cbf66098df9022103f23"
-SRC_URI = "git://github.com/CodeConstruct/mctp;branch=main;protocol=https \
- file://0001-build-Adjust-for-kernel-mctp.h.patch \
- "
+SRC_URI = "git://github.com/CodeConstruct/mctp;branch=main;protocol=https"
S = "${WORKDIR}/git"
--
2.33.0
^ permalink raw reply related [flat|nested] 5+ messages in thread* [meta-networking][PATCH 2/2] mctp: install dbus service configuration
2021-12-16 8:31 [meta-networking][PATCH 1/2] mctp: upgrade to 18e45b42 Jeremy Kerr
@ 2021-12-16 8:31 ` Jeremy Kerr
2021-12-16 17:52 ` [oe] " Khem Raj
0 siblings, 1 reply; 5+ messages in thread
From: Jeremy Kerr @ 2021-12-16 8:31 UTC (permalink / raw)
To: openembedded-devel
mctpd ships with an example dbus service configuration, so install in
the dbus system configuration dir.
Signed-off-by: Jeremy Kerr <jk@codeconstruct.com.au>
---
meta-networking/recipes-support/mctp/mctp_git.bb | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/meta-networking/recipes-support/mctp/mctp_git.bb b/meta-networking/recipes-support/mctp/mctp_git.bb
index 6cc5b1480..9c440b6d4 100644
--- a/meta-networking/recipes-support/mctp/mctp_git.bb
+++ b/meta-networking/recipes-support/mctp/mctp_git.bb
@@ -24,10 +24,18 @@ PACKAGECONFIG ??= " \
PACKAGECONFIG[systemd] = ",,systemd,libsystemd"
SYSTEMD_SERVICE:${PN} = "mctpd.service"
+FILES:${PN} += " \
+ ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', \
+ '${datadir}/dbus-1/system.d/mctpd.conf', '', d)} \
+"
+
do_install:append () {
if ${@bb.utils.contains('PACKAGECONFIG', 'systemd', 'true', 'false', d)}; then
install -d ${D}${systemd_system_unitdir}
install -m 0644 ${S}/conf/mctpd.service \
${D}${systemd_system_unitdir}/mctpd.service
+ install -d ${D}${datadir}/dbus-1/system.d
+ install -m 0644 ${S}/conf/mctpd-dbus.conf \
+ ${D}${datadir}/dbus-1/system.d/mctpd.conf
fi
}
--
2.33.0
^ permalink raw reply related [flat|nested] 5+ messages in thread* Re: [oe] [meta-networking][PATCH 2/2] mctp: install dbus service configuration
2021-12-16 8:31 ` [meta-networking][PATCH 2/2] mctp: install dbus service configuration Jeremy Kerr
@ 2021-12-16 17:52 ` Khem Raj
2021-12-17 1:57 ` Jeremy Kerr
0 siblings, 1 reply; 5+ messages in thread
From: Khem Raj @ 2021-12-16 17:52 UTC (permalink / raw)
To: Jeremy Kerr; +Cc: openembeded-devel
On Thu, Dec 16, 2021 at 12:32 AM Jeremy Kerr <jk@codeconstruct.com.au> wrote:
>
> mctpd ships with an example dbus service configuration, so install in
> the dbus system configuration dir.
>
> Signed-off-by: Jeremy Kerr <jk@codeconstruct.com.au>
> ---
> meta-networking/recipes-support/mctp/mctp_git.bb | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/meta-networking/recipes-support/mctp/mctp_git.bb b/meta-networking/recipes-support/mctp/mctp_git.bb
> index 6cc5b1480..9c440b6d4 100644
> --- a/meta-networking/recipes-support/mctp/mctp_git.bb
> +++ b/meta-networking/recipes-support/mctp/mctp_git.bb
> @@ -24,10 +24,18 @@ PACKAGECONFIG ??= " \
> PACKAGECONFIG[systemd] = ",,systemd,libsystemd"
> SYSTEMD_SERVICE:${PN} = "mctpd.service"
>
> +FILES:${PN} += " \
> + ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', \
> + '${datadir}/dbus-1/system.d/mctpd.conf', '', d)} \
> +"
> +
this should go below do_install and other functions. You can run
./contrib/oe-stylize.py
also to get some help on formatting
> do_install:append () {
> if ${@bb.utils.contains('PACKAGECONFIG', 'systemd', 'true', 'false', d)}; then
> install -d ${D}${systemd_system_unitdir}
> install -m 0644 ${S}/conf/mctpd.service \
> ${D}${systemd_system_unitdir}/mctpd.service
> + install -d ${D}${datadir}/dbus-1/system.d
> + install -m 0644 ${S}/conf/mctpd-dbus.conf \
> + ${D}${datadir}/dbus-1/system.d/mctpd.conf
> fi
> }
> --
> 2.33.0
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#94382): https://lists.openembedded.org/g/openembedded-devel/message/94382
> Mute This Topic: https://lists.openembedded.org/mt/87763264/1997914
> Group Owner: openembedded-devel+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [raj.khem@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [oe] [meta-networking][PATCH 2/2] mctp: install dbus service configuration
2021-12-16 17:52 ` [oe] " Khem Raj
@ 2021-12-17 1:57 ` Jeremy Kerr
2021-12-17 2:28 ` Khem Raj
0 siblings, 1 reply; 5+ messages in thread
From: Jeremy Kerr @ 2021-12-17 1:57 UTC (permalink / raw)
To: Khem Raj; +Cc: openembeded-devel
Hi Khem,
> > +FILES:${PN} += " \
> > + ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', \
> > + '${datadir}/dbus-1/system.d/mctpd.conf', '', d)} \
> > +"
> > +
>
> this should go below do_install and other functions.
OK, can do! I'll send a v2 shortly.
> You can run ./contrib/oe-stylize.py also to get some help on
> formatting
Hm, that seems to make a bit of a mess of the recipe - it moves a bunch
of variable declarations to within the do_install:append() block.
I'm no expert on the full syntax, but something like this might fix it:
diff --git a/contrib/oe-stylize.py b/contrib/oe-stylize.py
index e1ba1b321..eac096a80 100755
--- a/contrib/oe-stylize.py
+++ b/contrib/oe-stylize.py
@@ -211,7 +211,7 @@ OE_vars = [
]
varRegexp = r'^([a-zA-Z_0-9${}-]*)([ \t]*)([+.:]?=[+.]?)([ \t]*)([^\t]+)'
-routineRegexp = r'^([a-zA-Z0-9_ ${}-]+?)\('
+routineRegexp = r'^([a-zA-Z0-9_ ${}:-]+?)\('
# Variables seen in the processed .bb
seen_vars = {}
- I can send that as a proper patch if that's the correct approach.
Cheers,
Jeremy
^ permalink raw reply related [flat|nested] 5+ messages in thread* Re: [oe] [meta-networking][PATCH 2/2] mctp: install dbus service configuration
2021-12-17 1:57 ` Jeremy Kerr
@ 2021-12-17 2:28 ` Khem Raj
0 siblings, 0 replies; 5+ messages in thread
From: Khem Raj @ 2021-12-17 2:28 UTC (permalink / raw)
To: Jeremy Kerr; +Cc: openembeded-devel
[-- Attachment #1: Type: text/plain, Size: 1297 bytes --]
On Thu, Dec 16, 2021 at 5:57 PM Jeremy Kerr <jk@codeconstruct.com.au> wrote:
> Hi Khem,
>
> > > +FILES:${PN} += " \
> > > + ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', \
> > > + '${datadir}/dbus-1/system.d/mctpd.conf', '', d)} \
> > > +"
> > > +
> >
> > this should go below do_install and other functions.
>
> OK, can do! I'll send a v2 shortly.
>
> > You can run ./contrib/oe-stylize.py also to get some help on
> > formatting
>
> Hm, that seems to make a bit of a mess of the recipe - it moves a bunch
> of variable declarations to within the do_install:append() block.
>
> I'm no expert on the full syntax, but something like this might fix it:
>
> diff --git a/contrib/oe-stylize.py b/contrib/oe-stylize.py
> index e1ba1b321..eac096a80 100755
> --- a/contrib/oe-stylize.py
> +++ b/contrib/oe-stylize.py
> @@ -211,7 +211,7 @@ OE_vars = [
> ]
>
> varRegexp = r'^([a-zA-Z_0-9${}-]*)([ \t]*)([+.:]?=[+.]?)([ \t]*)([^\t]+)'
> -routineRegexp = r'^([a-zA-Z0-9_ ${}-]+?)\('
> +routineRegexp = r'^([a-zA-Z0-9_ ${}:-]+?)\('
>
> # Variables seen in the processed .bb
> seen_vars = {}
>
>
> - I can send that as a proper patch if that's the correct approach.
>
This seems fine we have new override operator and stylize script needs
adjusting
> Cheers,
>
>
> Jeremy
>
[-- Attachment #2: Type: text/html, Size: 2158 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-12-17 2:28 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-12-16 8:31 [meta-networking][PATCH 1/2] mctp: upgrade to 18e45b42 Jeremy Kerr
2021-12-16 8:31 ` [meta-networking][PATCH 2/2] mctp: install dbus service configuration Jeremy Kerr
2021-12-16 17:52 ` [oe] " Khem Raj
2021-12-17 1:57 ` Jeremy Kerr
2021-12-17 2:28 ` Khem Raj
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.