Received: by 2002:a05:7412:ba23:b0:fa:4c10:6cad with SMTP id jp35csp1704597rdb; Sat, 20 Jan 2024 09:34:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IEMI8pSRJCcZgjMSIVfbd0k7nN6OL06Jucu8VsVDMl1op8qRamuVxwpkqe8ud1JhhZrikhs X-Received: by 2002:a05:6a20:d807:b0:19b:4ac9:33c2 with SMTP id iv7-20020a056a20d80700b0019b4ac933c2mr2274964pzb.44.1705772045437; Sat, 20 Jan 2024 09:34:05 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1705772045; cv=pass; d=google.com; s=arc-20160816; b=jIbA/QCcKnuozIOVqjFSKgcDKN6rUUHAw4APF/QCok4RET6zzi8+wQEzebkXo9o8Xo 9jnFViG4QP/Z+GuWVnbuJ07ihYqiFEOkwRn2Pm0SVqMj5l0TFJP27M2JgoQe/nvSh23S BJo3JSKbwAXS+8mXIEVVNB0Tl9ADH/0q87xI4bjqcZpbdSuoXOns/xyb6wXx1JxMNPkL XsI0ymVEpreRz/E3q7yphm086wBfsr+nFQubdTJ/zEkwpXGmTGLVP0YMMbwUWRXkEcE5 fZZaTIZlgyIZhhxSRyfLnY7DsZAs9wXwcIOJ0EzT/PuaqJBj0GSv7m0k0r7Sh2gA59fX zFAw== 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:dkim-signature; bh=1IceXrUeUnICXH6GUBO78e4Wp+ogWdagRYozQ1Kv0X4=; fh=TSebI7ArmbSOuRUXqz6PPnUifsM+Hygi2EOcbqvMUv0=; b=SkXq5uqQkGizYqJGM/wHRguYmsPeDRjvRZsZJKP1TF3jvaU1euwM0S9VGhtRqeBgbT o/5pkGkByYLsuLUdlDgiTsUtOGHcerZcG8bxkX6Q1GPPeLXoVPmDjhXpW4JYbxTOXECs ARCiSzAPgzw4YM5P/QxODVRNS2lZeSd/Z1Kh3J4OcejsS16X/Wg+NXnvv5MH0WCcW7mK zBK9IQ1qu4lDEd7xZnEJ3RZZebH4xZmVs0EB0eYuUJBB2in+AJStPygmYVCYiDPH8OJs tTJthLadfYfOCUYBZ9T1KjviF72DVbeoEMyde47O39KNBSucqBLLZ0QxYO7sw7Sj1hW/ w95A== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="G//6unyP"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-nfs+bounces-1210-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-nfs+bounces-1210-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id y3-20020a056a00180300b006db1136b362si7750179pfa.33.2024.01.20.09.34.05 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 20 Jan 2024 09:34:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-nfs+bounces-1210-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="G//6unyP"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-nfs+bounces-1210-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-nfs+bounces-1210-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org 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 sv.mirrors.kernel.org (Postfix) with ESMTPS id E13BD283237 for ; Sat, 20 Jan 2024 17:34:04 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 36C231095C; Sat, 20 Jan 2024 17:34:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="G//6unyP" X-Original-To: linux-nfs@vger.kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 0C8551094E; Sat, 20 Jan 2024 17:34:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705772043; cv=none; b=PF635nilEe8I/pRV0Jd348IxyhgMG0HnnLalDantI7c9VNQZFFMdcR+pUlOdTH8XFYSMwErc2WfLFC+CqL6U30NDGD8wMR6Z8Oz3+Ntb1RhlvYYsr+Tb0eEmW2pJX7TE6l2OaD+L0+/J1AFbr5HW46DPZT90lSKf2c66ScmsPsA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705772043; c=relaxed/simple; bh=7GgBh/qpAS9IH8JJ4QNVMuDWn+um6pf5lH+Qln2AaEU=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=klr2iQ59r93H05JSZUOnHwnQ7EKwGgLZStibGWqdvfbAWUSlQQ45s9lGOPfpywYPtnSXwDyAaxtpVWLdS1YLV1BRfz4PkQB3pnieT2HZboG0ft+3R/PJE2C9EF9ggDfpKVRV3osIi9125BUuWitwWgcbX04Fty7os3yz/xn8vHA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=G//6unyP; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id DBEEDC433C7; Sat, 20 Jan 2024 17:34:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1705772041; bh=7GgBh/qpAS9IH8JJ4QNVMuDWn+um6pf5lH+Qln2AaEU=; h=From:To:Cc:Subject:Date:From; b=G//6unyP9nLF3/WesvyMFgWyepUiwNRpOvga9Q/ZJiFbiyL6JiZqaDjLRIHJCLMlC MN4Iw2KtwF24Pbxu4vxhKHpY20JkWYe7h9IY2VhVFL3a6aMmB3s9rBQ6sEcPwO1GQX WR3Gq9WbTW1zrSn5DY0TGabxhZnZf9H4AfVrwVrc/q6YeQRO/eyaLDjcaEy/sxxnhV U88wev8aLzWCrAt02Pz7IYLeHAt1oLqvuXy10NY+5QShR2wxL3I7ZVK20RQ0l2v1qc sCYEKtG7+avK3XK9KuOI+Eb1TIk65kWeMZICQl35C7a7gWvTbUr/qX2sHiciyaJtem hXj1QLNFQTn0A== From: Lorenzo Bianconi To: linux-nfs@vger.kernel.org Cc: lorenzo.bianconi@redhat.com, neilb@suse.de, jlayton@kernel.org, kuba@kernel.org, chuck.lever@oracle.com, horms@kernel.org, netdev@vger.kernel.org Subject: [PATCH v6 0/3] convert write_threads, write_version and write_ports to netlink commands Date: Sat, 20 Jan 2024 18:33:29 +0100 Message-ID: X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-nfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Introduce write_threads, write_version and write_ports netlink commands similar to the ones available through the procfs. Changes since v5: - for write_ports and write_version commands, userspace is expected to provide a NFS listeners/supported versions list it want to enable (all the other ports/versions will be disabled). - fix comments - rebase on top of nfsd-next Changes since v4: - rebase on top of nfsd-next tree Changes since v3: - drop write_maxconn and write_maxblksize for the moment - add write_version and write_ports commands Changes since v2: - use u32 to store nthreads in nfsd_nl_threads_set_doit - rename server-attr in control-plane in nfsd.yaml specs Changes since v1: - remove write_v4_end_grace command - add write_maxblksize and write_maxconn netlink commands This patch can be tested with user-space tool reported below: https://github.com/LorenzoBianconi/nfsd-netlink.git Lorenzo Bianconi (3): NFSD: convert write_threads to netlink command NFSD: add write_version to netlink command NFSD: add write_ports to netlink command Documentation/netlink/specs/nfsd.yaml | 94 ++++++ fs/nfsd/netlink.c | 63 ++++ fs/nfsd/netlink.h | 10 + fs/nfsd/nfsctl.c | 396 ++++++++++++++++++++++ include/uapi/linux/nfsd_netlink.h | 44 +++ tools/net/ynl/generated/nfsd-user.c | 460 ++++++++++++++++++++++++++ tools/net/ynl/generated/nfsd-user.h | 155 +++++++++ 7 files changed, 1222 insertions(+) -- 2.43.0