Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src/sys/arch/xen/x86




To: source-changes%NetBSD.org@localhost

Subject: CVS commit: src/sys/arch/xen/x86

From: "Jaromir Dolecek" <jdolecek%netbsd.org@localhost>

Date: Sun, 21 Feb 2021 20:11:59 +0000


Module Name:    src
Committed By:   jdolecek
Date:           Sun Feb 21 20:11:59 UTC 2021

Modified Files:
        src/sys/arch/xen/x86: xen_shm_machdep.c

Log Message:
in xen_shm_map(), make sure to unmap any successfully mapped pages
before returning failure if there is partial failure

fix detection of partial failure - GNTTABOP_map_grant_ref can actually return
zero for partial failure, so we need to always check all the entries
to detect it

previously, DIAGNOSTIC kernel triggered panic() for partial failure,
and non-DIAGNOSTIC kernel did not detect it at all, leading to Dom0 page
fault later; since the mapping failure can be triggered by malicious
DomU via bad grant reference, it's important to expect the calls
to fail, and handle it gracefully without crashing Dom0

part of fixes for XSA-362


To generate a diff of this commit:
cvs rdiff -u -r1.16 -r1.17 src/sys/arch/xen/x86/xen_shm_machdep.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.






Prev by Date: CVS commit: src/sys/arch/xen/xen

Next by Date: CVS commit: src/games/cgram

Previous by Thread: CVS commit: src/sys/arch/xen/xen

Next by Thread: CVS commit: src/games/cgram

Indexes:

reverse Date

reverse Thread

Old Index



Home | Main Index | Thread Index | Old Index