summaryrefslogtreecommitdiff
path: root/rust/kernel/gpu/git@git.tavy.me:linux-stable.git
diff options
context:
space:
mode:
authorEric Biggers <ebiggers@kernel.org>2026-02-05 20:59:36 -0800
committerMikulas Patocka <mpatocka@redhat.com>2026-03-09 15:13:19 +0100
commitca0da6cc096870e9e138f4c2bb78bd2560e29590 (patch)
tree68015f9dff0dc146f1e16db1907eca80bc8e0187 /rust/kernel/gpu/git@git.tavy.me:linux-stable.git
parent3ad2b952a3ea26c05ed6fdd6484051604b1dee66 (diff)
dm-verity-fec: move computation of offset and rsb down a level
verity_fec_decode() computes (offset, rsb) from the target block index and calls fec_decode_rsb() with these parameters. Move this computation into fec_decode_rsb(), and rename fec_decode_rsb() to fec_decode(). This ends up being simpler and enables further refactoring, specifically making use of the quotient from the division more easily. The function renaming also eliminates a reference to the ambiguous term "rsb". This change does mean the same div64_u64_rem() can now be executed twice per block, since verity_fec_decode() calls fec_decode() up to twice per block. However, this cost is negligible compared to the rest of FEC. Signed-off-by: Eric Biggers <ebiggers@kernel.org> Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Diffstat (limited to 'rust/kernel/gpu/git@git.tavy.me:linux-stable.git')
0 files changed, 0 insertions, 0 deletions