From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.221.41 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796048046; b=zXycc1w3Qb+LZ+zU1P32H62j39HrFGA5T2xwkGyZWsmjPqYKHga9YXr94H1zlG2nVsIB u44qClOZMEPLdJLBj49h+Hv/f+qHY30RxBkteM5Vks/o9mY0ZwXV292YGFKvpjQRNux2Q Ot9OmReV9pmyHaBxbGIAWg0KIEy4t9Twrqf7EEIWKbCx7RcOah+eLyk6XoO6MffpPaxkq U84R6HZPWdHraEEvjdZ3pmI2h3pfvEANTamkOZygDFqojTunjxjPtqXsCHBHIrdDRitVi OJ08kQZPgwjoZhzGWqBw3kHRX/Ml0AGYbRIsY4DWIs8ArO8OCkGuG/UooOAWEkoe2pw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796048046; h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received: From:To:Cc:Subject:Date:Message-ID:X-Mailer:MIME-Version: Content-Transfer-Encoding; bh=+TJOqiainl1LYHbG7uw1rOc7zGzNkCSpMzSxb6aT9U8=; b=h9K+EUb4ZJs0GirxGgaRpu31cakE7vwEH5VjEwVu03oqT7enBfJozjFMWsH4hvSMWS1H /NSMQv7dq8BE37ZGx9ZczuwpCnAsof3ELhJi2PJJZURVHQz6dYkZVS48/lMD9R/Y2IFHd 2aBZBYF18s9NRNiGrxnMnvFFmaFZ8wstF2a9gVniwtb5zI3/ibUR5zzO0TDNS2lwXyfjv E8CVFWLjnUalmtw6ZCUINGYb6uayNI30nLBW271Ubj+dAkFclYyaVYcBNZPpEiqJGSoeq 6IE6aPWzfVH7McHfEi62csy4b9x/oMde3FRanZrsu9jtfigOmWv7Pu59uqRYNSQq9pA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=Y+stL+hc; arc=none smtp.remote-ip=209.85.221.41 Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com [209.85.221.41]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 125D3606A31C for ; Mon, 30 Nov 2026 14:14:05 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 125D3606A31C Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=Y+stL+hc Received: by mail-wr1-f41.google.com with SMTP id ffacd0b85a97d-4c4b8e58cfeso896178f8f.3 for ; Mon, 30 Nov 2026 06:14:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20260707; t=1796048044; x=1796652844; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to:content-type; bh=+TJOqiainl1LYHbG7uw1rOc7zGzNkCSpMzSxb6aT9U8=; b=Y+stL+hctvJP5lhc0eh/ke+OBKgZzdqZ0qgLgULEviO9Jkik7ZE/QxlUCYxIOVL8MB EWaWIAqenTEpQPyhTKMOlpIYJ/T44WBNBjNrJdm7KhPa4SLqT6PlOa9sCmhW1d0G9r8h MuY/I/f3MLWbvVHA5uOtL+VxlHIj/+w8SygN0Hn5JqU5QenaXQTIluw+5ZqmOwrI+kFg Wourp5ziHGoWPY77LDlwYvshLaB+IhxSXu9ruk7/XD3dgZ8Udka/HMEm5LHTfYo3ATOB 2F6t+X0YinvaFa6Hz1DR7XwDwbH+Q3z687TfVnoBmebQ5E867MS34yOjteQwAF02GI1P MeQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796048044; x=1796652844; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to:content-type; bh=+TJOqiainl1LYHbG7uw1rOc7zGzNkCSpMzSxb6aT9U8=; b=NNQcCxcj0RBXTb9CEXEeqGMz5SdRXgof2+uOeoYi4Rj+cJiSlwvPPkYUm2Q2wCQ+o5 0id3E5VW4/7iDq8okJovV1qlbJRPads7Kpf4QAepCsvDkmpc9IyiVRNawp/NGl1J5gcv z9dZM5jjM5jxsW6+vawOr8wL1Z57LwfAlNaPxzub6TDJSnnxQqLVReLbzp79v2je2D4+ qrDIHQ4Q6tZXtwCgASj03qbRnen5cLVNeMbygad7YUDsq7hwaHyc8R/v5VLZXP3lom6b ET+46NruSxKSoe68mG6Kxz2gS6E2Lv+y/x3m7/AuUK5HCR2PgWG4PdLWMkT/jFt+2fBD /GVw== X-Forwarded-Encrypted: i=1; AL+hErFbiO3Wu9yYwDQo2ZTepZxe6SBdsNAzdHwHQEhvTsq7gwmnk9HycfFe8CcaMjSXyFJR6nNHBiGCs3n/aw==@vger.kernel.org X-Gm-Message-State: APuU4Z/XX2VloJsSZRftSeH1SwcqLx/4esHV+0Oteitqy1xVQe6J7L9O wp9rSCia3Xff9nEEStfYWXU/78TRKYFm8XuJ/BbfoJcSRIiS5wRZBmvg X-Gm-Gg: AZFdTZcClncHL5ogY+6NfBf3TT/qu2rEaspeO9Sp301sSG+taCukKmJvAGWnuppjL0o B+EwJIM17lexnT/D7vKN+yk/8TJH02VUJjSBT7wdVyYcRhJWs53qaVSH/c+SDnMGSTspF/M/2UC cocRMCi334O9j61Em8aROr0uctp3WxIVLYFlkKYoVB21vivtlPNwMxj0buewGKhsW76GDo6dGzR oyV6BKxlh7GHFXOLofHQZnobzJbO44tQq8PPY9dgoW+fMKHLw0wsBfZOgvilTR8VK1Exhjulr1N exNw1sjAjCJfHJbRAjNsQvO4s+dQJMAHoyaszNkS9a3ZZEoAGFrA0YKl7CLLI/BLpNu1uX1L2+3 izl1DWF9cx7v7Rh5o0qdzlxCSpLOgjEVS394cz+vTLohfOe4rcQT/dQcKI/akzr0JRvXo41Oajg GogiMLNXbkAYqhP2iMZArwgEpxIk6rkjl4/GvcBurjYuw/RwIfu+PXn5sjbXyCHV/w1rKfeSu7V aH+qV7s8jmnmeDI+DO0eFqb3FbytmEu4eE/+33AUdVGB/jjimoZNT/tS/Mn39wJC8jtuinx09Wa z7pc6SWrCPLpaWcB4GZTLJ4GJDRnBHDtd0VascfExBEpwDHDOu5IwjZLOy7+8YQstXUtHtzD+zC gqna8L8p7mLvo91d7sAGuETXMTrwh9ivuGZ0icO+rfJi63l2Sv6M2uG+Q3F9xlH2TNM/76wDELN q/CXMDKxBwEZA7L3Hw2IsZ6OEqZoWHIey4wwU3NHGZ+by4dk+JIexI5fYC2Uf7k+Axbai9IouQe Eu2yTqX4qJeXJ97LHtplKU= X-Received: by 2002:adf:e014:0:10b0:4a7:7bec:e159 with SMTP id ffacd0b85a97d-4abb400bb4fmr48104116f8f.15.1796048044053; Mon, 30 Nov 2026 06:14:04 -0800 (PST) Received: from fedora.homenet.telecomitalia.it (host-80-180-247-220.retail.telecomitalia.it. [80.180.247.220]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-4ab69bf6804sm64716248f8f.10.2026.11.30.06.14.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Nov 2026 06:14:03 -0800 (PST) From: Andrea Spitaleri To: Jiri Kosina , Benjamin Tissoires Cc: Andrea Spitaleri , Dmitry Torokhov , =?UTF-8?q?Filipe=20La=C3=ADns?= , linux-input@vger.kernel.org, stable@vger.kernel.org Subject: [PATCH] HID: logitech-hidpp: fix G920 force feedback init timing out Date: Mon, 30 Nov 2026 15:13:06 +0100 Message-ID: <20261130141337.14283-1-spita90@gmail.com> X-Mailer: git-send-email 2.56.1 X-Mailing-List: linux-input@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Since commit 544315e40172 ("HID: logitech-hidpp: move FF initialization to .input_configured()"), the force feedback of the G920 (and of the G923 for Xbox, which shares its class) no longer initializes: logitech-hidpp-device 0003:046D:C262.000A: Unable to initialize force feedback support, errno -110 hidpp_input_configured() runs from hid_connect(), which hidpp_probe() calls right after hid_device_io_stop(). While IO is stopped, __hid_input_report() cannot take driver_input_lock and drops every incoming report, so the answer to the first HID++ request of g920_get_config() never reaches hidpp_raw_event(). hidpp_send_message_sync() waits 5 seconds for it, gets an empty response, tries twice more and returns -ETIMEDOUT: the probe takes 15 seconds longer and the wheel is left without force feedback. Start IO for the duration of the force feedback initialization. hdev->claimed is still empty at that point, so the incoming reports only reach the driver's raw_event, not hid-input, hiddev or hidraw, which are not connected yet. Tested on a G920 (046d:c262) with 7.3.4: the wheel probes at once and has its force feedback again, as on 7.2. Fixes: 544315e40172 ("HID: logitech-hidpp: move FF initialization to .input_configured()") Cc: stable@vger.kernel.org Assisted-by: Claude:claude-opus-5-5 Signed-off-by: Andrea Spitaleri --- drivers/hid/hid-logitech-hidpp.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/hid/hid-logitech-hidpp.c b/drivers/hid/hid-logitech-hidpp.c index 60fc6b8..6abf07b 100644 --- a/drivers/hid/hid-logitech-hidpp.c +++ b/drivers/hid/hid-logitech-hidpp.c @@ -4092,13 +4092,25 @@ static int hidpp_input_configured(struct hid_device *hdev, struct hid_input *hid if (hidpp->quirks & HIDPP_QUIRK_CLASS_G920) { struct hidpp_ff_private_data data; + bool io_stopped; if (!list_is_first(&hidinput->list, &hdev->inputs)) return 0; + /* + * hidpp_probe() stops IO before hid_connect(), which calls us, + * so the answers to the HID++ requests below would be dropped. + * Allow incoming packets meanwhile: hdev->claimed is not set + * yet, so they only reach hidpp_raw_event(). + */ + io_stopped = !hdev->io_started; + if (io_stopped) + hid_device_io_start(hdev); ret = g920_get_config(hidpp, &data); if (!ret) ret = hidpp_ff_init(hidpp, &data); + if (io_stopped) + hid_device_io_stop(hdev); if (ret) { hid_warn(hidpp->hid_dev, -- 2.56.1