]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
ACPI / PMIC: Add byt prefix to Crystal Cove PMIC OpRegion driver
authorHans de Goede <hdegoede@redhat.com>
Thu, 24 Oct 2019 21:38:25 +0000 (23:38 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 25 Oct 2019 09:43:08 +0000 (11:43 +0200)
Our current Crystal Cove OpRegion driver is only valid for the
Crystal Cove PMIC variant found on Bay Trail (BYT) boards,
Cherry Trail (CHT) based boards use another variant.

At least the regulator registers are different on CHT and these registers
are one of the things controlled by the custom PMIC OpRegion.

Commit 4d9ed62ab142 ("mfd: intel_soc_pmic: Export separate mfd-cell
configs for BYT and CHT") has disabled the intel_pmic_crc.c code for CHT
devices by removing the "crystal_cove_pmic" MFD cell on CHT devices.

This commit renames the intel_pmic_crc.c driver and the cell to be
prefixed with "byt" to indicate that this code is for BYT devices only.

This is a preparation patch for adding a separate PMIC OpRegion
driver for the CHT variant of the Crystal Cove PMIC (sometimes called
Crystal Cove Plus in Android kernel sources).

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/Kconfig
drivers/acpi/Makefile
drivers/acpi/pmic/intel_pmic_bytcrc.c [moved from drivers/acpi/pmic/intel_pmic_crc.c with 98% similarity]
drivers/mfd/intel_soc_pmic_crc.c

index ebe1e9e5fd81cb5a134d85c244fa81cba335d88c..089f7f8e1be713c22ea51e858140dac5f5a2090e 100644 (file)
@@ -513,11 +513,12 @@ menuconfig PMIC_OPREGION
          PMIC chip.
 
 if PMIC_OPREGION
-config CRC_PMIC_OPREGION
-       bool "ACPI operation region support for CrystalCove PMIC"
+config BYTCRC_PMIC_OPREGION
+       bool "ACPI operation region support for Bay Trail Crystal Cove PMIC"
        depends on INTEL_SOC_PMIC
        help
-         This config adds ACPI operation region support for CrystalCove PMIC.
+         This config adds ACPI operation region support for the Bay Trail
+         version of the Crystal Cove PMIC.
 
 config XPOWER_PMIC_OPREGION
        bool "ACPI operation region support for XPower AXP288 PMIC"
index 5d361e4e3405a06e59de148f6d1ae15c375722f1..ee59b1db69a1608b3c7ca4e00309907015a91d0d 100644 (file)
@@ -109,7 +109,7 @@ obj-$(CONFIG_ACPI_APEI)             += apei/
 obj-$(CONFIG_ACPI_EXTLOG)      += acpi_extlog.o
 
 obj-$(CONFIG_PMIC_OPREGION)    += pmic/intel_pmic.o
-obj-$(CONFIG_CRC_PMIC_OPREGION) += pmic/intel_pmic_crc.o
+obj-$(CONFIG_BYTCRC_PMIC_OPREGION) += pmic/intel_pmic_bytcrc.o
 obj-$(CONFIG_XPOWER_PMIC_OPREGION) += pmic/intel_pmic_xpower.o
 obj-$(CONFIG_BXT_WC_PMIC_OPREGION) += pmic/intel_pmic_bxtwc.o
 obj-$(CONFIG_CHT_WC_PMIC_OPREGION) += pmic/intel_pmic_chtwc.o
similarity index 98%
rename from drivers/acpi/pmic/intel_pmic_crc.c
rename to drivers/acpi/pmic/intel_pmic_bytcrc.c
index a0f411a6e5ac2c75ad708e385f8f4fa827b4d29b..2a692cc4b7ae6a25dd6ee6b1c34ec336d8b12f5e 100644 (file)
@@ -1,6 +1,6 @@
 // SPDX-License-Identifier: GPL-2.0
 /*
- * Intel CrystalCove PMIC operation region driver
+ * Intel Bay Trail Crystal Cove PMIC operation region driver
  *
  * Copyright (C) 2014 Intel Corporation. All rights reserved.
  */
@@ -295,7 +295,7 @@ static int intel_crc_pmic_opregion_probe(struct platform_device *pdev)
 static struct platform_driver intel_crc_pmic_opregion_driver = {
        .probe = intel_crc_pmic_opregion_probe,
        .driver = {
-               .name = "crystal_cove_pmic",
+               .name = "byt_crystal_cove_pmic",
        },
 };
 builtin_platform_driver(intel_crc_pmic_opregion_driver);
index b6ab72fa056971228a2948846fcd1a42c7cec13f..ab09b8225b7606937dc63c8beef5ae1b40303b39 100644 (file)
@@ -75,7 +75,7 @@ static struct mfd_cell crystal_cove_byt_dev[] = {
                .resources = gpio_resources,
        },
        {
-               .name = "crystal_cove_pmic",
+               .name = "byt_crystal_cove_pmic",
        },
        {
                .name = "crystal_cove_pwm",