From patchwork Wed Nov 20 08:30:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiale Yang <295107659@qq.com> X-Patchwork-Id: 13880865 Received: from out203-205-221-153.mail.qq.com (out203-205-221-153.mail.qq.com [203.205.221.153]) (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 E16B615B115; Wed, 20 Nov 2024 08:35:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=203.205.221.153 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732091761; cv=none; b=WFZdXqEowwCHbuQNg5BGPVDZEybRT0NBBpnhk8oFO8Cc+/W+ijaNk5xu7s4IVAgAOSDBCyT6hlgG7KCXGJe5oWYpn1MeB5/WSjvqT/q68q+Ln9BJTZEqf8apl/RQv5ZXUWJqQp48JBNayH7YpybcsYzrxqSCygozjqDC/22ZkzU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732091761; c=relaxed/simple; bh=kE6IhiiKo6o/6TfgJ14Z3Ldjqe/ogNLuo3X0pMDSnhg=; h=Message-ID:From:To:Cc:Subject:Date:MIME-Version; b=aH9lKKvfJmlnuYrYX9ViGrV8QaTacl5aYVQJXJDZOPmRwf1QVccciwm2FR18/VkXcMCZikG1iEtuBvAHEUSXclV7ratEIIFvCpeVL/PV9B3xzrJN9SOMxxR8QBIWcl4xZR+IAxKvdErBqTLyjPCv4t3mjpq3NRzpNVHXS9McmEE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=qq.com; spf=pass smtp.mailfrom=qq.com; dkim=pass (1024-bit key) header.d=qq.com header.i=@qq.com header.b=vvcIhFYW; arc=none smtp.client-ip=203.205.221.153 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=qq.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=qq.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=qq.com header.i=@qq.com header.b="vvcIhFYW" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qq.com; s=s201512; t=1732091448; bh=1100kT0Cu7ugv7fQWYJ7fK9SOzVRMf+w+Llm8axcO0s=; h=From:To:Cc:Subject:Date; b=vvcIhFYWrGgUiveP97aqxey4oNspeZAy9knD0AaW/qm3ju6skzh+dYpncQ+2edbCJ Dtp9evCrFW4Ce8dBfbOauTN6A67354muUGbyfWjMfv/gECGL//m1s47nGEXv02JAvI MD87HhDoAWDiovx/f0jhLJKCRoRncuNvEFnfxvYo= Received: from archlinux-sandisk.localdomain ([218.95.110.191]) by newxmesmtplogicsvrsza15-1.qq.com (NewEsmtp) with SMTP id 7AE90E8E; Wed, 20 Nov 2024 16:30:46 +0800 X-QQ-mid: xmsmtpt1732091446td8v84zyq Message-ID: X-QQ-XMAILINFO: M+EmadCGxmHfzpKMgwfERU/P9gwIzfS+JkcQQA9WvFFDvRwVa6KaWXu+o96woa FCLf65PNOyIYgXMuDJUkD1bKHUY1uk0UiXZ99e1SeisHfRVYl09KOzGhg/fgM7wWYlXD/7Ud0Zyr 8cf1ORq3dHRUG5c2z6oImbCDDw3ex4AeEgGq55J471fFFr+fXy9ecGI58U86UQ8zp1bDlEg5+oXo 4kTMLsqpr8tLPJrfCSKgXFSPFmOOCGGuQivUrxdktUdVr4ajnhKTGEGyMmfdjp7CcQ2jIhJAbm41 MiWgZo9J8HTRQvM3s7iCeXPjE7NOHHEZmkxqj5JQm3cEhboxNoY+0zTiPJWEB8/y4Hu2gimmP0hi UdIm2sRPpPV0sbfPXSKmXFWO07Rm2lQMO1Hio8hBSh/Rpe07KEyNJkmD+K3p5RIr/s8cnXBjqwnF CIP1cpRhWqn6BTadIBQStLPGMdbZQe1lVJLavcFXanOaEmO2HIviWQBXvbiodm1z7OodITWTP3u0 TLJG07hSzSkgT8gm9FO0ELpksq6ZqV7NSKJZe4uMnntHa9UU+cGIpNbHBl0qC1jU5xSlG3Skg+ce Yf+xWuXTLXf0cSI9O52aiNZFJFekPPWWvObiRompyh5vuetgbPEJ7NJbJDzo2LdGLKqpTqa5+81l arLTq+NdnjfK3sGfPt5XXbygSM5CrDEA3UapxlrloEO/7EYC2NcNBQ2aQVXwjbPi0f7gYKaj4BJ8 tlg2LBLSid0PRhZ6hK9+HXceCnB+IGEXL2TzhD8hlzeuA0h0Ku6eKzz7K2RpdSt/2pOPc+QvzQ8f yX8FjMGdZePs+OidxY+udMCjrKfCP0yk+07jVLd2sh/nyyVQ41xfMRTSanPePh0uZAdgJtW+9bcS YSCIlKstFJttwoj2hE++zYUqv0WEMjGhPB5Cl6AqeVwLMIx8sSmTRN7iOFEjqJ0eQD8/+CCTrRWq MjzmcaYvk= X-QQ-XMRINFO: Mp0Kj//9VHAxr69bL5MkOOs= From: Jiale Yang <295107659@qq.com> To: miklos@szeredi.hu Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, Jiale Yang <295107659@qq.com> Subject: [PATCH 1/2] fs/fuse: Change 'unsigned's to 'unsigned int's. Date: Wed, 20 Nov 2024 16:30:28 +0800 X-OQ-MSGID: <20241120083029.1944-1-295107659@qq.com> X-Mailer: git-send-email 2.47.0 Precedence: bulk X-Mailing-List: linux-fsdevel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Prefer 'unsigned int' to bare 'unsigned', as reported by checkpatch.pl: WARNING: Prefer 'unsigned int' to bare use of 'unsigned'. Signed-off-by: Jiale Yang <295107659@qq.com> --- fs/fuse/inode.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c index 3ce4f4e81..78d049990 100644 --- a/fs/fuse/inode.c +++ b/fs/fuse/inode.c @@ -37,7 +37,7 @@ static int set_global_limit(const char *val, const struct kernel_param *kp); unsigned int fuse_max_pages_limit = 256; -unsigned max_user_bgreq; +unsigned int max_user_bgreq; module_param_call(max_user_bgreq, set_global_limit, param_get_uint, &max_user_bgreq, 0644); __MODULE_PARM_TYPE(max_user_bgreq, "uint"); @@ -45,7 +45,7 @@ MODULE_PARM_DESC(max_user_bgreq, "Global limit for the maximum number of backgrounded requests an " "unprivileged user can set"); -unsigned max_user_congthresh; +unsigned int max_user_congthresh; module_param_call(max_user_congthresh, set_global_limit, param_get_uint, &max_user_congthresh, 0644); __MODULE_PARM_TYPE(max_user_congthresh, "uint"); @@ -1026,7 +1026,7 @@ struct fuse_conn *fuse_conn_get(struct fuse_conn *fc) } EXPORT_SYMBOL_GPL(fuse_conn_get); -static struct inode *fuse_get_root_inode(struct super_block *sb, unsigned mode) +static struct inode *fuse_get_root_inode(struct super_block *sb, unsigned int mode) { struct fuse_attr attr; memset(&attr, 0, sizeof(attr)); @@ -1201,7 +1201,7 @@ static const struct super_operations fuse_super_operations = { .show_options = fuse_show_options, }; -static void sanitize_global_limit(unsigned *limit) +static void sanitize_global_limit(unsigned int *limit) { /* * The default maximum number of async requests is calculated to consume @@ -1222,7 +1222,7 @@ static int set_global_limit(const char *val, const struct kernel_param *kp) if (rv) return rv; - sanitize_global_limit((unsigned *)kp->arg); + sanitize_global_limit((unsigned int *)kp->arg); return 0; } From patchwork Wed Nov 20 08:40:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiale Yang <295107659@qq.com> X-Patchwork-Id: 13880872 Received: from out162-62-57-252.mail.qq.com (out162-62-57-252.mail.qq.com [162.62.57.252]) (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 0C5208615A; Wed, 20 Nov 2024 08:40:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=162.62.57.252 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732092055; cv=none; b=hONcz1f1nLmd7NSLAq8HFuSj6ufUoBfvnAU4Bws3uVBfpoAypHrBSHba5cEfllk3m/mfj81zn/2pjc1aoTyuH2Ynd0W9gBt1DOJYjp0I0IlJWUDDeyPcWjxdT1Fu5Iz7sg6QJZ684VWC6txRiEdlqmLwkPSgvjRme6i0CymdXrY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1732092055; c=relaxed/simple; bh=Ui3ctbnKKRdOImumJ4A3TJT2obyL1ylkW3xkwgNY7NU=; h=Message-ID:From:To:Cc:Subject:Date:MIME-Version; b=bS5wwl9mgJAMcajPx85QtILu/0b5dH05A3HS0HEnK8rqmnk2MnNVCoXdWi+j9/mzKq8yx8dmFtN32GkkIWdAXcNi2OarmN5NX0r6FvPSlULwjMuwZaagCkEkTFF6ai8yIIc7dE3xirANhWBzZiHMw1kmDdRra5qWl9ehF0dOSq8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=qq.com; spf=pass smtp.mailfrom=qq.com; dkim=pass (1024-bit key) header.d=qq.com header.i=@qq.com header.b=YaRdoGOn; arc=none smtp.client-ip=162.62.57.252 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=qq.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=qq.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=qq.com header.i=@qq.com header.b="YaRdoGOn" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qq.com; s=s201512; t=1732092048; bh=H9Y1oBLqHBrIdDkJYdX6Ga8AnpCl7ourwR5hxF0QsUI=; h=From:To:Cc:Subject:Date; b=YaRdoGOn6TPBsED4jNlVteL4NC1RBTbhiL/8emxQ61nU0tV4YSuiyzKvindvlidKu G+2lrWgzsLFL742Ow9SHjAI0wLsKhfgOhKavaDrrqN6ax/MVAClgDd17IoPoFTNmmJ 1Lh1vEx8+btIBITkFOz70AeFb5lkmdkEIwmgDUO0= Received: from archlinux-sandisk.localdomain ([218.95.110.191]) by newxmesmtplogicsvrszc16-0.qq.com (NewEsmtp) with SMTP id A2EAEE34; Wed, 20 Nov 2024 16:40:46 +0800 X-QQ-mid: xmsmtpt1732092046t0uad8frp Message-ID: X-QQ-XMAILINFO: M9J3/gYsWGfr80NJ+ti6rl1M1uxoROc9GFuJxt/tf5ma6Z6aBW52ok7P6sEgbc QWWXfYWN4IwPgggaZghuhbIKmAFCa7WWISi5H/+HELEwsFambNpcsAz74lC13Z4l5EHUN3fzXSVM /V74K2bJKLM0lSYyFPBnQ9kIc8m68DAclUJe8swuG8fDyKqDRgQOx7f8hHTAbF0p3lRIUduEj3jn YTFnCeTRVf5vdCU67j8xJLjVkb1VA95Xb0Ru8dAz94tXoETLJzYR/S9DoLL2/NTP/de0wI+dG/U8 USML1nY+DKg7Xwc/yXri2hUQXSAYwBqh8iEsN6WBQw7RD7OSYWw7jL4G/9JFEouLWz0Tc5G3OAKY T+4culshWcKIgaAxk35WlksXqbVqkNhCYGQF/bChB9H/D3iLTJQKeuhEy3085mxpwGj2cUprTTfg AWP0CY3xjEUuZPHNZt0zm5A7m7jYrih0tmvlvGHNLjVs2AZIHSNiw4+RVmoCzEBPaPLDLSfarwXG qG5bBt4jSQxu73nfFoPl5oU2rpxH2aClJSGEY0RpfIoxK22sVK8uuR3Ub0HD9jI0VUXMrtuT7Yx7 R1bfmp8fyy3felYU04oQgoGtIBONGlKUKaPYwGOoqPp+bE+GXT3Z8gzHvVquD6+O5IPB0+3DQdY4 M3cEehL6mIt+qQxuD07qI3lKLt1dVtJ6tiLWi8enam46V6Toc9s/sQcbbvKol4qkyBJfONzrU79w hp6pdQPJ0Zz7QHHn5lBDwR1zAKoMwwBSNGNbW0E+bytnAyJa5C0PE+dM5bnn5qVRX/caMuIKCVO4 fmzvYCv4n9yPOXX0JNGZ/TW3Z+FBqshQJhvdCHr4Hq9jhg4F5dF+hhBzdfRN8B1xtRcdQXOxONUr BoYvaaafam4G3MtXS6F0aQEiqFXmFpqM/7z2DrcmbA3rk60GuDModSIYLcAKVsEHwhyVoRkioRM4 Ix7lmM6Pg= X-QQ-XMRINFO: M/715EihBoGSf6IYSX1iLFg= From: Jiale Yang <295107659@qq.com> To: miklos@szeredi.hu Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, Jiale Yang <295107659@qq.com> Subject: [PATCH 2/2] fs/fuse: Keep variables in fuse_i.h consistent with those in inode.c Date: Wed, 20 Nov 2024 16:40:13 +0800 X-OQ-MSGID: <20241120084013.1990-1-295107659@qq.com> X-Mailer: git-send-email 2.47.0 Precedence: bulk X-Mailing-List: linux-fsdevel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 A similar patch to the previous one. Change 'unsigned's to 'unsigned int's, to keep these extern variables consistent with their declarations in inode.c. Signed-off-by: Jiale Yang <295107659@qq.com> --- fs/fuse/fuse_i.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/fuse/fuse_i.h b/fs/fuse/fuse_i.h index 74744c6f2..7f761c087 100644 --- a/fs/fuse/fuse_i.h +++ b/fs/fuse/fuse_i.h @@ -54,8 +54,8 @@ extern struct list_head fuse_conn_list; extern struct mutex fuse_mutex; /** Module parameters */ -extern unsigned max_user_bgreq; -extern unsigned max_user_congthresh; +extern unsigned int max_user_bgreq; +extern unsigned int max_user_congthresh; /* One forget request */ struct fuse_forget_link {