Re: [PATCH 4/8] platform: dell: Allow DELL_LAPTOP to be arch-independent

From: Brian Mak

Date: Mon Nov 23 2026 - 16:17:10 EST


On 11/23/26 13:00, Pali Rohár wrote:
> On Monday 23 November 2026 20:33:11 Brian Mak wrote:
>> On 11/23/26 11:39, Pali Rohár wrote:
>>> On Monday 23 November 2026 19:11:00 Brian Mak wrote:
>>>> On 11/20/26 16:48, Pali Rohár wrote:
>>>>> On Friday 20 November 2026 16:05:50 Brian Mak wrote:
>> The dell-rbtn interface is not present on my XPS 16 Creator
>> Edition either. There isn't an rfkill interface on this platform, to my
>> knowledge. When I suggested to make rfkill setup fail without failing
>> probe, that was for in case the dell-rbtn interface is available on a
>> future platform. Since you said that it's abandoned, I would agree that
>> there's no possible sources for rfkill events on ARM64 Dell platforms.
>>
>> I can gate rfkill setup logic behind an ifdef as well then, for v2. Is
>> your preference to gate behind SERIO_I8042 or X86?
>
> The i8042 and dell-rbtn are two event reports. These "HW" parts are
> sending events to kernel when the hard rfkill state changes. On some
> laptops it is i8042 on another it is dell-rbtn and on some both.
> Obviously it is enough to get just one event that hard rfkill state was
> changed (the driver will re-read state and inform listeners).
>
> But to provide kernel events to listeners, it is needed to have
> something which will report it to kernel. And in case there is hard
> rfkill on arm64 there would be also some interrupt mechanism which will
> report it. I'm just guessing, this is something which Dell or laptop
> platform people would know.
>
> So right now, when the driver is moving out of the x86 subdir, gating
> i8042 logic should be behind the SERIO_I8042.
>
> In my opinion there would be some interrupt / event mechanism also on
> arm64 products (if not now then maybe in some later products), so the
> code would be revisited in future.
>
>>> In any case, it does not make any sense to provide "fake" or "dummy"
>>> device by linux just to make driver compilable.
>>
>> I'm not sure I understand what you mean by this. Under my original
>> proposal of making rfkill setup fail without failing probe, no dummy or
>> non-functional devices would be exposed by the driver. rfkill setup
>> would fail gracefully, and the rfkill devices would go away with it. I
>> agree with you, but I'm not sure if I'm missing something here.
>
> Ok, if rfkill devices go away then it is fine. I was not fully sure
> about it.

Ok, I will go with this way for v2 then.

> Now I see that I forgot lot of logic behind those dell drivers, so I
> would need to re-read it again.
>
>>>> For the touchpad LED currently, the i8042_command() stub will return
>>>> -ENODEV and do nothing. This will register an LED that does nothing. For
>>>> v2, I can gate the LED registration behind a SERIO_I8042 ifdef.
>>>
>>> I think that this is correct way. The i8042 touchpad led should not be
>>> enabled when the i8042 HW is not present at all. And that touchpad led
>>> is only for few models based on whitelist.
>>>
>>>> For the Kconfig, since i8042 is required on some x86 Dell platforms, I
>>>> can change the Kconfig dependency to be like such, to ensure that
>>>> SERIO_I8042 is required on x86 and optional elsewhere (in case there's
>>>> another arch introduced by Dell that supports i8042 in the future):
>>>>
>>>> depends on SERIO_I8042 || (SERIO_I8042 = n && !X86)
>>>>
>>>> Please let me know if these changes are good with you.
>>>>
>>>> Thanks,
>>>> Brian
>>>
>>> My personal opinion is to make i8042 dependency only on x86. And do not
>>> even try to enable i8042 on non-x86 platforms. All dell drivers were in
>>> x86 subdirectory which cause that explicit x86 was not written in
>>> Kconfig (as it was not needed).
>>>
>>> Now when you are moving dell drivers out of the x86 subdir, maybe it
>>> could make sense to check if there are some other config options which
>>> have also hidden dependency on x86.
>>>
>>> Anyway, I highly doubt that any new platform / device (which is designed
>>> from scratch; not rebranded or evoluted) would use i8042 for any such
>>> API. Nowadays all those functionalities are based on ACPI or WMI APIs.
>>
>> If I understand your suggestion correctly, you are asking, instead of
>> gating behind:
>>
>> depends on SERIO_I8042 || (SERIO_I8042 = n && !X86)
>>
>> You would gate behind:
>>
>> depends on SERIO_I8042 || !X86
>>
>> Thanks,
>> Brian
>
> Ufff... some more complicated logic behind.
>
> Let me think... If you extend the driver to compile touchpad led support
> conditionally based on CONFIG_SERIO_I8042 and same for that rfkill event
> reported, then it should be enough to write just:
>
> depends on SERIO_I8042 || SERIO_I8042 = n
>
> After those changes if somebody compiles kernel without the SERIO_I8042
> support (e.g. because uses only USB keywords) then would be able to use
> dell drivers on laptops without touchpad led and without rfkill. (I
> guess there are many such laptops).
>
> And at the same time it will solve also your problem with arm64. And do
> not need to think about "|| !X86" part at all.
>
> It is correct, or did I some mistake here?
>
> (I'm trying to simplify that logic and setup.)

Yes, this seems correct to me. So, I will keep this patch the same as it
is now in v1, and then in a preceding patch, add the appropriate gates.

Also, sorry for the spam in my last message. I'm not sure what happened
there! :)

Thanks,
Brian