Re: [PATCH v2 12/12] EDAC/versalnet: Make get_ddr_config() return errors

From: Yazen Ghannam

Date: Wed Nov 25 2026 - 12:22:37 EST


On Wed, Nov 18, 2026 at 07:50:36PM +0530, Shubhrajyoti Datta wrote:
> get_ddr_config() invokes cdx_mcdi_rpc() but ignores its return value,
> and proceeds even if the cdx_mcdi_rpc returned errors. Also it
> copies the data out of the response buffer without checking that
> the firmware actually returned that much data.
>
> Make get_ddr_config() return an int: propagate cdx_mcdi_rpc()'s
> return code on failure, and return -EIO if the response is shorter
> than expected. Update mc_probe() to check the return value and bail
> out through the existing error path on failure.
>
> Fixes: d5fe2fec6c40 ("EDAC: Add a driver for the AMD Versal NET DDR controller")
> Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xxxxxxx>
> ---

Fixes should generally go first in a series. Any reason to leave this
until the end?

Thanks,
Yazen