aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2023-10-28hwmon: (pmbus/mpq7932) Get page count based on chip infoSaravanan Sekar1-3/+3
Get page count using compatible match to support the series of chipsets which differs in number of regualator/page. Signed-off-by: Saravanan Sekar <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28dt-bindings: hwmon: Add possible new properties to max31827 bindingsDaniel Matyas1-0/+66
These modify the corresponding bits in the configuration register. adi,comp-int is a hardware property, because it affects the behavior of the interrupt signal and whatever it is connected to. adi,timeout-enable is a hardware property, because it affects i2c bus operation. Signed-off-by: Daniel Matyas <[email protected]> Reviewed-by: Conor Dooley <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28hwmon: (max31827) Modify conversion wait timeDaniel Matyas2-3/+3
There is nothing in the datasheet indicating that the 1ms error is needed and I didn't encounter any error during testing with 140ms wait time. Signed-off-by: Daniel Matyas <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28hwmon: (max31827) Make code cleanerDaniel Matyas1-69/+54
Used enums and while loops to replace switch for selecting and getting update interval from conversion rate bits. Divided the write_alarm_val function into 2 functions. The new function is more generic: it can be used not only for alarm writes, but for any kind of writes which require the device to be in shutdown mode. Signed-off-by: Daniel Matyas <[email protected]> Link: https://lore.kernel.org/r/[email protected] [groeck: Reverted error return value change (EOPNOTSUPP -> EINVAL)] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28MAINTAINERS: Add Hal as one of the maintainers of SFCTEMP HWMON DRIVERHal Feng1-0/+1
As he is the submitter of this driver, add his mail so he can maintain the driver and easily reply in the mailing list. Acked-by: Emil Renner Berthing <[email protected]> Signed-off-by: Hal Feng <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28hwmon: (nct6683) Add another customer ID for ASRock X670E TaichiAlexander Koskovich2-0/+4
This value was found on an ASRock X670E Taichi with an NCT6686D chip. Signed-off-by: Alexander Koskovich <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28hwmon: (ltc2992) Avoid division by zeroAntoniu Miclaus1-1/+5
Do not allow setting shunt resistor to 0. This results in a division by zero when performing current value computations based on input voltages and connected resistor values. Signed-off-by: Antoniu Miclaus <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28hwmon: (npcm750-pwm) Add an error code check in npcm7xx_en_pwm_fanSu Hui1-0/+2
npcm7xx_pwm_config_set() can return '-ENODEV' for failed. So check the value of 'ret' after calling npcm7xx_pwm_config_set(). Signed-off-by: Su Hui <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28hwmon: (hs3001) remove redundant store on divisionColin Ian King1-1/+1
Currently the local variable hum is being divided by a constant and the results is being re-assigned back to hum before the value is being returned to the caller. The assignment to hum is redundant and can be removed. Cleans up clang scan build warning: drivers/hwmon/hs3001.c:65:9: warning: Although the value stored to 'hum' is used in the enclosing expression, the value is never actually read from 'hum' [deadcode.DeadStores] Signed-off-by: Colin Ian King <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28hwmon: (nct6775) use acpi_dev_hid_uid_match() for matching _HID and _UIDRaag Jadav1-3/+1
Convert manual _UID references to use the standard ACPI helper. Signed-off-by: Raag Jadav <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Guenter Roeck <[email protected]>
2023-10-28porting: update locking requirementsChristian Brauner1-0/+7
Now that s_umount is never taken under open_mutex update the documentation to say so. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28fs: assert that open_mutex isn't held over holder opsChristian Brauner1-0/+1
With recent block level changes we should never be in a situation where we hold disk->open_mutex when calling into these helpers. So assert that in the code. Signed-off-by: Christoph Hellwig <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ming Lei <[email protected]> Reviewed-by: Jan Kara <[email protected]> Reviewed-by: Jens Axboe <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28block: assert that we're not holding open_mutex over blk_report_disk_deadChristian Brauner1-0/+7
blk_report_disk_dead() has the following major callers: (1) del_gendisk() (2) blk_mark_disk_dead() Since del_gendisk() acquires disk->open_mutex it's clear that all callers are assumed to be called without disk->open_mutex held. In turn, blk_report_disk_dead() is called without disk->open_mutex held in del_gendisk(). All callers of blk_mark_disk_dead() call it without disk->open_mutex as well. Ensure that it is clear that blk_report_disk_dead() is called without disk->open_mutex on purpose by asserting it and a comment in the code. Signed-off-by: Christoph Hellwig <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ming Lei <[email protected]> Reviewed-by: Jan Kara <[email protected]> Reviewed-by: Jens Axboe <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28block: move bdev_mark_dead out of disk_check_media_changeChristoph Hellwig4-18/+17
disk_check_media_change is mostly called from ->open where it makes little sense to mark the file system on the device as dead, as we are just opening it. So instead of calling bdev_mark_dead from disk_check_media_change move it into the few callers that are not in an open instance. This avoid calling into bdev_mark_dead and thus taking s_umount with open_mutex held. Signed-off-by: Christoph Hellwig <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ming Lei <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Reviewed-by: Jan Kara <[email protected]> Reviewed-by: Jens Axboe <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28block: WARN_ON_ONCE() when we remove active partitionsChristian Brauner1-13/+17
The logic for disk->open_partitions is: blkdev_get_by_*() -> bdev_is_partition() -> blkdev_get_part() -> blkdev_get_whole() // bdev_whole->bd_openers++ -> if (part->bd_openers == 0) disk->open_partitions++ part->bd_openers In other words, when we first claim/open a partition we increment disk->open_partitions and only when all part->bd_openers are closed will disk->open_partitions be zero. That should mean that disk->open_partitions is always > 0 as long as there's anyone that has an open partition. So the check for disk->open_partitions should mean that we can never remove an active partition that has a holder and holder ops set. Assert that in the code. The main disk isn't removed so that check doesn't work for disk->part0 which is what we want. After all we only care about partition not about the main disk. Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ming Lei <[email protected]> Reviewed-by: Jan Kara <[email protected]> Reviewed-by: Jens Axboe <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28block: simplify bdev_del_partition()Christian Brauner1-1/+12
BLKPG_DEL_PARTITION refuses to delete partitions that still have openers, i.e., that has an elevated @bdev->bd_openers count. If a device is claimed by setting @bdev->bd_holder and @bdev->bd_holder_ops @bdev->bd_openers and @bdev->bd_holders are incremented. @bdev->bd_openers is effectively guaranteed to be >= @bdev->bd_holders. So as long as @bdev->bd_openers isn't zero we know that this partition is still in active use and that there might still be @bdev->bd_holder and @bdev->bd_holder_ops set. The only current example is @fs_holder_ops for filesystems. But that means bdev_mark_dead() which calls into bdev->bd_holder_ops->mark_dead::fs_bdev_mark_dead() is a nop. As long as there's an elevated @bdev->bd_openers count we can't delete the partition and if there isn't an elevated @bdev->bd_openers count then there's no @bdev->bd_holder or @bdev->bd_holder_ops. So simply open-code what we need to do. This gets rid of one more instance where we acquire s_umount under @disk->open_mutex. Link: https://lore.kernel.org/r/20231016-fototermin-umriss-59f1ea6c1fe6@brauner Reviewed-by: Christoph Hellwig <[email protected]> Reviewed-by: Jan Kara <[email protected]> Reviewed-by: Jens Axboe <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Ming Lei <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28fs: Avoid grabbing sb->s_umount under bdev->bd_holder_lockJan Kara3-22/+38
The implementation of bdev holder operations such as fs_bdev_mark_dead() and fs_bdev_sync() grab sb->s_umount semaphore under bdev->bd_holder_lock. This is problematic because it leads to disk->open_mutex -> sb->s_umount lock ordering which is counterintuitive (usually we grab higher level (e.g. filesystem) locks first and lower level (e.g. block layer) locks later) and indeed makes lockdep complain about possible locking cycles whenever we open a block device while holding sb->s_umount semaphore. Implement a function bdev_super_lock_shared() which safely transitions from holding bdev->bd_holder_lock to holding sb->s_umount on alive superblock without introducing the problematic lock dependency. We use this function fs_bdev_sync() and fs_bdev_mark_dead(). Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Christoph Hellwig <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28jfs: fix log->bdev_handle null ptr deref in lbmStartIOLizhi Xu1-1/+5
When sbi->flag is JFS_NOINTEGRITY in lmLogOpen(), log->bdev_handle can't be inited, so it value will be NULL. Therefore, add the "log ->no_integrity=1" judgment in lbmStartIO() to avoid such problems. Reported-and-tested-by: [email protected] Signed-off-by: Lizhi Xu <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Jan Kara <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28bcache: Fixup error handling in register_cache()Jan Kara1-13/+10
Coverity has noticed that the printing of error message in register_cache() uses already freed bdev_handle to get to bdev. In fact the problem has been there even before commit "bcache: Convert to bdev_open_by_path()" just a bit more subtle one - cache object itself could have been freed by the time we looked at ca->bdev and we don't hold any reference to bdev either so even that could in principle go away (due to device unplug or similar). Fix all these problems by printing the error message before closing the bdev. Fixes: dc893f51d24a ("bcache: Convert to bdev_open_by_path()") Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Asked-by: Coly Li <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28xfs: Convert to bdev_open_by_path()Jan Kara3-31/+36
Convert xfs to use bdev_open_by_path() and pass the handle around. CC: "Darrick J. Wong" <[email protected]> CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Dave Chinner <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Acked-by: "Darrick J. Wong" <[email protected]> Reviewed-by: "Darrick J. Wong" <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28reiserfs: Convert to bdev_open_by_dev/path()Jan Kara3-36/+33
Convert reiserfs to use bdev_open_by_dev/path() and pass the handle around. CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28ocfs2: Convert to use bdev_open_by_dev()Jan Kara1-36/+45
Convert ocfs2 heartbeat code to use bdev_open_by_dev() and pass the handle around. CC: Joseph Qi <[email protected]> CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Joseph Qi <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28nfs/blocklayout: Convert to use bdev_open_by_dev/path()Jan Kara2-40/+38
Convert block device handling to use bdev_open_by_dev/path() and pass the handle around. CC: [email protected] CC: Trond Myklebust <[email protected]> CC: Anna Schumaker <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28jfs: Convert to bdev_open_by_dev()Jan Kara3-16/+18
Convert jfs to use bdev_open_by_dev() and pass the handle around. CC: Dave Kleikamp <[email protected]> CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: Dave Kleikamp <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28f2fs: Convert to bdev_open_by_dev/path()Jan Kara2-6/+8
Convert f2fs to use bdev_open_by_dev/path() and pass the handle around. CC: Jaegeuk Kim <[email protected]> CC: Chao Yu <[email protected]> CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28ext4: Convert to bdev_open_by_dev()Jan Kara3-30/+33
Convert ext4 to use bdev_open_by_dev() and pass the handle around. CC: [email protected] CC: Ted Tso <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28erofs: Convert to use bdev_open_by_path()Jan Kara3-13/+13
Convert erofs to use bdev_open_by_path() and pass the handle around. CC: Gao Xiang <[email protected]> CC: Chao Yu <[email protected]> CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: Gao Xiang <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28btrfs: Convert to bdev_open_by_path()Jan Kara4-72/+73
Convert btrfs to use bdev_open_by_path() and pass the handle around. We also drop the holder from struct btrfs_device as it is now not needed anymore. CC: David Sterba <[email protected]> CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28fs: Convert to bdev_open_by_dev()Jan Kara4-8/+12
Convert mount code to use bdev_open_by_dev() and propagate the handle around to bdev_release(). Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28mm/swap: Convert to use bdev_open_by_dev()Jan Kara2-11/+13
Convert swapping code to use bdev_open_by_dev() and pass the handle around. CC: [email protected] CC: Andrew Morton <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28PM: hibernate: Drop unused snapshot_test argumentJan Kara3-11/+11
snapshot_test argument is now unused in swsusp_close() and load_image_and_restore(). Drop it CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: "Rafael J. Wysocki" <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28PM: hibernate: Convert to bdev_open_by_dev()Jan Kara1-15/+16
Convert hibernation code to use bdev_open_by_dev(). CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: "Rafael J. Wysocki" <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28scsi: target: Convert to bdev_open_by_path()Jan Kara4-22/+26
Convert iblock and pscsi drivers to use bdev_open_by_path() and pass the handle around. CC: [email protected] CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: "Martin K. Petersen" <[email protected]> Signed-off-by: Christian Brauner <[email protected]>
2023-10-28s390/dasd: Convert to bdev_open_by_path()Jan Kara4-30/+31
Convert dasd to use bdev_open_by_path() and pass the handle around. CC: [email protected] CC: Christian Borntraeger <[email protected]> CC: Sven Schnelle <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28nvmet: Convert to bdev_open_by_path()Jan Kara2-9/+12
Convert nvmet to use bdev_open_by_path() and pass the handle around. CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Reviewed-by: Chaitanya Kulkarni <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28mtd: block2mtd: Convert to bdev_open_by_dev/path()Jan Kara1-22/+29
Convert block2mtd to use bdev_open_by_dev() and bdev_open_by_path() and pass the handle around. CC: Joern Engel <[email protected]> CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28md: Convert to bdev_open_by_dev()Jan Kara2-18/+9
Convert md to use bdev_open_by_dev() and pass the handle around. We also don't need the 'Holder' flag anymore so remove it. CC: [email protected] CC: Song Liu <[email protected]> Acked-by: Song Liu <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28dm: Convert to bdev_open_by_dev()Jan Kara2-9/+12
Convert device mapper to use bdev_open_by_dev() and pass the handle around. CC: Alasdair Kergon <[email protected]> CC: Mike Snitzer <[email protected]> CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28bcache: Convert to bdev_open_by_path()Jan Kara2-37/+43
Convert bcache to use bdev_open_by_path() and pass the handle around. CC: [email protected] CC: Coly Li <[email protected]> CC: Kent Overstreet <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Acked-by: Coly Li <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28zram: Convert to use bdev_open_by_dev()Jan Kara2-18/+15
Convert zram to use bdev_open_by_dev() and pass the handle around. CC: Minchan Kim <[email protected]> CC: Sergey Senozhatsky <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Reviewed-by: Sergey Senozhatsky <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28xen/blkback: Convert to bdev_open_by_dev()Jan Kara3-23/+25
Convert xen/blkback to use bdev_open_by_dev() and pass the handle around. CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28rnbd-srv: Convert to use bdev_open_by_path()Jan Kara2-14/+15
Convert rnbd-srv to use bdev_open_by_path() and pass the handle around. CC: Jack Wang <[email protected]> CC: "Md. Haris Iqbal" <[email protected]> Acked-by: "Md. Haris Iqbal" <[email protected]> Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28pktcdvd: Convert to bdev_open_by_dev()Jan Kara2-36/+44
Convert pktcdvd to use bdev_open_by_dev(). Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28drdb: Convert to use bdev_open_by_path()Jan Kara2-33/+34
Convert drdb to use bdev_open_by_path(). CC: [email protected] Acked-by: Christoph Hellwig <[email protected]> Acked-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28block: Use bdev_open_by_dev() in disk_scan_partitions() and blkdev_bszset()Jan Kara2-8/+10
Convert disk_scan_partitions() and blkdev_bszset() to use bdev_open_by_dev(). Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28block: Use bdev_open_by_dev() in blkdev_open()Jan Kara3-16/+32
Convert blkdev_open() to use bdev_open_by_dev(). To be able to propagate handle from blkdev_open() to blkdev_release() we need to stop using existence of file->private_data to determine exclusive block device opens. Use bdev_handle->mode for this purpose since file->f_flags isn't usable for this (O_EXCL is cleared from the flags during open). Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28block: Provide bdev_open_* functionsJan Kara2-0/+58
Create struct bdev_handle that contains all parameters that need to be passed to blkdev_put() and provide bdev_open_* functions that return this structure instead of plain bdev pointer. This will eventually allow us to pass one more argument to blkdev_put() (renamed to bdev_release()) without too much hassle. Acked-by: Christoph Hellwig <[email protected]> Reviewed-by: Christian Brauner <[email protected]> Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Christian Brauner <[email protected]>
2023-10-28net: fill in MODULE_DESCRIPTION()s under drivers/net/Jakub Kicinski7-0/+7
W=1 builds now warn if module is built without a MODULE_DESCRIPTION(). Acked-by: Willem de Bruijn <[email protected]> Acked-by: Jamal Hadi Salim <[email protected]> Acked-by: Arnd Bergmann <[email protected]> Acked-by: Jason Wang <[email protected]> Acked-by: Taehee Yoo <[email protected]> Signed-off-by: Jakub Kicinski <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2023-10-28net: fill in MODULE_DESCRIPTION()s under net/802*Jakub Kicinski7-0/+7
W=1 builds now warn if module is built without a MODULE_DESCRIPTION(). Reviewed-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Jakub Kicinski <[email protected]> Signed-off-by: David S. Miller <[email protected]>
2023-10-28net: fill in MODULE_DESCRIPTION()s under net/coreJakub Kicinski2-0/+2
W=1 builds now warn if module is built without a MODULE_DESCRIPTION(). Reviewed-by: Oleksij Rempel <[email protected]> Signed-off-by: Jakub Kicinski <[email protected]> Signed-off-by: David S. Miller <[email protected]>