Re: [PATCH vfs.all 22/26] block: stash a bdev_file to read/write raw blcok_device

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Apr 12, 2024 at 11:21:08AM +0200, Christian Brauner wrote:

> Your series just replaces bd_inode in struct block_device with
> bd_mapping. In a lot of places we do have immediate access to the bdev
> file without changing any calling conventions whatsoever. IMO it's
> perfectly fine to just use file_mapping() there. Sure, let's use
> bdev_mapping() in instances like btrfs where we'd otherwise have to
> change function signatures I'm not opposed to that. But there's no good
> reason to just replace everything with bdev->bd_mapping access. And
> really, why keep that thing in struct block_device when we can avoid it.

Because having to have struct file around in the places where we want to
get to page cache of block device fast is often inconvenient (see fs/buffer.c,
if nothing else).

It also simplifies the hell out of the patch series - it's one obviously
safe automatic change in a single commit.

And AFAICS the flags-related rationale can be dealt with in a much simpler
way - see #bf_flags in my tree.




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux