Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2854173rwd; Mon, 22 May 2023 05:28:17 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7K6vY7JYDVoDVk98INOPXBo+2WKFU7fEpcMt4J3f2xSvXPl+qqzqG8FLHpCh6TKMr9D/Vk X-Received: by 2002:a17:902:e848:b0:1ac:820e:c34a with SMTP id t8-20020a170902e84800b001ac820ec34amr16217628plg.0.1684758497707; Mon, 22 May 2023 05:28:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684758497; cv=none; d=google.com; s=arc-20160816; b=nXleAyT7l8WVkSnjxUo/fMxFSJTO7ESOFma7Y3ZnaM9H6aOpV/llfZa9VFtp3bZLQ8 7qnk/U2K8E2vssTYPvUqWZVXiaehjKoJ/SNEZ9F6k1qZzYHlNWnoWWAMGjXO2lCHZHME Lam3YH3ovsBgiqbyDikQd3vq+mxvd6BdGq6ENebJm2INaxqQ+9lb+aHpJg30QtY50gZt dDq3VBWoJGosSr9lCYNoIqRnOPlA7PoSsXAC8KGgTVPjdFXLPCi5BSLQV5+326jNjzu0 m5ZPBrnaz0kHuY3ROWmAQbcGFmrVS9gCNbui9ILXJa8VtKNTEa8bPj8ep/uneRzYZsJf 921Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:references :cc:to:from:content-language:subject:user-agent:mime-version:date :message-id:dkim-signature; bh=XmGSkIC15ZBdqEyVUHdk4p0WQzlHdQ5XyKYa3D0QoFA=; b=F6FXeEXsdJY+bMM5p5mu9Uhrg7BXrJ56MFrHwjixZWfH3nbMOz6ziBtRU6ISHslcoX geLYmJ02c3F9lhEUM8x9hkFdfG1OnJ/F3oQEeIHm7Ov40EmhiMLVPTInCzFRGdg40mP3 BdBz16wew9sxXRJNzHd5kuRAWjdU4PYVRBgkAh63vbY3EI7WgxplTcZ18twsf640Skoq iTT2pgmTc4WkI5euUNRI10u8knGuntDalE/VHthcHDFpuwwoO1swDvFW5LZ/qiwW+UN7 gXSPJEI8csOJCwSZjXL0tFLICT1j0z2IFr18mWoU9/04+892Bw3Pn/sD+Gw/Vo0rDQ+n KgIA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20221208.gappssmtp.com header.s=20221208 header.b=P8Pl0wzG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e11-20020a170902b78b00b001a05a78f952si4585650pls.272.2023.05.22.05.28.05; Mon, 22 May 2023 05:28:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20221208.gappssmtp.com header.s=20221208 header.b=P8Pl0wzG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233688AbjEVMEv (ORCPT + 99 others); Mon, 22 May 2023 08:04:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42888 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233526AbjEVMEu (ORCPT ); Mon, 22 May 2023 08:04:50 -0400 Received: from mail-wr1-x42b.google.com (mail-wr1-x42b.google.com [IPv6:2a00:1450:4864:20::42b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 456B09B for ; Mon, 22 May 2023 05:04:48 -0700 (PDT) Received: by mail-wr1-x42b.google.com with SMTP id ffacd0b85a97d-306dbad5182so3884796f8f.1 for ; Mon, 22 May 2023 05:04:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20221208.gappssmtp.com; s=20221208; t=1684757087; x=1687349087; h=content-transfer-encoding:in-reply-to:references:cc:to:from :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=XmGSkIC15ZBdqEyVUHdk4p0WQzlHdQ5XyKYa3D0QoFA=; b=P8Pl0wzG47Mrb4LOoe4y8hQKWb8XRQlBbaXjAcCoNfohmbC1mNS2da3YGTc3r9qjgi 5lbalTBg89BSBDYeFYJWRMh4n7AnDXbvgl+qYkaLINDiwc6Qp33EAjPDKF1pyHLvLCEa Doj2qzzqwDDlFR77+CIeQCTSQSVhm7b1vci1Xgq5/j7ZjLS1sC0+7u3iMEkGCKw7KQtp f+5/YIddIgz6yfe1tR1kvHw1qukDRrYBi7h74/mEkRHHgf/K7775wFsBj/reyUdgQsp7 MgWA/nos/X0+07fLcpACtyfAU+puf7nncoDXm9Qq5jLy1qWPjWbHyOO+Tv6xzg20o3wp Pp8w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684757087; x=1687349087; h=content-transfer-encoding:in-reply-to:references:cc:to:from :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=XmGSkIC15ZBdqEyVUHdk4p0WQzlHdQ5XyKYa3D0QoFA=; b=ahBsy2jSM0iCrr69tn9NhNirp15bKymLkiZUqIprF/ZXGo2wPhJHSx3H4ro7H/7I8t RxYwR5gD27452GakQsYRB+dTFMXJMJcxHhRZQGHwUC9aQS/KkYwn8xwljjOo56iLmwnt 20caE8LUX8ny1PbWg2V7nEwGI7KAi078uBSNYB2t9oBIn3nkM5lAYf4EmCINoZ1KYNDW k64sG+3VB5EWRm3+Eno0qdTWyh3TnvtcvttLFX+hsfquHH6V7zxFvWXOvDTpWYMXxk4d YIZajnlROfLtlcNijmNTBZsmk8GXom2I8NA9aDDgbwj5DMkjdFkZXC2z5QoJOXW+s+r7 BZSQ== X-Gm-Message-State: AC+VfDxyjwn5672D0g1VzhyK69iuZcxt+DcQzU7nu6l4nRrkNrYT7Cnt Q79wyn1e6SVO/uEMwytBUBPRmw== X-Received: by 2002:a5d:6509:0:b0:306:2b5a:d8db with SMTP id x9-20020a5d6509000000b003062b5ad8dbmr7866960wru.23.1684757086606; Mon, 22 May 2023 05:04:46 -0700 (PDT) Received: from [192.168.1.91] (192.201.68.85.rev.sfr.net. [85.68.201.192]) by smtp.gmail.com with ESMTPSA id i7-20020a5d55c7000000b003079ed1f0a0sm7560047wrw.44.2023.05.22.05.04.45 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 22 May 2023 05:04:46 -0700 (PDT) Message-ID: Date: Mon, 22 May 2023 14:04:45 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: RCU WARNING on 6.4-rc2, TI AM62 and TPS65219 Content-Language: en-US From: jerome Neanne To: Francesco Dolcini , nm@ti.com, lee@kernel.org, tony@atomide.com, vigneshr@ti.com Cc: afd@ti.com, khilman@baylibre.com, narmstrong@baylibre.com, msp@baylibre.com, j-keerthy@ti.com, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-omap@vger.kernel.org, Wolfram Sang , linux-i2c@vger.kernel.org References: <1a0a796c-497f-41a5-2f76-493c09e29325@baylibre.com> In-Reply-To: <1a0a796c-497f-41a5-2f76-493c09e29325@baylibre.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 22/05/2023 11:27, jerome Neanne wrote: > > > On 19/05/2023 16:26, Francesco Dolcini wrote: >> Hello all, >> while testing 6.4-rc2 (2d1bcbc6cd70) on a TI K3 AM625 SoC with TPS65219 >> PMIC I noticed this warning. >> >> [   80.117502] systemd-shutdown[1]: All loop devices detached. >> [   80.123176] systemd-shutdown[1]: Stopping MD devices. >> [   80.128700] systemd-shutdown[1]: All MD devices stopped. >> [   80.134123] systemd-shutdown[1]: Detaching DM devices. >> [   80.139553] systemd-shutdown[1]: All DM devices detached. >> [   80.144970] systemd-shutdown[1]: All filesystems, swaps, loop >> devices, MD devices and DM devices detached. >> [   80.162682] systemd-shutdown[1]: Syncing filesystems and block >> devices. >> [   80.169602] systemd-shutdown[1]: Rebooting. >> [   80.173817] kvm: exiting hardware virtualization >> [   80.213016] reboot: Restarting system >> [   80.216767] ------------[ cut here ]------------ >> [   80.221380] Voluntary context switch within RCU read-side critical >> section! >> [   80.221404] WARNING: CPU: 0 PID: 1 at kernel/rcu/tree_plugin.h:318 >> rcu_note_context_switch+0x31c/0x390 >> [   80.237669] Modules linked in: 8021q garp mrp stp llc cfg80211 >> usb_f_ncm u_ether bluetooth ecdh_generic ecc rfkill sp >> idev crct10dif_ce snd_soc_simple_card snd_soc_simple_card_utils >> rtc_ti_k3 sa2ul sha256_generic libsha256 authenc snd_soc >> _davinci_mcasp snd_soc_ti_udma snd_soc_ti_edma snd_soc_ti_sdma >> ti_ads1015 ina2xx industrialio_triggered_buffer pwm_tiehr >> pwm snd_soc_nau8822 tps65219_pwrbutton lm75 kfifo_buf spi_omap2_mcspi >> rtc_ds1307 libcomposite fuse drm ipv6 >> [   80.278507] CPU: 0 PID: 1 Comm: systemd-shutdow Not tainted >> 6.4.0-rc2-00166-gf932e7bb873b #3 >> [   80.286938] Hardware name: Toradex Verdin AM62 on Verdin >> Development Board (DT) >> [   80.294238] pstate: 600000c5 (nZCv daIF -PAN -UAO -TCO -DIT -SSBS >> BTYPE=--) >> [   80.301193] pc : rcu_note_context_switch+0x31c/0x390 >> [   80.306154] lr : rcu_note_context_switch+0x31c/0x390 >> [   80.311114] sp : ffff80000a71b4c0 >> [   80.314422] x29: ffff80000a71b4c0 x28: 0000000000000000 x27: >> ffff000000118000 >> [   80.321556] x26: 0000000000000000 x25: ffff000000118000 x24: >> ffff800008fafbd8 >> [   80.328689] x23: ffff000000118000 x22: 0000000000000000 x21: >> ffff000000118000 >> [   80.335822] x20: 0000000000000000 x19: ffff00003fd68cc0 x18: >> 0000000000000010 >> [   80.342955] x17: 0000000000000000 x16: 0000000000000000 x15: >> ffff000000118000 >> [   80.350087] x14: 00000000000001c5 x13: ffff000000118478 x12: >> 00000000ffffffea >> [   80.357220] x11: 00000000ffffefff x10: 00000000ffffefff x9 : >> ffff80000a2a9a98 >> [   80.364352] x8 : 0000000000017fe8 x7 : c0000000ffffefff x6 : >> 000000000000bff4 >> [   80.371485] x5 : 0000000000057fa8 x4 : 0000000000000000 x3 : >> 0000000000000000 >> [   80.378617] x2 : ffff80000a251990 x1 : 0000000000000000 x0 : >> 0000000000000000 >> [   80.385751] Call trace: >> [   80.388193]  rcu_note_context_switch+0x31c/0x390 >> [   80.392807]  __schedule+0x98/0xa7c >> [   80.396214]  schedule+0x5c/0xc4 >> [   80.399354]  schedule_timeout+0x180/0x25c >> [   80.403362]  wait_for_completion_timeout+0x80/0x15c >> [   80.408238]  ti_sci_set_device_state+0xb4/0x1e4 >> [   80.412771]  ti_sci_cmd_get_device_exclusive+0x18/0x24 >> [   80.417907]  ti_sci_pd_power_on+0x28/0x48 >> [   80.421914]  _genpd_power_on+0x94/0x154 >> [   80.425749]  genpd_power_on.part.0+0xa4/0x174 >> [   80.430104]  genpd_runtime_resume+0x118/0x294 >> [   80.434457]  __rpm_callback+0x48/0x140 >> [   80.438206]  rpm_callback+0x6c/0x78 >> [   80.441692]  rpm_resume+0x3bc/0x59c >> [   80.445179]  __pm_runtime_resume+0x4c/0x90 >> [   80.449272]  omap_i2c_xfer_common+0x38/0x598 >> [   80.453540]  omap_i2c_xfer_polling+0x14/0x20 >> [   80.457804]  __i2c_transfer+0x138/0x35c >> [   80.461642]  i2c_transfer+0x94/0xf4 >> [   80.465130]  regmap_i2c_read+0x60/0xa8 >> [   80.468879]  _regmap_raw_read+0xf0/0x170 >> [   80.472799]  _regmap_bus_read+0x44/0x7c >> [   80.476632]  _regmap_read+0x64/0xf4 >> [   80.480118]  _regmap_update_bits+0xf4/0x130 >> [   80.484298]  regmap_update_bits_base+0x64/0x98 >> [   80.488738]  tps65219_restart+0x38/0x48 >> [   80.492576]  atomic_notifier_call_chain+0x60/0x90 >> [   80.497280]  do_kernel_restart+0x24/0x30 >> [   80.501202]  machine_restart+0x38/0x5c >> [   80.504950]  kernel_restart+0x88/0x98 >> [   80.508612]  __do_sys_reboot+0x1e0/0x264 >> [   80.512533]  __arm64_sys_reboot+0x24/0x30 >> [   80.516538]  invoke_syscall+0x44/0x104 >> [   80.520287]  el0_svc_common.constprop.0+0x44/0xec >> [   80.524988]  do_el0_svc+0x38/0x98 >> [   80.528302]  el0_svc+0x2c/0x84 >> [   80.531354]  el0t_64_sync_handler+0xb8/0xbc >> [   80.535534]  el0t_64_sync+0x190/0x194 >> [   80.539192] ---[ end trace 0000000000000000 ]--- >> >> >> This looks similar to what is described here [1], same issue or >> something else? Any suggestion? >> >> The issue is systematic and happens at every boot. With a TI downstream >> 5.10 kernel this issue was never experienced. >> >> Francesco >> >> [1] >> https://lore.kernel.org/all/20230327-tegra-pmic-reboot-v6-0-af44a4cd82e9@skidata.com/ >> > I don't have the same board to test and don't experience this boot issue > with the am62 board I'm using (the board version I have is a custom > board not released publicly by TI unfortunately). > > Notice that: > https://lore.kernel.org/lkml/20230511122100.2225417-1-jneanne@baylibre.com/ > > Is not yet applied and would help handle shutdown/reboot under some > conditions. > > This might help for reboot handling if you are forcing a shutdown/reboot > in your test. > > But if the problem is your device tries to shutdown at each boot, then > this is just a side effect, not the original root cause. > > Regards, > Jerome More background in thread: Link: https://lore.kernel.org/all/7hfseqa7l0.fsf@baylibre.com/ This explains why downstream is different on that point.