[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 3/8] x86/emul: Add pending_dbg field to x86_event
- To: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Wed, 30 Aug 2023 17:18:11 +0200
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=pApXcpexZHy/JfADEbdVoRXBFyCgDnRYKr85jq7XUdM=; b=a+5NbXJXu4HbEVcyT8j4nt6p/bqxETyazclP7+Rs22Y5FBnMBB92PCkH0jsbn6xR89LLgAikRr625rjfG81R+ESQHcJzq0i3MQ1ZNmH0zxHWR/ZnH/lqlTv3iBMwghWiBIHN00FotmLlz4O8v8xJQ0lVn+VualSsAX9A2lR3xgCPMY960pAYttUwBbqgQrfRl4jkYw/IApjS1ngGPy7iEaKvHEluySgXz0EXKTDvxp2jwnQlnKSmbi4IMTz5FdT3AJVY0u9GZP3D2m4O1u2JjR3KufhK3cAj37QekMEeric44QCv4zFyxhbcUHV1IbCalI7WCWEf7mL0OUmoMJq7sg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ADo/qdtAKcttk/35lpCcvmxai4plc+JiseUe3P8nHKL1+Gz8hyfFYdXtbm/iUmhZd6/hQfTyHJHno5eGq5xRIXWwoEo3SVvZLN37iPrTIEmrTGCP2/KEQu6p8hNyE585DYO79uWCXjqT/K3ZwwNRRyY6neD3Ebw6hKfZ8sZt807rrNAPZGF3UI//6dYxPjd3qP2P3DkpgEnr8YWsxCp1xQtRDCd3FntgyfzR5gDok8K/SQW299VbLSgw1yXij8dJyej7xlP7xrM28Mw/Kkv3eT7jFT2FRRjiWxAoAn5KWv6p//edgkkaxU4Hv4Aw0rwZoipWCc7ZhXiC2nIC9UE4xA==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
- Cc: Wei Liu <wl@xxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Jun Nakajima <jun.nakajima@xxxxxxxxx>, Kevin Tian <kevin.tian@xxxxxxxxx>, Tim Deegan <tim@xxxxxxx>, Tamas K Lengyel <tamas@xxxxxxxxxxxxx>, Alexandru Isaila <aisaila@xxxxxxxxxxxxxxx>, Petre Pircalabu <ppircalabu@xxxxxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx, Jinoh Kang <jinoh.kang.kr@xxxxxxxxx>
- Delivery-date: Wed, 30 Aug 2023 15:18:25 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 30.08.2023 16:20, Andrew Cooper wrote:
> On 30/08/2023 2:39 pm, Jan Beulich wrote:
>> On 24.08.2023 17:26, Jinoh Kang wrote:
>>> --- a/xen/arch/x86/x86_emulate/x86_emulate.h
>>> +++ b/xen/arch/x86/x86_emulate/x86_emulate.h
>>> @@ -78,7 +78,10 @@ struct x86_event {
>>> uint8_t type; /* X86_EVENTTYPE_* */
>>> uint8_t insn_len; /* Instruction length */
>>> int32_t error_code; /* X86_EVENT_NO_EC if n/a */
>>> - unsigned long cr2; /* Only for X86_EXC_PF h/w exception */
>>> + union {
>>> + unsigned long cr2; /* #PF */
>>> + unsigned long pending_dbg; /* #DB (new DR6 bits, positive
>>> polarity) */
>
> As a tangent, since I wrote the original series, there's #NM and
> MSR_XFD_ERR which needs to fit into this union for AMX support.
In "x86: XFD enabling" (posted over 2 years ago) I'm getting away
without this quite fine, and I didn't think it's wrong to write the
MSR right from the emulator (using the write_msr() hook).
Jan
|