Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 21 Oct 2022 14:13:28 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        "Bjoern A. Zeeb" <bz@freebsd.org>
Cc:        Andrew Turner <andrew@fubar.geek.nz>, Gleb Smirnoff <glebius@freebsd.org>,  "src-committers@freebsd.org" <src-committers@freebsd.org>,  "dev-commits-src-all@freebsd.org" <dev-commits-src-all@freebsd.org>,  "dev-commits-src-main@freebsd.org" <dev-commits-src-main@freebsd.org>
Subject:   Re: git: 2782ed8f6cd3 - main - dpaa2: fix standalone module build
Message-ID:  <CANCZdfrn2HPBY1THTF2GKX1cDnEuSMJYjDaJJ4Es_8KBzO4bJQ@mail.gmail.com>
In-Reply-To: <1pr758pp-3640-43ss-451-nqnoqs248s5p@SerrOFQ.bet>
References:  <202210180540.29I5eNBZ068087@gitrepo.freebsd.org> <8sps479n-9961-rq8o-52op-po77rpo9p377@mnoonqbm.arg> <90B2F15A-3102-4771-BD46-C5304091569C@fubar.geek.nz> <1pr758pp-3640-43ss-451-nqnoqs248s5p@SerrOFQ.bet>

next in thread | previous in thread | raw e-mail | index | archive | help

