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 Sun, Apr 07, 2024 at 05:57:58AM +0100, Al Viro wrote:

> PS: in grow_dev_folio() we probably want
> 	struct address_space *mapping = bdev->bd_inode->i_mapping;
> instead of
> 	struct inode *inode = bdev->bd_inode;
> as one of the preliminary chunks.
> FWIW, it really looks like address_space (== page cache of block device,
> not an unreasonably candidate for primitive) and block size (well,
> logarithm thereof) cover the majority of what remains, with device
> size possibly being (remote) third...

Incidentally, how painful would it be to switch __bread_gfp() and __bread()
to passing *logarithm* of block size instead of block size?  And possibly
supply the same to clean_bdev_aliases()...

That would reduce fs/buffer.c uses to just "give me the address_space of
that block device"...




[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