From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx-relay50-hz3.antispameurope.com (mx-relay50-hz3.antispameurope.com [94.100.134.239]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C079636996A for ; Wed, 11 Feb 2026 10:42:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=pass smtp.client-ip=94.100.134.239 ARC-Seal:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770806570; cv=pass; b=BGxTbwq6dFGF4zYeKypNK0Tz8sxZ6zoKbVFZ99lqKzZXWi2ACOAyVx9PY9zpn/U69Y5ikKdIHRfQZRdPBlw50nJE/0OIrxL9zTMcbqc7c++aT8OXQFTrFFjGXlHyJMC9tBersf8pbPz4uWKt8rgowc1dRfy/8/UUxp+hLg5cJVk= ARC-Message-Signature:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770806570; c=relaxed/simple; bh=ahbzhUC3Vh4BBM5acDlBweT2Yz36dSGstQsc0Os1IuA=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=HNkBASI3nZlvn4dneHQfeiQdq+VcOn3Nmw0CZkaBbvLoCYWoj992LMcMSYpyZMQ+bM4NypqIm5Fno4BNXTr6HGpKVEtQ0bg5VMEm2DYASCOcAuOSZrLymF8mui9T1k5keSoYAOOIKNRseo1Xyts75BKQf2/Lk7T8EcrwVKjgzc4= ARC-Authentication-Results:i=2; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=ew.tq-group.com; spf=pass smtp.mailfrom=ew.tq-group.com; dkim=pass (2048-bit key) header.d=ew.tq-group.com header.i=@ew.tq-group.com header.b=iFPeesAp; arc=pass smtp.client-ip=94.100.134.239 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=ew.tq-group.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ew.tq-group.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ew.tq-group.com header.i=@ew.tq-group.com header.b="iFPeesAp" ARC-Authentication-Results: i=1; mx-gate50-hz3.hornetsecurity.com 1; spf=pass reason=mailfrom (ip=94.100.132.6, headerfrom=ew.tq-group.com) smtp.mailfrom=ew.tq-group.com smtp.helo=hmail-p-smtp01-out03-hz1.hornetsecurity.com; dmarc=pass header.from=ew.tq-group.com orig.disposition=pass ARC-Message-Signature: a=rsa-sha256; bh=UFl5YgSA4AVltIjZ58cGO/PBtIJpgan1487sq6q6KzE=; c=relaxed/relaxed; d=hornetsecurity.com; h=from:to:date:subject:mime-version:; i=1; s=hse1; t=1770806557; b=dkr1d/9Ko5/hWXrBUn9Olbhj1p5YimEfAlu093/jNnGmhNtE0pEBe1kG6OghgT9kncCpkDNB ZZiBCG9/XjG4jOBARvh7Vb0QsAmTEhNPVjPDF5Fr0+UrOHV+7a5WkmTsHB6BqN+Y9zM9PbMhBAa ILlAzOwgfXDj85nCSPAlkHyTbPkmdgvlIUQoMVjKRTnTffz59sWLYNOgvJTIftxA9PQVmaMO9z+ RQwdNVeertI+H4D24yBCKqiwSBIyBIxe+gVzkVOl1mvSc+UH5u0BRxJBUhCwVdjVjMminOaBcFj U/VlF47+UBbF9qfTVK8I970pMZgz+zuCPbcNLfBhlP+3Q== ARC-Seal: a=rsa-sha256; cv=none; d=hornetsecurity.com; i=1; s=hse1; t=1770806557; b=mK7oi4fgbLOTgU64j0ZeVNqQGh5mUuQmITfHVzCgkM/ZM451kySLp6u6HLoIVsrMXeR1em0s fI/eMCveYjO85HA18LYLBPqxJAoufWjG+yq2R68jE+L1KL+SDKtK6bTgExaUIGVcEaBN0H4/0BK PPgrTPOsuI15oqasImPg+OuUGRJQ3Yqoz7d5B8JCW7EpV2bsmyUWBr1m6jCd/QlfE6Nma+pjqAr DOoqZ/3FxYtigzUuR7UHccsNwKGJifOR2c4mREfpD0T+7k1XVdT/Od/iycHhZlwpq2yXvuclYl6 +uqULLJYOqbd1N4m+HR2gDadAwKpnS/uv9csd8Sq17Xlg== Received: from he-nlb01-hz1.hornetsecurity.com ([94.100.132.6]) by mx-relay50-hz3.antispameurope.com; Wed, 11 Feb 2026 11:42:37 +0100 Received: from steina-w.localnet (host-82-135-125-110.customer.m-online.net [82.135.125.110]) (Authenticated sender: alexander.stein@ew.tq-group.com) by hmail-p-smtp01-out03-hz1.hornetsecurity.com (Postfix) with ESMTPSA id 89514CC0D30; Wed, 11 Feb 2026 11:42:21 +0100 (CET) From: Alexander Stein To: Gui-Dong Han , Mark Brown Cc: gregkh@linuxfoundation.org, rafael@kernel.org, dakr@kernel.org, linux-kernel@vger.kernel.org, baijiaju1990@gmail.com, Qiu-ji Chen , Aishwarya.TCV@arm.com Subject: Re: [PATCH v5] driver core: enforce device_lock for driver_match_device() Date: Wed, 11 Feb 2026 11:42:21 +0100 Message-ID: <13955113.uLZWGnKmhe@steina-w> Organization: TQ-Systems GmbH In-Reply-To: <7ae38e31-ef31-43ad-9106-7c76ea0e8596@sirena.org.uk> References: <20260113162843.12712-1-hanguidong02@gmail.com> <7ae38e31-ef31-43ad-9106-7c76ea0e8596@sirena.org.uk> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1" X-cloud-security-sender:alexander.stein@ew.tq-group.com X-cloud-security-recipient:linux-kernel@vger.kernel.org X-cloud-security-crypt: load encryption module X-cloud-security-Mailarchiv: E-Mail archived for: alexander.stein@ew.tq-group.com X-cloud-security-Mailarchivtype:outbound X-cloud-security-Virusscan:CLEAN X-cloud-security-disclaimer: This E-Mail was scanned by E-Mailservice on mx-relay50-hz3.antispameurope.com with 4f9w3y0QZsz2nHv9 X-cloud-security-connect: he-nlb01-hz1.hornetsecurity.com[94.100.132.6], TLS=1, IP=94.100.132.6 X-cloud-security-Digest:d0f225830104217d8c53e52525cbc303 X-cloud-security:scantime:2.005 DKIM-Signature: a=rsa-sha256; bh=UFl5YgSA4AVltIjZ58cGO/PBtIJpgan1487sq6q6KzE=; c=relaxed/relaxed; d=ew.tq-group.com; h=content-type:mime-version:subject:from:to:message-id:date; s=hse1; t=1770806557; v=1; b=iFPeesApfT+t3G16+pxWPLT6RHil49S0EJFjYBic2M64aOkSvFkGGAYw8OdbOhi61zN78zsH ghBBSTWBr63k6w8SuMUrx/ztvqTuG2ezqzi/085HLL57H3kZddRyWIr2rThrXKBiFbz+qZUqwxr GAlDDsSM9IBpq31Mo8mURsJMmhrHynmBzWmM6znrLKcziploxAXpB6AdjUnDgiXUd6tY6aORsCS x485r2UUgQuaj5GB9Lz+Akbb99prkYEIdkv35mThkxK4adQiK5f6XDh93ulfa1HPlK23bY2fXsD 3Osr2npJVXoocZznf/mERqsK6k7MObts6kwpKMsJNFjfQ== Hi, Am Dienstag, 20. Januar 2026, 14:22:19 CET schrieb Mark Brown: > On Wed, Jan 14, 2026 at 12:28:43AM +0800, Gui-Dong Han wrote: > > Currently, driver_match_device() is called from three sites. One site > > (__device_attach_driver) holds device_lock(dev), but the other two > > (bind_store and __driver_attach) do not. This inconsistency means that > > bus match() callbacks are not guaranteed to be called with the lock > > held. >=20 > I'm seeing boot hangs on Arm Juno in next/pending-fixes which bisect to > this commit. The boot grinds to a halt near the end of boot: >=20 > [ 2.570549] ledtrig-cpu: registered to indicate activity on CPUs > [ 2.618301] Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled > [ 2.623547] msm_serial: driver initialized > [ 2.624058] SuperH (H)SCI(F) driver initialized > [ 2.624312] STM32 USART driver initialized >=20 > with no further output, full log: >=20 > https://lava.sirena.org.uk/scheduler/job/2387335#L862 >=20 > We are also seeing similar looking boot hangs on some Qualcomm platforms > in Arm's test lab which aren't verified to be the same thing but are > hanging at a similar point in boot. I've also experienced a boot problem on an NXP i.MX8QM based board (DT currently in process of upstreaming). Bisect also resulted in this commit. Boot suddenly blocks, after about 4 minutes I get a blocked task backtrace: [ 1.053132] NET: Registered PF_PACKET protocol family [ 1.057958] Key type dns_resolver registered [ 1.070822] registered taskstats version 1 [ 1.074738] Loading compiled-in X.509 certificates [ 1.091208] Demotion targets for Node 0: null [ 1.099632] imx-scu system-controller: NXP i.MX SCU Initialized [ 242.855834] INFO: task swapper/0:1 blocked for more than 120 seconds. [ 242.861994] Not tainted 6.19.0-rc5+ #41 [ 242.866304] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables = this message. [ 242.874122] task:swapper/0 state:D stack:0 pid:1 tgid:1 = ppid:0 task_flags:0x0140 flags:0x00000010 [ 242.884981] Call trace: [ 242.887406] __switch_to+0xdc/0x120 (T) [ 242.891233] __schedule+0x310/0x7a0 [ 242.894708] schedule+0x30/0xa4 [ 242.897835] schedule_timeout+0x10c/0x118 [ 242.901831] wait_for_completion+0xd4/0x170 [ 242.906002] __flush_work+0x6c/0xdc [ 242.909476] flush_work+0x2c/0x38 [ 242.912777] deferred_probe_initcall+0x58/0xb0 [ 242.917208] do_one_initcall+0x40/0x24c [ 242.921030] do_initcalls+0xf0/0x1c4 [ 242.924592] kernel_init_freeable+0x114/0x224 [ 242.928936] kernel_init+0x20/0x1d4 [ 242.932413] ret_from_fork+0x10/0x20 [ 242.935990] INFO: task kworker/u16:1:42 blocked for more than 120 second= s. [ 242.942836] Not tainted 6.19.0-rc5+ #41 [ 242.947179] "echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables = this message. [ 242.955000] task:kworker/u16:1 state:D stack:0 pid:42 tgid:42 = ppid:2 task_flags:0x4208060 flags:0x00000010 [ 242.966127] Workqueue: events_unbound deferred_probe_work_func [ 242.971940] Call trace: [ 242.974364] __switch_to+0xdc/0x120 (T) [ 242.978195] __schedule+0x310/0x7a0 [ 242.981669] schedule+0x30/0xa4 [ 242.984803] schedule_preempt_disabled+0x20/0x38 [ 242.989401] __mutex_lock.constprop.0+0x4c4/0xc90 [ 242.994094] __mutex_lock_slowpath+0x10/0x18 [ 242.998349] mutex_lock+0x68/0x74 [ 243.001650] __driver_attach+0x28/0x254 [ 243.005473] bus_for_each_dev+0x74/0xd4 [ 243.009295] driver_attach+0x20/0x28 [ 243.012857] bus_add_driver+0x118/0x238 [ 243.016681] driver_register+0x58/0x114 [ 243.020502] __platform_driver_register+0x20/0x28 [ 243.025193] imx_clk_scu_init+0xe8/0xf8 [ 243.029016] imx8qxp_clk_probe+0x3c/0x11c0 [ 243.033099] platform_probe+0x58/0x90 [ 243.036748] really_probe+0xbc/0x3d4 [ 243.040310] __driver_probe_device+0x7c/0x174 [ 243.044653] driver_probe_device+0x38/0x108 [ 243.048823] __device_attach_driver+0xb0/0x154 [ 243.053254] bus_for_each_drv+0x80/0xdc [ 243.057076] __device_attach+0x9c/0x1bc [ 243.060899] device_initial_probe+0x48/0x4c [ 243.065069] bus_probe_device+0x34/0x98 [ 243.068898] device_add+0x4bc/0x6b4 [ 243.072367] of_device_add+0x40/0x58 [ 243.075929] of_platform_device_create_pdata+0x94/0x158 [ 243.081141] of_platform_bus_create+0xcc/0x280 [ 243.085571] of_platform_populate+0x78/0x174 [ 243.089828] devm_of_platform_populate+0x54/0xb0 [ 243.094435] imx_scu_probe+0x1f8/0x30c [ 243.098169] platform_probe+0x58/0x90 [ 243.101819] really_probe+0xbc/0x3d4 [ 243.105379] __driver_probe_device+0x7c/0x174 [ 243.109728] driver_probe_device+0x38/0x108 [ 243.113896] __device_attach_driver+0xb0/0x154 [ 243.118326] bus_for_each_drv+0x80/0xdc [ 243.122148] __device_attach+0x9c/0x1bc [ 243.125971] device_initial_probe+0x48/0x4c [ 243.130141] bus_probe_device+0x34/0x98 [ 243.133963] deferred_probe_work_func+0x9c/0xf4 [ 243.138480] process_one_work+0x14c/0x3c0 [ 243.142477] worker_thread+0x2dc/0x3f0 [ 243.146212] kthread+0x124/0x1e4 [ 243.149427] ret_from_fork+0x10/0x20 [ 243.152992] INFO: task kworker/u16:1:42 is blocked on a mutex likely own= ed by task kworker/u16:1:42. The patches regarding QSPI or SMMU in this thread don't seem to apply for /= affect this platform. Best regards, Alexander =2D-=20 TQ-Systems GmbH | M=FChlstra=DFe 2, Gut Delling | 82229 Seefeld, Germany Amtsgericht M=FCnchen, HRB 105018 Gesch=E4ftsf=FChrer: Detlef Schneider, R=FCdiger Stahl, Stefan Schneider http://www.tq-group.com/