Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp664436pxb; Wed, 25 Aug 2021 12:03:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwMvuNAECYjo+z0dTIYos0YZce3VpnLdxWNjrMJWoyieI7Hi+3xoyPccmmqiSbON9wjGd8m X-Received: by 2002:a5d:928c:: with SMTP id s12mr36546857iom.151.1629918182473; Wed, 25 Aug 2021 12:03:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629918182; cv=none; d=google.com; s=arc-20160816; b=yqkHCLP/BBnM6sexbjxr+LNychUdssGAQgORoSwlBSHeLO5EaIqsUhufLTBiGcDDyI YbNVJ6rAFOet9evbQGG9yua2u0b3ZMGEe8KV86Zk5I+biPT5cjf58/uvePbF0MoZZvZu RvwWJdabmgi55Pf2BjQxRWk79vfdTdDp3VsZ9nSPAdnenA3026jPU6RP9J0C/ZWCPlpu RvJp2m2nLdys6wc0R7mCg2iZrv/PElEXx/CF5dknI3IfmTakeWEdH92AG1qAZETrSVow r87sd2dOaH/ks+TDZZi7/u2byog+10GI/fHpjfEnH5E17WWRQXeXiahyZqyWfzhwPlTD IWIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=QKeGGaoJQyURD1cjD9qSHuKZwVcvwBv4yk33zRD9Qd0=; b=YnNonNwao6Bo6gU2jmOwn4a/P2x0XiSdLBX758A7R4Cx8ut/NMkCJHfQ+nNCypLFLe r7OUrv+CnRXImmQkwtDmnpIBQda1ed1ECsXtz4PIqYCXYX53dw3dJQUqoLjQ0A2+VSoH lP0zJZTfMEjPH7oyv83Z44QZNhQer63qrYZXNxdyFe2Y/I4oqV13g1H/jQWEOlMIRxwV VfjmSckrCdJf1B/yghzTvW9wlPp6HV5nglkQU65zguvvU9HjaIG5UnIBylC+qFs0FrRA U16H5fuOnuvjDZIZwUOwT/NwuqA3FCirLRAsjPlhTzEl8ZbQT8fsF3eX+QpQmZViTk1I yUYA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=dRKlqUVV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t11si347375jal.119.2021.08.25.12.02.39; Wed, 25 Aug 2021 12:03:02 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=dRKlqUVV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237144AbhHYPzl (ORCPT + 99 others); Wed, 25 Aug 2021 11:55:41 -0400 Received: from mail.kernel.org ([198.145.29.99]:43668 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241481AbhHYPzk (ORCPT ); Wed, 25 Aug 2021 11:55:40 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 7B62B6112D; Wed, 25 Aug 2021 15:54:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1629906895; bh=ZsNvCZY/k5MAyPCNnGO8Lp/k5DGvW29FcyQiTLu08Zk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=dRKlqUVVsV2ljxT2c4ZRjOq5nG72QYd67Y0lZhysG+32/ssEDvZqOJ0hHzMy36dqv xkdoKwIV5sUXH/+rkdkvqHxyywQFUS24IaKVdaq4ot3/t7xvN8BgYerugsrOBKgh9h Z0gxKQp67YXCIEu0IPi/ZUbvXa6qF39ZJp8lCJwSiASnu2LSgXojOOlkdfqDFIXodT nL0+7pJ27kPcjdT7EhsjbJGTVVidtrpBy13RBGgopjfpn5jva/YrTXag9/s5wvZlAM hc9SqHt8Onkg14QOOcKsOis6rEkqwSIdEnephuson1e1iDHeVBEYNoyaD4GwLcLN1x Ti/uFJ9Vxz2lQ== Date: Wed, 25 Aug 2021 16:54:27 +0100 From: Mark Brown To: Vladimir Oltean Cc: Rasmus Villemoes , Lee Jones , Arnd Bergmann , Thomas Gleixner , Marc Zyngier , linux-kernel@vger.kernel.org Subject: Re: "BUG: Invalid wait context" in ls_extirq_set_type Message-ID: <20210825155427.GK5186@sirena.org.uk> References: <20210825135438.ubcuxm5vctt6ne2q@skbuf> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="8tUgZ4IE8L4vmMyh" Content-Disposition: inline In-Reply-To: <20210825135438.ubcuxm5vctt6ne2q@skbuf> X-Cookie: MY income is ALL disposable! User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --8tUgZ4IE8L4vmMyh Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Aug 25, 2021 at 04:54:38PM +0300, Vladimir Oltean wrote: > - Use a hwspinlock. Never used one, don't know what it's about?! hwspinlocks are for locking around things that are shared with other processors not running Linux where the other processors might also take the lock, they're very specialist. > Either way, there seems to be no option to use a raw spinlock. "Disable > locking" sounds like the best bet, but regmap offers regmap_bulk_read() > and regmap_bulk_write() and those would be broken without locking taken > at the syscon driver level, I think? If you disable locks at the regmap level something needs to ensure that there's no concurrency issues which for a MFD if any of the registers are shared sounds off. > I did google for fixes for this kind of issues that were sent in the > past, but in my limited search I did not find any other driver which > uses regmap while under a raw spinlock. No problem with adding raw spinlocks to regmap, I think it's just nobody needed them before. I've not looked at the problem in sufficient detail to figure out if that's actually the best solution here but from an initial pass through it looks reasonableit looks reasonable --8tUgZ4IE8L4vmMyh Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmEmZ7MACgkQJNaLcl1U h9BZkgf+JxwiGsMZkWzpAui2Utv/n7vPJEtP85nTm6yiunbxRB4kq7r9mDckijVX XDWWB4BktE25SX1cIy8XPLi3YDfKwjirsDQ71yeIo5OM6sJ2c8Nd/z8twe0spD9L UvWtOTKcOsX9xE3LDnXu4/LbpwBSm1Z4xE90EiffeBPplHrs7DbB5yqm48T2lrSp 0VD7CkZofQSvj8fuSjeCyMp27md5Exr2S3mkrgCiIGNlXzhcoaGK4X5Tt4np8wQ0 QNQaq5OOcoHos4cwuw+PE5tlm9fSSph8yTQ+Ic/qpPWfDIX51vK+0WfPTNpNwGJn 6MeRnoqpa3kUl+1CyIeL7bpR51p0jw== =ZrHG -----END PGP SIGNATURE----- --8tUgZ4IE8L4vmMyh--