From patchwork Tue Dec 20 15:56:02 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Roman Kagan X-Patchwork-Id: 9481829 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B6D37601C0 for ; Tue, 20 Dec 2016 16:43:23 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A87C22816B for ; Tue, 20 Dec 2016 16:43:23 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9D17F2818B; Tue, 20 Dec 2016 16:43:23 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 58BB52816B for ; Tue, 20 Dec 2016 16:43:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932226AbcLTQmh (ORCPT ); Tue, 20 Dec 2016 11:42:37 -0500 Received: from mail-db5eur01on0095.outbound.protection.outlook.com ([104.47.2.95]:63121 "EHLO EUR01-DB5-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1761921AbcLTQmS (ORCPT ); Tue, 20 Dec 2016 11:42:18 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=jrZm6huuZ8MrCi4CL6tSllPFn1fhK5IzB55T9F3Au5Q=; b=HJvE2rvHGC4DusxLemFqZykLVw3RITT6y4AiPid2rtWxWL1C0J/alIWTnZZOuy/TXC8/rkKUNwBnMLitCaCT5Utb7yMe+tAn632wHLn8L2yqBImjMBD+o2W7ltvGqJBN3O/hk42gAM2thehjGrx8aeSkuWTrvuhmM21ZK3JelCw= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=rkagan@virtuozzo.com; Received: from rkaganb.sw.ru (195.214.232.10) by VI1PR0802MB2478.eurprd08.prod.outlook.com (10.175.26.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.789.14; Tue, 20 Dec 2016 15:56:59 +0000 From: Roman Kagan To: Paolo Bonzini , =?UTF-8?q?Radim=20Kr=C4=8Dm=C3=A1=C5=99?= , "K. Y. Srinivasan" , Vitaly Kuznetsov CC: Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , , Haiyang Zhang , , , , "Denis V . Lunev" , Roman Kagan Subject: [PATCH 15/15] hyperv: redefine hv_message without bitfields Date: Tue, 20 Dec 2016 18:56:02 +0300 Message-ID: <20161220155602.6298-16-rkagan@virtuozzo.com> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20161220155602.6298-1-rkagan@virtuozzo.com> References: <20161220155602.6298-1-rkagan@virtuozzo.com> MIME-Version: 1.0 X-Originating-IP: [195.214.232.10] X-ClientProxiedBy: AM4PR01CA0030.eurprd01.prod.exchangelabs.com (10.164.74.168) To VI1PR0802MB2478.eurprd08.prod.outlook.com (10.175.26.21) X-MS-Office365-Filtering-Correlation-Id: 929dfbae-2b2e-46f9-d80b-08d428f0d57f X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001); SRVR:VI1PR0802MB2478; X-Microsoft-Exchange-Diagnostics: 1; VI1PR0802MB2478; 3:f2VKHKqq6eVTIGNiIKFvLfRGbaKiBmRBQ2BePlkmt3FD39IfTxudHXiCXSiapzFIetxoNx0/5UqycdwyU6r8iwPnDuQ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mAoR7gCNHZhHEr5ZkFeT5YItH1oBcbDJqeK+nwk0+3JuZs9V4NOF4phIX2/dDGVMi/BBHOakpfKxpooZfbKC82K//tyjUbW8psUS+58e/hmIZfW+CCdEMbkvDxTFt3svQHXS+nQh3yUa1HQHd3ImeDp0/yOTV2a6FMiMumdD8Vcd3SGu7dB3OvZ2+fPGAgWX59uknVwJoFI3i3rCappuCPe61bK6+a8CMtxig==; 20:Qwu2Iq43iIxp46vPCA8IL8dwnLBp5g6Mq/Dey99tT4al65Z2Tv4BdGTDu1/nDGcRqprl9oqD5rstMoLnRBrG1VRBqm8O9SCwffNOwwPTGkYhnfQ9cD7oBmItVFvhSFIialQHcnvPUX05XR6xrhZQG237V5gOTW+fkm5NiU1rb8nVm6et0Xjd/fw/puzfWPOjSfKH892aykglQCGK1YVdQwwtLUKfZRHTXJwy5gjTy8VfZ0l/XJvicnm5zeVlhHiu X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(8121501046)(5005006)(10201501046)(3002001)(6041248)(20161123564025)(20161123555025)(20161123560025)(20161123558021)(20161123562025)(6072148); SRVR:VI1PR0802MB2478; BCL:0; PCL:0; RULEID:; SRVR:VI1PR0802MB2478; X-Microsoft-Exchange-Diagnostics: 1; VI1PR0802MB2478; 4:6BA+wyZte1lcV1al2OXtHtalRDa41xSSRffqeZqLDnr/L+5dYeQ1F94YSYNWeUIK9u6rZ8JmugK0PX42bF57lSN/7vueVlOnNS/cMV04LqdV2uoMH1qEJP/IYqB36ukoJ/bPHHslx6zBGN4LA4lLiGdf6bpzHBH06JjHuOswjNpquWqfsmPf5oD1h/auMh6/TwYkXfzqjYA2KXF1nV1T/ojjt05BFCF+x6B5sQWMQULL6kapuigWM3CRqDxQf8Eq5A2cQlcKM+NRRjIFyyqa4kJEXN5jykEhYrzN4fefjJrSl1L6dITmTk/aTJE0aGHmasUVBosaO8Oqtv+wwlJg37aKovfXaW+THoQwBcIoaDGVl8YfqyZppmCA7f0CkgOsAu00omB5g+4a/8BrbvhlT9BdfM0vsXZPjM25Th+d+k9XEDjLrD25071ezPQBGIxKjD2ZWiU/bxvPSMZH4v20M/3JmhFIEsI1Z8rZr47t5201XxifuFrDW0f8UVnSUDwtP0iw2CQEFGsyPo9K4mV6tu3geyGMWfo7LbXS6rhGheQ4dg50HWfSGPi9FTcAercDztsnR4pRzhZeOq8bssZ0lcFvNFbvgKBvqqAqauEJn+U= X-Forefront-PRVS: 0162ACCC24 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(4630300001)(6009001)(7916002)(39450400003)(199003)(189002)(6666003)(97736004)(189998001)(101416001)(5001770100001)(4001430100002)(5003940100001)(36756003)(81166006)(47776003)(50986999)(66066001)(1511001)(2950100002)(50466002)(76176999)(5660300001)(81156014)(2906002)(8666005)(305945005)(69596002)(48376002)(7736002)(92566002)(7416002)(106356001)(53416004)(25786008)(6116002)(105586002)(6486002)(2421001)(6506006)(1076002)(3846002)(575784001)(86362001)(4326007)(68736007)(8676002)(50226002)(42186005)(107886002)(2561002)(38730400001)(6512006)(33646002)(226483002); DIR:OUT; SFP:1102; SCL:1; SRVR:VI1PR0802MB2478; H:rkaganb.sw.ru; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: virtuozzo.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; VI1PR0802MB2478; 23:+1eTbI9bwhQK4ycaFMZVQbPbG2B5WxzhN8yAWvw?= =?us-ascii?Q?jnEzO9WNzxxXzsdiPMqtPLfZ6vwabX4UyN75Wf9KfBisM1yJLSlIuf83Nzu6?= =?us-ascii?Q?VplB8NYQAHRWrYyKWgf8Xz72RnCBLS5cIxHfh98HwBy/9BCPsmLzIk3gZXan?= =?us-ascii?Q?CvSZWEe+TdelZVny6ev8njGoY0JjytZdkb6kdTGFZDdx/h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put: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; VI1PR0802MB2478; 7:AAO5lq5GZNCztwvvCMUzvUsA28p7yh4L6E4vAKiY6vNuH/hev/Xt4sK88sCrwXaGple63TGemEDaiL7D74O5PBSWiEXfAPOfFJnapE4Un8q+PhWfvvMmGOt580lji9myVa89aVsS+6veMGtIJqBkxbTiA/cjYPuF+nmYs+q7dvSMl6N6XNWBr7f5iYBi7/H9DWjxYQMMWpD7zZDDbLb+hmZikZksS3zgOpIaSr9Q98O1Q1QoM2hcislKyQ6Sh2Z04KtBGUD6jsdKrIc24ogMkX9+BGGqdO5moXFe5iHxEgTUcENOrCSEAboAQoc9cux5njuhwGcDhaWMEDSLfEoCd0FSPqFgp689o4DPOzQ/iFm4D8pUgf/JdK2StOkxh3ddhuGRTf6JbLA1m/F7ybz+v5ZQCdI17Z/EU4ApGcSyPUZhJtbMpUDYDdrP+fMgBO+u7IyDeFYWmTksV39xkTBU7g==; 20:JPbX7153AQCke5ozYPEYnb7V1Yz4GKFi3GM8Krx/16uMts3XXdJHhhO8+nUmgE1lBTf58PpmNKydF142Vnr/HcCoOTBi90AApd5powNCY61zQHTgI1PFgSNpRvkeGQZWaJirUjUSt67wFGDO9BZVCYmvOA3q+fZZdJ4OaX1Nzos= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Dec 2016 15:56:59.5011 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0802MB2478 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This brings more symmetry in the API. The downside is that this changes the userspace-visible structure. Hopefully no userspace code had a chance to use it yet. Signed-off-by: Roman Kagan --- arch/x86/include/uapi/asm/hyperv.h | 32 +++++--------------------------- drivers/hv/hyperv_vmbus.h | 2 +- arch/x86/kvm/hyperv.c | 10 +++++----- drivers/hv/channel_mgmt.c | 6 +++--- drivers/hv/vmbus_drv.c | 2 +- 5 files changed, 15 insertions(+), 37 deletions(-) diff --git a/arch/x86/include/uapi/asm/hyperv.h b/arch/x86/include/uapi/asm/hyperv.h index 5d6e525..89ef9c2 100644 --- a/arch/x86/include/uapi/asm/hyperv.h +++ b/arch/x86/include/uapi/asm/hyperv.h @@ -276,7 +276,8 @@ struct hv_ref_tsc_page { /* Define synthetic interrupt controller message constants. */ #define HV_MESSAGE_SIZE (256) #define HV_MESSAGE_PAYLOAD_BYTE_COUNT (240) -#define HV_MESSAGE_PAYLOAD_QWORD_COUNT (30) + +#define HV_MESSAGE_FLAG_PENDING (1) /* Define hypervisor message types. */ enum hv_message_type { @@ -308,42 +309,19 @@ enum hv_message_type { HVMSG_X64_LEGACY_FP_ERROR = 0x80010005 }; -/* Define synthetic interrupt controller message flags. */ -union hv_message_flags { - __u8 asu8; - struct { - __u8 msg_pending:1; - __u8 reserved:7; - }; -}; - -/* Define port identifier type. */ -union hv_port_id { - __u32 asu32; - struct { - __u32 id:24; - __u32 reserved:8; - } u; -}; - /* Define synthetic interrupt controller message header. */ struct hv_message_header { __u32 message_type; __u8 payload_size; - union hv_message_flags message_flags; + __u8 message_flags; __u8 reserved[2]; - union { - __u64 sender; - union hv_port_id port; - }; + __u64 origination_id; }; /* Define synthetic interrupt controller message format. */ struct hv_message { struct hv_message_header header; - union { - __u64 payload[HV_MESSAGE_PAYLOAD_QWORD_COUNT]; - } u; + __u64 payload[HV_MESSAGE_PAYLOAD_BYTE_COUNT / 8]; }; /* Define the synthetic interrupt message page layout. */ diff --git a/drivers/hv/hyperv_vmbus.h b/drivers/hv/hyperv_vmbus.h index 8ce6d64..87713cc 100644 --- a/drivers/hv/hyperv_vmbus.h +++ b/drivers/hv/hyperv_vmbus.h @@ -260,7 +260,7 @@ static inline void vmbus_signal_eom(struct hv_message *msg, u32 old_msg_type) */ mb(); - if (msg->header.message_flags.msg_pending) { + if (msg->header.message_flags & HV_MESSAGE_FLAG_PENDING) { /* * This will cause message queue rescan to * possibly deliver another msg from the diff --git a/arch/x86/kvm/hyperv.c b/arch/x86/kvm/hyperv.c index c7db112..546dddc 100644 --- a/arch/x86/kvm/hyperv.c +++ b/arch/x86/kvm/hyperv.c @@ -137,7 +137,7 @@ static void synic_clear_sint_msg_pending(struct kvm_vcpu_hv_synic *synic, msg_page = kmap_atomic(page); msg = &msg_page->sint_message[sint]; - msg->header.message_flags.msg_pending = 0; + msg->header.message_flags &= ~HV_MESSAGE_FLAG_PENDING; kunmap_atomic(msg_page); kvm_release_page_dirty(page); @@ -564,10 +564,10 @@ static int synic_deliver_msg(struct kvm_vcpu_hv_synic *synic, u32 sint, dst_msg = &msg_page->sint_message[sint]; if (sync_cmpxchg(&dst_msg->header.message_type, HVMSG_NONE, src_msg->header.message_type) != HVMSG_NONE) { - dst_msg->header.message_flags.msg_pending = 1; + dst_msg->header.message_flags |= HV_MESSAGE_FLAG_PENDING; r = -EAGAIN; } else { - memcpy(&dst_msg->u.payload, &src_msg->u.payload, + memcpy(&dst_msg->payload, &src_msg->payload, src_msg->header.payload_size); dst_msg->header.message_type = src_msg->header.message_type; dst_msg->header.payload_size = src_msg->header.payload_size; @@ -588,7 +588,7 @@ static int stimer_send_msg(struct kvm_vcpu_hv_stimer *stimer) struct kvm_vcpu *vcpu = stimer_to_vcpu(stimer); struct hv_message *msg = &stimer->msg; struct hv_timer_message_payload *payload = - (struct hv_timer_message_payload *)&msg->u.payload; + (struct hv_timer_message_payload *)&msg->payload; payload->expiration_time = stimer->exp_time; payload->delivery_time = get_time_ref_counter(vcpu->kvm); @@ -653,7 +653,7 @@ static void stimer_prepare_msg(struct kvm_vcpu_hv_stimer *stimer) { struct hv_message *msg = &stimer->msg; struct hv_timer_message_payload *payload = - (struct hv_timer_message_payload *)&msg->u.payload; + (struct hv_timer_message_payload *)&msg->payload; memset(&msg->header, 0, sizeof(msg->header)); msg->header.message_type = HVMSG_TIMER_EXPIRED; diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c index 4a5cc11..3576a0b 100644 --- a/drivers/hv/channel_mgmt.c +++ b/drivers/hv/channel_mgmt.c @@ -680,7 +680,7 @@ static void vmbus_wait_for_unload(void) continue; hdr = (struct vmbus_channel_message_header *) - msg->u.payload; + msg->payload; if (hdr->msgtype == CHANNELMSG_UNLOAD_RESPONSE) complete(&vmbus_connection.unload_event); @@ -1071,14 +1071,14 @@ void vmbus_onmessage(void *context) struct vmbus_channel_message_header *hdr; int size; - hdr = (struct vmbus_channel_message_header *)msg->u.payload; + hdr = (struct vmbus_channel_message_header *)msg->payload; size = msg->header.payload_size; if (hdr->msgtype >= CHANNELMSG_COUNT) { pr_err("Received invalid channel message type %d size %d\n", hdr->msgtype, size); print_hex_dump_bytes("", DUMP_PREFIX_NONE, - (unsigned char *)msg->u.payload, size); + (unsigned char *)msg->payload, size); return; } diff --git a/drivers/hv/vmbus_drv.c b/drivers/hv/vmbus_drv.c index f6b626b..60571a8 100644 --- a/drivers/hv/vmbus_drv.c +++ b/drivers/hv/vmbus_drv.c @@ -883,7 +883,7 @@ void vmbus_on_msg_dpc(unsigned long data) /* no msg */ return; - hdr = (struct vmbus_channel_message_header *)msg->u.payload; + hdr = (struct vmbus_channel_message_header *)msg->payload; if (hdr->msgtype >= CHANNELMSG_COUNT) { WARN_ONCE(1, "unknown msgtype=%d\n", hdr->msgtype);