[dpdk-dev] [PATCH v1] examples/vm_power_manager: fix buffer overrun
Thomas Monjalon
thomas at monjalon.net
Tue Apr 23 10:33:30 CEST 2019
23/04/2019 10:21, Hunt, David:
> Hi Thomas,
>
> On 22/4/2019 10:54 PM, Thomas Monjalon wrote:
> > 10/04/2019 14:49, David Hunt:
> >> The freqs array in freq_info struct has RTE_MAX_LCORE_FREQS elements,
> >> yet the code can attemtp to look at the index at POWER_MANAGER_MAX_CPUS,
> >> which may be greater than RTE_MAX_LCORE_FREQS. Fix to limit index to
> >> RTE_MAX_LCORE_FREQS.
> >>
> >> Fixes: d26c18c93260 ("examples/vm_power: cpu frequency in host")
> >> Coverity issue: 337660
> >>
> >> Signed-off-by: David Hunt <david.hunt at intel.com>
> > It seems to have been fixed in another patch, isn't it?
> >
>
> It was not fixed in another patch, although I can see the confusion.
>
> A previous patch made the #defines more consistent, and
> POWER_MGR_MAX_CPUS was changed to RTE_MAX_LCORE on the affected line.
> However, this was later revealed as a coverity issue, and was fixed in
> this patch to be RTE_LCORE_MAX_FREQS, which is the size of the array
> it's trying to index into.
>
> So looking at RC2, this patch is still needed.
I think it needs to be rebased in a v2 then.
More information about the dev
mailing list