Received: by 2002:a05:7412:b995:b0:f9:9502:5bb8 with SMTP id it21csp3940769rdb; Thu, 28 Dec 2023 05:19:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IGKRl9z08VlK5M2shGoQWsyF5U+ZQvsjjrom2xkStdyOyiw0zIZKFVz70wEqKQyDOsQdvKL X-Received: by 2002:a2e:8883:0:b0:2cc:68d4:f6cd with SMTP id k3-20020a2e8883000000b002cc68d4f6cdmr4605172lji.51.1703769555733; Thu, 28 Dec 2023 05:19:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703769555; cv=none; d=google.com; s=arc-20160816; b=ullRNx/tULhRZOwMx8vh2qnICKIxznl3Yx3Cd5YmBwSfSx2V9BF2DfU7/v2Xciizna teJXgKdgmvFNlPI+1C663QHAf6RcCA3qWbp5Izeg4Dawu+p7cMParUabzXh1mNNqvqmH x2+rwDQt7iVgkwqgOSGSNfBM5Fiq9UChN7zGh/lb7Mt9312omGdN6Qdy24ZBbXxKEQud jtb26TzaPxmbOiIhz3WjrfnzwtoVFuVbrF4X+y0nd5P2e9Oj1Ok9ZUcejSCe9ar2aK26 XJO0bXJwI6PQP2cofEY06hB3ZEqJdcqlRbWK/9T37+OB3ogiYMlrIMx2Ms3/puoVJmQM Xdmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence; bh=wQv2RIGJtc8YAdnoO1f20QZUdNA/cAou6jd52Lqn6S0=; fh=xfU/qAG01RYSUbJdDi46B9Vg2qf2mg9xYb5TJwpwaY0=; b=K/9sEJw/v+IyBQ7bSq3NaImxblk+MH9qdCDZZZbjJryt7W43wbzAEuMiOokIypY3Sz 7oCFkUq85XwQuDE30st8/2a3ujylyP69QosKNSQTDk/QOxWU69Y+iAdI/+7eI1j7HP4h TyGBD248Pchsx8fBV8Z9xOdX2G5L1j9YCaK70RHRLQVmyRoBvcyvrKSYtA95ILz4JCqe 1xp1a4r1SjIT2lueCo479imihRdTX9wn7JEnKoQKt6gjr0VYtqXxHugZ6QsUhUjoAXlN ZvHtMo/CSzr3ho6cX4KU4NJ6vn9PL8Rlh4NfLHZLVjbMGWvGn4PUhq8gRUc/MamEMzkr LorA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-12676-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-12676-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id q23-20020a50aa97000000b00553b6187400si7238946edc.378.2023.12.28.05.19.15 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Dec 2023 05:19:15 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-12676-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-12676-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-12676-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 730441F242FF for ; Thu, 28 Dec 2023 13:19:15 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D83B38479; Thu, 28 Dec 2023 13:19:06 +0000 (UTC) X-Original-To: linux-kernel@vger.kernel.org Received: from mail-ot1-f44.google.com (mail-ot1-f44.google.com [209.85.210.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 21BA18464; Thu, 28 Dec 2023 13:19:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-ot1-f44.google.com with SMTP id 46e09a7af769-6dbd87b706aso1104928a34.0; Thu, 28 Dec 2023 05:19:04 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703769544; x=1704374344; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=wQv2RIGJtc8YAdnoO1f20QZUdNA/cAou6jd52Lqn6S0=; b=NxIKpD+FY8twuQdK/JkArGJ2BVcSo54HH3F+gYRlor6IOlHG1DxSkaAvaHwwTb00eS vmxBfIv989bd6dmVbT4KQkrjwdKhg5TvRXVKd/XOw0xTqYmqFN1mB5jWtxbbdMaEGt/k MbEHKLd5Yn5OqdWZEIZvow0z/iCPRuHOM2pj0QeG4Q3Xscy7noM9l68v4V0dv+52OfmV BMYMl2A8vL6xkHVcVq/X+VDJ3cS1FSZJoVEwopxjhpXg94TKPAoLhzhpkvgsExGHUnG8 8CFef2OlxvJwM3JFFVVZo+XuFwzwKvLaNgA0lPwvdc+qj5HLG+aAVguRtcCXVpK8HXto YfDA== X-Gm-Message-State: AOJu0Yzt7hJcLC0miAqZSXPFyttdktoVo09XgVF14PI4Dk/EBh/qVzCb zXrDfFChFGtnUTiyEGopjaoFzx+NJQ5mdrkNQNo= X-Received: by 2002:a05:6820:2e01:b0:594:35b4:8a with SMTP id ec1-20020a0568202e0100b0059435b4008amr13751279oob.0.1703769544039; Thu, 28 Dec 2023 05:19:04 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <2330034.ElGaqSPkdT@kreacher> In-Reply-To: <2330034.ElGaqSPkdT@kreacher> From: "Rafael J. Wysocki" Date: Thu, 28 Dec 2023 14:18:52 +0100 Message-ID: Subject: Re: [PATCH v1 0/3] ACPI: OSL/EC: Use spin locks without disabling interrupts To: "Rafael J. Wysocki" Cc: Linux ACPI , LKML , Zhang Rui , Srinivas Pandruvada , Michal Wilczynski , Hans de Goede , Andy Shevchenko , Mika Westerberg , Heikki Krogerus , Mario Limonciello , Daniel Drake Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, Dec 15, 2023 at 12:34=E2=80=AFPM Rafael J. Wysocki wrote: > > Hi Everyone, > > After > > https://patchwork.kernel.org/project/linux-acpi/patch/5745568.DvuYhMxLoT@= kreacher/ > > the SCI interrupt handler is threaded, so ACPICA spin locks can be used w= ithout > disabling interrupts, because they cannot be acquired from a hardirq hand= ler > running on the same CPU as any code already holding the spin lock. This = patch > [1/3] removes disabling interrupts from acpi_os_acquire_lock() and update= s > acpi_os_release_lock() accordingly. > > Patch [2/2] uses the observation that if acpi_handle_interrupt() can run > in a threaded interrupt handler in the GPE case, it can also run in a thr= eaded > interrupt handler in the dedicated IRQ case, so it makes the EC driver us= e a > threaded handler for the dedicated EC interrupt. > > Patch [3/3], in analogy with patch [1/3], uses the observation that after= patch > [2/2] all of the EC code runs in thread context, so it need not disable > interrupts on the local CPU before acquiring a spin lock, so the EC drive= r is > updated to operate its spin lock without disabling interrupts. I don't see any objections to these patches, so queuing them up for 6.8. Thanks!