iomap_dio_bio_iter()
On 12/03/2025 23:59, Dave Chinner wrote:
*/
static inline blk_opf_t iomap_dio_bio_opflags(struct iomap_dio *dio,
- const struct iomap *iomap, bool use_fua, bool atomic_hw)
+ const struct iomap *iomap, bool use_fua, bool bio_atomic)
Not new here, but these two bools are pretty ugly.
I'd rather have a
blk_opf_t extra_flags;
in the caller that gets REQ_FUA and REQ_ATOMIC assigned as needed,
and then just clear
Yep, that is cleaner..
This suggestion is not clear to me.
Is it that iomap_dio_bio_iter() [the only caller of
iomap_dio_bio_opflags()] sets REQ_FUA and REQ_ATOMIC in extra_flags, and
then we extra_flags | bio_opf?
Note that iomap_dio_bio_opflags() does still use use_fua for clearing
IOMAP_DIO_WRITE_THROUGH.
And to me it seems nicer to set all the REQ_ flags in one place.