From patchwork Fri Sep 22 19:28:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Olaf Hering X-Patchwork-Id: 143739 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:910f:0:b0:403:3b70:6f57 with SMTP id r15csp765vqg; Fri, 22 Sep 2023 17:15:39 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE5dZ2z0N94jovQ74rjyWzJeHy3KKkC+5iKrB7bcYI2mRcIbvDdNXVt48nOy+z/eMqLwaWs X-Received: by 2002:a05:6358:428e:b0:142:f97f:7acb with SMTP id s14-20020a056358428e00b00142f97f7acbmr1376939rwc.12.1695428138736; Fri, 22 Sep 2023 17:15:38 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1695428138; cv=pass; d=google.com; s=arc-20160816; b=xoT8y5D/q89AgJgxnux9gOwrcqSkiqRS9Zemboqm73WUHbUFw3wU39+Jo2Cr23Jlwr ++uT3Apg5igow30LcIEdNoDeBuJgmI6lAt8ckBVYpd9YlGCjf2AMiH/InMI255L4lZOW TVZssZcad7jRowjkgfKmECGggf9aCl1zAaGtN1ag6zNllsXuJjWV8kEp6NkiWuMaK3/h MJ8DymENogdyHwWT/lGuDWVm5d9Ew3G1Pgzas/QkNlP9b9aw17OOLgEuN6FrkzreR1gK K5nfgyXdK2TAuklze+GHIvkvM+3Qx4pzmNvbS5KrSI7SDkO81TLrHz3nzdEGUEYbK5jp lBNQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature:dkim-signature; bh=zk3k328hgovnBCBlDXuQXLcoaZsgP5mLEqng5TkR5JQ=; fh=OdhiLaw2T3hK7H6U4RpX6VKiaesM/DmBUUsKcS76R2Q=; b=UOoDy2izl53f8LX8J5WaKTk1lei173LQECN8R2ZsaFcHaFt4wzLiKWRvj8ksRp5pf/ 6HdH5VQUqKpjlUM8CmVeRAy6QN1tYpwlcwO7yCeYPmxpCnyob9ei1Hr6TOsR7nHvNGZo IVfz9+zQJtaPSHqAHUIEL5JeZ9YW+a/K3K8aO68koHIMFpExu8zNnOLNZxY2JFb4Rk1Z BHypYD3Vt9gizSjqq3ErPCk9c6DvEHGVt6FyMwcM72BraE5w8HeCLnQDoI6SyZz55Ek5 qYegDtRDrY1FUNkMjrh3Xht0XY94PtdZRVbA3FQHg2PzhxVdiUBHWeWlfQE1R7beRCnF osfg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@aepfle.de header.s=strato-dkim-0002 header.b="nl/fH7u6"; dkim=neutral (no key) header.i=@aepfle.de header.s=strato-dkim-0003; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id p11-20020a17090adf8b00b00263e299dff6si4995347pjv.74.2023.09.22.17.15.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Sep 2023 17:15:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; dkim=pass header.i=@aepfle.de header.s=strato-dkim-0002 header.b="nl/fH7u6"; dkim=neutral (no key) header.i=@aepfle.de header.s=strato-dkim-0003; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id BFCC683D9B59; Fri, 22 Sep 2023 12:32:11 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233785AbjIVTb5 (ORCPT + 28 others); Fri, 22 Sep 2023 15:31:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51194 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232377AbjIVTb4 (ORCPT ); Fri, 22 Sep 2023 15:31:56 -0400 X-Greylist: delayed 161 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Fri, 22 Sep 2023 12:31:49 PDT Received: from mo4-p01-ob.smtp.rzone.de (mo4-p01-ob.smtp.rzone.de [85.215.255.52]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 75A2394; Fri, 22 Sep 2023 12:31:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695410924; cv=none; d=strato.com; s=strato-dkim-0002; b=hqw57XLZtkDLU8tskHINx6s05s6dT3HJ2PDb01kxB7u4aGhj37MyVrmBdAtpLsqm9q B/Fr2g9wSvBYqbT043zbYDiwkj0Brw2z5XeQ+hUV2nUU4JxAHeZN09sOzbb0Opir+lRc EdQn6qVc9DoSPHvtGx5oulk/ToC+Z3rvLWhk5dmyM5f44Sbb7n6Kzl0Vnn9aAr6V3ZJr KjhmwRyTmxzN6bfURpTkejXVg7RS9utu+PwBbFeFv62AhF/Q3Ig0hczqP8kB7hZ3vlXg zOirTBsRSsIdIeNQjfbZyM/uw0Fj0D8fQRiXG4aD11gGL8l2ZlT3rVEFnT2Zscdad5lW dU5A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; t=1695410924; s=strato-dkim-0002; d=strato.com; h=Message-Id:Date:Subject:Cc:To:From:Cc:Date:From:Subject:Sender; bh=zk3k328hgovnBCBlDXuQXLcoaZsgP5mLEqng5TkR5JQ=; b=n7FHynLHt8a877V/qdEH0TVb466kYjSBKOa2DxYXGIS7WGJwDyKj5nagM7sNKkD9fr p59IR/rPzKeK4/1N72bgR6Z2drU+FVHW2Ws/7Tx4RqZx79UtMDHDcAlVsj8hclE1VsnE STJFDAE8SBJhijE1bmfY2+mGvFIkEhfy9OcPGNGbtbzrnnVF6qn5rS6Us//Rpv6XqVKz stjGelvHqTs83L2LP7HobPWP32QKqy9aRLMq7WgOvSGeskhLJNRsgyWFr0H0u7bJYLjf LkmEBUgvGlFqXmCIJFDWl6reVTWFfxYpjsdw8cugVj52+AMkGOLHTnHfDEIz13oj0wBp CqXw== ARC-Authentication-Results: i=1; strato.com; arc=none; dkim=none X-RZG-CLASS-ID: mo01 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1695410924; s=strato-dkim-0002; d=aepfle.de; h=Message-Id:Date:Subject:Cc:To:From:Cc:Date:From:Subject:Sender; bh=zk3k328hgovnBCBlDXuQXLcoaZsgP5mLEqng5TkR5JQ=; b=nl/fH7u6+eOm3Wql3zmZe66L7utnN43GSBmn7WarrEn4dsKKr+nlRWGpAYqz2sQIpw Ty2dKfYyfgQZodmTaeFfw0sH1JNfFpKKnkEW1GjvBi6B5nxmRJJadNePgt+mBtVum05r dxTn4OPVbx/2RX0RjbdunyJPgfDOZ+5pzf0AHoQlIUT3gzfTWJ3cNiuzrIAj9acVIqY8 xDFW75wv3HtXmF9xnyMpEQeNgGUaWQI6Vz638FERA9MyY3ibI9Qj0HdMC31voZedEgJh ZR9Zg52KKkPMjllnXRG2fjben53vZ/JERBrSpbgv9EMhM0aWSzzeFN9ynvE23Qf6e3mg Dd0w== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; t=1695410924; s=strato-dkim-0003; d=aepfle.de; h=Message-Id:Date:Subject:Cc:To:From:Cc:Date:From:Subject:Sender; bh=zk3k328hgovnBCBlDXuQXLcoaZsgP5mLEqng5TkR5JQ=; b=aJi8fSp0jDQCL+Ql5tLsPIyOVOM5PP9Obox0IbfK55BLJA+7GG7owagLBhFRUWGGtc 2cxfafHFPcguif0asEAg== X-RZG-AUTH: ":P2EQZWCpfu+qG7CngxMFH1J+3q8wa/QXkBR9MXjAuzoZG0ivpswfW93lKL5OLSJeaogTnBaSYHCSFyJtwcJv0YWEnfIN" Received: from sender by smtp.strato.de (RZmta 49.8.2 AUTH) with ESMTPSA id C041b2z8MJSiHhR (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Fri, 22 Sep 2023 21:28:44 +0200 (CEST) From: Olaf Hering To: linux-hyperv@vger.kernel.org, linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org Cc: "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Arnd Bergmann Subject: [PATCH v2] hyperv: reduce size of ms_hyperv_info Date: Fri, 22 Sep 2023 21:28:40 +0200 Message-Id: <20230922192840.3886-1-olaf@aepfle.de> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 X-Spam-Status: No, score=2.7 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, RCVD_IN_SBL_CSS,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Fri, 22 Sep 2023 12:32:11 -0700 (PDT) X-Spam-Level: ** X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1777771037855171255 X-GMAIL-MSGID: 1777785255885904815 Use the hole prior shared_gpa_boundary to store the result of get_vtl. This reduces the size by 8 bytes. Signed-off-by: Olaf Hering --- v2: move vtl up, as suggested by Dexuan Cui include/asm-generic/mshyperv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/asm-generic/mshyperv.h b/include/asm-generic/mshyperv.h index cecd2b7bd033..430f0ae0dde2 100644 --- a/include/asm-generic/mshyperv.h +++ b/include/asm-generic/mshyperv.h @@ -36,6 +36,7 @@ struct ms_hyperv_info { u32 nested_features; u32 max_vp_index; u32 max_lp_index; + u8 vtl; union { u32 isolation_config_a; struct { @@ -54,7 +55,6 @@ struct ms_hyperv_info { }; }; u64 shared_gpa_boundary; - u8 vtl; }; extern struct ms_hyperv_info ms_hyperv; extern bool hv_nested;