Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2362212pxa; Mon, 3 Aug 2020 14:25:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwUUphX65xxJBcKJLfNIeLKbS776dLItVWa2sxVz56H8dA/hBSJWQ4o8jhMgxXF6cOBP7BX X-Received: by 2002:a17:906:3803:: with SMTP id v3mr17751328ejc.165.1596489923532; Mon, 03 Aug 2020 14:25:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596489923; cv=none; d=google.com; s=arc-20160816; b=W9HEJnjaIcHixtxxBtw3/GNOAIu/3LgKiBIhg/mT0pwBv7WAKgwtzpXWHcov9GnlAX NbgnMiEgNwxVSpTM36sKTgfozpyL9wNrt8PK9zfTH3zypJeHiDe+rOSCQ8kDG7y6krkE ctBSfjK+RuIcP81teKKAIivtx/fzBAkyjDTT+YMvud8Pnj24IIxhGx7o5c0HHMwsYRxD Ryw7fql3ESbPkMksqBkzX64sdsJSGDkkOulxxQYY6KfCl9HYLNJno5feU5BTTmKhuEFt f3U6vQUHAKCZs78KU/SVzkkMCpZDvMttAHaqv6lakfHHKeazuS8qgu0RftVZL/lsfnOb ofvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:in-reply-to:cc:references:message-id :date:subject:mime-version:from:content-transfer-encoding :dkim-signature; bh=dXYb/lLcqMNHaL94ouMomDU8DMTLeQCp1rZbDZouExs=; b=INWQd2T9bO0IbEEhs0KmExVbOrhEDQpw5pDl4jPikJ998BfEXqTCJ65amBOEboopHs LYW/askPax0NpivGTYJFqg+NQQh4ikLLRWyoBss5W7TexiGlW0ooXZcdUQ16YtmwZxJV Vn6m/PX355UbhlWNDxFGQy1DapFN5AMf/Iigqs2TJ27KHkKpJnwSj5+iZFPAponwdjoA eJ7IFWWigb43djYmfIr/r2AUYuE7WfGSpDDbFE/xgBYzlpFpEi1hd84NfL2gfEDApqFQ d/1wGmUOVpkZO4Lg8wyyfAo1w8aJ1WrmaGU1W0v2Xy4PRmcfVKeI103QVEalZeFRFWMR JwLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ZXBqGDnX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id lo6si10335267ejb.584.2020.08.03.14.25.00; Mon, 03 Aug 2020 14:25:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ZXBqGDnX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728307AbgHCVYC (ORCPT + 99 others); Mon, 3 Aug 2020 17:24:02 -0400 Received: from us-smtp-delivery-1.mimecast.com ([207.211.31.120]:40599 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726370AbgHCVYB (ORCPT ); Mon, 3 Aug 2020 17:24:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1596489840; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=dXYb/lLcqMNHaL94ouMomDU8DMTLeQCp1rZbDZouExs=; b=ZXBqGDnXr/LhW7uqP8xyI4Kn8UBsiLEAzd2JS4PjZmWCU42F+MiE0f8QlRh89z39HW05fY u3DuDZ6qPeBvgoi3CX+wGmuNKpi3FmFqrtS6ciH5lw3LJVQu+WhVQcEtevnusRvB/I3SK2 NKdTVoyPD3GydaAG8GJwnFhgtfKma9M= Received: from mail-ej1-f69.google.com (mail-ej1-f69.google.com [209.85.218.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-203-x3L17Wn0NT2noTgt_6uuIw-1; Mon, 03 Aug 2020 17:23:58 -0400 X-MC-Unique: x3L17Wn0NT2noTgt_6uuIw-1 Received: by mail-ej1-f69.google.com with SMTP id e22so9381293ejx.18 for ; Mon, 03 Aug 2020 14:23:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:content-transfer-encoding:from:mime-version :subject:date:message-id:references:cc:in-reply-to:to; bh=dXYb/lLcqMNHaL94ouMomDU8DMTLeQCp1rZbDZouExs=; b=L8vdmJ+T198rKKiVWzFBK8vNNIH4OOOAgGRNlYhHcYQv/HwP2DSDEmn3wy5WV2JM3e rJe3NCFVKXxjpicbA//0GS7+dDkJ+gXml7EwFxXr4QNdRPnfA4/DZLCmoybgTqdFCJFf RMN5Hs02F665TutbLJQZWzMnC0iYV3s2s3wE88jMHCLykX/lA7yFFzpU3x37U0RO+XFd kWFQeS88oYAjnf5UH75gYcie1QOrUKHCfiUj3ZsfLUZ8GweN7PoeC6dYs0Lq8QVqHn8s EBJ6wHS/sqYzPzhPuXtxgI2uU3u7xtz4q7HJyGn1Vnx7kydwLxCLryXjRAet6cEzoxSC qVPA== X-Gm-Message-State: AOAM531+83JHuOt18iagE6zFv6CP9WwD9FwhQ6aFE+KWBLr4OZtVPSUK 5KjHwR9/A2MG0XRN02byeE0AAfxjn74ixMA+CkJCjSqyLR8Uy0BWA1uX1xWxNX7WeMwt5jbg0gF 4Vn6szGCbrpSVf5B0MULw9OBc X-Received: by 2002:a50:d655:: with SMTP id c21mr17128421edj.49.1596489836975; Mon, 03 Aug 2020 14:23:56 -0700 (PDT) X-Received: by 2002:a50:d655:: with SMTP id c21mr17128405edj.49.1596489836766; Mon, 03 Aug 2020 14:23:56 -0700 (PDT) Received: from [192.168.3.122] (p5b0c6449.dip0.t-ipconnect.de. [91.12.100.73]) by smtp.gmail.com with ESMTPSA id s15sm16948785ejb.16.2020.08.03.14.23.55 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 03 Aug 2020 14:23:56 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable From: David Hildenbrand Mime-Version: 1.0 (1.0) Subject: Re: [PATCH v2 13/24] virtio_mem: correct tags for config space fields Date: Mon, 3 Aug 2020 23:23:55 +0200 Message-Id: References: <20200803205814.540410-14-mst@redhat.com> Cc: linux-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org, Jason Wang , David Hildenbrand In-Reply-To: <20200803205814.540410-14-mst@redhat.com> To: "Michael S. Tsirkin" X-Mailer: iPhone Mail (17F80) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > Am 03.08.2020 um 22:59 schrieb Michael S. Tsirkin : >=20 > =EF=BB=BFSince this is a modern-only device, > tag config space fields as having little endian-ness. >=20 > TODO: check other uses of __virtioXX types in this header, > should probably be __leXX. Doesn=E2=80=98t matter in practice IIRC, like this change. But we could do i= t (the spec documents everything as __le) in case it makes things clearer. Acked-by: David Hildenbrand >=20 > Signed-off-by: Michael S. Tsirkin > --- > include/uapi/linux/virtio_mem.h | 14 +++++++------- > 1 file changed, 7 insertions(+), 7 deletions(-) >=20 > diff --git a/include/uapi/linux/virtio_mem.h b/include/uapi/linux/virtio_m= em.h > index a9ffe041843c..70e01c687d5e 100644 > --- a/include/uapi/linux/virtio_mem.h > +++ b/include/uapi/linux/virtio_mem.h > @@ -185,27 +185,27 @@ struct virtio_mem_resp { >=20 > struct virtio_mem_config { > /* Block size and alignment. Cannot change. */ > - __u64 block_size; > + __le64 block_size; > /* Valid with VIRTIO_MEM_F_ACPI_PXM. Cannot change. */ > - __u16 node_id; > + __le16 node_id; > __u8 padding[6]; > /* Start address of the memory region. Cannot change. */ > - __u64 addr; > + __le64 addr; > /* Region size (maximum). Cannot change. */ > - __u64 region_size; > + __le64 region_size; > /* > * Currently usable region size. Can grow up to region_size. Can > * shrink due to VIRTIO_MEM_REQ_UNPLUG_ALL (in which case no config > * update will be sent). > */ > - __u64 usable_region_size; > + __le64 usable_region_size; > /* > * Currently used size. Changes due to plug/unplug requests, but no > * config updates will be sent. > */ > - __u64 plugged_size; > + __le64 plugged_size; > /* Requested size. New plug requests cannot exceed it. Can change. */ > - __u64 requested_size; > + __le64 requested_size; > }; >=20 > #endif /* _LINUX_VIRTIO_MEM_H */ > --=20 > MST >=20