From: Kees Cook <keescook@chromium.org>
To: Brendan Higgins <brendanhiggins@google.com>
Cc: David Gow <davidgow@google.com>,
linux-kernel-mentees@lists.linuxfoundation.org,
Rasmus Villemoes <linux@rasmusvillemoes.dk>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
"open list:KERNEL SELFTEST FRAMEWORK"
<linux-kselftest@vger.kernel.org>,
Alan Maguire <alan.maguire@oracle.com>,
KUnit Development <kunit-dev@googlegroups.com>
Subject: Re: [Linux-kernel-mentees] common KUnit Kconfig and file naming (was: Re: [PATCH] lib: kunit_test_overflow: add KUnit test of check_*_overflow functions)
Date: Thu, 18 Jun 2020 20:42:01 -0700 [thread overview]
Message-ID: <202006182016.C93BC8AB@keescook> (raw)
In-Reply-To: <CAFd5g44kZe7h+qKHmx029Qj15FdqxsFRFD3TEx_iEhPEt0jJmA@mail.gmail.com>
On Thu, Jun 18, 2020 at 01:27:55PM -0700, Brendan Higgins wrote:
> I am cool with changing *-test.c to *-kunit.c. The *-test.c was a hold
I am fine with basically any decision as long as there's a single naming
convention, *except* for this part. Dashes in source files creates
confusion for module naming. Separators should be underscores. This is
a standing pet-peeve of mine, and while I certainly can't fix it
universally in the kernel, we can at least avoid creating an entire
subsystem that gets this wrong for all modules. :)
To illustrate:
$ modinfo dvb-bt8xx
filename: .../kernel/drivers/media/pci/bt8xx/dvb-bt8xx.ko
...
name: dvb_bt8xx
^ does not match the .ko file, nor source.
Primarily my issue is the disconnect between "dmesg" output and finding
the source. It's not like, a huge deal, but it bugs me. :) As in:
$ strings drivers/media/pci/bt8xx/dvb-bt8xx.o | grep 'Init Error'
4dvb_bt8xx: or51211: Init Error - Can't Reset DVR (%i)
All this said, if there really is some good reason to use dashes, I will
get over it. :P
(And now that I've had to say all this "out loud", I wonder if maybe I
could actually fix this all at the root cause: KBUILD_MOD_NAME... it is
sometimes used for identifiers, which is why it does the underscore
replacement... I wonder if it could be split into "name" and
"identifier"...)
--
Kees Cook
_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees
WARNING: multiple messages have this Message-ID (diff)
From: Kees Cook <keescook@chromium.org>
To: Brendan Higgins <brendanhiggins@google.com>
Cc: David Gow <davidgow@google.com>,
Alan Maguire <alan.maguire@oracle.com>,
Vitor Massaru Iha <vitor@massaru.org>,
KUnit Development <kunit-dev@googlegroups.com>,
Shuah Khan <skhan@linuxfoundation.org>,
"open list:KERNEL SELFTEST FRAMEWORK"
<linux-kselftest@vger.kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
linux-kernel-mentees@lists.linuxfoundation.org,
Rasmus Villemoes <linux@rasmusvillemoes.dk>
Subject: Re: common KUnit Kconfig and file naming (was: Re: [PATCH] lib: kunit_test_overflow: add KUnit test of check_*_overflow functions)
Date: Thu, 18 Jun 2020 20:42:01 -0700 [thread overview]
Message-ID: <202006182016.C93BC8AB@keescook> (raw)
In-Reply-To: <CAFd5g44kZe7h+qKHmx029Qj15FdqxsFRFD3TEx_iEhPEt0jJmA@mail.gmail.com>
On Thu, Jun 18, 2020 at 01:27:55PM -0700, Brendan Higgins wrote:
> I am cool with changing *-test.c to *-kunit.c. The *-test.c was a hold
I am fine with basically any decision as long as there's a single naming
convention, *except* for this part. Dashes in source files creates
confusion for module naming. Separators should be underscores. This is
a standing pet-peeve of mine, and while I certainly can't fix it
universally in the kernel, we can at least avoid creating an entire
subsystem that gets this wrong for all modules. :)
To illustrate:
$ modinfo dvb-bt8xx
filename: .../kernel/drivers/media/pci/bt8xx/dvb-bt8xx.ko
...
name: dvb_bt8xx
^ does not match the .ko file, nor source.
Primarily my issue is the disconnect between "dmesg" output and finding
the source. It's not like, a huge deal, but it bugs me. :) As in:
$ strings drivers/media/pci/bt8xx/dvb-bt8xx.o | grep 'Init Error'
4dvb_bt8xx: or51211: Init Error - Can't Reset DVR (%i)
All this said, if there really is some good reason to use dashes, I will
get over it. :P
(And now that I've had to say all this "out loud", I wonder if maybe I
could actually fix this all at the root cause: KBUILD_MOD_NAME... it is
sometimes used for identifiers, which is why it does the underscore
replacement... I wonder if it could be split into "name" and
"identifier"...)
--
Kees Cook
next prev parent reply other threads:[~2020-06-19 3:42 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-11 21:55 [Linux-kernel-mentees] [PATCH] lib: kunit_test_overflow: add KUnit test of check_*_overflow functions Vitor Massaru Iha
2020-06-11 21:55 ` Vitor Massaru Iha
2020-06-12 19:06 ` [Linux-kernel-mentees] " Brendan Higgins via Linux-kernel-mentees
2020-06-12 19:06 ` Brendan Higgins
2020-06-12 22:36 ` [Linux-kernel-mentees] " Kees Cook
2020-06-12 22:36 ` Kees Cook
2020-06-13 6:51 ` [Linux-kernel-mentees] " David Gow via Linux-kernel-mentees
2020-06-13 6:51 ` David Gow
2020-06-14 17:48 ` [Linux-kernel-mentees] common KUnit Kconfig and file naming (was: Re: [PATCH] lib: kunit_test_overflow: add KUnit test of check_*_overflow functions) Kees Cook
2020-06-14 17:48 ` Kees Cook
2020-06-16 7:25 ` [Linux-kernel-mentees] " David Gow via Linux-kernel-mentees
2020-06-16 7:25 ` David Gow
2020-06-16 9:40 ` [Linux-kernel-mentees] " Alan Maguire
2020-06-16 9:40 ` Alan Maguire
2020-06-17 4:20 ` [Linux-kernel-mentees] " David Gow via Linux-kernel-mentees
2020-06-17 4:20 ` David Gow
2020-06-18 20:27 ` [Linux-kernel-mentees] " Brendan Higgins via Linux-kernel-mentees
2020-06-18 20:27 ` Brendan Higgins
2020-06-19 3:42 ` Kees Cook [this message]
2020-06-19 3:42 ` Kees Cook
2020-06-19 6:39 ` [Linux-kernel-mentees] " David Gow via Linux-kernel-mentees
2020-06-19 6:39 ` David Gow
2020-06-19 20:12 ` [Linux-kernel-mentees] " Brendan Higgins via Linux-kernel-mentees
2020-06-19 20:12 ` Brendan Higgins
2020-06-15 16:30 ` [Linux-kernel-mentees] [PATCH] lib: kunit_test_overflow: add KUnit test of check_*_overflow functions Vitor Massaru Iha
2020-06-15 16:30 ` Vitor Massaru Iha
2020-06-15 18:37 ` [Linux-kernel-mentees] " Kees Cook
2020-06-15 18:37 ` Kees Cook
2020-06-13 6:56 ` [Linux-kernel-mentees] " David Gow via Linux-kernel-mentees
2020-06-13 6:56 ` David Gow
2020-06-15 16:33 ` [Linux-kernel-mentees] " Vitor Massaru Iha
2020-06-15 16:33 ` Vitor Massaru Iha
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202006182016.C93BC8AB@keescook \
--to=keescook@chromium.org \
--cc=alan.maguire@oracle.com \
--cc=brendanhiggins@google.com \
--cc=davidgow@google.com \
--cc=kunit-dev@googlegroups.com \
--cc=linux-kernel-mentees@lists.linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=linux@rasmusvillemoes.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.