From patchwork Fri Jun 29 22:19:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Venu Busireddy X-Patchwork-Id: 10497693 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 D9A636022E for ; Fri, 29 Jun 2018 22:22:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BB5182935B for ; Fri, 29 Jun 2018 22:22:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id AB42929375; Fri, 29 Jun 2018 22:22:25 +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=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 467F32935B for ; Fri, 29 Jun 2018 22:22:25 +0000 (UTC) Received: from localhost ([::1]:44717 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fZ1ma-0004Hm-Ee for patchwork-qemu-devel@patchwork.kernel.org; Fri, 29 Jun 2018 18:22:24 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42660) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fZ1k7-0001u5-9G for qemu-devel@nongnu.org; Fri, 29 Jun 2018 18:19:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fZ1k3-00089f-7D for qemu-devel@nongnu.org; Fri, 29 Jun 2018 18:19:51 -0400 Received: from aserp2130.oracle.com ([141.146.126.79]:50264) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fZ1k2-00088n-UW for qemu-devel@nongnu.org; Fri, 29 Jun 2018 18:19:47 -0400 Received: from pps.filterd (aserp2130.oracle.com [127.0.0.1]) by aserp2130.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w5TMJjFB083036; Fri, 29 Jun 2018 22:19:45 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references; s=corp-2017-10-26; bh=8mPiuKvl/AmjGRepILqoA9VAiGyo1zgUFVnZmWIHZIM=; b=bSJteljqinXwPRLZAblk+NDRvV0y11YjDleEqg53Xbt1mV6tRLmZ/cOer3AhYZrwYvRP O+0O9tWkXU+OC0Mh8MQCYXebwMcOgjkar+MVyRa+6VcH1p/3UEGwW7IsgIGa7VQx82Mn J51zqolWP/UvPoakz47abtgAvW7+Z9QGxtVx3bIB+lqtzceTFkJEuJiSKBUaLkQZ84c7 g669deAjAXH9ewP6lh8Fa2KoXuPhqP2K4EfwLldRsmHENCj34ANMTRlyrPUqtj20LmcP dP0XGeXkDvaHgRhGb6p8BsG2Ca8fpTsYkciTQNCABes+ptbqdhiYTQgRWgPi+44JEhy2 9g== Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by aserp2130.oracle.com with ESMTP id 2jukmu85ws-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 29 Jun 2018 22:19:45 +0000 Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id w5TMJhkk025469 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 29 Jun 2018 22:19:44 GMT Received: from abhmp0004.oracle.com (abhmp0004.oracle.com [141.146.116.10]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id w5TMJh3a015919; Fri, 29 Jun 2018 22:19:43 GMT Received: from troi.attlocal.net (/10.154.170.104) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 29 Jun 2018 15:19:43 -0700 From: Venu Busireddy To: venu.busireddy@oracle.com, "Michael S . Tsirkin" , Marcel Apfelbaum Date: Fri, 29 Jun 2018 17:19:07 -0500 Message-Id: <20180629221907.3662-5-venu.busireddy@oracle.com> X-Mailer: git-send-email 2.14.4 In-Reply-To: <20180629221907.3662-1-venu.busireddy@oracle.com> References: <20180629221907.3662-1-venu.busireddy@oracle.com> X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=8939 signatures=668703 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=968 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1806210000 definitions=main-1806290237 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] [fuzzy] X-Received-From: 141.146.126.79 Subject: [Qemu-devel] [PATCH v3 virtio 1/1] Add "Group Identifier" to virtio PCI capabilities. X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: virtio-dev@lists.oasis-open.org, qemu-devel@nongnu.org Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP Add VIRTIO_PCI_CAP_GROUP_ID_CFG (Group Identifier) capability to the virtio PCI capabilities to allow for the grouping of devices. Signed-off-by: Venu Busireddy --- content.tex | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/content.tex b/content.tex index be18234..34627e5 100644 --- a/content.tex +++ b/content.tex @@ -599,6 +599,8 @@ The fields are interpreted as follows: #define VIRTIO_PCI_CAP_DEVICE_CFG 4 /* PCI configuration access */ #define VIRTIO_PCI_CAP_PCI_CFG 5 +/* Group Identifier */ +#define VIRTIO_PCI_CAP_GROUP_ID_CFG 6 \end{lstlisting} Any other value is reserved for future use. @@ -997,6 +999,34 @@ address \field{cap.length} bytes within a BAR range specified by some other Virtio Structure PCI Capability of type other than \field{VIRTIO_PCI_CAP_PCI_CFG}. +\subsubsection{Group Identifier capability}\label{sec:Virtio Transport Options / Virtio Over PCI Bus / PCI Device Layout / Group Identifier capability} + +The VIRTIO_PCI_CAP_GROUP_ID_CFG capability provides means for grouping +devices together. + +The capability is immediately followed by an identifier of type u64 +as below: + +\begin{lstlisting} +struct virtio_pci_group_id_cap { + struct virtio_pci_cap cap; + u64 group_id; /* Group Identifier */ +}; +\end{lstlisting} + +\devicenormative{\paragraph}{Group Identifier capability}{Virtio Transport Options / Virtio Over PCI Bus / PCI Device Layout / Group Identifier capability} + +The device MAY present the VIRTIO_PCI_CAP_GROUP_ID_CFG capability. + +When this capability is present, the device must set the fields +\field{cap.bar}, \field{cap.offset} and \field{cap.length} to 0, and +set the group_id to a unique identifier. + +\drivernormative{\paragraph}{Group Identifier capability}{Virtio Transport Options / Virtio Over PCI Bus / PCI Device Layout / Group Identifier capability} + +The fields \field{cap.bar}, \field{cap.offset}, \field{cap.length} +and \field{group_id} are read-only for the driver. + \subsubsection{Legacy Interfaces: A Note on PCI Device Layout}\label{sec:Virtio Transport Options / Virtio Over PCI Bus / PCI Device Layout / Legacy Interfaces: A Note on PCI Device Layout} Transitional devices MUST present part of configuration