Message ID | 20240124172345.853129-1-suzuki.poulose@arm.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-37420-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:2553:b0:103:945f:af90 with SMTP id p19csp1139976dyi; Wed, 24 Jan 2024 09:28:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IGLgtQNMSZe0tzpxkhT67uFQtzgPR2vIANFWzNhyyNNc7uJngMgieK9Lf/9KA4ptYvSnXnS X-Received: by 2002:a05:620a:2624:b0:783:96c4:782 with SMTP id z36-20020a05620a262400b0078396c40782mr8270601qko.153.1706117286609; Wed, 24 Jan 2024 09:28:06 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706117286; cv=pass; d=google.com; s=arc-20160816; b=R+RKiIwjCL83vXo66x2WwKChmFQWKHul110lVOIpItrYt8dFrEuh12f3EgIrl82hLR PK7nVvVYIuRyf9K1JrBo2RXo1e5D6Z3kqxLnLc9rsKYyFZeimWJfMH39NrZMZjKhG0qI d1cW68r+oPdvivX/ThgLhU8QaRSe57nHmrQvv5Nw/IxDEsYyKBC91+Dg6rh8AHn6BDZh bdPvuIWt0faA0wIvHchgtmNS/gWBgjGhx4iBGnpYn98ydTz1E3eNP5h8DChX4AblQR0O +cWItZ7NPIO+i6Vmgq5ZNf4CMUwvlwmmMDgkoyvgGto+cIueRHo74Y9BZ3QphkpYdfCR u9XA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from; bh=+4og+l0clIiIeZMJsPRbTNam9EXH384g2O2K6SewRzo=; fh=uAzi0InFaxAiip42humuQxYyWwI+U1aHOM44+ffmevs=; b=nwEs/RvywbR2/sMyDSsT6lnnbUighjjecmmIv8iUkWamaFnGC83qJD9dOu+NAp5Hzs 2uWpmKsV5abDY+m6XIupFuYdvPD57t78vzZ6DW5gAeWuaZjfFnfKZ4Kv33fb04l2oc5L /4Jzvay9clMMza6CTu6PejxxEVLfMkGUb8uBbyc3MfWlJDbrXb0PAZZ3qjVYM+4Wv29D /D1KzUwJJcOQ5uqRWkFTzuVNV1HlZTVqnIU5h5EUBCXiUQWlGWU73iXEPdfBS3YU5hpI rRvnb2RsBiOiyCMRWvk2NDP5DlddPDznAyyXyAB1GiT9j1ZdEmqvcekPlLmkbCq6CrHJ R4bA== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=arm.com dmarc=pass fromdomain=arm.com); spf=pass (google.com: domain of linux-kernel+bounces-37420-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-37420-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id oo12-20020a05620a530c00b00781d27b7ba3si10655054qkn.99.2024.01.24.09.28.06 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Jan 2024 09:28:06 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-37420-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=arm.com dmarc=pass fromdomain=arm.com); spf=pass (google.com: domain of linux-kernel+bounces-37420-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-37420-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 4B82A1C2670E for <ouuuleilei@gmail.com>; Wed, 24 Jan 2024 17:28:06 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9817D1272C3; Wed, 24 Jan 2024 17:24:09 +0000 (UTC) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 089837CF18; Wed, 24 Jan 2024 17:24:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706117048; cv=none; b=uMi+S0USr3KrBYEB8zgkoZt2ErsKnzTgWwSEVje7ZPfRzl2kyQHzb/GGI2yFGA3WY8J4un9SnDwpgLOMArm9lhzVAGi1caawGluVCogopqyN/kHWG32a1bgCkLHQ542MXv5sGn7e1GT464M8iSuAmA63Fpq+63cY6rqQrYxsBvk= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706117048; c=relaxed/simple; bh=Nel1C4fahRSLksyTQGpvXQXEvhkmWvAfgHn6lsWzUdE=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=BvJpRX7DIa9SC39n3p3LYXup8jFoJZklmflEPV7xDjpniGjoL7crGGpKPz+cd7pWrZ5XJ7/IUm1RVlNxJsUUubEfYE3nVhWaYaN/KNOe44YkQyDT3MePBsXtoYrOLWi/Ah16EEH7ds0U0axLI/nxnm5iF1Pm0vWXIKyvOs6jKfM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id E06A71FB; Wed, 24 Jan 2024 09:24:49 -0800 (PST) Received: from ewhatever.cambridge.arm.com (ewhatever.cambridge.arm.com [10.1.197.1]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 0AF5A3F762; Wed, 24 Jan 2024 09:24:03 -0800 (PST) From: Suzuki K Poulose <suzuki.poulose@arm.com> To: linux-kernel@vger.kernel.org Cc: kvm@vger.kernel.org, Suzuki K Poulose <suzuki.poulose@arm.com>, Feng Liu <feliu@nvidia.com>, "Michael S . Tsirkin" <mst@redhat.com>, Yishai Hadas <yishaih@nvidia.com>, Alex Williamson <alex.williamson@redhat.com>, Jean-Philippe Brucker <jean-philippe@linaro.org> Subject: [PATCH] virtio: uapi: Drop __packed attribute in linux/virtio_pci.h: Date: Wed, 24 Jan 2024 17:23:45 +0000 Message-Id: <20240124172345.853129-1-suzuki.poulose@arm.com> X-Mailer: git-send-email 2.34.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1788993640021020376 X-GMAIL-MSGID: 1788993640021020376 |
Series |
virtio: uapi: Drop __packed attribute in linux/virtio_pci.h:
|
|
Commit Message
Suzuki K Poulose
Jan. 24, 2024, 5:23 p.m. UTC
Commit 92792ac752aa ("virtio-pci: Introduce admin command sending function")
added "__packed" structures to UAPI header linux/virtio_pci.h. This triggers
build failures in the consumer userspace applications without proper "definition"
of __packed (e.g., kvmtool build fails).
Moreover, the structures are already packed well, and doesn't need explicit
packing, similar to the rest of the structures in all virtio_* headers. Remove
the __packed attribute.
Fixes: commit 92792ac752aa ("virtio-pci: Introduce admin command sending function")
Cc: Feng Liu <feliu@nvidia.com>
Cc: Michael S. Tsirkin <mst@redhat.com>
Cc: Yishai Hadas <yishaih@nvidia.com>
Cc: Alex Williamson <alex.williamson@redhat.com>
Cc: Jean-Philippe Brucker <jean-philippe@linaro.org>
Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com>
---
include/uapi/linux/virtio_pci.h | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
Comments
On Wed, Jan 24, 2024 at 05:23:45PM +0000, Suzuki K Poulose wrote: > Commit 92792ac752aa ("virtio-pci: Introduce admin command sending function") > added "__packed" structures to UAPI header linux/virtio_pci.h. This triggers > build failures in the consumer userspace applications without proper "definition" > of __packed (e.g., kvmtool build fails). > > Moreover, the structures are already packed well, and doesn't need explicit > packing, similar to the rest of the structures in all virtio_* headers. Remove > the __packed attribute. > > Fixes: commit 92792ac752aa ("virtio-pci: Introduce admin command sending function") > Cc: Feng Liu <feliu@nvidia.com> > Cc: Michael S. Tsirkin <mst@redhat.com> > Cc: Yishai Hadas <yishaih@nvidia.com> > Cc: Alex Williamson <alex.williamson@redhat.com> > Cc: Jean-Philippe Brucker <jean-philippe@linaro.org> > Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Reviewed-by: Jean-Philippe Brucker <jean-philippe@linaro.org> > --- > include/uapi/linux/virtio_pci.h | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/include/uapi/linux/virtio_pci.h b/include/uapi/linux/virtio_pci.h > index ef3810dee7ef..a8208492e822 100644 > --- a/include/uapi/linux/virtio_pci.h > +++ b/include/uapi/linux/virtio_pci.h > @@ -240,7 +240,7 @@ struct virtio_pci_cfg_cap { > #define VIRTIO_ADMIN_CMD_LEGACY_DEV_CFG_READ 0x5 > #define VIRTIO_ADMIN_CMD_LEGACY_NOTIFY_INFO 0x6 > > -struct __packed virtio_admin_cmd_hdr { > +struct virtio_admin_cmd_hdr { > __le16 opcode; > /* > * 1 - SR-IOV > @@ -252,20 +252,20 @@ struct __packed virtio_admin_cmd_hdr { > __le64 group_member_id; > }; > > -struct __packed virtio_admin_cmd_status { > +struct virtio_admin_cmd_status { > __le16 status; > __le16 status_qualifier; > /* Unused, reserved for future extensions. */ > __u8 reserved2[4]; > }; > > -struct __packed virtio_admin_cmd_legacy_wr_data { > +struct virtio_admin_cmd_legacy_wr_data { > __u8 offset; /* Starting offset of the register(s) to write. */ > __u8 reserved[7]; > __u8 registers[]; > }; > > -struct __packed virtio_admin_cmd_legacy_rd_data { > +struct virtio_admin_cmd_legacy_rd_data { > __u8 offset; /* Starting offset of the register(s) to read. */ > }; > > @@ -275,7 +275,7 @@ struct __packed virtio_admin_cmd_legacy_rd_data { > > #define VIRTIO_ADMIN_CMD_MAX_NOTIFY_INFO 4 > > -struct __packed virtio_admin_cmd_notify_info_data { > +struct virtio_admin_cmd_notify_info_data { > __u8 flags; /* 0 = end of list, 1 = owner device, 2 = member device */ > __u8 bar; /* BAR of the member or the owner device */ > __u8 padding[6]; > -- > 2.34.1 >
On Wed, Jan 24, 2024 at 05:23:45PM +0000, Suzuki K Poulose wrote: > Commit 92792ac752aa ("virtio-pci: Introduce admin command sending function") > added "__packed" structures to UAPI header linux/virtio_pci.h. This triggers > build failures in the consumer userspace applications without proper "definition" > of __packed (e.g., kvmtool build fails). > > Moreover, the structures are already packed well, and doesn't need explicit > packing, similar to the rest of the structures in all virtio_* headers. Remove > the __packed attribute. > > Fixes: commit 92792ac752aa ("virtio-pci: Introduce admin command sending function") Proper form is: Fixes: 92792ac752aa ("virtio-pci: Introduce admin command sending function") > Cc: Feng Liu <feliu@nvidia.com> > Cc: Michael S. Tsirkin <mst@redhat.com> > Cc: Yishai Hadas <yishaih@nvidia.com> > Cc: Alex Williamson <alex.williamson@redhat.com> > Cc: Jean-Philippe Brucker <jean-philippe@linaro.org> > Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> > --- > include/uapi/linux/virtio_pci.h | 10 +++++----- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/include/uapi/linux/virtio_pci.h b/include/uapi/linux/virtio_pci.h > index ef3810dee7ef..a8208492e822 100644 > --- a/include/uapi/linux/virtio_pci.h > +++ b/include/uapi/linux/virtio_pci.h > @@ -240,7 +240,7 @@ struct virtio_pci_cfg_cap { > #define VIRTIO_ADMIN_CMD_LEGACY_DEV_CFG_READ 0x5 > #define VIRTIO_ADMIN_CMD_LEGACY_NOTIFY_INFO 0x6 > > -struct __packed virtio_admin_cmd_hdr { > +struct virtio_admin_cmd_hdr { > __le16 opcode; > /* > * 1 - SR-IOV > @@ -252,20 +252,20 @@ struct __packed virtio_admin_cmd_hdr { > __le64 group_member_id; > }; > > -struct __packed virtio_admin_cmd_status { > +struct virtio_admin_cmd_status { > __le16 status; > __le16 status_qualifier; > /* Unused, reserved for future extensions. */ > __u8 reserved2[4]; > }; > > -struct __packed virtio_admin_cmd_legacy_wr_data { > +struct virtio_admin_cmd_legacy_wr_data { > __u8 offset; /* Starting offset of the register(s) to write. */ > __u8 reserved[7]; > __u8 registers[]; > }; > > -struct __packed virtio_admin_cmd_legacy_rd_data { > +struct virtio_admin_cmd_legacy_rd_data { > __u8 offset; /* Starting offset of the register(s) to read. */ > }; > > @@ -275,7 +275,7 @@ struct __packed virtio_admin_cmd_legacy_rd_data { > > #define VIRTIO_ADMIN_CMD_MAX_NOTIFY_INFO 4 > > -struct __packed virtio_admin_cmd_notify_info_data { > +struct virtio_admin_cmd_notify_info_data { > __u8 flags; /* 0 = end of list, 1 = owner device, 2 = member device */ > __u8 bar; /* BAR of the member or the owner device */ > __u8 padding[6]; Acked-by: Michael S. Tsirkin <mst@redhat.com> I will queue this. > -- > 2.34.1
On 25/01/2024 22:48, Michael S. Tsirkin wrote: > On Wed, Jan 24, 2024 at 05:23:45PM +0000, Suzuki K Poulose wrote: >> Commit 92792ac752aa ("virtio-pci: Introduce admin command sending function") >> added "__packed" structures to UAPI header linux/virtio_pci.h. This triggers >> build failures in the consumer userspace applications without proper "definition" >> of __packed (e.g., kvmtool build fails). >> >> Moreover, the structures are already packed well, and doesn't need explicit >> packing, similar to the rest of the structures in all virtio_* headers. Remove >> the __packed attribute. >> >> Fixes: commit 92792ac752aa ("virtio-pci: Introduce admin command sending function") > > > Proper form is: > > Fixes: 92792ac752aa ("virtio-pci: Introduce admin command sending function") Apologies, for messing that up. > >> Cc: Feng Liu <feliu@nvidia.com> >> Cc: Michael S. Tsirkin <mst@redhat.com> >> Cc: Yishai Hadas <yishaih@nvidia.com> >> Cc: Alex Williamson <alex.williamson@redhat.com> >> Cc: Jean-Philippe Brucker <jean-philippe@linaro.org> >> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> >> --- >> include/uapi/linux/virtio_pci.h | 10 +++++----- >> 1 file changed, 5 insertions(+), 5 deletions(-) >> >> diff --git a/include/uapi/linux/virtio_pci.h b/include/uapi/linux/virtio_pci.h >> index ef3810dee7ef..a8208492e822 100644 >> --- a/include/uapi/linux/virtio_pci.h >> +++ b/include/uapi/linux/virtio_pci.h >> @@ -240,7 +240,7 @@ struct virtio_pci_cfg_cap { >> #define VIRTIO_ADMIN_CMD_LEGACY_DEV_CFG_READ 0x5 >> #define VIRTIO_ADMIN_CMD_LEGACY_NOTIFY_INFO 0x6 >> >> -struct __packed virtio_admin_cmd_hdr { >> +struct virtio_admin_cmd_hdr { >> __le16 opcode; >> /* >> * 1 - SR-IOV >> @@ -252,20 +252,20 @@ struct __packed virtio_admin_cmd_hdr { >> __le64 group_member_id; >> }; >> >> -struct __packed virtio_admin_cmd_status { >> +struct virtio_admin_cmd_status { >> __le16 status; >> __le16 status_qualifier; >> /* Unused, reserved for future extensions. */ >> __u8 reserved2[4]; >> }; >> >> -struct __packed virtio_admin_cmd_legacy_wr_data { >> +struct virtio_admin_cmd_legacy_wr_data { >> __u8 offset; /* Starting offset of the register(s) to write. */ >> __u8 reserved[7]; >> __u8 registers[]; >> }; >> >> -struct __packed virtio_admin_cmd_legacy_rd_data { >> +struct virtio_admin_cmd_legacy_rd_data { >> __u8 offset; /* Starting offset of the register(s) to read. */ >> }; >> >> @@ -275,7 +275,7 @@ struct __packed virtio_admin_cmd_legacy_rd_data { >> >> #define VIRTIO_ADMIN_CMD_MAX_NOTIFY_INFO 4 >> >> -struct __packed virtio_admin_cmd_notify_info_data { >> +struct virtio_admin_cmd_notify_info_data { >> __u8 flags; /* 0 = end of list, 1 = owner device, 2 = member device */ >> __u8 bar; /* BAR of the member or the owner device */ >> __u8 padding[6]; > > > Acked-by: Michael S. Tsirkin <mst@redhat.com> > > I will queue this. Thanks Suzuki > >> -- >> 2.34.1 >
On Thu, Jan 25, 2024 at 11:10:16PM +0000, Suzuki K Poulose wrote: > On 25/01/2024 22:48, Michael S. Tsirkin wrote: > > On Wed, Jan 24, 2024 at 05:23:45PM +0000, Suzuki K Poulose wrote: > > > Commit 92792ac752aa ("virtio-pci: Introduce admin command sending function") > > > added "__packed" structures to UAPI header linux/virtio_pci.h. This triggers > > > build failures in the consumer userspace applications without proper "definition" > > > of __packed (e.g., kvmtool build fails). > > > > > > Moreover, the structures are already packed well, and doesn't need explicit > > > packing, similar to the rest of the structures in all virtio_* headers. Remove > > > the __packed attribute. > > > > > > Fixes: commit 92792ac752aa ("virtio-pci: Introduce admin command sending function") > > > > > > Proper form is: > > > > Fixes: 92792ac752aa ("virtio-pci: Introduce admin command sending function") > > Apologies, for messing that up. Pls repost a fixed one. > > > > > Cc: Feng Liu <feliu@nvidia.com> > > > Cc: Michael S. Tsirkin <mst@redhat.com> > > > Cc: Yishai Hadas <yishaih@nvidia.com> > > > Cc: Alex Williamson <alex.williamson@redhat.com> > > > Cc: Jean-Philippe Brucker <jean-philippe@linaro.org> > > > Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> > > > --- > > > include/uapi/linux/virtio_pci.h | 10 +++++----- > > > 1 file changed, 5 insertions(+), 5 deletions(-) > > > > > > diff --git a/include/uapi/linux/virtio_pci.h b/include/uapi/linux/virtio_pci.h > > > index ef3810dee7ef..a8208492e822 100644 > > > --- a/include/uapi/linux/virtio_pci.h > > > +++ b/include/uapi/linux/virtio_pci.h > > > @@ -240,7 +240,7 @@ struct virtio_pci_cfg_cap { > > > #define VIRTIO_ADMIN_CMD_LEGACY_DEV_CFG_READ 0x5 > > > #define VIRTIO_ADMIN_CMD_LEGACY_NOTIFY_INFO 0x6 > > > -struct __packed virtio_admin_cmd_hdr { > > > +struct virtio_admin_cmd_hdr { > > > __le16 opcode; > > > /* > > > * 1 - SR-IOV > > > @@ -252,20 +252,20 @@ struct __packed virtio_admin_cmd_hdr { > > > __le64 group_member_id; > > > }; > > > -struct __packed virtio_admin_cmd_status { > > > +struct virtio_admin_cmd_status { > > > __le16 status; > > > __le16 status_qualifier; > > > /* Unused, reserved for future extensions. */ > > > __u8 reserved2[4]; > > > }; > > > -struct __packed virtio_admin_cmd_legacy_wr_data { > > > +struct virtio_admin_cmd_legacy_wr_data { > > > __u8 offset; /* Starting offset of the register(s) to write. */ > > > __u8 reserved[7]; > > > __u8 registers[]; > > > }; > > > -struct __packed virtio_admin_cmd_legacy_rd_data { > > > +struct virtio_admin_cmd_legacy_rd_data { > > > __u8 offset; /* Starting offset of the register(s) to read. */ > > > }; > > > @@ -275,7 +275,7 @@ struct __packed virtio_admin_cmd_legacy_rd_data { > > > #define VIRTIO_ADMIN_CMD_MAX_NOTIFY_INFO 4 > > > -struct __packed virtio_admin_cmd_notify_info_data { > > > +struct virtio_admin_cmd_notify_info_data { > > > __u8 flags; /* 0 = end of list, 1 = owner device, 2 = member device */ > > > __u8 bar; /* BAR of the member or the owner device */ > > > __u8 padding[6]; > > > > > > Acked-by: Michael S. Tsirkin <mst@redhat.com> > > > > I will queue this. > > Thanks > Suzuki > > > > > > -- > > > 2.34.1 > >
diff --git a/include/uapi/linux/virtio_pci.h b/include/uapi/linux/virtio_pci.h index ef3810dee7ef..a8208492e822 100644 --- a/include/uapi/linux/virtio_pci.h +++ b/include/uapi/linux/virtio_pci.h @@ -240,7 +240,7 @@ struct virtio_pci_cfg_cap { #define VIRTIO_ADMIN_CMD_LEGACY_DEV_CFG_READ 0x5 #define VIRTIO_ADMIN_CMD_LEGACY_NOTIFY_INFO 0x6 -struct __packed virtio_admin_cmd_hdr { +struct virtio_admin_cmd_hdr { __le16 opcode; /* * 1 - SR-IOV @@ -252,20 +252,20 @@ struct __packed virtio_admin_cmd_hdr { __le64 group_member_id; }; -struct __packed virtio_admin_cmd_status { +struct virtio_admin_cmd_status { __le16 status; __le16 status_qualifier; /* Unused, reserved for future extensions. */ __u8 reserved2[4]; }; -struct __packed virtio_admin_cmd_legacy_wr_data { +struct virtio_admin_cmd_legacy_wr_data { __u8 offset; /* Starting offset of the register(s) to write. */ __u8 reserved[7]; __u8 registers[]; }; -struct __packed virtio_admin_cmd_legacy_rd_data { +struct virtio_admin_cmd_legacy_rd_data { __u8 offset; /* Starting offset of the register(s) to read. */ }; @@ -275,7 +275,7 @@ struct __packed virtio_admin_cmd_legacy_rd_data { #define VIRTIO_ADMIN_CMD_MAX_NOTIFY_INFO 4 -struct __packed virtio_admin_cmd_notify_info_data { +struct virtio_admin_cmd_notify_info_data { __u8 flags; /* 0 = end of list, 1 = owner device, 2 = member device */ __u8 bar; /* BAR of the member or the owner device */ __u8 padding[6];