From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pf1-f178.google.com (mail-pf1-f178.google.com [209.85.210.178]) (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 0FACA35CB80 for ; Wed, 4 Mar 2026 23:50:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.210.178 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772668203; cv=none; b=ZQ4AVRINGPrUUeFzTUgwlDuML2j+U0cu9K+u5P6WysrpRXNVSP0ROcuYbl80Lt99qNRAi9PSxIrkVMkr6RQh5HQIVu5kq/QtZdfJrXg9NMeiktQ7nU6u5sGAxWQ0OUcJCp7Ya0gXlcsV0zg1+ICPVSRRcPpI/ZyZIbSR7D3hW+4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772668203; c=relaxed/simple; bh=mx3kVw3Nce2fnqk8JGthU6qFDOxZAiVzljiCAwnxHqE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=nFR2pXbc+jVxdllPGeLrZ754526Idm5euU6b0f1Ea1gbZFJ85T2fh9Q0fvRl3QnoYnhmnK84wJ1uxLtOUH9adik++PG27G/W1hVKCEQNdBS3/jOWqK9MrgVDR+XBAWmfiwQXC4N2GWgO567G+unwLnRrxetyAzO2pQg6XGrxTI0= 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=CuBR1rSj; arc=none smtp.client-ip=209.85.210.178 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 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="CuBR1rSj" Received: by mail-pf1-f178.google.com with SMTP id d2e1a72fcca58-8296dabef74so1398303b3a.1 for ; Wed, 04 Mar 2026 15:50:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1772668201; x=1773273001; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=LpT6Ri1JZ7zRc+gH8Ikbp98R6plbM/rAdu+pRzYMoUg=; b=CuBR1rSjkdXT4J4RqpAyzCSXKDEswPms6ww5Ld1bIFI57sICITuAAjGFmopS/hRLLo qBuufaFUg3JQ+s+SEkUE8I12CAK4uc12DZsLkpkJZatTBbjCyFsJeeiryZaaJHxSO91x zwRant/k+6vmbHMBkBiE0Lj4LASMErMmUGOQEr1kUepiaV7/hNoYsnpl2kCTpNl2FIsH ANxYwfHKfoB6K5v7EWGbksXEKU/H6Bv0tq8fuZBbmGtCsIi7GgirXpBjBynQMX7ZZwVC /NUZgkzZWkYIpmMw1Ylo6BXfzm0DurEV146RlcAUDA7uqQfUKhgFC1Yt01IYw1sC6I/a zlnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772668201; x=1773273001; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LpT6Ri1JZ7zRc+gH8Ikbp98R6plbM/rAdu+pRzYMoUg=; b=m4v9Sz/PzutVus/kLRYQYtCTd8vEAqQjsPZYK1PnzKHlfRrFejU4QkeS0pjfHfM51g a8CuUoCAf/xqb7cvkbjeE8iMpjRyacUy8RxkoSDr5XC7rBemCCphw581IwFatBUqAX/p Gmy0+axX5MN3jhl2nW54+CQHZJKT6gijYfhPc1Vw2VBUgYCkNEhZIweA3Ofro+Nmj+LI n/JqhQDmNW9F0go6KSQEMa5KOSO6Rp9Co7Z9VIHUCK7Zz+WcAWNt3+URzCnmIZA30FkT h8br/GdipvbvKwrQqBE7huzzoahHS96VhVvr1Sp87SfCIKgw2I+8gonT3lapBnzHlmY/ LT+A== X-Forwarded-Encrypted: i=1; AJvYcCVq18w9UFZtSKcYzPTmPO9VcoNGKqsk2ZeQpkR+j0JvKsndAjZ+M5QTPdeJiIVVjAXbHL3AtKZt2ULzIMI=@vger.kernel.org X-Gm-Message-State: AOJu0YyOoboSHKc08ZTXBN38oOQby8OTv6pHgzcXTFe4S/IFn3mt75z/ iQJuHidwHsXH3D/Ijkv+hWq4N6duM8gpKxWLhrmWN7QW9TTsaQ0wd3PA X-Gm-Gg: ATEYQzwexQWlG+uJG6Lviw06GoHKd4y/oxaoMv35dgxN+SS1ym99ozDGILSwNqEjnh2 fu+wERe9zW4sM2Q8sPxMfi89qSioNr1sNpgsNRsf8NxN7z2pXNNl2MkHrnQbv+eM3B1TlKB/B5E 2WeKznZAEtRdGxX402aLE/G+04NMY9I8IDQYzhzG/Qt+/SOV0QlpCr1og1tAF0B5gT2HL6c11jJ d8CfnEAsx88Q0sZsN6xNV5e4XsShJM4PoZven9eEsY5mADljEvKozqMnYIREZfxMWH57RUaw2Ko ghq32EexqPlYgqNA93miYFos/FV3nnym2uATMSSF1DHUjwap842GurtGCvxD+AVvdn5M+bKy/Eq J/KIrQocJdbxtlXmLuW1Tkr6SSA7m0Ho2mrPtd+4Ecnl39Tk1BEEU8SU9/RLOBqMBHRtvSykULT mUNZ/sOznwlO5qeQ== X-Received: by 2002:a05:6a00:2ea3:b0:81f:9f1d:114b with SMTP id d2e1a72fcca58-829728f04dfmr3382088b3a.12.1772668201369; Wed, 04 Mar 2026 15:50:01 -0800 (PST) Received: from localhost ([27.122.242.71]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-82739d4c910sm19312223b3a.8.2026.03.04.15.50.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 04 Mar 2026 15:50:00 -0800 (PST) Date: Thu, 5 Mar 2026 08:49:58 +0900 From: Hyunchul Lee To: Christoph Hellwig Cc: Viacheslav Dubeyko , John Paul Adrian Glaubitz , Yangtao Li , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, cheol.lee@lge.com Subject: Re: [PATCH] hfsplus: limit sb_maxbytes to partition size Message-ID: References: <20260303082807.750679-1-hyc.lee@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: On Wed, Mar 04, 2026 at 05:08:15AM -0800, Christoph Hellwig wrote: > On Tue, Mar 03, 2026 at 05:28:07PM +0900, Hyunchul Lee wrote: > > s_maxbytes currently is set to MAX_LFS_FILESIZE, > > which allows writes beyond the partition size. > > The "partition size" does not matter here. s_maxbytes is the maximum > size supported by the format and has nothing to do with the actual space > allocated to the file system (which in Linux terminology would be the > block device and not the partition anyway). > > > > > As a result, > > large-offset writes on small partitions can fail late > > with ENOSPC. > > That sounds like some other check is missing in hfsplus, but it > should be about the available free space, not the device size. > When running xfs_io -c "pwrite 8t 512", hfsplus fills the block device with zeros before returning ENOSPC. I was trying to fix this, but as you mentioned, I will look for another solution. Thank for your review and comments. -- Thanks, Hyunchul