Skip to content

Commit 2ae624d

Browse files
jagalacticweiny2
authored andcommitted
dax: export dax_dev_get()
famfs needs to look up a dax_device by dev_t when resolving fmap entries that reference character dax devices. Reviewed-by: Dave Jiang <dave.jiang@intel.com> Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com> Signed-off-by: John Groves <john@groves.net> Link: https://patch.msgid.link/0100019d311daab5-bb212f0b-4e05-4668-bf53-d76fab56be68-000000@email.amazonses.com Signed-off-by: Ira Weiny <ira.weiny@intel.com>
1 parent eec38f5 commit 2ae624d

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

drivers/dax/super.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -521,7 +521,7 @@ static int dax_set(struct inode *inode, void *data)
521521
return 0;
522522
}
523523

524-
static struct dax_device *dax_dev_get(dev_t devt)
524+
struct dax_device *dax_dev_get(dev_t devt)
525525
{
526526
struct dax_device *dax_dev;
527527
struct inode *inode;
@@ -544,6 +544,7 @@ static struct dax_device *dax_dev_get(dev_t devt)
544544

545545
return dax_dev;
546546
}
547+
EXPORT_SYMBOL_GPL(dax_dev_get);
547548

548549
struct dax_device *alloc_dax(void *private, const struct dax_operations *ops)
549550
{

include/linux/dax.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ struct dax_device *alloc_dax(void *private, const struct dax_operations *ops);
5454
void *dax_holder(struct dax_device *dax_dev);
5555
void put_dax(struct dax_device *dax_dev);
5656
void kill_dax(struct dax_device *dax_dev);
57+
struct dax_device *dax_dev_get(dev_t devt);
5758
void dax_write_cache(struct dax_device *dax_dev, bool wc);
5859
bool dax_write_cache_enabled(struct dax_device *dax_dev);
5960
bool dax_synchronous(struct dax_device *dax_dev);

0 commit comments

Comments
 (0)