]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
platform/x86: intel_pmc_core: fix: Replace dev_dbg macro with dev_info()
authorGayatri Kammela <gayatri.kammela@intel.com>
Wed, 7 Oct 2020 03:51:07 +0000 (20:51 -0700)
committerHans de Goede <hdegoede@redhat.com>
Wed, 7 Oct 2020 21:07:38 +0000 (23:07 +0200)
dev_dbg macro is used to dump the debug registers in resume from an S0ix
failure. However, when CONFIG_DYNAMIC_DEBUG is not set, the user may not be
able to find the debug dump on an S0ix failure which defeats the purpose.
The output of these messages is already controlled by a module parameter,
warn_on_s0ix_failures, making it a 2 step process to enable anyway when
CONFIG_DYNAMIC_DEBUG is set.

Hence, replace dev_dbg with dev_info, allowing the control of the messages
solely through the module parameter which is N by default.

Fixes commit 913f984a8347 ("platform/x86: intel_pmc_core: Add an
additional parameter to pmc_core_lpm_display()")

Cc: Srinivas Pandruvada <srinivas.pandruvada@intel.com>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: David E. Box <david.e.box@linux.intel.com>
Signed-off-by: Gayatri Kammela <gayatri.kammela@intel.com>
Signed-off-by: David E. Box <david.e.box@linux.intel.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Reviewed-by: Rajneesh Bhardwaj <irenic.rajneesh@gmail.com>
Link: https://lore.kernel.org/r/20201007035108.31078-4-david.e.box@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/x86/intel_pmc_core.c

index da316000785ed675f8f3eed18c45057d83eeb542..3e5fe66333f137e4fd90d6a8811677f1dfdf0171 100644 (file)
@@ -640,7 +640,7 @@ static void pmc_core_slps0_display(struct pmc_dev *pmcdev, struct device *dev,
                offset += 4;
                while (map->name) {
                        if (dev)
-                               dev_dbg(dev, "SLP_S0_DBG: %-32s\tState: %s\n",
+                               dev_info(dev, "SLP_S0_DBG: %-32s\tState: %s\n",
                                        map->name,
                                        data & map->bit_mask ? "Yes" : "No");
                        if (s)
@@ -683,7 +683,7 @@ static void pmc_core_lpm_display(struct pmc_dev *pmcdev, struct device *dev,
 
        for (idx = 0; idx < arr_size; idx++) {
                if (dev)
-                       dev_dbg(dev, "\nLPM_%s_%d:\t0x%x\n", str, idx,
+                       dev_info(dev, "\nLPM_%s_%d:\t0x%x\n", str, idx,
                                lpm_regs[idx]);
                if (s)
                        seq_printf(s, "\nLPM_%s_%d:\t0x%x\n", str, idx,
@@ -691,7 +691,7 @@ static void pmc_core_lpm_display(struct pmc_dev *pmcdev, struct device *dev,
                for (index = 0; maps[idx][index].name && index < len; index++) {
                        bit_mask = maps[idx][index].bit_mask;
                        if (dev)
-                               dev_dbg(dev, "%-30s %-30d\n",
+                               dev_info(dev, "%-30s %-30d\n",
                                        maps[idx][index].name,
                                        lpm_regs[idx] & bit_mask ? 1 : 0);
                        if (s)