[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YNyp/ZsGwnjFZr04@zn.tnic>
Date: Wed, 30 Jun 2021 19:29:33 +0200
From: Borislav Petkov <bp@...en8.de>
To: Yazen Ghannam <yazen.ghannam@....com>
Cc: linux-edac@...r.kernel.org, linux-kernel@...r.kernel.org,
mchehab@...nel.org, tony.luck@...el.com,
Smita.KoralahalliChannabasappa@....com
Subject: Re: [PATCH v2 08/31] EDAC/amd64: Define function to read DRAM
address map registers
On Wed, Jun 23, 2021 at 07:19:39PM +0000, Yazen Ghannam wrote:
> @@ -1170,22 +1194,13 @@ static int umc_normaddr_to_sysaddr(u64 norm_addr, u16 nid, u8 umc, u64 *sys_addr
> if (remove_dram_offset(&ctx))
> goto out_err;
>
> - reg = df_regs[DRAM_BASE_ADDR];
> - reg.offset += ctx.map_num * 8;
> - if (amd_df_indirect_read(nid, reg, umc, &tmp))
> - goto out_err;
> -
> - /* Check if address range is valid. */
> - if (!(tmp & BIT(0))) {
> - pr_err("%s: Invalid DramBaseAddress range: 0x%x.\n",
> - __func__, tmp);
> + if (get_dram_addr_map(&ctx))
> goto out_err;
> - }
Aha, I see where you're going with the context struct. Yap, ok.
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette
Powered by blists - more mailing lists