Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp3009011rdb; Tue, 12 Sep 2023 21:32:05 -0700 (PDT) X-Google-Smtp-Source: AGHT+IF96vQmFrkAhtD1pr0Z2/tvoM3UsP9sI9GMB53bhXEzHyMpJ7Ejq5zZr9h9COTlznGRFNyV X-Received: by 2002:a17:902:f68e:b0:1b8:8682:62fb with SMTP id l14-20020a170902f68e00b001b8868262fbmr5881093plg.4.1694579524880; Tue, 12 Sep 2023 21:32:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694579524; cv=none; d=google.com; s=arc-20160816; b=x4EpIxE+nrec3zYdtt2wne52Kp2Cnk3Tjt8w0uv4Za5vvb59kXp+urdWl4iwRDKRB6 jH2XgqbVJ38FbyVpE0X31Zz5l7OWD1r1HKh8pxpCEdaGIHsLXqGjWotSzLiLJkDmpDjp SDB+aAJEVIg7iT2aXm1qINpyrvUFs3l6XqEgrPFhfLVCgUtkcQPNAks6kOM3gEYC/ZsX /uZIaIse1UyyyafUZdiKjN4MW4O6E20sGpHsdWc5liE/6RMGIbwlkeBXLfbopfsXB8iP AOZ9oF7gJHxxoJkZJn2BorMZUyXEAHKdnpseGxLa2u4ZxyDmvGRLdQqS1BSsVSl0RTeM dsmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=5NRCL/xSBSuFgu7em92vBs1igQbTUxJIfZeUuKm3Sk4=; fh=sqHW1rYw/TkmPJTWC3cNbNdFIQDFTtai2RwbxgaKqto=; b=mWkYQBlHW0025vosUHZB9ZRlR3m/veWcI4xVYw79+ETwqceUm41r2eKck5nSfZdZAe glu23mHWdQFQL0CpXdWxuiV8anLtR/8E04CwzmKlCLSfZOhsRul1AZJ3OAi0hUPT0spy PkE0+xW992fQYM4MExiDMiv5RMOOItYcJa4t+57th4rJo0WjUAuxVtqe0HGhCMcpuKfp BHOQceNjH0PeVMdwvuaJQ8pTqBl4EoHvvlW5QFc+oiAkGpU4zPja4cPn8rPyIx1tP8Rb J/otZMchw0kZ8lHVjXgZR+uOKrb2uo02jdb/lbwg4FfbQGaemUUV8snJ3MIl1ojh+TGP oRBQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=GfiKv1aA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 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 morse.vger.email (morse.vger.email. [2620:137:e000::3:1]) by mx.google.com with ESMTPS id n184-20020a6340c1000000b00573fc6de956si9357532pga.223.2023.09.12.21.32.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Sep 2023 21:32:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) client-ip=2620:137:e000::3:1; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=GfiKv1aA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 95F22822A497; Tue, 12 Sep 2023 18:04:50 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238015AbjIMBEp (ORCPT + 99 others); Tue, 12 Sep 2023 21:04:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36390 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229553AbjIMBEn (ORCPT ); Tue, 12 Sep 2023 21:04:43 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 27D66170F for ; Tue, 12 Sep 2023 18:03:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1694567037; 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=5NRCL/xSBSuFgu7em92vBs1igQbTUxJIfZeUuKm3Sk4=; b=GfiKv1aA08ZSqE04kut1kzsKfbo2yb8jH+C67gtFIiMq5E3WoovezaxNjVtNbcppFdJ0Ej HWHEWDzRAIP6N0Id1iPV2jpaJpMZ+bj2X0Xcw+AooHxHvI/KL9djIznL2aq2M+cCvFGY83 vB1EXznlMehB7L/+YcxrqoHBIzIJnbo= Received: from mail-ed1-f71.google.com (mail-ed1-f71.google.com [209.85.208.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-141-72MN-FBMM3u58Za3l1QFSQ-1; Tue, 12 Sep 2023 21:03:54 -0400 X-MC-Unique: 72MN-FBMM3u58Za3l1QFSQ-1 Received: by mail-ed1-f71.google.com with SMTP id 4fb4d7f45d1cf-52a06f5f4e2so4116087a12.2 for ; Tue, 12 Sep 2023 18:03:53 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694567032; x=1695171832; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=5NRCL/xSBSuFgu7em92vBs1igQbTUxJIfZeUuKm3Sk4=; b=xJfi5tMghT5phxZh7eljxD4krzbjpTrNgY6TyhraJUPDBg6K5NUVMb8B2pDeUeacYm 1Rg+rLxYrbnnYOhhST/sH7Wu761Iz6zLCUEsv9k8W+4YJECDIhhHuxa2bISUIsVrG6TO Fis+0vUYUbPT2I34esNb2CHYMZPmIapzp9DGX9lQ/j4Foh14AUpXamBWsztXVmVTtANq oek5WtQ9w8dDHXEO1NlXnuofsE0O9WWwWWeMOP6rHqK8/baUlYuW71Y8pVDC9UgltHef cvv3GY1vyfjNwTx11HS19Yxktj2IzsXY497RuhHNqSI95Euamx5AYHihoMXztDX1kdDS cFBA== X-Gm-Message-State: AOJu0YwRIxhDQT3KMj9gI/1Jet+gcVVuBtai376cFKKFkRyxmFbyQ4SD Co5CBlfuLS6YcrzvK9WnJLAIqpaujyel8vgDWQzMCoHaCQws8beETw1XOF4Wmi0EK29TLtastda 63I10q2TWg/FS3OW50tjnWEcKtcwbvkoJVKQxcBkf X-Received: by 2002:aa7:c50b:0:b0:523:cc3d:9121 with SMTP id o11-20020aa7c50b000000b00523cc3d9121mr857279edq.14.1694567032759; Tue, 12 Sep 2023 18:03:52 -0700 (PDT) X-Received: by 2002:aa7:c50b:0:b0:523:cc3d:9121 with SMTP id o11-20020aa7c50b000000b00523cc3d9121mr857267edq.14.1694567032457; Tue, 12 Sep 2023 18:03:52 -0700 (PDT) MIME-Version: 1.0 References: <20230912130132.561193-1-dtatulea@nvidia.com> In-Reply-To: <20230912130132.561193-1-dtatulea@nvidia.com> From: Lei Yang Date: Wed, 13 Sep 2023 09:03:15 +0800 Message-ID: Subject: Re: [PATCH 00/16] vdpa: Add support for vq descriptor mappings To: Dragos Tatulea , =?UTF-8?Q?Eugenio_P=C3=A9rez?= , Si-Wei Liu Cc: Jason Wang , "Michael S . Tsirkin" , Saeed Mahameed , virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Parav Pandit , Xuan Zhuo , kvm@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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 (morse.vger.email [0.0.0.0]); Tue, 12 Sep 2023 18:04:50 -0700 (PDT) X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Hi Dragos, Eugenio and Si-Wei My name is Lei Yang, a software Quality Engineer from Red Hat. And always paying attention to improving the live migration downtime issues because there are others QE asked about this problem when I share live migration status recently. Therefore I would like to test it in my environment. Before the testing I want to know if there is an expectation of downtime range based on this series of patches? In addition, QE also can help do a regression test based on this series of patches if there is a requirement. Regards and thanks Lei On Tue, Sep 12, 2023 at 9:04=E2=80=AFPM Dragos Tatulea wrote: > > This patch series adds support for vq descriptor table mappings which > are used to improve vdpa live migration downtime. The improvement comes > from using smaller mappings which take less time to create and destroy > in hw. > > The first part adds the vdpa core changes from Si-Wei [0]. > > The second part adds support in mlx5_vdpa: > - Refactor the mr code to be able to cleanly add descriptor mappings. > - Add hardware descriptor mr support. > - Properly update iotlb for cvq during ASID switch. > > [0] https://lore.kernel.org/virtualization/1694248959-13369-1-git-send-em= ail-si-wei.liu@oracle.com > > Dragos Tatulea (13): > vdpa/mlx5: Create helper function for dma mappings > vdpa/mlx5: Decouple cvq iotlb handling from hw mapping code > vdpa/mlx5: Take cvq iotlb lock during refresh > vdpa/mlx5: Collapse "dvq" mr add/delete functions > vdpa/mlx5: Rename mr destroy functions > vdpa/mlx5: Allow creation/deletion of any given mr struct > vdpa/mlx5: Move mr mutex out of mr struct > vdpa/mlx5: Improve mr update flow > vdpa/mlx5: Introduce mr for vq descriptor > vdpa/mlx5: Enable hw support for vq descriptor mapping > vdpa/mlx5: Make iotlb helper functions more generic > vdpa/mlx5: Update cvq iotlb mapping on ASID change > Cover letter: vdpa/mlx5: Add support for vq descriptor mappings > > Si-Wei Liu (3): > vdpa: introduce dedicated descriptor group for virtqueue > vhost-vdpa: introduce descriptor group backend feature > vhost-vdpa: uAPI to get dedicated descriptor group id > > drivers/vdpa/mlx5/core/mlx5_vdpa.h | 31 +++-- > drivers/vdpa/mlx5/core/mr.c | 191 ++++++++++++++++------------- > drivers/vdpa/mlx5/core/resources.c | 6 +- > drivers/vdpa/mlx5/net/mlx5_vnet.c | 100 ++++++++++----- > drivers/vhost/vdpa.c | 27 ++++ > include/linux/mlx5/mlx5_ifc.h | 8 +- > include/linux/mlx5/mlx5_ifc_vdpa.h | 7 +- > include/linux/vdpa.h | 11 ++ > include/uapi/linux/vhost.h | 8 ++ > include/uapi/linux/vhost_types.h | 5 + > 10 files changed, 264 insertions(+), 130 deletions(-) > > -- > 2.41.0 >