[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] x86/shadow: Drop dubious lastpage diagnostic
- To: Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
- Date: Fri, 20 Jan 2023 11:45:56 +0000
- Authentication-results: esa4.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none
- Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Jan Beulich <JBeulich@xxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxxxxx>, Tim Deegan <tim@xxxxxxx>
- Delivery-date: Fri, 20 Jan 2023 11:46:35 +0000
- Ironport-data: A9a23:G0gsj6yBB4KOFGqTlb16t+c4xirEfRIJ4+MujC+fZmUNrF6WrkUBn WsYDG+OPPqDZmDxeth3OY7noBtQ7MSGytdmGwA4+yAxQypGp/SeCIXCJC8cHc8wwu7rFxs7s ppEOrEsCOhuExcwcz/0auCJQUFUjP3OHfykTbaeYUidfCc8IA85kxVvhuUltYBhhNm9Emult Mj75sbSIzdJ4RYtWo4vw//F+UwHUMja4mtC5QRnP6gT5jcyqlFOZH4hDfDpR5fHatE88t6SH 47r0Ly/92XFyBYhYvvNfmHTKxBirhb6ZGBiu1IOM0SQqkEqSh8ai87XAME0e0ZP4whlqvgqo Dl7WT5cfi9yVkHEsLx1vxC1iEiSN4UekFPMCSDXXcB+UyQq2pYjqhljJBheAGEWxgp4KXxxy fsGITE0Vxu8pc+03rG6WMxdmst2eaEHPKtH0p1h5TTQDPJgSpHfWaTao9Rf2V/chOgXQ6yYP ZBAL2MyMlKZOUYn1lQ/UfrSmM+BgHXlfiIeg1WSvactuEDYzRBr0airO93QEjCPbZQIzxrJ+ z6dl4j/Kg0oGIKw92Kozi+1r/XItBnjZrkoCITto5aGh3XMnzdOWXX6T2CTvv2RmkO4HdVFJ CQ85isrhbg/8gqsVNaVdw21pjuIswARX/JUEvYm80edx6zM+QGbC2MYCDlbZ7QOluU7WDgr3 V+hhM7yCHpkt7j9dJ6G3u7K93XoY3FTdDJcI3ZeFmPp/uUPvqkusS7IUN9iKZe+sf/YGy/zw iKvnTQx0uB7YdEw60mrwbzWq2vy+cSQHlduvVW/snGNtV0gOtP8D2C8wR2CtKsbct7EJrWUl CJc8/Vy+tziGn1keMalZOwWVI+k6P+eWNE3qQ4+RsJxn9hBFpPKQGyx3N2dDB0zWir8UWW1C HI/QCsIjHOpAFOkbLVsf6W6ANkwwK7rGLzND66LMoMTOcIoKl7ZrUmCgHJ8OEi0wCARfVwXY 8/HIa5A815EYUiY8NZGb7hEiuJ6rszP7WjSWYr633yaPUm2PRaopUM+GALWNIgRtfrUyDg5B v4Db6NmPT0DCryhCsQWmKZPRW03wY8TX8Gv+pwHKrTaSuekcUl4Y8LsLXoaU9QNt8xoei3gp xlRhmcwJILDuED6
- Ironport-hdrordr: A9a23:cPdQ+KCIF0r6CHflHelA55DYdb4zR+YMi2TDtnoBNiC9F/byqy nAppomPHPP5Qr4dhkb+Oxoe5PwI080jKQFmbX5ZI3SJzUO21HYT72Kj7GSvwEIcheWnoRgPM FbAtVD4bbLYmSS4/yX3OD2KadE/PC3tI2lgOfAw2x8JDsaDJ2JiG9Ce3ym++BNNW97LIt8Pq C1ouBAoyOkeXwRZMj+PH8YROLOzueqqHujW29+Ozc3rA2Dlymh5rLZHwjw5GZ7bw9y
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
This is a global variable (actually 3, one per GUEST_PAGING_LEVEL), operated
on using atomics only (with no regard to what else shares the same cacheline),
which emits a diagnostic (in debug builds only) without changing any program
behaviour.
Based on read-only p2m types including logdirty, this diagnostic can be
tripped by entirely legitimate guest behaviour.
Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
---
CC: Jan Beulich <JBeulich@xxxxxxxx>
CC: Roger Pau Monné <roger.pau@xxxxxxxxxx>
CC: Wei Liu <wl@xxxxxxx>
CC: George Dunlap <george.dunlap@xxxxxxxxxxxxx>
CC: Tim Deegan <tim@xxxxxxx>
---
xen/arch/x86/mm/shadow/multi.c | 7 -------
1 file changed, 7 deletions(-)
diff --git a/xen/arch/x86/mm/shadow/multi.c b/xen/arch/x86/mm/shadow/multi.c
index 8b3e678fa0fa..3b06cfaf9a5a 100644
--- a/xen/arch/x86/mm/shadow/multi.c
+++ b/xen/arch/x86/mm/shadow/multi.c
@@ -2597,14 +2597,7 @@ static int cf_check sh_page_fault(
/* Ignore attempts to write to read-only memory. */
if ( p2m_is_readonly(p2mt) && (ft == ft_demand_write) )
- {
- static unsigned long lastpage;
- if ( xchg(&lastpage, va & PAGE_MASK) != (va & PAGE_MASK) )
- gdprintk(XENLOG_DEBUG, "guest attempted write to read-only memory"
- " page. va page=%#lx, mfn=%#lx\n",
- va & PAGE_MASK, mfn_x(gmfn));
goto emulate_readonly; /* skip over the instruction */
- }
/* In HVM guests, we force CR0.WP always to be set, so that the
* pagetables are always write-protected. If the guest thinks
--
2.11.0
|