platform/x86:intel/pmc: Move pmc assignment closer to first usage

Move pmc variable assignment closer to the conditional statement of
its first use for better readability.

Signed-off-by: Xi Pardee <xi.pardee@linux.intel.com>
Link: https://lore.kernel.org/r/20240624203218.2428475-5-xi.pardee@linux.intel.com
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
This commit is contained in:
Xi Pardee 2024-06-24 13:32:13 -07:00 committed by Ilpo Järvinen
parent a57a94d185
commit 4455e2b1c8
No known key found for this signature in database
GPG Key ID: 59AC4F6153E5CE31

View File

@ -621,9 +621,10 @@ static int pmc_core_ltr_show(struct seq_file *s, void *unused)
unsigned int i, index, ltr_index = 0;
for (i = 0; i < ARRAY_SIZE(pmcdev->pmcs); ++i) {
struct pmc *pmc = pmcdev->pmcs[i];
struct pmc *pmc;
const struct pmc_bit_map *map;
pmc = pmcdev->pmcs[i];
if (!pmc)
continue;