Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp4602971rdh; Wed, 29 Nov 2023 06:09:25 -0800 (PST) X-Google-Smtp-Source: AGHT+IHNTDFOSeZraV9J9asA+E1UYuOYiobeyoK0dqvBOr6bSTrLBhijtVdFKCImffuLZRNxgHqC X-Received: by 2002:a17:902:ce91:b0:1d0:2bb:de18 with SMTP id f17-20020a170902ce9100b001d002bbde18mr5011855plg.44.1701266964671; Wed, 29 Nov 2023 06:09:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701266964; cv=none; d=google.com; s=arc-20160816; b=LwT9hDRI+FTie3mWmjq4nS4AnxcKVIKV79NdIQ3INaYJZBavQOH6Cq9AQkNwy4pkXx j8QxWUyZAlmJCQuD1fH/3KgynfbtlEKB4U2JrRmgcI3jUjFlJd5PKTMAGF6MCLxAfSrW pHCbFpauOlNSrzvWxH3R+pHYj28OgmNFaEPoH1kNvBg8cz0eXO2Uvgp4nG/xP3KVSur1 MDmTmoKpz8yhrNCJtxlBklCyPCydxB0PGSEKwMTARsh5xjBmIqueForKMivoHFFUKMgC BhbsLFrPJGMxmSXYV0/c1Isl5RSCEu7CkNz9KOm8L2B3ZWRZz28va9BHKErot9J6ExD3 4iiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:organization:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=TDhz7Xo8PaqOYXbK3ChXTZP23sRqvzYN8x+rk01Go08=; fh=QWm058wx6WUBS9IO2eZRUdFl7VjNABqXV0pGnR7dtDI=; b=mWug8jNwaT7Khs7yHomgmP7857oeodg13qYvEEnu4Aagg55U01hd0g+YnRxFNUaj6f 4LWWuK77Sc3wsFsjqkIUc+DhK3VZ5qMsam9ofykxk6ek2eioKd0TchSsQ6xGbKl+8+E2 6hohZc4tvzEm00XLHQP0hl6R6tz2PMmv0Yy3osKqhncHsR+c8xI8ftWzfJtk5vicRVZM pVAnj3DlYHhueeKXFMjUITAYpF4RqCdpAJmG5+2uW3u2ko2HEPCqOz+PkA0XUv6B6ahw 5aDaS06/peYRbooJq+RxEacT6YX8Axfm2jfBPrO99qmaqkGs6I0ZJ9wli20mFWCHofNc 5mlw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=nV1VAOSj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id ju12-20020a170903428c00b001cf67e08915si13826644plb.562.2023.11.29.06.09.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 Nov 2023 06:09:24 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=nV1VAOSj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 7EF4D80A9AA5; Wed, 29 Nov 2023 06:09:21 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234131AbjK2OJC (ORCPT + 99 others); Wed, 29 Nov 2023 09:09:02 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41164 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230480AbjK2OJB (ORCPT ); Wed, 29 Nov 2023 09:09:01 -0500 Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.13]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E844AF; Wed, 29 Nov 2023 06:09:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1701266948; x=1732802948; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=+fOWzb6OXn2tsYSYA4iym/lgxytyGV3SehVFw4FWBT4=; b=nV1VAOSjGtLFBtCDf1/uECk48bBqSyNHf9fH4z7sdytjXDZrJLfd7ydC 1FS41I6kw1RZA9A4eEmTcKsYetF4buvBlpoUkp3BMdQVO1LIApfQDrtMh KHULyOD4ygW1kOL/6KYBypb6WEXmiU7LKWmL7wusCT+2t5AmlqpZ6gSfU lgvgVj5j7y4svss7UTFN1qGaD8HM1Dh+AhzIs/ZrzOSmC7fUDXCYzEVMa hL7ZAwppkWDq0++x6IqR6WSidpUBgwSvY9BOVyzapole/mGwhRnVcMFp7 u9tOaG3FGMRsZcWBNwAm8qQ2ap8fQ5moSZet4gOEXzo1y4Nz7vhO/HQAl w==; X-IronPort-AV: E=McAfee;i="6600,9927,10909"; a="152877" X-IronPort-AV: E=Sophos;i="6.04,235,1695711600"; d="scan'208";a="152877" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orvoesa105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Nov 2023 06:09:08 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10909"; a="912865925" X-IronPort-AV: E=Sophos;i="6.04,235,1695711600"; d="scan'208";a="912865925" Received: from smile.fi.intel.com ([10.237.72.54]) by fmsmga001.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Nov 2023 06:09:05 -0800 Received: from andy by smile.fi.intel.com with local (Exim 4.97) (envelope-from ) id 1r8LFO-00000000SOq-0Aua; Wed, 29 Nov 2023 16:09:02 +0200 Date: Wed, 29 Nov 2023 16:09:01 +0200 From: Andy Shevchenko To: "Rafael J. Wysocki" Cc: Linux ACPI , LKML , Zhang Rui , Srinivas Pandruvada , Michal Wilczynski , Hans de Goede , Mika Westerberg , Heikki Krogerus , Mario Limonciello Subject: Re: [PATCH v1 3/4] ACPI: OSL: Allow Notify () handlers to run on all CPUs Message-ID: References: <3281896.aeNJFYEL58@kreacher> <7617703.EvYhyI6sBW@kreacher> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <7617703.EvYhyI6sBW@kreacher> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Wed, 29 Nov 2023 06:09:21 -0800 (PST) On Wed, Nov 29, 2023 at 02:50:54PM +0100, Rafael J. Wysocki wrote: > From: Rafael J. Wysocki > > Notify () handlers, like GPE handlers, are only allowed to run on CPU0 > now out of the concern that they might trigger an SMM trap and that (in > some cases) the SMM code running as a result of that might corrupt > memory if not run on CPU0. Pardon my French, but I'm a bit lost in the semantics of all those "that". Maybe the above can be simplified? > However, Notify () handlers are registered by kernel code and they > are not likely to evaluate AML that would trigger an SMM trap. In > fact, many of them don't even evaluate any AML at all and even if > they do, that AML may as well be evaluated in other code paths. In > other words, they are not special from the AML evaluation perspective, > so there is no real reason to treat them in any special way. > > Accordingly, allow Notify () handlers, unlike GPE handlers, to be > executed by all CPUs in the system. > > Also adjust the allocation of the "notify" workqueue to allow multiple > handlers to be executed at the same time, because they need not be > serialized. Code wise LGTM, Reviewed-by: Andy Shevchenko -- With Best Regards, Andy Shevchenko