From: Huaisheng Ye Date: Mon, 30 Jul 2018 07:15:46 +0000 (+0800) Subject: dax/super: Do not request a pointer kaddr when not required X-Git-Tag: v4.19~279^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e0b401e3fef0f81fd87434793db1adb0d7568058;p=platform%2Fkernel%2Flinux-rpi.git dax/super: Do not request a pointer kaddr when not required Function __bdev_dax_supported doesn't need to get local pointer kaddr from direct_access. Using NULL instead of having to pass in a useless local pointer that caller then just throw away. Signed-off-by: Huaisheng Ye Reviewed-by: Ross Zwisler Signed-off-by: Dave Jiang --- diff --git a/drivers/dax/super.c b/drivers/dax/super.c index 903d9c4..c2f42b1 100644 --- a/drivers/dax/super.c +++ b/drivers/dax/super.c @@ -88,7 +88,6 @@ bool __bdev_dax_supported(struct block_device *bdev, int blocksize) bool dax_enabled = false; pgoff_t pgoff; int err, id; - void *kaddr; pfn_t pfn; long len; char buf[BDEVNAME_SIZE]; @@ -114,7 +113,7 @@ bool __bdev_dax_supported(struct block_device *bdev, int blocksize) } id = dax_read_lock(); - len = dax_direct_access(dax_dev, pgoff, 1, &kaddr, &pfn); + len = dax_direct_access(dax_dev, pgoff, 1, NULL, &pfn); dax_read_unlock(id); put_dax(dax_dev);