On 7/20/21 5:06 PM, Sean Christopherson wrote: > On Fri, Jul 16, 2021, Brijesh Singh wrote: >> On 7/15/21 2:28 PM, Brijesh Singh wrote: >>>> Looking at the future patches, dump_rmpentry() is the only power user, >>>> e.g. everything else mostly looks at "assigned" and "level" (and one >>>> ratelimited warn on "validated" in snp_make_page_shared(), but I suspect >>>> that particular check can and should be dropped). >>> Yes, we need "assigned" and "level" and other entries are mainly for >>> the debug purposes. >>> >> For the debug purposes, we would like to dump additional RMP entries. If >> we go with your proposed function then how do we get those information >> in the dump_rmpentry()? > As suggested below, move dump_rmpentry() into sev.c so that it can use the > microarchitectural version. For debug, I'm pretty that's what we'll want anyways, > e.g. dump the raw value along with the meaning of various bits. Based on other feedbacks, I am not sure if we need to dump the RMP entry; In other feedback we agreed to unmap the pages from the direct map while adding them in the RMP table, so, if anyone attempts to access those pages they will now get the page-not-present instead of the RMP violation. thanks