Received: by 2002:ad5:4acb:0:0:0:0:0 with SMTP id n11csp3198187imw; Wed, 6 Jul 2022 20:01:20 -0700 (PDT) X-Google-Smtp-Source: AGRyM1srKkXm/3yS7KAbf4/QCzAVHL63YsuZkyUaITwnS0FTtM4bCYP7SzF9B0NmqedqVja2WyiJ X-Received: by 2002:a17:90b:3b52:b0:1ec:db2a:b946 with SMTP id ot18-20020a17090b3b5200b001ecdb2ab946mr2256782pjb.229.1657162879813; Wed, 06 Jul 2022 20:01:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1657162879; cv=none; d=google.com; s=arc-20160816; b=HD9fEalhIQRf58tUW62bvLWIxpw3JG+yoy9pSbkmT1dbjMF5tPRohXQJiOnT/RbasP r8grEj4Zv6dMGsFwK5mL4U2gX5l+xq7WHDklaS9T8fWpPs4AS4Id8Gz74wkuFOeONCx4 C1BYIsTKgA1iFt//PLx3k5bSEEgdddFFtaf5JotFJxF5sI0nZq7M0b1ZUbwuzMO0vClb cb0mcJsFMPpHZu6EU73lHIWd4TKT+kN3HL6Ayxd62IDPz3lbIVbuW38z30fnwzGirmVo v7Uoj9V9B0GTAon/ncMyqnJP4aKBh+OtjE1MyaTWjTgsATtb2cPpxlzChI/DlEOBc4Au ejgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=yq0EkLKhEOTgGtasBlcR5a8TrpGiXe/BZ7GVLnIRb5w=; b=lN3VsrElW0pf4Nr+xFhYoNoAoLBZ1pxA1RPX7jt7pZQw7rRpXPUSiSwjdqoH0veO+7 39oeZYlAKqPigxFRG/QL0JonUsXFJLcBWpPY+EqFeQyUlT7rk7cbWVWifIFxyMCzduep 7Mn5GcEvfWME0/rj2kLXqK0Z+mGZxc+CY6pqkkrXQwo4xDBZ36KfOR71kmfhbkOFIsGF uV/Bt0XcPA0UyNL6+Cqknxj0W5RVGtMYNgojk1r4q7XwVh56a9Hw3EjIA9eyI9eAYp2O 7OtdDtIIhFd19QtJqkD+5Z6NDioN86tFaYmSP0dhHemJEmmVQMg4Q2w82A5qkrD8cpAW nBDw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id z19-20020a1709028f9300b0016bef83c3e1si10193493plo.611.2022.07.06.20.01.01; Wed, 06 Jul 2022 20:01:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234842AbiGGDAF (ORCPT + 99 others); Wed, 6 Jul 2022 23:00:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60322 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231829AbiGGDAD (ORCPT ); Wed, 6 Jul 2022 23:00:03 -0400 Received: from smtp236.sjtu.edu.cn (smtp236.sjtu.edu.cn [202.120.2.236]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AEDAE2F3BF for ; Wed, 6 Jul 2022 20:00:02 -0700 (PDT) Received: from proxy02.sjtu.edu.cn (smtp188.sjtu.edu.cn [202.120.2.188]) by smtp236.sjtu.edu.cn (Postfix) with ESMTPS id 3FBB71008B38F; Thu, 7 Jul 2022 10:44:20 +0800 (CST) Received: from localhost (localhost.localdomain [127.0.0.1]) by proxy02.sjtu.edu.cn (Postfix) with ESMTP id 16CB6200C91EC; Thu, 7 Jul 2022 10:44:20 +0800 (CST) X-Virus-Scanned: amavisd-new at Received: from proxy02.sjtu.edu.cn ([127.0.0.1]) by localhost (proxy02.sjtu.edu.cn [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id t861SywAjMia; Thu, 7 Jul 2022 10:44:20 +0800 (CST) Received: from localhost.localdomain (unknown [202.120.40.82]) (Authenticated sender: qtxuning1999@sjtu.edu.cn) by proxy02.sjtu.edu.cn (Postfix) with ESMTPSA id 1B47E200A5BFF; Thu, 7 Jul 2022 10:44:10 +0800 (CST) From: Guo Zhi To: jasowang@redhat.com, mst@redhat.com Cc: eperezma@redhat.com, virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org, sgarzare@redhat.com, Guo Zhi Subject: [PATCH v2 0/4] virtio/virtio_test Date: Thu, 7 Jul 2022 10:44:05 +0800 Message-Id: <20220707024409.1869-1-qtxuning1999@sjtu.edu.cn> X-Mailer: git-send-email 2.17.1 X-Spam-Status: No, score=-0.4 required=5.0 tests=BAYES_00,RCVD_IN_SORBS_WEB, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Original virtio_test only use add one descriptor for each io event, thus code of descriptor chain and indirection have not been tested(one descriptor will not use indirect feature even indirect feature has been specified). In fact it would have not been possible for vhost_test to access to the indirect descriptor table, because it's impossible for virtio_ring.c to allocate it. This series using descriptor chain and enable indirection feature. And through gcov we find the code coverage has been improved(not high for virtio_ring.c because virtio_test only test split virtqueue): +------------+-------------+-------------+ | |virtio_test.c|virtio_ring.c| +------------+-------------+-------------+ | original | 72.32% | 24.71% | +------------+-------------+-------------+ | current | 75% | 28.05% | +------------+-------------+-------------+ Guo Zhi (4): virtio_test: kick vhost for a batch of descriptors virtio_test: move magic number in code as defined constant virtio_test: use random length scatterlists to test descriptor chain virtio_test: enable indirection feature tools/virtio/virtio_test.c | 86 ++++++++++++++++++++++++++++---------- 1 file changed, 64 insertions(+), 22 deletions(-) -- 2.17.1