From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by mx.groups.io with SMTP id smtpd.web10.1764.1610058324991275772 for ; Thu, 07 Jan 2021 14:25:25 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@ibm.com header.s=pp1 header.b=ehuD7sX2; spf=pass (domain: linux.ibm.com, ip: 148.163.158.5, mailfrom: jejb@linux.ibm.com) Received: from pps.filterd (m0098421.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 107M26KZ028261; Thu, 7 Jan 2021 17:25:22 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=message-id : subject : from : reply-to : to : cc : date : in-reply-to : references : content-type : mime-version : content-transfer-encoding; s=pp1; bh=p768uDKAsp2hPHgvxRN/OgWvPWVvlom1gjmWnfwn25Q=; b=ehuD7sX2iphzJjaF025J8xUh8M+li0Lsw6PqGsUyp/8dOUtbxSiE3VUa5XvpV6p1ejpw WINvKrl5qyU41P+/9z27eKsgUZFVuQJ0ELMoistbbJ4j4DHzBJrskEe9t+YbkqCaZxj3 HWXBFqfJJpcR/3TVJZT+GKS7gsDXi0+fQy3Q2EQcLox+yTckTw3g1a6QsM/kSvr1mzIt 9rtplx05MkJTj4YCKz4eej0NqbJx5OVP1a8RB8QGUGgmLOY0L2ZwvbWQOhsJVcvt7w9Y +cmvrLU4lfeQ7Rc9kOaY1osahmBPDZhwXWHZzWDZGwcZW6rxZ/sr4mzHJLKRSxuNdrll Jg== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com with ESMTP id 35x7yrmuts-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 07 Jan 2021 17:25:22 -0500 Received: from m0098421.ppops.net (m0098421.ppops.net [127.0.0.1]) by pps.reinject (8.16.0.36/8.16.0.36) with SMTP id 107M4maW039626; Thu, 7 Jan 2021 17:25:22 -0500 Received: from ppma02wdc.us.ibm.com (aa.5b.37a9.ip4.static.sl-reverse.com [169.55.91.170]) by mx0a-001b2d01.pphosted.com with ESMTP id 35x7yrmutg-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 07 Jan 2021 17:25:22 -0500 Received: from pps.filterd (ppma02wdc.us.ibm.com [127.0.0.1]) by ppma02wdc.us.ibm.com (8.16.0.42/8.16.0.42) with SMTP id 107MNK6C026548; Thu, 7 Jan 2021 22:25:21 GMT Received: from b03cxnp08027.gho.boulder.ibm.com (b03cxnp08027.gho.boulder.ibm.com [9.17.130.19]) by ppma02wdc.us.ibm.com with ESMTP id 35tgf9fjyg-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 07 Jan 2021 22:25:21 +0000 Received: from b03ledav004.gho.boulder.ibm.com (b03ledav004.gho.boulder.ibm.com [9.17.130.235]) by b03cxnp08027.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 107MPK4V12321316 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 7 Jan 2021 22:25:20 GMT Received: from b03ledav004.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 079667805C; Thu, 7 Jan 2021 22:25:20 +0000 (GMT) Received: from b03ledav004.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 6184578060; Thu, 7 Jan 2021 22:25:18 +0000 (GMT) Received: from jarvis.int.hansenpartnership.com (unknown [9.85.172.80]) by b03ledav004.gho.boulder.ibm.com (Postfix) with ESMTP; Thu, 7 Jan 2021 22:25:18 +0000 (GMT) Message-ID: <88732d221e94954a910ed9e8c501b2a0e5d5338f.camel@linux.ibm.com> Subject: Re: [edk2-devel] [PATCH V2] UefiCpuPkg/CpuDxe: Fix boot error From: "James Bottomley" Reply-To: jejb@linux.ibm.com To: devel@edk2.groups.io, lersek@redhat.com, Guo Dong Cc: eric.dong@intel.com, ray.ni@intel.com, rahul1.kumar@intel.com, Tom Lendacky , Michael Kinney Date: Thu, 07 Jan 2021 14:25:17 -0800 In-Reply-To: <045e12bb-f4d8-1d7a-ea3a-fa7b8d09ce12@redhat.com> References: <20210107031045.6760-1-guo.dong@intel.com> <045e12bb-f4d8-1d7a-ea3a-fa7b8d09ce12@redhat.com> User-Agent: Evolution 3.34.4 MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.343,18.0.737 definitions=2021-01-07_09:2021-01-07,2021-01-07 signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 lowpriorityscore=0 adultscore=0 mlxlogscore=999 priorityscore=1501 clxscore=1011 suspectscore=0 bulkscore=0 phishscore=0 spamscore=0 malwarescore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2101070124 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit On Thu, 2021-01-07 at 12:56 +0100, Laszlo Ersek wrote: > Adding James, Mike, and Tom: > > On 01/07/21 04:10, Guo Dong wrote: > > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3084 > > > > When DXE drivers are dispatched above 4GB memory in 64bit > > mode, the address setCodeSelectorLongJump in stack will > > be override by parameter. Jump to Qword is not supported > > by some processors. So use "o64 retf" instead. > > > > Signed-off-by: Guo Dong > > --- > > UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm | 8 +++----- > > 1 file changed, 3 insertions(+), 5 deletions(-) > > > > diff --git a/UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm > > b/UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm > > index c3489bcc3e..a8216cd56f 100644 > > --- a/UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm > > +++ b/UefiCpuPkg/CpuDxe/X64/CpuAsm.nasm > > @@ -20,13 +20,11 @@ > > ;----------------------------------------------------------------- > > ------------- > > global ASM_PFX(SetCodeSelector) > > ASM_PFX(SetCodeSelector): > > - sub rsp, 0x10 > > + push rcx, > > lea rax, [setCodeSelectorLongJump] > > - mov [rsp], rax > > - mov [rsp+4], cx > > - jmp dword far [rsp] > > + push rax > > + o64 retf > > setCodeSelectorLongJump: > > - add rsp, 0x10 > > ret > > > > ;----------------------------------------------------------------- > > ------------- > > > > I'm asking for: > James Bottomley > - a Reviewed-by or Tested-by from James please, and Tested-by: James Bottomley James