Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp6605287rdb; Fri, 15 Dec 2023 03:34:55 -0800 (PST) X-Google-Smtp-Source: AGHT+IHKgQQPvZnHKA+pLzQSWM9+JPurMkU6fHCP0Q939pG0lkgUwaDfeQ8I1Fgjf4sqHGJeCLSY X-Received: by 2002:a05:620a:1647:b0:77e:fbba:6468 with SMTP id c7-20020a05620a164700b0077efbba6468mr15626057qko.71.1702640095576; Fri, 15 Dec 2023 03:34:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702640095; cv=none; d=google.com; s=arc-20160816; b=nUzJ2WJGaIpnOuWXizpvW6e3TwP2A4yTfePWHxZqLki2L0aOrudNxhigZYvJoFLA6U 6TdZvn9Vr9pEy6VmEj/DnBHKbYhUdtyLMuRJA/RXP23gfKjwPx72JgbY7B/qOV3Qqrye gUrzsyyMK1cGjMkmKpVUS+X8vTjDQFefpW6L4CQOirJM6Op5TD2CC5kZ9IJQ204uVPHM G0jRfm+4L7WfAfZeBBmboJtB0LnU7slifOERysADqXbOHMuQr2/dULTscpZfPOajaVdy uq6UOFY++5zswfBP/1xmUvfuVhz7Tuof5WzAD559OH4/VQy8bPqWI+QqYm7+GpjF4eZe JyWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from; bh=DJiu/0vCOphpWYZscQ/lBnjGIveChWZE6LAz0VZqg3Q=; fh=onaXV/9tgv2VQNqWsV5miYD1muoRQWddouYPtnrp6Do=; b=a2SNZYsSHbEHb8yV/vqFm92+ePioErfUcOfCnb4RAL2CYl1L88zXwJfQAZCuz8Gl63 DKI2iVya4UFZ+ycU2GtLvCBBxyLjo83CNF/c88FuiXBmS0SCF0O//3olB++15Gv6zzy3 Kf+hLHgqVe1TIMLX4jwi/GeAR2YBiFfHYtPoK+nGL1R4xZbCl+ply7VA3jvj76vreC6i X9JhHgPUkst8Tyb5e5SYkHhGq140UDk6I47bZmCAK6fRC38PGCZTGUm0xQBO2WGcoL6H iSqoNm9BBuNnC9UCn3A9TIQUzU2SlXQ/xXjVU37c527exkhx91gIQSwI9GQ+ls0kQNfY CN1g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-850-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-850-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id g6-20020a05620a40c600b0077dc67bca0csi19453197qko.343.2023.12.15.03.34.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 03:34:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-850-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel+bounces-850-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-850-linux.lists.archive=gmail.com@vger.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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 5767A1C230A6 for ; Fri, 15 Dec 2023 11:34:55 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 646212556E; Fri, 15 Dec 2023 11:34:34 +0000 (UTC) X-Original-To: linux-kernel@vger.kernel.org Received: from cloudserver094114.home.pl (cloudserver094114.home.pl [79.96.170.134]) (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 DCDD2250E8; Fri, 15 Dec 2023 11:34:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=rjwysocki.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=rjwysocki.net Received: from localhost (127.0.0.1) (HELO v370.home.net.pl) by /usr/run/smtp (/usr/run/postfix/private/idea_relay_lmtp) via UNIX with SMTP (IdeaSmtpServer 5.4.0) id 2951e9a5c537d893; Fri, 15 Dec 2023 12:27:50 +0100 Received: from kreacher.localnet (unknown [195.136.19.94]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by cloudserver094114.home.pl (Postfix) with ESMTPSA id 36107668B1E; Fri, 15 Dec 2023 12:27:50 +0100 (CET) From: "Rafael J. Wysocki" To: Linux ACPI Cc: LKML , Zhang Rui , Srinivas Pandruvada , Michal Wilczynski , Hans de Goede , Andy Shevchenko , Mika Westerberg , Heikki Krogerus , Mario Limonciello , Daniel Drake Subject: [PATCH v1 0/3] ACPI: OSL/EC: Use spin locks without disabling interrupts Date: Fri, 15 Dec 2023 12:23:54 +0100 Message-ID: <2330034.ElGaqSPkdT@kreacher> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="UTF-8" X-CLIENT-IP: 195.136.19.94 X-CLIENT-HOSTNAME: 195.136.19.94 X-VADE-SPAMSTATE: clean X-VADE-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedvkedrvddtvddgvdekucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecujffqoffgrffnpdggtffipffknecuuegrihhlohhuthemucduhedtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhvfevufffkfgggfgtsehtufertddttdejnecuhfhrohhmpedftfgrfhgrvghlucflrdcuhgihshhotghkihdfuceorhhjfiesrhhjfiihshhotghkihdrnhgvtheqnecuggftrfgrthhtvghrnhepgeffhfdujeelhfdtgeffkeetudfhtefhhfeiteethfekvefgvdfgfeeikeeigfehnecuffhomhgrihhnpehkvghrnhgvlhdrohhrghenucfkphepudelhedrudefiedrudelrdelgeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepihhnvghtpeduleehrddufeeirdduledrleegpdhhvghlohepkhhrvggrtghhvghrrdhlohgtrghlnhgvthdpmhgrihhlfhhrohhmpedftfgrfhgrvghlucflrdcuhgihshhotghkihdfuceorhhjfiesrhhjfiihshhotghkihdrnhgvtheqpdhnsggprhgtphhtthhopeduuddprhgtphhtthhopehlihhnuhigqdgrtghpihesvhhgvghrrdhkvghrnhgvlhdrohhrghdprhgtphhtthhopehlihhnuhigqdhkvghrnhgvlhesvhhgvghrrdhkvghrnhgvlhdrohhrghdprhgtphhtthhopehruhhirdiihhgrnhhgsehinhhtvghlrdgtohhmpdhrtghpthhtohepshhrihhnihhvrghsrdhprghnughruhhv rggurgeslhhinhhugidrihhnthgvlhdrtghomhdprhgtphhtthhopehmihgthhgrlhdrfihilhgtiiihnhhskhhisehinhhtvghlrdgtohhmpdhrtghpthhtohephhguvghgohgvuggvsehrvgguhhgrthdrtghomh X-DCC--Metrics: v370.home.net.pl 1024; Body=11 Fuz1=11 Fuz2=11 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 without disabling interrupts, because they cannot be acquired from a hardirq handler 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 updates 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 threaded interrupt handler in the dedicated IRQ case, so it makes the EC driver use 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 driver is updated to operate its spin lock without disabling interrupts. Thanks!