x86/resctrl: fix the uninitialized variable warning
Subsystems (2)
Moger, Babu
reviewerPATCH v2 1/1 x86/resctrl: fix the uninitialized variable warning
Fix the following compiler warning caused by recent change.
arch/x86/kernel/cpu/resctrl/ctrlmondata.c:227 parse_cbm()
error: uninitialized symbol 'cbm_val'
Fixes a36c5ff560fb ("x86/resctrl: Bring cbm_validate() into the resource structure")
Reported-by Dan Carpenter <[email protected]>
Signed-off-by Babu Moger <[email protected]>
---
v1->v2
Added the actual warning.
arch/x86/kernel/cpu/resctrl/ctrlmondata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/kernel/cpu/resctrl/ctrlmondata.c +1 -1
@@ -202,7 +202,7 @@ int parse_cbm(struct rdt_parse_data *data, struct rdt_resource *r, struct rdt_domain *d) {struct rdtgroup *rdtgrp = data->rdtgrp; -u32 cbm_val; +u32 cbm_val =0 ;if (d->have_new_ctrl) {rdt_last_cmd_printf ("Duplicate domain %d\n" , d->id);
Signature · 1 line
2.17.1