Re: [PATCH 1/2] HID: picolcd: Move output requests out of spinlocked sections

From: Sebastian Andrzej Siewior

Date: Mon Sep 28 2026 - 08:29:42 EST


On 2026-09-28 13:46:53 [+0200], Aveline Noir wrote:
> Creating a PicoLCD through UHID triggers a sleeping-in-invalid-context
> warning in picolcd_set_contrast() on PREEMPT_RT. hid_hw_request() can

This is not limited to PREEMPT_RT.

> allocate with GFP_KERNEL and wait for a reply through __hid_request(),
> but the driver invokes it while holding data->lock. The same pattern

picolcd_data::lock. The important part is that the lock is a spinlock_t.
Non-PREEMPT_RT builds should complain here, too.

Sebastian