diff --git a/drivers/platform/mpam/mpam_devices.c b/drivers/platform/mpam/mpam_devices.c index 21ca76695d3e9bd59af7c82bcf5fde41f73b90a4..19e2153652eb8df2560dc9a4dfaa00c2e631ed42 100644 --- a/drivers/platform/mpam/mpam_devices.c +++ b/drivers/platform/mpam/mpam_devices.c @@ -1057,7 +1057,7 @@ static void __ris_msmon_read(void *arg) static int _msmon_read(struct mpam_component *comp, struct mon_read *arg) { - int err, idx; + int err = 0, idx; bool read_again; u64 wait_jiffies; struct mpam_msc *msc; @@ -1606,7 +1606,8 @@ static int __setup_ppi(struct mpam_msc *msc) for_each_cpu(cpu, &msc->accessibility) { struct mpam_msc *empty = *per_cpu_ptr(msc->error_dev_id, cpu); if (empty != NULL) { - pr_err_once("%s shares PPI with %s!\n", dev_name(&msc->pdev->dev), + pr_err_once("%s shares PPI with %s!\n", + dev_name(&msc->pdev->dev), dev_name(&empty->pdev->dev)); return -EBUSY; } @@ -1626,7 +1627,6 @@ static int mpam_msc_setup_error_irq(struct mpam_msc *msc) /* Allocate and initialise the percpu device pointer for PPI */ if (irq_is_percpu(irq)) - return __setup_ppi(msc); /* sanity check: shared interrupts can be routed anywhere? */ @@ -1696,7 +1696,7 @@ static int mpam_dt_parse_resource(struct mpam_msc *msc, struct device_node *np, static int mpam_dt_parse_resources(struct mpam_msc *msc, void *ignored) { - int err, num_ris = 0; + int err = 0, num_ris = 0; const u32 *ris_idx_p; struct device_node *iter, *np; diff --git a/fs/resctrl/ctrlmondata.c b/fs/resctrl/ctrlmondata.c index 3f0380a2386a7d878d9be3a08d4e7a23c4416a6b..bf87eed826ff40113d43284280acdd2b3c637ec7 100644 --- a/fs/resctrl/ctrlmondata.c +++ b/fs/resctrl/ctrlmondata.c @@ -507,7 +507,7 @@ void mon_event_read(struct rmid_read *rr, struct rdt_resource *r, * MPAM's resctrl_arch_rmid_read() is unable to read the * counters on some platforms if its called in irq context. */ - if (tick_nohz_full_cpu(cpu)) + if (tick_nohz_full_cpu(cpu) && !IS_ENABLED(CONFIG_ARM64_MPAM)) smp_call_function_any(&d->cpu_mask, mon_event_count, rr, 1); else smp_call_on_cpu(cpu, smp_mon_event_count, rr, false); diff --git a/include/linux/resctrl.h b/include/linux/resctrl.h index e2e63b3bd50857d390c5f426f406cee3f15987cc..958b1f39d016bfb0d8d010c7902bfb5ca6c4d900 100644 --- a/include/linux/resctrl.h +++ b/include/linux/resctrl.h @@ -315,9 +315,9 @@ static inline u32 resctrl_get_config_index(u32 closid, case CDP_NONE: return closid; case CDP_CODE: - return (closid * 2) + 1; + return (closid * 2) + 1; case CDP_DATA: - return (closid * 2); + return (closid * 2); } }