From patchwork Mon Jan 7 22:29:39 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Venu Busireddy X-Patchwork-Id: 10751257 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 63F38746 for ; Mon, 7 Jan 2019 22:31:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 47EB728AF9 for ; Mon, 7 Jan 2019 22:31:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3BFFF28B27; Mon, 7 Jan 2019 22:31:32 +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=-2.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D795128AB6 for ; Mon, 7 Jan 2019 22:31:30 +0000 (UTC) Received: from localhost ([127.0.0.1]:50954 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ggdQf-00066V-F0 for patchwork-qemu-devel@patchwork.kernel.org; Mon, 07 Jan 2019 17:31:29 -0500 Received: from eggs.gnu.org ([209.51.188.92]:39165) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ggdPG-0004gc-Az for qemu-devel@nongnu.org; Mon, 07 Jan 2019 17:30:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ggdPF-0003w4-L9 for qemu-devel@nongnu.org; Mon, 07 Jan 2019 17:30:02 -0500 Received: from aserp2130.oracle.com ([141.146.126.79]:54510) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ggdPF-0003rJ-Bk for qemu-devel@nongnu.org; Mon, 07 Jan 2019 17:30:01 -0500 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 x07MIxSk065745; Mon, 7 Jan 2019 22:29:59 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id; s=corp-2018-07-02; bh=6LY2oJ/778hEP2d+CW1KJAnwsyB9MchTPy1lfb46mmQ=; b=UKd5IvaXa5NfHEogkbMN1UKmuHrCgKRu1d8gBcvqRjVjWplvDrkorz3PHHBv/wmpFpcX Ol64jgAs1y8txUqP/XRRtzwgv/WvAF+Y15qfWWALXCEpSd/kFcb6BmNPzAaUYBqnLhQl KWcVrSrXPfaCTCC6xWHbSzP0Dj7V6T4uMuIOF9dJNFciEL3tXNDMzX3QmYLe2Urit62y aNETlq1Qg82MyeaeHJdI3BBJjIwxZ3ybocvOuy7FyQwhS6+qUbsCGPlJxIPNORXu//Fg 9GMt4dEP672TwC8oFPH8us0rOJFDvfu5aeUI9gEeW7Ynqq/QdArNN7A+Btj7nxx1Zd0X KQ== Received: from aserv0021.oracle.com (aserv0021.oracle.com [141.146.126.233]) by aserp2130.oracle.com with ESMTP id 2ptj3drmnh-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 07 Jan 2019 22:29:59 +0000 Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by aserv0021.oracle.com (8.14.4/8.14.4) with ESMTP id x07MTvh8018027 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 7 Jan 2019 22:29:58 GMT Received: from abhmp0013.oracle.com (abhmp0013.oracle.com [141.146.116.19]) by userv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x07MTuRM004763; Mon, 7 Jan 2019 22:29:57 GMT Received: from ban25x6uut28.us.oracle.com (/10.153.73.28) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 07 Jan 2019 14:29:56 -0800 From: Venu Busireddy To: venu.busireddy@oracle.com, "Michael S. Tsirkin" , Marcel Apfelbaum Date: Mon, 7 Jan 2019 17:29:39 -0500 Message-Id: <1546900184-27403-1-git-send-email-venu.busireddy@oracle.com> X-Mailer: git-send-email 1.8.3.1 X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9129 signatures=668680 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=803 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1901070183 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 141.146.126.79 Subject: [Qemu-devel] [PATCH v3 0/5] Support for datapath switching during live migration 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 Implement the infrastructure to support datapath switching during live migration involving SR-IOV devices. 1. This patch is based off on the current VIRTIO_NET_F_STANDBY feature bit and MAC address device pairing. 2. This set of events will be consumed by userspace management software to orchestrate all the hot plug and datapath switching activities. This scheme has the least QEMU modifications while allowing userspace software to build its own intelligence to control the whole process of SR-IOV live migration. 3. While the hidden device model (viz. coupled device model) is still being explored for automatic hot plugging (QEMU) and automatic datapath switching (host-kernel), this series provides a supplemental set of interfaces if management software wants to drive the SR-IOV live migration on its own. It should not conflict with the hidden device model but just offers simplicity of implementation. Si-Wei Liu (2): vfio-pci: Add FAILOVER_PRIMARY_CHANGED event to shorten downtime during failover pci: query command extension to check the bus master enabling status of the failover-primary device Sridhar Samudrala (1): virtio_net: Add VIRTIO_NET_F_STANDBY feature bit. Venu Busireddy (2): virtio_net: Add support for "Data Path Switching" during Live Migration. virtio_net: Add a query command for FAILOVER_STANDBY_CHANGED event. --- Changes in v3: Fix issues with coding style in patch 3/5. Changes in v2: Added a query command for FAILOVER_STANDBY_CHANGED event. Added a query command for FAILOVER_PRIMARY_CHANGED event. hmp.c | 5 +++ hw/acpi/pcihp.c | 27 +++++++++++ hw/net/virtio-net.c | 42 +++++++++++++++++ hw/pci/pci.c | 5 +++ hw/vfio/pci.c | 60 +++++++++++++++++++++++++ hw/vfio/pci.h | 1 + include/hw/pci/pci.h | 1 + include/hw/virtio/virtio-net.h | 1 + include/net/net.h | 2 + net/net.c | 61 +++++++++++++++++++++++++ qapi/misc.json | 5 ++- qapi/net.json | 100 +++++++++++++++++++++++++++++++++++++++++ 12 files changed, 309 insertions(+), 1 deletion(-)