Commit 1de9992
KVM: x86/mmu: Remove unnecessary ‘NULL’ values from sptep
Don't initialize "spte" and "sptep" in fast_page_fault() as they are both
guaranteed (for all intents and purposes) to be written at the start of
every loop iteration. Add a sanity check that "sptep" is non-NULL after
walking the shadow page tables, as encountering a NULL root would result
in "spte" not being written, i.e. would lead to uninitialized data or the
previous value being consumed.
Signed-off-by: Li zeming <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
[sean: rewrite changelog with --verbose]
Signed-off-by: Sean Christopherson <[email protected]>1 parent c9f65a3 commit 1de9992
1 file changed
+10
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3425 | 3425 | | |
3426 | 3426 | | |
3427 | 3427 | | |
3428 | | - | |
3429 | | - | |
| 3428 | + | |
| 3429 | + | |
3430 | 3430 | | |
3431 | 3431 | | |
3432 | 3432 | | |
| |||
3442 | 3442 | | |
3443 | 3443 | | |
3444 | 3444 | | |
| 3445 | + | |
| 3446 | + | |
| 3447 | + | |
| 3448 | + | |
| 3449 | + | |
| 3450 | + | |
| 3451 | + | |
| 3452 | + | |
3445 | 3453 | | |
3446 | 3454 | | |
3447 | 3455 | | |
| |||
0 commit comments