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

Re: [PATCH] x86/PV: use 64-bit subtract to adjust guest RIP upon missing SYSCALL callbacks


  • To: Jan Beulich <jbeulich@xxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
  • Date: Tue, 26 Jan 2021 16:57:25 +0000
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=FOmcSWe4kl7YGRgMpBv3Md/25J1BuFNzG511s1A3SKE=; b=JXqz8AYZJHnFbw/QkxCk0LQ/Qy6CqpLKF5HRfaDUkQE/lcxYIWl7WvHBqwwVtpAfDRCGW8NV1YjowEYv/UuZ1Q2gXwY+bmzgSz1+gzb2wn/zV2LfYIO69MePnw3OlaWGqpCARv7Iy9UgDsJn5+bTsTycsh003geD7MCmPymYninXrHyjchCdKilfvRtIp0H6ZNzSQWVckdRRHZQv4bD4WtWhVT15skawZNt+zcBStGwdCm9MfE1zp6K3+beSJmxMxhF+W7h7AhPaHvkaX26+vC6+hmQ/2vmWnAL/MIh9SCp489vUlp8YFNu3d3s1gRcfFQeapT16P5A44n4Zog5Ucg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kxGrwTb5W5IXCEx22uCgb4KVKV1apCaorPZAyGRhWMmEDP1AdFcPdlY/uM5vlLNqw+ErUv+XeuFIu1wFvS2ggWOUfx3rX2dSKugYpbW4HOPZ+1zv03s3kAf62aDgiysZrGOvEe4GAJydNkmqytOJ9Q99VQS0fXXGe2NQHAgfVXcTpe/0YVVZ1apOaXEYW2JaFE26SAebdRevbLVhtvBBqch4fLes/9kKDpwt6eLtiXFFRDLkBWGgyiMSNsjPu+PylnCoFcbShnSY/t9bLnYvKjghuOosdzTajokuABLzOi47fgBiivEsntliFZtoHmkkHklJXfTTjrvcuWAh/h0Ojg==
  • Authentication-results: esa4.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: Wei Liu <wl@xxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Delivery-date: Tue, 26 Jan 2021 16:57:40 +0000
  • Ironport-sdr: xO2BuPt/j3SKvF34/giTkaSL+qxgdVWfJCoxYy3zP+zACbwOHHSAgBM7mzTVCCtgRsID+1pw4M ciyQidpjyPzM06M8CSinBSGTpxurleKW1hTb0nF84nuC/YMIF44NRnz+97+J1fXIlsmiNnj7ho AenHB01FC/qEzbLmjGTrJpL1xTNqVfbmEz0CleNBE3S/CRecdLVTFrCzorxfxNiwWw3EUu731V xqZXlUCqQtq0CLW91wfnBiKoCMbnyF8p0dTrFInRbGav3WSYMRn+MOQOF2M5s+UHBhLx3kW25Z P3E=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 26/01/2021 16:31, Jan Beulich wrote:
> When discussing the shrunk down version of the commit in question it
> was said (in reply to my conditional choosing of the width):
>
> "However, the 32bit case isn't actually interesting here.  A
>  guest can't execute a SYSCALL instruction on/across the 4G->0 boundary
>  because the M2P is mapped NX up to the 4G boundary, so we can never
>  reach this point with %eip < 2.
>
>  Therefore, the 64bit-only form is the appropriate one to use, which
>  solves any question of cleverness, or potential decode stalls it
>  causes."
>
> Fixes: ca6fcf4321b3 ("x86/pv: Inject #UD for missing SYSCALL callbacks")
> Signed-off-by: Jan Beulich <JBeulich@xxxxxxxx>

Crap.  I folded the fix into my wrong tree.  Sorry.

Reviewed-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>

~Andrew



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.