Received: by 2002:ab2:3b09:0:b0:1ed:14ea:9113 with SMTP id b9csp177299lqc; Thu, 29 Feb 2024 14:00:25 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCV2LfBW/qRZ5FGIcGVUOcmKDgWxAld+u+38qYzfFTz3ukhY75f7zyJFkxu6pThceBq4/Adc1XuOtXKGboQripPkLF21skXq3QJMuRtmyQ== X-Google-Smtp-Source: AGHT+IF66SX51028FB8zrR3lVnsKX1XEZOnJKP6c6ABdIib1qDzlL6/4LukK5D3HaQDZ22KsKOSa X-Received: by 2002:a05:6e02:1b04:b0:365:1750:cdae with SMTP id i4-20020a056e021b0400b003651750cdaemr325853ilv.27.1709244024955; Thu, 29 Feb 2024 14:00:24 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709244024; cv=pass; d=google.com; s=arc-20160816; b=X7w/EpFO8oMa84fDWFNOEQpawRYN28oNESguTUXXPnrzglWaCOUIS8aiPQMawDSBNV gDeBNIyp+lm/bwli2eG7pgruIT5ySCzf7K9VyAuhjXtSm3O0adJnY7UIhg/A+UHly9pz B7M1YZ8CLcojTs72Azj4FFd+UQ0RywEajMiSpNgyFi9hNthES+CnKH+F5Snj7AMjxVPn 7aGwhQEMtukfk+eNEBK9hKEsNX0GArjq5tqUKmBcIqkGXZ11+QqA8rVG2zK93bHhLVaK ewg1D45kATEZdHYtFytHHp+/hjOGxmF/Al063MReGvaqm81Y0aeGKc6tmBzpmpbmXy8x qH9w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:dkim-signature; bh=BbgG5w7yu+QX5FfjrTF2VmLEo++5O/1fX3vCzvCmwjs=; fh=2t7SloZLefHRtzSEtJVbg9fxW/3thHJFxcHfTeBZ+iE=; b=ThIDnwPlUZH5HFtUq3B7+ekQNImgyLB3NSaTNt7Zn7j5wG24+BDswOExngDGKnRRNo A9uH+4l8DHFG2YLk3IwUf8OyEZdr++N+gTl5t96O97otNAWvwEJ79y+RO/I9q0AXO3ch uQapelj1PZK1asIwk6kVq9iWl8EXNsDInBroTeHch4sFqNh9rgbPFzq/2OR+rP3Q9ndq H/raBWxO6qBTnPxr8YsnsfxPfSwF716G5Wz9Ay8VKSTeE1zDJ45FmYQxedShsbIBEXwa Ju2Y3Nq1iOlEQflMDQvCSkDJ4eOKMZxLT2G9EMBaOSoqnTsTg70A5MZJ42WIWy8UMTxH UqJA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@toblux-com.20230601.gappssmtp.com header.s=20230601 header.b=dj1ocBUj; arc=pass (i=1 dkim=pass dkdomain=toblux-com.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-87482-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-87482-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 m4-20020a62f204000000b006e55b46440bsi2054555pfh.254.2024.02.29.14.00.24 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Feb 2024 14:00:24 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-87482-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=@toblux-com.20230601.gappssmtp.com header.s=20230601 header.b=dj1ocBUj; arc=pass (i=1 dkim=pass dkdomain=toblux-com.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-87482-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-87482-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 37465B2520B for ; Thu, 29 Feb 2024 20:52:18 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1167613E7E9; Thu, 29 Feb 2024 20:40:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=toblux-com.20230601.gappssmtp.com header.i=@toblux-com.20230601.gappssmtp.com header.b="dj1ocBUj" Received: from mail-ej1-f46.google.com (mail-ej1-f46.google.com [209.85.218.46]) (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 7C46113E7DB for ; Thu, 29 Feb 2024 20:40:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.46 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709239237; cv=none; b=qR0y91SwjT5CSRMxQiixxkxZWLNtYKjytg2UD7a7sxlk0+2uO+44w5lv1RYUFTi0dczNcbuUJ/JDa98epfLzVP6YvjAF9xGXkXgcLFt724yZW37hkQo325ipdpUtyL1I+w1o8M4GIH4VKPDhBwYtHfOW1d6/xd5ygtTM+inaqyU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709239237; c=relaxed/simple; bh=BbgG5w7yu+QX5FfjrTF2VmLEo++5O/1fX3vCzvCmwjs=; h=Content-Type:Mime-Version:Subject:From:In-Reply-To:Date:Cc: Message-Id:References:To; b=Chf9polt+Wx2HRxvZ4iI0BhdnMkfyOoyPqek/BGBogRfb64UrKgEMdtKmQOsLhv0xPvNMy0YiylMHzZ8alMQ9V9Ss5k3YOz+oW2So9n5nlppC4qmjVFSsiVjXeIrwMA/P1MhFL9okGu1cSi6y+Pm1Vp2n9GKO/Q4FXiQXpqPO7U= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=toblux.com; spf=none smtp.mailfrom=toblux.com; dkim=pass (2048-bit key) header.d=toblux-com.20230601.gappssmtp.com header.i=@toblux-com.20230601.gappssmtp.com header.b=dj1ocBUj; arc=none smtp.client-ip=209.85.218.46 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=toblux.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=toblux.com Received: by mail-ej1-f46.google.com with SMTP id a640c23a62f3a-a293f2280c7so277881866b.1 for ; Thu, 29 Feb 2024 12:40:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=toblux-com.20230601.gappssmtp.com; s=20230601; t=1709239234; x=1709844034; darn=vger.kernel.org; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=BbgG5w7yu+QX5FfjrTF2VmLEo++5O/1fX3vCzvCmwjs=; b=dj1ocBUjYxX3wEF4+Tezmioygx9UC2PReUf8BLuKZ/Vba4woFBgd5wavj3GMWlIbcQ On/POQiAYmB9irzQRJDahx2RsnBnJph/8/HGg0WdcwD9bITCJJ9Mxl1rgmJ0eC28fxdr lk/szNMOAvtB8wM1MnRoxZrmYW6LUJsnodaz6cb2BxeQjLsFKN+GMrV/QbEm/E9qOzkS bMBuKuBFQfo6dDwRHpHyCAqdOv9L97LERKPEd+IWhN+MDmdU5Sjr5eH0eSshTjbtQ7t6 0Wabmqakkl1RFJtqe/5UltzA2wXPBFINymCun5DeUZ3aR3+rMmJ62eqoKQBnjatulOhr TWqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709239234; x=1709844034; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=BbgG5w7yu+QX5FfjrTF2VmLEo++5O/1fX3vCzvCmwjs=; b=PCHJwQ+t32FJqaTw/K5Xm3Bwnteyu6DGgccwriGmQOgnPqXGYKv2NiE98/hPxe6Krq ep8m0n14Jd0TQy4u8hhKlzFMaDhjM1GFl18be7zwMkFSjnygIc9Cm62mXoVfXMAhWLPX 6WmAmWKjzalAoHZcIgKwNSy4fDu4dYRZB7fz1Efp3sl+IVo0dn51M2xopSejtMfNXIrp RHgnCONrnXA25LeFNJuHXJoEab0lAz2F7DI/QZdTtGGvPjQP1FsrCygeRyUcdqvv1fYR Jl11HaI4H71dvO95VkeX9sw8Zy/ZbAyRtpbeGwQ9SQRNAZphNGyNcmz/mfJcoqJDyacE T94A== X-Forwarded-Encrypted: i=1; AJvYcCW2SwIDu3hkQd1WdSbe2V18OkvjsaqOQEdJpOwa0tQgD/iEOAUCYWwpdtLs3MnoO7xFGxQ19Yrt//yMTZH9GX/OE0sQ2gC/negJCgeT X-Gm-Message-State: AOJu0YznI9q+AKBxf+0aueRBeOhfaUdPERQO+FhF2T+rkwLVhljulox7 8zXy3Rc0u0WSWa1T9SUkHJLBX6vfYU1GbHtySRMOz1PeTwK50DFXb+caqel/mAs= X-Received: by 2002:a17:906:5a94:b0:a3d:b6c2:fc58 with SMTP id l20-20020a1709065a9400b00a3db6c2fc58mr56249ejq.2.1709239233697; Thu, 29 Feb 2024 12:40:33 -0800 (PST) Received: from smtpclient.apple ([2001:a61:1069:f701:6c1a:d05d:ad7c:b80d]) by smtp.gmail.com with ESMTPSA id f26-20020a170906139a00b00a4417c46efbsm1013526ejc.82.2024.02.29.12.40.32 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 29 Feb 2024 12:40:33 -0800 (PST) Content-Type: text/plain; charset=us-ascii Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.400.31\)) Subject: Re: [PATCH] nilfs2: Use div64_ul() instead of do_div() From: Thorsten Blum In-Reply-To: <19910196-DFF3-4F94-B6D3-B9BF722DF8B8@toblux.com> Date: Thu, 29 Feb 2024 21:40:22 +0100 Cc: linux-nilfs@vger.kernel.org, linux-kernel@vger.kernel.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <20240229121650.33983-1-thorsten.blum@toblux.com> <19910196-DFF3-4F94-B6D3-B9BF722DF8B8@toblux.com> To: Ryusuke Konishi X-Mailer: Apple Mail (2.3774.400.31) > On Feb 29, 2024, at 20:41, Thorsten Blum = wrote: >=20 >> On Feb 29, 2024, at 19:45, Ryusuke Konishi = wrote: >>=20 >> All of the fixes in this patch seem to be correct, but this doesn't >> cover nilfs_resize_fs(), nilfs_max_segment_count(), and >> nilfs_sb2_bad_offset(), which also have do_div() that doesn't use the >> return value. >=20 > For nilfs_sb2_bad_offset(), where the dividend is u64 and the divisor = is u32, we > would need a dedicated function like div64_u32() that doesn't = calculate the > remainder, which doesn't seem to exist. What do you think? Never mind, there is div_u64(u64, u32). I'll submit a v2 shortly. Thorsten=