2022-08-02 14:12:11

by Grzegorz Szymaszek

[permalink] [raw]
Subject: The r8188eu kernel module does not depend on the rtlwifi/rtl8188eufw.bin firmware file

Dear r8188eu Maintainers,

The old rtl8188eu kernel module, removed in v5.15[1][2], indicated that
it requires the rtlwifi/rtl8188eufw.bin firmware file[3]. The new
r8188eu driver no longer does so.

I don’t know if it should be considered a regression or just a different
behaviour of the two drivers. I’ve noticed it[4] when I tried to use an
RTL8188EU‐based card in the initramfs of two different Ubuntu kernels:
v5.4 and v5.15. In v5.4, the firmware would be automatically included
when the (old) driver was included, whereas in v5.15 I would have to add
it manually so that the card actually worked. (One can verify the active
driver’s requirements using “modinfo -F firmware r8188eu”.)

If there are cards the new driver supports that do not need that
firmware file, it makes sense to not automatically include it. In
general, I don’t know the kernel policy on such dependencies.

[1]: commit 55dfa29b43d23bab37d98f087615ff46d38241df
[2]: https://lore.kernel.org/all/[email protected]/
[3]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/staging/rtl8188eu/os_dep/os_intfs.c?id=06889446a78fb9655332954a2288ecbacc7f0ff8#n22
[4]: https://answers.launchpad.net/ubuntu/+source/linux-meta-hwe-5.15/+question/702611

Best regards

--
Grzegorz Szymaszek


Attachments:
(No filename) (1.32 kB)
signature.asc (849.00 B)
Download all attachments

2022-08-02 14:43:03

by Grzegorz Szymaszek

[permalink] [raw]
Subject: Re: The r8188eu kernel module does not depend on the rtlwifi/rtl8188eufw.bin firmware file

On Tue, Aug 02, 2022 at 04:07:25PM +0200, Greg KH wrote:
> Looks like someone needs to add a line to the driver that looks like:
> MODULE_FIRMWARE("rtlwifi/rtl8188eufw.bin");
> […] Can you make a patch that does this?

Sure, I will prepare and send one later (hopefully today), assuming no
one objects in the meantime. Thanks for quick response.


Attachments:
(No filename) (356.00 B)
signature.asc (849.00 B)
Download all attachments

2022-08-02 14:45:14

by Greg KH

[permalink] [raw]
Subject: Re: The r8188eu kernel module does not depend on the rtlwifi/rtl8188eufw.bin firmware file

On Tue, Aug 02, 2022 at 03:17:58PM +0200, Grzegorz Szymaszek wrote:
> Dear r8188eu Maintainers,
>
> The old rtl8188eu kernel module, removed in v5.15[1][2], indicated that
> it requires the rtlwifi/rtl8188eufw.bin firmware file[3]. The new
> r8188eu driver no longer does so.
>
> I don’t know if it should be considered a regression or just a different
> behaviour of the two drivers. I’ve noticed it[4] when I tried to use an
> RTL8188EU‐based card in the initramfs of two different Ubuntu kernels:
> v5.4 and v5.15. In v5.4, the firmware would be automatically included
> when the (old) driver was included, whereas in v5.15 I would have to add
> it manually so that the card actually worked. (One can verify the active
> driver’s requirements using “modinfo -F firmware r8188eu”.)
>
> If there are cards the new driver supports that do not need that
> firmware file, it makes sense to not automatically include it. In
> general, I don’t know the kernel policy on such dependencies.
>
> [1]: commit 55dfa29b43d23bab37d98f087615ff46d38241df
> [2]: https://lore.kernel.org/all/[email protected]/
> [3]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/drivers/staging/rtl8188eu/os_dep/os_intfs.c?id=06889446a78fb9655332954a2288ecbacc7f0ff8#n22
> [4]: https://answers.launchpad.net/ubuntu/+source/linux-meta-hwe-5.15/+question/702611

Looks like someone needs to add a line to the driver that looks like:
MODULE_FIRMWARE("rtlwifi/rtl8188eufw.bin");
so that the tools will automatically pick it up properly going forward.

Can you make a patch that does this?

thanks,

greg k-h

2022-08-02 15:09:49

by Larry Finger

[permalink] [raw]
Subject: Re: The r8188eu kernel module does not depend on the rtlwifi/rtl8188eufw.bin firmware file

On 8/2/22 09:17, Grzegorz Szymaszek wrote:
> On Tue, Aug 02, 2022 at 04:07:25PM +0200, Greg KH wrote:
>> Looks like someone needs to add a line to the driver that looks like:
>> MODULE_FIRMWARE("rtlwifi/rtl8188eufw.bin");
>> […] Can you make a patch that does this?
>
> Sure, I will prepare and send one later (hopefully today), assuming no
> one objects in the meantime. Thanks for quick response.

There will be no objections. All 8188eu-based devices need that firmware.
Omitting the MODULE_FIRMWARE macro was simply an oversight.

Larry