Received: by 2002:a05:7412:5112:b0:fa:6e18:a558 with SMTP id fm18csp554316rdb; Tue, 23 Jan 2024 07:39:22 -0800 (PST) X-Google-Smtp-Source: AGHT+IG02G+L4qUktIdVvo6vweVHo3j7ZZR7hIRNwuuVu9hbbRL3Oj0v+TkJTPpOTdlP9L0wzQg8 X-Received: by 2002:a17:902:6946:b0:1d4:ebbd:e057 with SMTP id k6-20020a170902694600b001d4ebbde057mr5746787plt.127.1706024361645; Tue, 23 Jan 2024 07:39:21 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706024361; cv=pass; d=google.com; s=arc-20160816; b=kKuouVt0b5VNaLccjQVGGJkWcH1On5mPz+LQgqbMW4vFkJQx1qyr7AW1PzI8nerzta RIzTIOkch6SyKSuKBGZE2QkZ73ZaHWctWA7Q7gPg+zt9fyyFJv1GNSweNh5+CGficXgH bxojr3q3ZFPndGXWGzol4vlFspz9mlck8R7IylETLIL8H6YZqVPTIssG8DpXC2Zn6ikK JT6kVF+ZXpGD4Ol7ZTbgEpp4388KhkOg2hoD02WyYO57Esn2cK4tR9CO1mR6pmAO/K6c CmV3jOvVwquthC+mjJ1FjNbKZFXfZAYAarEdntwY6N8eWHaCMpypHH1BJFUjSHcP0zsn Vkkg== 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:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature:dkim-signature :dkim-signature:dkim-signature; bh=eu2ae060uuJ6wXoYcqiz2HGb2x/G8FHqkHENUKtU6P8=; fh=qXaivh2Fa7d3K+n0GuvghyA0j4Zb6rNWiQ6clbur/Lw=; b=H67mYFGRzAp4E1z6Qf5pBMtQT3BEach9FQ8ASWh+zlH5X3HyAzooFmRsKzdM4vrIQ3 K5VewYN4nQYO+JHUojAHMgYd56RN9Ggjl59RxL0S73mS4LvYDAq8gWpm8cMePxdzLTJp mofNSJmUOeRg6t7fVAYtG04MAhJ9+dq8X+w+hDvVDWa7L7DnP9F9NHgkViSzY6eHHfw1 ZR3UH395omqWy2JswZcVIlpTMAvrDH3vECsVDwHBHNbzquShq1IMf1rb8Nd7wdPcYWVu DCF3DwoPNpXWXZmEJKrP2zjAV8sNzao0PeGTm/QXPG7LM+n9IEf9ejkcIKp048qZ3VY5 AEzQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=Lf1RTar0; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=Lf1RTar0; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; arc=pass (i=1 spf=pass spfdomain=suse.cz dkim=pass dkdomain=suse.cz dkim=pass dkdomain=suse.cz); spf=pass (google.com: domain of linux-ext4+bounces-868-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-ext4+bounces-868-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id a5-20020a170902ecc500b001d4ac318456si10294789plh.49.2024.01.23.07.39.21 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 Jan 2024 07:39:21 -0800 (PST) Received-SPF: pass (google.com: domain of linux-ext4+bounces-868-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=Lf1RTar0; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=Lf1RTar0; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; arc=pass (i=1 spf=pass spfdomain=suse.cz dkim=pass dkdomain=suse.cz dkim=pass dkdomain=suse.cz); spf=pass (google.com: domain of linux-ext4+bounces-868-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-ext4+bounces-868-linux.lists.archive=gmail.com@vger.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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 94272B23D99 for ; Tue, 23 Jan 2024 15:25:47 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 763C55FEEF; Tue, 23 Jan 2024 15:25:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=suse.cz header.i=@suse.cz header.b="Lf1RTar0"; dkim=permerror (0-bit key) header.d=suse.cz header.i=@suse.cz header.b="ukjFYIuX"; dkim=pass (1024-bit key) header.d=suse.cz header.i=@suse.cz header.b="Lf1RTar0"; dkim=permerror (0-bit key) header.d=suse.cz header.i=@suse.cz header.b="ukjFYIuX" X-Original-To: linux-ext4@vger.kernel.org Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5EC4750A71; Tue, 23 Jan 2024 15:25:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=195.135.223.130 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706023529; cv=none; b=kKkrsCgONn8pkuptGTvDDvTQyScesExBdRZIXuErQTOg+lSp+tVDW3UtxESRQFbSNWTWPS31ksRg/pNFCtCM08oug08fi4Aj4vsfk6VXTJR/j+2sA1JrbOKuPWtpdtyyayKn+Cz23cj7LXQqM2leQIoOKWFITSXzAmgPfkS+Iqk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706023529; c=relaxed/simple; bh=5bQr+Ha8gFH12hdvNUJslYgvohqb5ImCJsuLlAN8XXg=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=lpnZR2rlR02fxfjjGQAytOUhxx2QifLdmPEMGtTFxN8H1SSyKBRxvhMbV+GJw4LSfDwvSE3iOCCIqjgLhuDDlQ5Lpwud3eI6KGpzxruHo1L3F2PDgOQBufybUrdTEQCr/1VbEwONx48kWUr0Gc03tPE7En4hPuSaSheYwnoLwqE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=suse.cz; spf=pass smtp.mailfrom=suse.cz; dkim=pass (1024-bit key) header.d=suse.cz header.i=@suse.cz header.b=Lf1RTar0; dkim=permerror (0-bit key) header.d=suse.cz header.i=@suse.cz header.b=ukjFYIuX; dkim=pass (1024-bit key) header.d=suse.cz header.i=@suse.cz header.b=Lf1RTar0; dkim=permerror (0-bit key) header.d=suse.cz header.i=@suse.cz header.b=ukjFYIuX; arc=none smtp.client-ip=195.135.223.130 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.cz Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [10.150.64.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 84AD8222AC; Tue, 23 Jan 2024 15:25:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1706023525; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eu2ae060uuJ6wXoYcqiz2HGb2x/G8FHqkHENUKtU6P8=; b=Lf1RTar0lo+5fDJ9W+ZyyGXvUiLtctp2h9QpusKE+8Eevo5AtvqSR9LzW5qykWhlYvUrsz coB29xwW3AGSn5BttKslxkGUNnsy4YeWlPgj2GzMW2ZW8/j/rz3beBZyEHWenwwLx/oBLF xdCsx5RcCMSgK2nrd9uaGWUIWesZL9w= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1706023525; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eu2ae060uuJ6wXoYcqiz2HGb2x/G8FHqkHENUKtU6P8=; b=ukjFYIuXSUw5K6+eqs0VsSFG68QAW9p+0ZLmfr0nsU/S84f1hB7n7D0lTTHVYFWcWteyZg TBtF1vJPLzSjhVDw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1706023525; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eu2ae060uuJ6wXoYcqiz2HGb2x/G8FHqkHENUKtU6P8=; b=Lf1RTar0lo+5fDJ9W+ZyyGXvUiLtctp2h9QpusKE+8Eevo5AtvqSR9LzW5qykWhlYvUrsz coB29xwW3AGSn5BttKslxkGUNnsy4YeWlPgj2GzMW2ZW8/j/rz3beBZyEHWenwwLx/oBLF xdCsx5RcCMSgK2nrd9uaGWUIWesZL9w= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1706023525; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eu2ae060uuJ6wXoYcqiz2HGb2x/G8FHqkHENUKtU6P8=; b=ukjFYIuXSUw5K6+eqs0VsSFG68QAW9p+0ZLmfr0nsU/S84f1hB7n7D0lTTHVYFWcWteyZg TBtF1vJPLzSjhVDw== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 70A05139B9; Tue, 23 Jan 2024 15:25:25 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id 6xANG2Xar2WcdQAAD6G6ig (envelope-from ); Tue, 23 Jan 2024 15:25:25 +0000 Received: by quack3.suse.cz (Postfix, from userid 1000) id D60A1A0804; Tue, 23 Jan 2024 16:25:20 +0100 (CET) From: Jan Kara To: Cc: , Matthew Wilcox , Jan Kara Subject: [PATCH 1/9] udf: Remove GFP_NOFS from dir iteration code Date: Tue, 23 Jan 2024 16:25:00 +0100 Message-Id: <20240123152520.4294-1-jack@suse.cz> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20240123152113.13352-1-jack@suse.cz> References: <20240123152113.13352-1-jack@suse.cz> Precedence: bulk X-Mailing-List: linux-ext4@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1181; i=jack@suse.cz; h=from:subject; bh=5bQr+Ha8gFH12hdvNUJslYgvohqb5ImCJsuLlAN8XXg=; b=owEBbQGS/pANAwAIAZydqgc/ZEDZAcsmYgBlr9pMvnPhSSAbDWXgDn8IPkr058JslJ+zOPfDwL0g j/lPZv2JATMEAAEIAB0WIQSrWdEr1p4yirVVKBycnaoHP2RA2QUCZa/aTAAKCRCcnaoHP2RA2YDgCA DZ9mWJSopbKG9E5G8rtSGZZe8jjPfgUIhcZVwDNo2p0jkR7s/AYR4EU3cneG7Wn6wqWzLgqW1YLAOa iZUd9Odxx95Adljq7Miomd6SHBH4t5GaiTmEwnD0G7ISvkDioql7CwXfJc29QnARgMz5y0a5aiRlfq TdMtg6vD4hEy6qmMhvmPwawg+E8zF5A7tI2xHMUJSbgTjJ+RU+sGMspFeD/znXLlDdlK7AKnnKBHI6 fpaXHWjQaX7BF0JNG72G+Xe9ViExZHTNkhWpgSewUH+MKo24uj9tdL3QBTHr3ZWYgASYQSfy5l6S8S O54olkmkfEaoN3u9a/XM/q2ZrUA81G X-Developer-Key: i=jack@suse.cz; a=openpgp; fpr=93C6099A142276A28BBE35D815BC833443038D8C Content-Transfer-Encoding: 8bit Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [4.90 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[4]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; BROKEN_CONTENT_TYPE(1.50)[]; TO_DN_SOME(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.cz:s=susede2_rsa,suse.cz:s=susede2_ed25519]; MID_CONTAINS_FROM(1.00)[]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Spam-Level: **** X-Spam-Score: 4.90 X-Spam-Flag: NO Directory iteration code was using GFP_NOFS allocations in two places. However the code is called only under inode->i_rwsem which is generally safe wrt reclaim. So we can do the allocations with GFP_KERNEL instead. Signed-off-by: Jan Kara --- fs/udf/dir.c | 2 +- fs/udf/namei.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/udf/dir.c b/fs/udf/dir.c index f6533f93851b..f94f45fe2c91 100644 --- a/fs/udf/dir.c +++ b/fs/udf/dir.c @@ -67,7 +67,7 @@ static int udf_readdir(struct file *file, struct dir_context *ctx) pos_valid = true; } - fname = kmalloc(UDF_NAME_LEN, GFP_NOFS); + fname = kmalloc(UDF_NAME_LEN, GFP_KERNEL); if (!fname) { ret = -ENOMEM; goto out; diff --git a/fs/udf/namei.c b/fs/udf/namei.c index 1bb6ed948927..1f14a0621a91 100644 --- a/fs/udf/namei.c +++ b/fs/udf/namei.c @@ -59,7 +59,7 @@ static int udf_fiiter_find_entry(struct inode *dir, const struct qstr *child, child->name[0] == '.' && child->name[1] == '.'; int ret; - fname = kmalloc(UDF_NAME_LEN, GFP_NOFS); + fname = kmalloc(UDF_NAME_LEN, GFP_KERNEL); if (!fname) return -ENOMEM; -- 2.35.3