Re: [PATCH 3/7] gpu: nova-core: rename module from nova_core to nova-core

From: Alexandre Courbot

Date: Thu Apr 30 2026 - 23:26:04 EST


On Fri May 1, 2026 at 12:07 AM JST, Joel Fernandes wrote:
> On 4/30/2026 10:55 AM, Alexandre Courbot wrote:
>> Rename the kbuild module target from `nova_core.o` to `nova-core.o`.
>> This avoids a name collision between the module target and the Rust
>> crate object (`nova_core.o` from `nova_core.rs`), allowing the driver to
>> be built as a composite module.
>>
>> Signed-off-by: Alexandre Courbot <acourbot@xxxxxxxxxx>
>> ---
>> drivers/gpu/nova-core/Kconfig | 2 +-
>> drivers/gpu/nova-core/Makefile | 4 +++-
>> 2 files changed, 4 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/gpu/nova-core/Kconfig b/drivers/gpu/nova-core/Kconfig
>> index d8456f8eaa05..f918f69e0599 100644
>> --- a/drivers/gpu/nova-core/Kconfig
>> +++ b/drivers/gpu/nova-core/Kconfig
>> @@ -14,4 +14,4 @@ config NOVA_CORE
>>
>> This driver is work in progress and may not be functional.
>>
>> - If M is selected, the module will be called nova_core.
>> + If M is selected, the module will be called nova-core.
>> diff --git a/drivers/gpu/nova-core/Makefile b/drivers/gpu/nova-core/Makefile
>> index 2d78c50126e1..1f794baadc86 100644
>> --- a/drivers/gpu/nova-core/Makefile
>> +++ b/drivers/gpu/nova-core/Makefile
>> @@ -1,3 +1,5 @@
>> # SPDX-License-Identifier: GPL-2.0
>>
>> -obj-$(CONFIG_NOVA_CORE) += nova_core.o
>> +obj-$(CONFIG_NOVA_CORE) += nova-core.o
>
> I think a more descriptive name would be better than relying on dashes versus
> versus underscores, that's super confusing, how about:
>
>> +
>> +nova-core-y := nova_core.o
>>
>
> Lets make this: `nova-core-y := nova-core-mod.o`?

We would have to rename `nova_core.rs` to `nova_core_mod.rs` though.

But your argument has a point generally speaking - if there wasn't
any underscore in the module's name, then we would have to pick a
different name anyway.

Another option would be to use the Rust-idiomatic `lib.rs`. That's what
the kernel crate and others do.

Danilo, WDYT?