From patchwork Thu Sep 14 11:17:21 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 139676 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:612c:172:b0:3f2:4152:657d with SMTP id h50csp462358vqi; Thu, 14 Sep 2023 09:15:34 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEhoGNFPJdRm91/Om5BD76+wpU1LHA9DWx4q1wXvf4pMMnuAyUYL7Q2tOrBMHT34N6ps2sc X-Received: by 2002:a05:6a20:548f:b0:159:dccb:8bb4 with SMTP id i15-20020a056a20548f00b00159dccb8bb4mr2623131pzk.23.1694708134341; Thu, 14 Sep 2023 09:15:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694708134; cv=none; d=google.com; s=arc-20160816; b=HnLO6mBGza0+J0PopdvojhTFPfswd9buneYgJR0EqRW6EGzK4IKyw9W0DRSIRbExy8 L7vWlUwiJViBt0GOBr2xL62SHA7JtOjvHic1OdRml8F0Cz36Xeee+Q+JfRS3g3Uu2TXZ jHXAOnWc8Pal4TWvPKvf0IivkVDOVJ33dUWs5z5pnTJ2sIepNHHXg9PIJ1eIRsCoa25g Jq+59vZo8dcmN1HZVwtO5eWxipiJLRgdyWb7YvDpff/UoBs+uV4sppFVd0qOjwwWzgax li7OTviGRs6GVOeYiwFgU928AiHtOz0PlkPmGShTe+WWg6VnNvQzSTRtditmoIxSv+8V 8/ig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=V3mbgmnyoTrMzfffrRfxAP2RkuD6rjug1WQEvOx/n/U=; fh=su0gCa0gPlDSKO6Hi5LQerBHS3iecGQaks/YBZPfpOw=; b=BHKZonDBwpxF/WtI/bJW3P6lWXpWOWvguBxmMLeXUqXKDqMYrA2gb8pVDb9i0i3y+o Pebu3oaI0KZpDrpNJL4oGc6ZXYdAG+yamjEw7xv0NI8RneQiX8tuOuB6X/CKT9QUL8h+ t1uNd+5RBXaEG0A2I2XV+mMh4M7ufs+aWApj2o4GysafSe86Vrzr4vgakRnp78DDcxAq fphPhLI37M6RGsLg7FQRSixUemRL9/THJNuuQMTK0RB08T7Zm3y5ljMNKjL/Bjef179l hlgMjywBv28Kmh7jGuzxbEuIHs5o2T3BlaHBXYO+d86BAM1gTuX7s7sm+T0SvMQbK8p/ BbSQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wWKnfGgi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id q136-20020a632a8e000000b0057754fd6270si1836191pgq.651.2023.09.14.09.15.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 Sep 2023 09:15:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wWKnfGgi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id E3B57836E5C0; Thu, 14 Sep 2023 04:17:45 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236893AbjINLRe (ORCPT + 35 others); Thu, 14 Sep 2023 07:17:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49940 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236436AbjINLRc (ORCPT ); Thu, 14 Sep 2023 07:17:32 -0400 Received: from mail-lf1-x129.google.com (mail-lf1-x129.google.com [IPv6:2a00:1450:4864:20::129]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0E6171FCE for ; Thu, 14 Sep 2023 04:17:28 -0700 (PDT) Received: by mail-lf1-x129.google.com with SMTP id 2adb3069b0e04-5029e4bfa22so1398599e87.3 for ; Thu, 14 Sep 2023 04:17:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1694690246; x=1695295046; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=V3mbgmnyoTrMzfffrRfxAP2RkuD6rjug1WQEvOx/n/U=; b=wWKnfGgixpdGbd7X4MXR4aRd1/BE+XkIMHECkIOmxY0LaUEJeZA+TEbJ0RchFFATaC xna2aBnr2EcZ+f9EXthRf3c0v52ZunDaY6zMaGFfl7RfH/obvvBLUmUFYHBwAKudpwrU Ny57VzA3zRQkhuBdNRXG/Y1BN3zeUv7HbR2j2iKYUj36+TrR2/kKECUJsbYDKQco/pPH z1c8ZfH1hrLh+CZ6L/OpG0B2iHgWF8B1kqq859qpO70GbZhWxk6xKcMcXXdkME+Ov7Bf VDKBbUEnCMD29LOMe5g997FNuvDAryZOuvWHNaRZVqHibUNsKoQ+Z8Uw2bvuBNNbK3Kp 1nww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694690246; x=1695295046; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=V3mbgmnyoTrMzfffrRfxAP2RkuD6rjug1WQEvOx/n/U=; b=UDKM4/5Ar/+5keLa5BOGtTnkEeV/epR1xG8JGgTS3OMC6AiDVV/QHjTYJJIXGVFlE6 ugEvJpjaNI8GVQHs7nU6mkO6PYldq/MekA4qKIeWeJ2U2WgeVDVwCa5qLDFxeUWyGh8X RMz6fab+a+kVxho20Et3Uz4CqoAk9P8k9tsYLxDMBrlC3KSv2ZHiL2RIo0/gIxKOd5LF x6CGGaTZ7viqkZvGgQv3z8gCOyzLEls+0I8GY3SuWVUDQDKjSZK9jI+WV4ruI8ylG68t p8Oh0Uahu3/UprdPTXz8NyYNtkdeqRhfgWeATqN+zqEr1tO2nG5Nr9IyOsxXcZVqVMfz +lrA== X-Gm-Message-State: AOJu0YyJflKNdxwv9ZXtvfe3cQRRpcnk/tARtfLzdsCtVGQpX6ZWymhb YmsemXzqijhqRVA1ha/Jdydx7w== X-Received: by 2002:a05:6512:1585:b0:500:bf33:3add with SMTP id bp5-20020a056512158500b00500bf333addmr6038147lfb.47.1694690246319; Thu, 14 Sep 2023 04:17:26 -0700 (PDT) Received: from uffe-tuxpro14.. (h-94-254-63-18.NA.cust.bahnhof.se. [94.254.63.18]) by smtp.gmail.com with ESMTPSA id r9-20020a056512102900b004fe48d0b639sm237143lfr.83.2023.09.14.04.17.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 14 Sep 2023 04:17:25 -0700 (PDT) From: Ulf Hansson To: Arnd Bergmann , Olof Johansson Cc: Ulf Hansson , linux-pm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Florian Fainelli , Ray Jui , Scott Branden , linux-mips@vger.kernel.org, linux-rpi-kernel@lists.infradead.org Subject: [PATCH 05/17] pmdomain: bcm: Move Kconfig options to the pmdomain subsystem Date: Thu, 14 Sep 2023 13:17:21 +0200 Message-Id: <20230914111721.586543-1-ulf.hansson@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 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 (howler.vger.email [0.0.0.0]); Thu, 14 Sep 2023 04:17:46 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1777030276587616371 X-GMAIL-MSGID: 1777030276587616371 The Kconfig options belongs closer to the corresponding implementations, hence let's move them from the soc subsystem to the pmdomain subsystem. Cc: Florian Fainelli Cc: Ray Jui Cc: Scott Branden Cc: Cc: Signed-off-by: Ulf Hansson --- drivers/pmdomain/Kconfig | 1 + drivers/pmdomain/bcm/Kconfig | 46 ++++++++++++++++++++++++++++++++++++ drivers/soc/bcm/Kconfig | 42 -------------------------------- 3 files changed, 47 insertions(+), 42 deletions(-) create mode 100644 drivers/pmdomain/bcm/Kconfig diff --git a/drivers/pmdomain/Kconfig b/drivers/pmdomain/Kconfig index 55a9ca191849..a0569a44ff4b 100644 --- a/drivers/pmdomain/Kconfig +++ b/drivers/pmdomain/Kconfig @@ -4,5 +4,6 @@ menu "Power Domains Support" source "drivers/pmdomain/actions/Kconfig" source "drivers/pmdomain/amlogic/Kconfig" source "drivers/pmdomain/apple/Kconfig" +source "drivers/pmdomain/bcm/Kconfig" endmenu diff --git a/drivers/pmdomain/bcm/Kconfig b/drivers/pmdomain/bcm/Kconfig new file mode 100644 index 000000000000..a4ee960b4749 --- /dev/null +++ b/drivers/pmdomain/bcm/Kconfig @@ -0,0 +1,46 @@ +# SPDX-License-Identifier: GPL-2.0-only +menu "Broadcom Power Domains" + +config BCM2835_POWER + bool "BCM2835 power domain driver" + depends on ARCH_BCM2835 || (COMPILE_TEST && OF) + default y if ARCH_BCM2835 + select PM_GENERIC_DOMAINS if PM + select RESET_CONTROLLER + help + This enables support for the BCM2835 power domains and reset + controller. Any usage of power domains by the Raspberry Pi + firmware means that Linux usage of the same power domain + must be accessed using the RASPBERRYPI_POWER driver + +config RASPBERRYPI_POWER + bool "Raspberry Pi power domain driver" + depends on ARCH_BCM2835 || (COMPILE_TEST && OF) + depends on RASPBERRYPI_FIRMWARE=y + select PM_GENERIC_DOMAINS if PM + help + This enables support for the RPi power domains which can be enabled + or disabled via the RPi firmware. + +config BCM_PMB + bool "Broadcom PMB (Power Management Bus) driver" + depends on ARCH_BCMBCA || (COMPILE_TEST && OF) + default ARCH_BCMBCA + select PM_GENERIC_DOMAINS if PM + help + This enables support for the Broadcom's PMB (Power Management Bus) that + is used for disabling and enabling SoC devices. + +if SOC_BCM63XX + +config BCM63XX_POWER + bool "BCM63xx power domain driver" + depends on BMIPS_GENERIC || (COMPILE_TEST && OF) + select PM_GENERIC_DOMAINS if PM + help + This enables support for the BCM63xx power domains controller on + BCM6318, BCM6328, BCM6362 and BCM63268 SoCs. + +endif # SOC_BCM63XX + +endmenu diff --git a/drivers/soc/bcm/Kconfig b/drivers/soc/bcm/Kconfig index f96906795fa6..406617aa3056 100644 --- a/drivers/soc/bcm/Kconfig +++ b/drivers/soc/bcm/Kconfig @@ -1,27 +1,6 @@ # SPDX-License-Identifier: GPL-2.0-only menu "Broadcom SoC drivers" -config BCM2835_POWER - bool "BCM2835 power domain driver" - depends on ARCH_BCM2835 || (COMPILE_TEST && OF) - default y if ARCH_BCM2835 - select PM_GENERIC_DOMAINS if PM - select RESET_CONTROLLER - help - This enables support for the BCM2835 power domains and reset - controller. Any usage of power domains by the Raspberry Pi - firmware means that Linux usage of the same power domain - must be accessed using the RASPBERRYPI_POWER driver - -config RASPBERRYPI_POWER - bool "Raspberry Pi power domain driver" - depends on ARCH_BCM2835 || (COMPILE_TEST && OF) - depends on RASPBERRYPI_FIRMWARE=y - select PM_GENERIC_DOMAINS if PM - help - This enables support for the RPi power domains which can be enabled - or disabled via the RPi firmware. - config SOC_BCM63XX bool "Broadcom 63xx SoC drivers" depends on BMIPS_GENERIC || COMPILE_TEST @@ -42,27 +21,6 @@ config SOC_BRCMSTB If unsure, say N. -config BCM_PMB - bool "Broadcom PMB (Power Management Bus) driver" - depends on ARCH_BCMBCA || (COMPILE_TEST && OF) - default ARCH_BCMBCA - select PM_GENERIC_DOMAINS if PM - help - This enables support for the Broadcom's PMB (Power Management Bus) that - is used for disabling and enabling SoC devices. - -if SOC_BCM63XX - -config BCM63XX_POWER - bool "BCM63xx power domain driver" - depends on BMIPS_GENERIC || (COMPILE_TEST && OF) - select PM_GENERIC_DOMAINS if PM - help - This enables support for the BCM63xx power domains controller on - BCM6318, BCM6328, BCM6362 and BCM63268 SoCs. - -endif # SOC_BCM63XX - source "drivers/soc/bcm/brcmstb/Kconfig" endmenu