block: remove __sync_blockdev
[ Upstream commit 70164eb6ccb76ab679b016b4b60123bf4ec6c162 ] Instead offer a new sync_blockdev_nowait helper for the !wait case. This new helper is exported as it will grow modular callers in a bit. Signed-off-by: Christoph Hellwig <hch@lst.de> Link: https://lore.kernel.org/r/20211019062530.2174626-3-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
4b7617ae04
commit
7877e7a5a5
@@ -1999,6 +1999,7 @@ int truncate_bdev_range(struct block_device *bdev, fmode_t mode, loff_t lstart,
|
||||
#ifdef CONFIG_BLOCK
|
||||
void invalidate_bdev(struct block_device *bdev);
|
||||
int sync_blockdev(struct block_device *bdev);
|
||||
int sync_blockdev_nowait(struct block_device *bdev);
|
||||
#else
|
||||
static inline void invalidate_bdev(struct block_device *bdev)
|
||||
{
|
||||
@@ -2007,6 +2008,10 @@ static inline int sync_blockdev(struct block_device *bdev)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
static inline int sync_blockdev_nowait(struct block_device *bdev)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
int fsync_bdev(struct block_device *bdev);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user