[-- Attachment #1 --]
Hey Bjoern,

On Fri, Oct 21, 2022 at 2:08 PM Bjoern A. Zeeb <bz@freebsd.org> wrote:

> On Fri, 21 Oct 2022, Andrew Turner wrote:
>
> >
> >
> >> On 21 Oct 2022, at 16:17, Bjoern A. Zeeb <bz@FreeBSD.org> wrote:
> >>
> >> On Tue, 18 Oct 2022, Gleb Smirnoff wrote:
> >>
> >>> The branch main has been updated by glebius:
> >>>
> >>> URL:
> https://cgit.FreeBSD.org/src/commit/?id=2782ed8f6cd3d7f59219a783bc7fa7bbfb1fe26f
> >>>
> >>> commit 2782ed8f6cd3d7f59219a783bc7fa7bbfb1fe26f
> >>> Author:     Gleb Smirnoff <glebius@FreeBSD.org>
> >>> AuthorDate: 2022-10-18 05:38:24 +0000
> >>> Commit:     Gleb Smirnoff <glebius@FreeBSD.org>
> >>> CommitDate: 2022-10-18 05:38:24 +0000
> >>>
> >>>   dpaa2: fix standalone module build
> >>> ---
> >>> sys/modules/dpaa2/Makefile | 2 ++
> >>> 1 file changed, 2 insertions(+)
> >>>
> >>> diff --git a/sys/modules/dpaa2/Makefile b/sys/modules/dpaa2/Makefile
> >>> index 556a1c531669..fa280452bcfa 100644
> >>> --- a/sys/modules/dpaa2/Makefile
> >>> +++ b/sys/modules/dpaa2/Makefile
> >>> @@ -19,6 +19,8 @@ SRCS+=    memac_mdio_common.c memac_mdio_if.c
> memac_mdio_if.h
> >>>
> >>> SRCS+=      bus_if.h device_if.h miibus_if.h
> >>> SRCS+=      pcib_if.h pci_if.h
> >>> +SRCS+=     mdio_if.h
> >>
> >> What do you need this for?
> >>
> >>> +SRCS+=     opt_acpi.h opt_platform.h
> >>
> >> opt_acpi gets inlcuded lines below and so does opt_platform under the
> >> respective OPT_ checks.  Now they are there twice.
> >
> > OPT_ACPI doesn’t exist as a make variable so the ".if !empty(OPT_ACPI)”
> check won’t work as it is expected to work here so opt_acpi.h won’t be
> built. The second problem is the opt_*.h files need to be unconditionally
> created so they can be included in the relevant code.
>
> Then they should probably have been removed from under the .ifdefs
> in the same commit?
>
>
> We do use OPT_ACPI elsewhere in the tree as well.. hwpmc?  Can't
> remember.  How's it working there?
>
> What is currently then including these files then?  Hmm I haven't used
> the module in a while...
>
> Should we duplicate the FDT logic for ACPI in sys/conf/kern.opts.mk
> so LINT-ACPI can be a better thing long-term as well?
>

Yes. We likely should clean this up... But the appetite to polish the
currently
way over polished and under powered config(8) program is low. However,
having it create a .mk file that can be included that summarizes all the
options in a kernel config would be the least amount of effort relative to
the
crazy greps we have going on now.

Warner

[-- Attachment #2 --]
<div dir="ltr"><div dir="ltr">Hey Bjoern,<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Oct 21, 2022 at 2:08 PM Bjoern A. Zeeb &lt;<a href="mailto:bz@freebsd.org">bz@freebsd.org</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Fri, 21 Oct 2022, Andrew Turner wrote:<br>
<br>
&gt;<br>
&gt;<br>
&gt;&gt; On 21 Oct 2022, at 16:17, Bjoern A. Zeeb &lt;bz@FreeBSD.org&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt; On Tue, 18 Oct 2022, Gleb Smirnoff wrote:<br>
&gt;&gt;<br>
&gt;&gt;&gt; The branch main has been updated by glebius:<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; URL: <a href="https://cgit.FreeBSD.org/src/commit/?id=2782ed8f6cd3d7f59219a783bc7fa7bbfb1fe26f" rel="noreferrer" target="_blank">https://cgit.FreeBSD.org/src/commit/?id=2782ed8f6cd3d7f59219a783bc7fa7bbfb1fe26f</a><br>;
&gt;&gt;&gt;<br>
&gt;&gt;&gt; commit 2782ed8f6cd3d7f59219a783bc7fa7bbfb1fe26f<br>
&gt;&gt;&gt; Author:     Gleb Smirnoff &lt;glebius@FreeBSD.org&gt;<br>
&gt;&gt;&gt; AuthorDate: 2022-10-18 05:38:24 +0000<br>
&gt;&gt;&gt; Commit:     Gleb Smirnoff &lt;glebius@FreeBSD.org&gt;<br>
&gt;&gt;&gt; CommitDate: 2022-10-18 05:38:24 +0000<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;   dpaa2: fix standalone module build<br>
&gt;&gt;&gt; ---<br>
&gt;&gt;&gt; sys/modules/dpaa2/Makefile | 2 ++<br>
&gt;&gt;&gt; 1 file changed, 2 insertions(+)<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; diff --git a/sys/modules/dpaa2/Makefile b/sys/modules/dpaa2/Makefile<br>
&gt;&gt;&gt; index 556a1c531669..fa280452bcfa 100644<br>
&gt;&gt;&gt; --- a/sys/modules/dpaa2/Makefile<br>
&gt;&gt;&gt; +++ b/sys/modules/dpaa2/Makefile<br>
&gt;&gt;&gt; @@ -19,6 +19,8 @@ SRCS+=    memac_mdio_common.c memac_mdio_if.c memac_mdio_if.h<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; SRCS+=      bus_if.h device_if.h miibus_if.h<br>
&gt;&gt;&gt; SRCS+=      pcib_if.h pci_if.h<br>
&gt;&gt;&gt; +SRCS+=     mdio_if.h<br>
&gt;&gt;<br>
&gt;&gt; What do you need this for?<br>
&gt;&gt;<br>
&gt;&gt;&gt; +SRCS+=     opt_acpi.h opt_platform.h<br>
&gt;&gt;<br>
&gt;&gt; opt_acpi gets inlcuded lines below and so does opt_platform under the<br>
&gt;&gt; respective OPT_ checks.  Now they are there twice.<br>
&gt;<br>
&gt; OPT_ACPI doesn’t exist as a make variable so the &quot;.if !empty(OPT_ACPI)” check won’t work as it is expected to work here so opt_acpi.h won’t be built. The second problem is the opt_*.h files need to be unconditionally created so they can be included in the relevant code.<br>
<br>
Then they should probably have been removed from under the .ifdefs<br>
in the same commit?<br>
<br>
<br>
We do use OPT_ACPI elsewhere in the tree as well.. hwpmc?  Can&#39;t<br>
remember.  How&#39;s it working there?<br>
<br>
What is currently then including these files then?  Hmm I haven&#39;t used<br>
the module in a while...<br>
<br>
Should we duplicate the FDT logic for ACPI in sys/conf/<a href="http://kern.opts.mk" rel="noreferrer" target="_blank">kern.opts.mk</a><br>
so LINT-ACPI can be a better thing long-term as well?<br></blockquote><div><br></div><div>Yes. We likely should clean this up... But the appetite to polish the currently</div><div>way over polished and under powered config(8) program is low. However,</div><div>having it create a .mk file that can be included that summarizes all the</div><div>options in a kernel config would be the least amount of effort relative to the</div><div>crazy greps we have going on now.</div><div><br></div><div>Warner</div></div></div>

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CANCZdfrn2HPBY1THTF2GKX1cDnEuSMJYjDaJJ4Es_8KBzO4bJQ>