Received: by 2002:a05:7412:a9a3:b0:f9:327e:43ab with SMTP id o35csp83838rdh; Mon, 18 Dec 2023 05:11:24 -0800 (PST) X-Google-Smtp-Source: AGHT+IF5phcjQ02+yVm/S3thCbWTS2feMl8U5EzYcyCqSMmpgo+RzvBVM8e/OjBO0SEBD5UnRrcj X-Received: by 2002:a05:6871:4c9:b0:1fb:75a:de71 with SMTP id n9-20020a05687104c900b001fb075ade71mr20082028oai.95.1702905083789; Mon, 18 Dec 2023 05:11:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702905083; cv=none; d=google.com; s=arc-20160816; b=jJY/ri2xchqEvCD5b3tx/I1htw1uyEQ38sWZO4U4NDj2VJqh+2mlmCkRXPikyT+DgO K8M3Vf8YMAr8jqm85UfL7FpQKpPPEYTOtzScwi4sRyUNjw41BUXWx2acnVBUi2wX4TsI tVyUxkSPc4XeO9Wpnq/NaZyrjfZa68ZNhrwBPGLfXQHqoQFx0QA9Grx50QU1Ka8v/uSb Xj+/mashSJksnbjyjGu40rSUx4A/JFn40NNJzSQkYzwUpzYAHizFIJCEFgAjTEmy0GMa bNrp8VjpF2TbEqQ8FFtUoULgT9hFmNh/s7BaUL69q9Pny3jFbENznZW+ogwNIjMPb1yc emKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :message-id:subject:cc:to:from:date:dkim-signature; bh=1tKUg55GyHTf08JBzgZtZPRuKz4R//UeiI1dQsdNZgo=; fh=P5zBB1N/HVmDFriWCJ6Qffp6bP+zgT4BB6XzwIQk2no=; b=sNU+bTXixZ+ihv8XDRWDHG04J5LBwPK1yU0WvPBz9CJwLMwWzeXtxogJBnywlTCS30 6SJyr3JkC9fjAGEF8bh4ELFMs2cDyKYaJAMoVHGQEn1lJgLmZGSW0RvsjMKO6upbX9Tt M/wpMGG9joMi7pVdBsMwVUdZyY5CyTbARuyqKbH2WMwA1RumuX/vEqAwyRi7iDSMqYb/ DTNx+ikaUqykWARpH6Eed22Loixe9gxokUbQ8YmmrWKIvmVEpd3QXT2oha2Bh5aCOZ0o SMqdyTANMQ3KKy0ku51voq6h+QqZ010ui/AmgKucZb2hOW/fI4wOkS6ES15wvLw+xnO0 yltg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=Qko+tfQD; spf=pass (google.com: domain of linux-kernel+bounces-3692-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-3692-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id j1-20020ac806c1000000b00423a2b349b6si21985424qth.346.2023.12.18.05.11.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 18 Dec 2023 05:11:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-3692-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; dkim=fail (test mode) header.i=@armlinux.org.uk header.s=pandora-2019 header.b=Qko+tfQD; spf=pass (google.com: domain of linux-kernel+bounces-3692-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-3692-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=armlinux.org.uk 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 7EB4F1C24028 for ; Mon, 18 Dec 2023 13:11:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 51A351DDCA; Mon, 18 Dec 2023 12:58:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b="Qko+tfQD" X-Original-To: linux-kernel@vger.kernel.org Received: from pandora.armlinux.org.uk (pandora.armlinux.org.uk [78.32.30.218]) (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 803F773470; Mon, 18 Dec 2023 12:58:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=armlinux.org.uk Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=armlinux.org.uk DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=1tKUg55GyHTf08JBzgZtZPRuKz4R//UeiI1dQsdNZgo=; b=Qko+tfQDFH5tQIm1p5IewFoZqc HQbLvnPtulg59EsBQmSHF3TGK/cg1U10PaVJbAPFhiDYDjQYcY0Tb45fv10B/s8amTj40tVQcUCGl orYICCQmfSSDBW1S8Va4xT8hdnzc3DVjCEYJhFpJZ9DM9SR8DgrYn9glT9DanCBbppoRBmAq9mlK6 rbEHePJnWqF3fL6nDzAJyixhWe6uU25tQTzDkVtKpDVb93iIiK1+Zr+A+j9xCCo2GohTYU791FOf2 YP4h4FqD1dG+3JNgOqZdD1sDv0QdhwyJiZno0EgDX7/vUu1hpnfUN74CEdu2Lk68k/uj0Soxl3/DQ aeSrb43Q==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:50904) by pandora.armlinux.org.uk with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1rFDCB-0005MM-0g; Mon, 18 Dec 2023 12:58:07 +0000 Received: from linux by shell.armlinux.org.uk with local (Exim 4.94.2) (envelope-from ) id 1rFDCB-0006ii-Ft; Mon, 18 Dec 2023 12:58:07 +0000 Date: Mon, 18 Dec 2023 12:58:07 +0000 From: "Russell King (Oracle)" To: Jonathan Cameron Cc: linux-pm@vger.kernel.org, loongarch@lists.linux.dev, linux-acpi@vger.kernel.org, linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-riscv@lists.infradead.org, kvmarm@lists.linux.dev, x86@kernel.org, acpica-devel@lists.linuxfoundation.org, linux-csky@vger.kernel.org, linux-doc@vger.kernel.org, linux-ia64@vger.kernel.org, linux-parisc@vger.kernel.org, Salil Mehta , Jean-Philippe Brucker , jianyong.wu@arm.com, justin.he@arm.com, James Morse Subject: Re: [PATCH RFC v3 18/21] ACPI: processor: Only call arch_unregister_cpu() if HOTPLUG_CPU is selected Message-ID: References: <20231215165009.000035f2@Huawei.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231215165009.000035f2@Huawei.com> Sender: Russell King (Oracle) On Fri, Dec 15, 2023 at 04:50:09PM +0000, Jonathan Cameron wrote: > On Wed, 13 Dec 2023 12:50:43 +0000 > Russell King (Oracle) wrote: > > > From: James Morse > > > > The kbuild robot points out that configurations without HOTPLUG_CPU > > selected can try to build acpi_processor_post_eject() without success > > as arch_unregister_cpu() is not defined. > > > > Check this explicitly. This will be merged into: > > | ACPI: Add post_eject to struct acpi_scan_handler for cpu hotplug > > for any subsequent posting. > > > > Reported-by: kbuild test robot > > Signed-off-by: James Morse > > Tested-by: Miguel Luis > > Tested-by: Vishnu Pajjuri > > Tested-by: Jianyong Wu > > --- > > This should probably be squashed into an earlier patch. > > Agreed. If not > Reviewed-by: Jonathan Cameron I'm not convinced that "ACPI: Add post_eject to struct acpi_scan_handler for cpu hotplug" is the correct commit to squash this into. As far as acpi_processor.c is concerned, This commit merely renames acpi_processor_remove() to be acpi_processor_post_eject(). The function references arch_unregister_cpu() before and after this change, and its build is dependent on CONFIG_ACPI_HOTPLUG_PRESENT_CPU being defined. Commit "ACPI: convert acpi_processor_post_eject() to use IS_ENABLED()" removed the ifdef CONFIG_ACPI_HOTPLUG_PRESENT_CPU surrounding acpi_processor_post_eject, and that symbol depends on CONFIG_HOTPLUG_CPU, so I think this commit is also fine. Commit "ACPI: Check _STA present bit before making CPUs not present" rewrites the function - the original body gets called acpi_processor_make_not_present() and a new acpi_processor_post_eject() is created. At this point, it doesn't reference arch_unregister_cpu(). Commit "ACPI: add support to register CPUs based on the _STA enabled bit" adds a reference to arch_unregister_cpu() in this new acpi_processor_post_eject() - so I think this is the correct commit this change should be merged into. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!