Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3385160pxv; Sun, 18 Jul 2021 21:25:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwm/AvIryWk0IVqx/YvvYS6sS2t+qhdW9Jtq7Uxg57C97zAzgKNVnOux0vGmMLwDN3yi8st X-Received: by 2002:a02:7348:: with SMTP id a8mr19780128jae.116.1626668723484; Sun, 18 Jul 2021 21:25:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626668723; cv=none; d=google.com; s=arc-20160816; b=bjBUzKW2ms3hasR/i9taawOVFO34EdFypce7dYaL0IBUI0RvQVtgX39oBMxa+DbqSQ /mEoy1wdMUkXtC55LaKQF+sUqnM+yPpO5fGjkLb+5vD6cXN8wuSkZ5Gb9MKp/ZHh/+bi qIiKZ1btqpwyLMs90Wp+7Qx4PvyNw9CBuABm+BBlfGMRNgjzHo9ICfMNbph70C1/EtkJ 3VNRkOyIfiv7BQ7+OpbnaGBYZifLZs7eC4kReiWctw7Vvp743w0Dd+Ldzyt8E05zRuAz MxL2pqtQkk9hAcmWUv/FbI9+9NYso9Y8QV/ULzV28IDZwVORFFON9+n5p/Rh38tQwhgA eRIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :subject; bh=HB/kTP8u1gf2djNXjGbB5HIY4YwDh0KjmcjKFay7ebU=; b=A7HLGhWDDQWtRJ8urNueyziEYvJJYQmKbN37XyWjkXrL1qkpTXcoCj3aC8h3M+QC0O 4c4kV1CL1I1iU/8EWptrsf96zWfrYBBa61ThgW/KK8dNr6fE+a44AbcXaa93xQuPSIuL 8wLy4U0tBGpfp+lqYZ7O207a9D9yG1X9KwQH62MJ1emN+d5mx3L58Liqo1UgWh08G5zv pD9o6dfr0Qc6i8l/XJjApwa6xa318PmOi+r5UWRTEqG6ufjd/sVPB5f4ZSgAUtob8x6Y KPVj1vf76SKfwr0BwmkukyO4BrhE39rRbDkqihdHCJ46NptvPpptW8GDtNAkOSKc2dK0 Wl9A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i16si5907304jam.109.2021.07.18.21.24.47; Sun, 18 Jul 2021 21:25:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229764AbhGSEZq (ORCPT + 99 others); Mon, 19 Jul 2021 00:25:46 -0400 Received: from out4436.biz.mail.alibaba.com ([47.88.44.36]:27312 "EHLO out4436.biz.mail.alibaba.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229512AbhGSEZp (ORCPT ); Mon, 19 Jul 2021 00:25:45 -0400 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R771e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04395;MF=xianting.tian@linux.alibaba.com;NM=1;PH=DS;RN=6;SR=0;TI=SMTPD_---0UgB0hYy_1626668564; Received: from B-LB6YLVDL-0141.local(mailfrom:xianting.tian@linux.alibaba.com fp:SMTPD_---0UgB0hYy_1626668564) by smtp.aliyun-inc.com(127.0.0.1); Mon, 19 Jul 2021 12:22:45 +0800 Subject: Re: [PATCH] virtio-balloon: Use virtio_find_vqs() helper To: Jason Wang , Xianting Tian , mst@redhat.com, david@redhat.com Cc: virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org References: <1626190724-7942-1-git-send-email-xianting_tian@126.com> From: tianxianting Message-ID: Date: Mon, 19 Jul 2021 12:22:44 +0800 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org thanks, I checked, actually all virtio drivers have switched to use the helper after this one merged. 在 2021/7/19 上午11:46, Jason Wang 写道: > > 在 2021/7/16 下午8:46, tianxianting 写道: >> Do you interest in this patch? just little improvment:) >> >> 在 2021/7/13 下午11:38, Xianting Tian 写道: >>> From: Xianting Tian >>> >>> Use the helper virtio_find_vqs(). >>> >>> Signed-off-by: Xianting Tian >>> --- >>>   drivers/virtio/virtio_balloon.c | 4 ++-- >>>   1 file changed, 2 insertions(+), 2 deletions(-) >>> >>> diff --git a/drivers/virtio/virtio_balloon.c >>> b/drivers/virtio/virtio_balloon.c >>> index 510e931..18e0bf3 100644 >>> --- a/drivers/virtio/virtio_balloon.c >>> +++ b/drivers/virtio/virtio_balloon.c >>> @@ -531,8 +531,8 @@ static int init_vqs(struct virtio_balloon *vb) >>>           callbacks[VIRTIO_BALLOON_VQ_REPORTING] = balloon_ack; >>>       } >>>   -    err = vb->vdev->config->find_vqs(vb->vdev, >>> VIRTIO_BALLOON_VQ_MAX, >>> -                     vqs, callbacks, names, NULL, NULL); >>> +    err = virtio_find_vqs(vb->vdev, VIRTIO_BALLOON_VQ_MAX, vqs, >>> +                callbacks, names, NULL); >>>       if (err) >>>           return err; >> > > Acked-by: Jason Wang > > Maybe it's better to convert all the drivers that doesn't use > virtio_find_vqs{_ctx}. > > Thanks