On Tue, Dec 14, 2021 at 10:24:12AM +0900, Damien Le Moal wrote: > Introduce the helper function zbd_offset_to_zone() to get a zone > structure using a file offset. In many functions, this replaces the > two line code pattern: > > zone_idx = zbd_offset_to_zone_idx(f, offset); > z = zbd_get_zone(f, zone_idx); > > with a single line of code: > > z = zbd_offset_to_zone(f, offset); > > Signed-off-by: Damien Le Moal <damien.lemoal@xxxxxxxxxxxxxxxxxx> > --- Reviewed-by: Niklas Cassel <niklas.cassel@xxxxxxx>