struct paging_mode's {write, cmpxchg}_guest_entry and guest_{map, get_eff}_l1e
Tim, George,
what's the reason that these aren't in struct shadow_paging_mode instead? They're only being used by shadow code, and I can't see an abstract reason why HAP would ever want to use them.
Thanks, Jan
Quoted 5 lines · Jan Beulich
Tim, George,
what's the reason that these aren't in struct
shadow_paging_modeinstead? They're only being used by shadow code, and I can't see an abstract reason why HAP would ever want to use them.
That seems fair. In fact AFAICT they're only called for _translated-mode_ PV guests!
So we should just refuse to enter a translated-but-not-external paging mode, since that's not maintained and almost certainly doesn't work, and then these hooks can go away entirely.
Cheers,
Tim.
Quoted 6 lines
Quoted 1 line
Quoted 1 line · On 15.10.15 at 11:39, <[email protected]> wrote:
Quoted 3 lines · Jan Beulich
what's the reason that these aren't in struct
shadow_paging_modeinstead? They're only being used by shadow code, and I can't see an abstract reason why HAP would ever want to use them.
Quoted 6 lines
That seems fair. In fact AFAICT they're only called for _translated-mode_ PV guests!
So we should just refuse to enter a translated-but-not-external paging mode, since that's not maintained and almost certainly doesn't work, and then these hooks can go away entirely.
Looking more closely, I think this is true for the latter two (in the subject), but not the former two (and indeed migration triggers them).
Jan
Quoted 9 lines · Jan Beulich
Quoted 9 lines
Quoted 1 line
Quoted 1 line · On 15.10.15 at 11:39, <[email protected]> wrote:
Quoted 3 lines · Jan Beulich
what's the reason that these aren't in struct
shadow_paging_modeinstead? They're only being used by shadow code, and I can't see an abstract reason why HAP would ever want to use them.That seems fair. In fact AFAICT they're only called for _translated-mode_ PV guests!
Quoted 7 lines
Quoted 3 lines
So we should just refuse to enter a translated-but-not-external paging mode, since that's not maintained and almost certainly doesn't work, and then these hooks can go away entirely.
Looking more closely, I think this is true for the latter two (in the subject), but not the former two (and indeed migration triggers them).
Oh, yes, I hadn't looked at those. Yes, we need to keep write/cmpxchg. I would be inclined to keep them as paging-level operations, at least as far as non-mm code is concerned. I have no objection to moving the function pointers into a shadow-specific struct and having the wrapper assert that the caller is in shadow mode.
Cheers,
Tim.