Received: by 2002:a89:48b:0:b0:1f5:f2ab:c469 with SMTP id a11csp282679lqd; Wed, 24 Apr 2024 02:02:37 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCU70+jymAdXgO1Bodk0SFgLYXvEpJ38o/uO87yqRukmEcY4NPyAS+T9r1T2Hj/4cmnhbAQ6OwxXHWQlAd4u4UvNMD8Jr9R5PEtTvOtLeQ== X-Google-Smtp-Source: AGHT+IEkvV1ZpZVNL5ulo6+Tz0/WlpA8C/o3fdLeNhmLBwWat4jF10HaTlFxWUSSrS33z5lKRweG X-Received: by 2002:a05:6214:2cd6:b0:6a0:7ddf:4004 with SMTP id lf22-20020a0562142cd600b006a07ddf4004mr1692483qvb.54.1713949357605; Wed, 24 Apr 2024 02:02:37 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713949357; cv=pass; d=google.com; s=arc-20160816; b=FgJWyYxZIQkdP92d6l4s+xuQ2KeBTd4Y/j2Nd/yfB0opOPMuAspwGmipSiEVP2j48I ysyEOTA5/vRGiIeq/arjvKuuWEVrXxEm+3mbKXCh1+E7VhpV1LIV0Oqol1cnfYl/apCK 8oPnGlSsQ3UqaFKn31oZHJlRWhpYB9f3vBeealGwYZKrFBr3PFniEAnpFbLSyJIl8VMH LzvcS4YBYMpVptqAHp/Sx21mRv/7LAZCTsvrgVvGw9Id3rmve9PsDeJ1jQwZsTD38bsI iMpH2tXbZZYEfzQq2qJk+HujnMWBa9OxtG3XOmIfe9XYA6M+J818M4zRHGSi1umo2WdD izwg== 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=iUDhDL/iIQ9uPlqyHuue5vlX2QLtSFvz03R1bFkBWdo=; fh=lW6MHi1ma+bdiE1he+iHyx9lPKntUb1s0946rN3rfJM=; b=A3CvtreG2qGIOnbVhLsj/beAZpnUPEfVIjP6K7jFgV8566AcPARYY3wRVIiZYTpo/x OPBTbsVTKddR8071mjOmJ8vWNqeyo2PGl7mPdPpsvmiEF7horJmWFaJ22ss8VOhk9MZz tz7ukkVjPi6Y6EXfTZxDsTHBYMpxiAeCo5i0cCfefuC/Z+g+kzKdlU7/WbftsT9bSgqS XPYqhz8vMFK5j3s3Rxb6ShPEU9RTJF0caJHLc53hwcarO/w239YVMIGfkK4W3OZTwFGC /zI6S13buGsRPYkqEiry0DnjbumKfpAWjr72/nbz78Y3gBhjfQwfeIwA0YXW9vAutPvR 3Mig==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-156587-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-156587-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id kk11-20020a056214508b00b0069b55bf1143si14385466qvb.240.2024.04.24.02.02.37 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Apr 2024 02:02:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-156587-linux.lists.archive=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=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-156587-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-156587-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.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 14C8F1C22B02 for ; Wed, 24 Apr 2024 09:02:37 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AA2DA158A36; Wed, 24 Apr 2024 09:02:27 +0000 (UTC) Received: from szxga05-in.huawei.com (szxga05-in.huawei.com [45.249.212.191]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2AE2A13A406; Wed, 24 Apr 2024 09:02:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.191 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713949347; cv=none; b=gVLJCXl7KIKa6YUVTmJPwobjl60j0rASpemWNfdiqlCHRVzMdXbXZUYiRnVo3XA8lebkxEM32h74g8s7UjI53wTlwqCjQumVq4v8G4yjXs78BIwHq6Luok6ReHm6GhcMGyuzzmp22VM7Vk6LplYUB02cOslxXlXywctF7nUDaGg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713949347; c=relaxed/simple; bh=yXFWoaQSid27j0ihrlBykIrBmnzl4uQX7jpdIxXuzkk=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=NH43mAKOJtMLXfAT0iU3HH7QP80M3yoHZqo6AifzETaMT1idMA+Rv0CZhe229C7Llk777QbZAqQ1RnClbSA/GILxrlvdWLUOprPdutuRARQaG2oqQJ8GwITb1u5bPtJCa9Bdkcj6NvOuw4lGr+vkHnHbUMr0Uh240h/ttG8BfN4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=45.249.212.191 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.19.162.112]) by szxga05-in.huawei.com (SkyGuard) with ESMTP id 4VPXwj6v6Pz1j0sK; Wed, 24 Apr 2024 16:59:17 +0800 (CST) Received: from kwepemm600005.china.huawei.com (unknown [7.193.23.191]) by mail.maildlp.com (Postfix) with ESMTPS id EC57E14040D; Wed, 24 Apr 2024 17:02:21 +0800 (CST) Received: from huawei.com (10.50.165.33) by kwepemm600005.china.huawei.com (7.193.23.191) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Wed, 24 Apr 2024 17:02:21 +0800 From: Longfang Liu To: , , , CC: , , , Subject: [PATCH v5 0/5] add debugfs to hisilicon migration driver Date: Wed, 24 Apr 2024 16:57:16 +0800 Message-ID: <20240424085721.12760-1-liulongfang@huawei.com> X-Mailer: git-send-email 2.24.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To kwepemm600005.china.huawei.com (7.193.23.191) Add a debugfs function to the hisilicon migration driver in VFIO to provide intermediate state values and data during device migration. When the execution of live migration fails, the user can view the status and data during the migration process separately from the source and the destination, which is convenient for users to analyze and locate problems. Changes v4 -> v5 Adjust the debugfs file directory Changes v3 -> v4 Rebased on kernel6.9 Changes v2 -> v3 Solve debugfs serialization problem. Changes v1 -> v2 Solve the racy problem of io_base. Longfang Liu (5): hisi_acc_vfio_pci: extract public functions for container_of hisi_acc_vfio_pci: modify the register location of the XQC address hisi_acc_vfio_pci: create subfunction for data reading hisi_acc_vfio_pci: register debugfs for hisilicon migration driver Documentation: add debugfs description for hisi migration .../ABI/testing/debugfs-hisi-migration | 27 ++ MAINTAINERS | 1 + .../vfio/pci/hisilicon/hisi_acc_vfio_pci.c | 302 ++++++++++++++++-- .../vfio/pci/hisilicon/hisi_acc_vfio_pci.h | 10 + 4 files changed, 308 insertions(+), 32 deletions(-) create mode 100644 Documentation/ABI/testing/debugfs-hisi-migration -- 2.24.0