Received: by 2002:ab2:7407:0:b0:1f4:b336:87c4 with SMTP id e7csp25982lqn; Thu, 11 Apr 2024 12:35:34 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWfulZ3h3EB9RuCiVLg+0GjaOglIwSLqmtTDXoHnHsu/JPqeB1ibTVp/fxPIw4oIl6Y7AcAJTLDWh4RB9OEhvGDidmEjdl/9G0wepl3ZQ== X-Google-Smtp-Source: AGHT+IErdlH0vFOHd6P+ZF1pMTuWRaoQhzWCmXeh/9lbu+tWzjceOeAOfms3qp2g3p4moF6186Ij X-Received: by 2002:a05:6e02:2181:b0:36a:fa1f:b571 with SMTP id j1-20020a056e02218100b0036afa1fb571mr638137ila.2.1712864134319; Thu, 11 Apr 2024 12:35:34 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712864134; cv=pass; d=google.com; s=arc-20160816; b=O/GAUyQ9PihDOG1gm22biTDgXULOqdBTiuxiq7DRmatkX+YZVGHcJff+VEKXOJBnnF V6i4erdp+SIVXITLolfsVhKdeWEtqggiW31AhAlr3maveQynebspMhcZ4zNVmMLtvbQ0 U4UQk6laHvg/HQhVuqoLhUpCwIRdyr4YwKzK1y+z4rR+qvPryIxScEEI4YOZ+j7JGYOK tOf6tCMFWiW+c4MTKjvz84Ysd1dNfEW5PORYAp9kMUOal0hFhVs8xNKo/mIZQgILhnh7 oDKIN+/UBBvrNJy2IVfgWnubk1VVwSfp2bRuNnG/BgFOPepiE5N93rTFy9vbgsGkcq1/ aIFg== 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=XKRQnKissdHCzmGNa2PV/255DMDi6uK/FNddjpC3dpw=; fh=IvJDhn2XbJ55zxf0p/e9A+SWoPpre/ymwh9Q/MPTdCg=; b=yp6ikMLlNQzMuBvYbzGNiCKIEw8p4/4aFgAmon5AK0xtSV4FPW4LjFrvNlCtFnUKi3 mdvzdnBANA84fv6fic1i3byDvb3fgmIa8iSIY+eDJYGyau3JT+RyxTUb6HV+VBLNs6zr jJOZmA7K8aYcerJhsyz9F7nyiUQBRxr8gCVIT4wRiVX1RGf47p3Dd/u2aCZMWryCvOYG vTdAVIInE9bEnxA8FNVgu9g72VJFEB4YuHH8EvLhK/DHJvYlJYengWYDkPiFuqVMeRH+ yMk5dmc5mkdGJG8q2CoiyFbjwvJXeNIkIHgcd8kN8Dp5zMex2bgxRVF8u7KuBRbMSCyH LwPg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=mB9eXMwy; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-141482-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-141482-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id v10-20020a65568a000000b005e46be657e9si1671871pgs.424.2024.04.11.12.35.33 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 11 Apr 2024 12:35:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-141482-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=mB9eXMwy; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-141482-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-141482-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com 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 B51AAB34793 for ; Thu, 11 Apr 2024 18:44:18 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 82DC64206B; Thu, 11 Apr 2024 18:38:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="mB9eXMwy" Received: from mail-pl1-f170.google.com (mail-pl1-f170.google.com [209.85.214.170]) (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 89713205E08 for ; Thu, 11 Apr 2024 18:37:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.170 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712860680; cv=none; b=GKHrNodcsGuD+QAamAAy3CT0161Py20/uVgnXvvTuU5rdMZmkI/jSnDrqalxZkGq6OHc7sIsLgbziKtWUMCe/lrwl7RUmnZdoHEYJiMidWNRw3oOtJaUp05dvmsbHTyGnfpDwRTdg7hu3UMulldlY4hq+NijLO3sAYwY4umNYis= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712860680; c=relaxed/simple; bh=BpACbSrmSMoqNqBdpG0z/OKxklof9d12+VKJaf/W8wY=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=uaQh48Ibf7K5sH3C1rvRzcB1zHPKJ36wsZjadw45qfMtaOC+q0VDNy46712TOMXD31//cIJqHJpOIEZw2xY6uTxPNpR1jdtMVotj/Nfa0awsWkGDv2MgPiog/1iAzv8CIZ1kliESh5i8IqgdKR8mIEp+DPrn5lzRHhSRHZgY464= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=mB9eXMwy; arc=none smtp.client-ip=209.85.214.170 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pl1-f170.google.com with SMTP id d9443c01a7336-1e2b137d666so1279885ad.2 for ; Thu, 11 Apr 2024 11:37:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1712860678; x=1713465478; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=XKRQnKissdHCzmGNa2PV/255DMDi6uK/FNddjpC3dpw=; b=mB9eXMwyGgD61+5SnKWtkpWFK61RW9NnXyIjhlGs8DGdO/LrivY4TLv5raVytOnrc8 Nt8qQBI/S/vuiyKBSWRQXOaGS9bST0TVcFKCcw2k0BWmSPrULFutHaG7SwQIBL4as5xl WQCifxoWgOxWKFHFUHn/8zss8Ckdb4E1ZZ1bpAAwVRm7Ny6mF+5cNUtT6j/aROsbFcN8 Z1oaQ5eThUzJb1Gh70zu7+ikieT9rXsLJA0EiWdeZB1OkGpJjZ0r8E0deBva8m4VeMgo J2D0rHgCl0gfkF/WlsIPVRASRtQiBstcV8Htf7RlfvxzCdib/oYWKcmtUdzV/dEMXhJZ mCcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712860678; x=1713465478; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=XKRQnKissdHCzmGNa2PV/255DMDi6uK/FNddjpC3dpw=; b=JNrG/92K388HQVmB23bs0/4b0G5cxAO0mZo/wSnQRHpjmmsK4rb/C/ZF52kjURbL95 CEkEdzSwIQ+TtqQdW4ldUjRtPZ35jsSA30n3PKAVxs+ZfUbhv2C2Kg006QxsgOHuQ/yk P6G1wSHViUwekLy4dNT/JFhDTmyMi4tOKN5EUhPpYMGKGQ39RVAp/xnHdhZSoGajP7J7 hiz3t+I5IDLHEdBdQ5XqvCSPMGKyDyIZ4er8GaCoWV0UlbGYY8jbjeyBag2YkNkvxir9 bnJOh4xSs9JuOW4P35VBYh2PpEue+WpDm69ilAGc6nIPV4iVaBdq6HX5L9ce+EW6Vd1N +7ng== X-Gm-Message-State: AOJu0YxVnAszz/fc7ja39DrDBThSul1niEzh6gbPeiKpur+hQp9PzBQj DoQcH8SQNsoBtGhnT1s0BKQWpptUNokK9RFdKioL2lcPHP98GzvMo+b81A== X-Received: by 2002:a17:902:780a:b0:1e2:a42a:af5d with SMTP id p10-20020a170902780a00b001e2a42aaf5dmr317714pll.30.1712860678506; Thu, 11 Apr 2024 11:37:58 -0700 (PDT) Received: from daehojeong-desktop.mtv.corp.google.com ([2620:0:1000:8411:e309:9090:b8ac:35b1]) by smtp.gmail.com with ESMTPSA id x6-20020a170902a38600b001e425d86ad9sm1519906pla.151.2024.04.11.11.37.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 11 Apr 2024 11:37:58 -0700 (PDT) From: Daeho Jeong To: linux-kernel@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, kernel-team@android.com Cc: Daeho Jeong Subject: [PATCH 2/2] f2fs: allow direct io of pinned files for zoned storage Date: Thu, 11 Apr 2024 11:37:53 -0700 Message-ID: <20240411183753.2417792-1-daeho43@gmail.com> X-Mailer: git-send-email 2.44.0.683.g7961c838ac-goog Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: Daeho Jeong Since the allocation happens in conventional LU for zoned storage, we can allow direct io for that. Signed-off-by: Daeho Jeong --- fs/f2fs/file.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c index 3ee61bc82c6f..c8e086077a48 100644 --- a/fs/f2fs/file.c +++ b/fs/f2fs/file.c @@ -833,7 +833,8 @@ static bool f2fs_force_buffered_io(struct inode *inode, int rw) * for blkzoned device, fallback direct IO to buffered IO, so * all IOs can be serialized by log-structured write. */ - if (f2fs_sb_has_blkzoned(sbi) && (rw == WRITE)) + if (f2fs_sb_has_blkzoned(sbi) && (rw == WRITE) && + !f2fs_is_pinned_file(inode)) return true; if (is_sbi_flag_set(sbi, SBI_CP_DISABLED)) return true; -- 2.44.0.683.g7961c838ac-goog