Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp8924784rwr; Thu, 11 May 2023 07:54:20 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ55h8JYDeVVUhAKtox5U/KkBjkS9VbdxQQZZTaR4Ym89gnwQR2msyP24bxAk1vCcYE2lMl6 X-Received: by 2002:a05:6a20:914e:b0:103:fa64:d385 with SMTP id x14-20020a056a20914e00b00103fa64d385mr2038722pzc.28.1683816859257; Thu, 11 May 2023 07:54:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683816859; cv=none; d=google.com; s=arc-20160816; b=uAnJjaVA2GtGDhtcIea6m2Sz7/8qmKA+CQ9yVF79JhGwYt8XbIbKAcyV5HwnRV4tA1 ks7NmLZEGMSCqOkJ2ivcMGjWyKoSK/tII1ndp2coPRQ8dL44ND1B2iJ4cU9CFghCL665 pF3C1Q8hu8asMTpekZVXEwFE0wt6TcKUz0fYFWTjWb+7swEYRXIi+BNRj328EgZW4el8 sGsDInKXJy7AeUZSehUBv7vBquISESdNSX03c7amAeH/AWgL4vgKo4j0kZNmdal66M/1 Snvg9/SoFTvpMBQbzxdapjBlbhzYVEke4646cNv4DEzqoDPZIQ9TYjh76L/s6/Zc7RJA T8Xw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:message-id:content-transfer-encoding :mime-version:subject:date:from:dkim-signature; bh=a6efHQHLQxEubBvjLohvdnj0cPIhWRyQMCXQg5mLb0I=; b=IZzxZJAf4qcnjWn/6Akx2j3zwxo/Rt35GA59Dk0bxL/FgPuNkMdMq9OptGXBvNgzXn xc7zkrytCqo76updk0lcEZn/CtumKea0amVW6js0str00QYniXZGiJhehMWyty1e7Ig1 4BXyAv7qcU2vlo4jRBbZl7cf7kZvx/EPX6skp6QN93ywWkCe2b1tC8E08ZkDmET2Ys0g cBRAuRLgZrdiKhuSmjEQGtuZsKFkS8+I74nIyI2FtXMjvR7vVuHatJHEIEcY5IoQLmfz q4xeKCgG17OAQEJCmxw+lyvPkqY3LP5DLYEGp1lUEGmnqIWhabTBQaQmBSjuxPfx2kMv f+6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=MCZIDs9F; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v22-20020a637a16000000b0052c44389455si7184184pgc.781.2023.05.11.07.54.07; Thu, 11 May 2023 07:54: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; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=MCZIDs9F; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238335AbjEKOtV (ORCPT + 99 others); Thu, 11 May 2023 10:49:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42328 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238368AbjEKOtF (ORCPT ); Thu, 11 May 2023 10:49:05 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D4AC51436A for ; Thu, 11 May 2023 07:47:05 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 2032464E42 for ; Thu, 11 May 2023 14:46:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5CE80C433EF; Thu, 11 May 2023 14:46:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1683816390; bh=+9uPDOuex5Pk0HKKJGTnib7+gzd+5ickAG9rMoNd+Qk=; h=From:Date:Subject:To:Cc:From; b=MCZIDs9FBojHg/rSBxXqFvBvIiz+6UakOAWbRCwfL9kByAs8wqRca6vRMdu5Y7yNJ PzsmJ7g5F7zkMlPZK8BEFaoNoCvTLdJ6TEOskyfz8tNitbT5JIv40R89gTDHyp1BuH Hww0EbkHYID+hE9L5YOnoOeFh66UALb20QPz4vgTuUnDyFn59tymrXdwQKIpHEUPaQ dnc48UvmnuxKJkaxE5RQdaNSmg+h94FYfP2NEhKe84f0hMfkJWQthIS1lwJg+2PxwE csWhOdFI0kroXCjvYK0c/6jzqOqKpK4RTlM3xr8G0Hq5KBSTrwlm8gAnoMKzIx8ixc mntexLsIAHjQw== From: Simon Horman Date: Thu, 11 May 2023 16:46:22 +0200 Subject: [PATCH v2] virtio: Add missing documentation for structure fields MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20230510-virtio-kdoc-v2-1-1c5a20eb4cfe@kernel.org> X-B4-Tracking: v=1; b=H4sIAL3/XGQC/22Nyw6CMBBFf4V07Zi2KA9X/odh0dIBJpDWTLHRE P7dytrlOcm9ZxMRmTCKW7EJxkSRgs+gT4XoJ+NHBHKZhZa6lFclIRGvFGB2oQfXVhU29VCXEkV eWBMRLBvfT3njX8uS5ZNxoPeReHSZJ4pr4M9RTOpn/58nBQqctqrRF9Mabe8zssflHHgU3b7vX 75fMWW8AAAA To: "Michael S. Tsirkin" , Jason Wang , Xuan Zhuo Cc: virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Simon Horman X-Mailer: b4 0.12.2 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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 Add missing documentation for the vqs_list_lock field of struct virtio_device, and the validate field of struct virtio_driver. ./scripts/kernel-doc says: .../virtio.h:131: warning: Function parameter or member 'vqs_list_lock' not described in 'virtio_device' .../virtio.h:192: warning: Function parameter or member 'validate' not described in 'virtio_driver' 2 warnings as Errors No functional changes intended. Signed-off-by: Simon Horman --- Changes in v2: - As suggested by Michael S. Tsirkin + @validate is not called on probe + @validate does validates config space + embarrassingly, validate was misspelt - Link to v1: https://lore.kernel.org/r/20230510-virtio-kdoc-v1-1-d2b1824a9a2b@kernel.org --- include/linux/virtio.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/virtio.h b/include/linux/virtio.h index b93238db94e3..3abe8e9c8090 100644 --- a/include/linux/virtio.h +++ b/include/linux/virtio.h @@ -103,6 +103,7 @@ int virtqueue_resize(struct virtqueue *vq, u32 num, * @config_enabled: configuration change reporting enabled * @config_change_pending: configuration change reported while disabled * @config_lock: protects configuration change reporting + * @vqs_list_lock: protects @vqs. * @dev: underlying device. * @id: the device type identification (used to match it with a driver). * @config: the configuration ops for this device. @@ -160,6 +161,7 @@ size_t virtio_max_dma_size(const struct virtio_device *vdev); * @feature_table_size: number of entries in the feature table array. * @feature_table_legacy: same as feature_table but when working in legacy mode. * @feature_table_size_legacy: number of entries in feature table legacy array. + * @validate: the function to call to validate features and config space * @probe: the function to call when a device is found. Returns 0 or -errno. * @scan: optional function to call after successful probe; intended * for virtio-scsi to invoke a scan.