Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 26 Oct 2024 20:36:00 +0100
From:      Jessica Clarke <jrtc27@freebsd.org>
To:        Mark Johnston <markj@freebsd.org>
Cc:        "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: 152382e6613d - main - rc.d/kld: Print the kernel modules being loaded
Message-ID:  <58A8DE4A-150D-45A8-8177-86534DB64025@freebsd.org>
In-Reply-To: <Zx0-eQaICRCa5Y4_@nuc>
References:  <202410261900.49QJ0cLo037733@gitrepo.freebsd.org> <08AA3DE1-0618-44A0-AE8C-7BDECD2BE933@freebsd.org> <Zx0-eQaICRCa5Y4_@nuc>

next in thread | previous in thread | raw e-mail | index | archive | help
On 26 Oct 2024, at 20:09, Mark Johnston <markj@freebsd.org> wrote:
>=20
> On Sat, Oct 26, 2024 at 08:02:27PM +0100, Jessica Clarke wrote:
>> On 26 Oct 2024, at 20:00, Mark Johnston <markj@FreeBSD.org> wrote:
>>>=20
>>> The branch main has been updated by markj:
>>>=20
>>> URL: =
https://cgit.FreeBSD.org/src/commit/?id=3D152382e6613d7998fe6f5233767df54d=
3fdec329
>>>=20
>>> commit 152382e6613d7998fe6f5233767df54d3fdec329
>>> Author:     Mark Felder <feld@FreeBSD.org>
>>> AuthorDate: 2024-10-26 18:43:46 +0000
>>> Commit:     Mark Johnston <markj@FreeBSD.org>
>>> CommitDate: 2024-10-26 18:43:46 +0000
>>>=20
>>>   rc.d/kld: Print the kernel modules being loaded
>>>=20
>>>   PR:             282269
>>>   MFC after:      2 weeks
>>> ---
>>> libexec/rc/rc.d/kld | 4 +++-
>>> 1 file changed, 3 insertions(+), 1 deletion(-)
>>>=20
>>> diff --git a/libexec/rc/rc.d/kld b/libexec/rc/rc.d/kld
>>> index d9c45a05f7a6..729416323d6e 100755
>>> --- a/libexec/rc/rc.d/kld
>>> +++ b/libexec/rc/rc.d/kld
>>> @@ -44,10 +44,12 @@ kld_start()
>>>=20
>>> local _kld
>>>=20
>>> - echo 'Loading kernel modules:'
>>> + echo -n 'Loading kernel modules: '
>>> for _kld in $kld_list ; do
>>> load_kld -e ${_kld}.ko $_kld
>>> + echo -n "${_kld} "
>>=20
>> This always prints a trailing space, whether the list is empty or =
not.
>=20
> If the list is empty, we won't get this far.

Yes, but the echo above does the same. By =E2=80=9Cthis=E2=80=9D I meant =
the combined
effect, I just put the comment here as it was the last relevant line.

>> Why not drop the space from the first echo and put it as a prefix in
>> the second instead?
>=20
> That's a better way to handle it, thanks.

Thanks for the follow-up.

Jess




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?58A8DE4A-150D-45A8-8177-86534DB64025>