udf: Unify types in anchor block detection
authorJan Kara <jack@suse.cz>
Wed, 18 Jan 2023 12:55:31 +0000 (13:55 +0100)
committerJan Kara <jack@suse.cz>
Thu, 26 Jan 2023 15:46:32 +0000 (16:46 +0100)
commitbd904f3c74969442b0ac42f81c0d02da54cd47eb
tree193683857ddd60dcf5eec2e68875a9327161e3ba
parent1ea1cd11c72d1405a6b98440a9d5ea82dfa07166
udf: Unify types in anchor block detection

When detecting last recorded block and from it derived anchor block
position, we were mixing unsigned long, u32, and sector_t types. Since
udf supports only 32-bit block numbers this is harmless but sometimes
makes things awkward. Convert everything to udf_pblk_t and also handle
the situation when block device size would not fit into udf_pblk_t.

Signed-off-by: Jan Kara <jack@suse.cz>
fs/udf/lowlevel.c
fs/udf/super.c
fs/udf/udfdecl.h