lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <e0c594f0a09dc2458f038b90bb0c436ff29ab4bb.1582845395.git.gayatri.kammela@intel.com>
Date:   Thu, 27 Feb 2020 15:29:15 -0800
From:   Gayatri Kammela <gayatri.kammela@...el.com>
To:     platform-driver-x86@...r.kernel.org
Cc:     linux-kernel@...r.kernel.org, vishwanath.somayaji@...el.com,
        dvhart@...radead.org, mika.westerberg@...el.com,
        peterz@...radead.org, charles.d.prestopine@...el.com,
        Gayatri Kammela <gayatri.kammela@...el.com>,
        Chen Zhou <chenzhou10@...wei.com>,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
        "David E . Box" <david.e.box@...el.com>
Subject: [PATCH v2 3/4] platform/x86: intel_pmc_core: fix: Remove the duplicate if() to create debugfs entry for substate_live_status_registers

A debugfs entry for substate_live_status_registers is created only if
the platform has sub-states, which requires the same condition to create
substate_status_registers debugfs entry. Hence remove the redundant
condition and re-use the exisiting one.

Cc: Chen Zhou <chenzhou10@...wei.com>
Cc: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc: David E. Box <david.e.box@...el.com>
Signed-off-by: Gayatri Kammela <gayatri.kammela@...el.com>
---
 drivers/platform/x86/intel_pmc_core.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/platform/x86/intel_pmc_core.c b/drivers/platform/x86/intel_pmc_core.c
index 3f000b6c8d8e..f6cc80987257 100644
--- a/drivers/platform/x86/intel_pmc_core.c
+++ b/drivers/platform/x86/intel_pmc_core.c
@@ -1121,9 +1121,6 @@ static void pmc_core_dbgfs_register(struct pmc_dev *pmcdev)
 		debugfs_create_file("substate_status_registers", 0444,
 				    pmcdev->dbgfs_dir, pmcdev,
 				    &pmc_core_substate_sts_regs_fops);
-	}
-
-	if (pmcdev->map->lpm_status_offset) {
 		debugfs_create_file("substate_live_status_registers", 0444,
 				    pmcdev->dbgfs_dir, pmcdev,
 				    &pmc_core_substate_l_sts_regs_fops);
-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