[PATCH 3/8] ram: k3-ddrss: Add comment about ecc_reserved_space
Kumar, Udit
u-kumar1 at ti.com
Tue Jan 28 06:47:41 CET 2025
On 1/27/2025 7:52 PM, Neha Malcom Francis wrote:
> The reserved space needed for storing the parity remains the same no
> matter the size of the region that is being protected. Add this as a
> comment for better code understanding.
>
> Signed-off-by: Neha Malcom Francis <n-francis at ti.com>
> ---
> drivers/ram/k3-ddrss/k3-ddrss.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/ram/k3-ddrss/k3-ddrss.c b/drivers/ram/k3-ddrss/k3-ddrss.c
> index 24932cd837c..ab46098adbf 100644
> --- a/drivers/ram/k3-ddrss/k3-ddrss.c
> +++ b/drivers/ram/k3-ddrss/k3-ddrss.c
> @@ -715,6 +715,10 @@ static void k3_ddrss_lpddr4_ecc_calc_reserved_mem(struct k3_ddrss_desc *ddrss)
> {
> fdtdec_setup_mem_size_base_lowest();
>
> + /*
> + * Reserved region remains 1/9th of the total DDR available no matter the
> + * size of the region under protection
> + */
Please add why , you need 1/9th of DDR
> ddrss->ecc_reserved_space = ddrss->ddr_ram_size;
> do_div(ddrss->ecc_reserved_space, 9);
>
More information about the U-Boot
mailing list