null_blk: add usage hints for NVM

If CONFIG_NVM is disabled, loading null_block module with use_lightnvm=1
fails. But there are no messages and documents related to the failure.

Add the appropriate error message.

Signed-off-by: Yasuaki Ishimatsu <[email protected]>

Massaged the text a bit.

Signed-off-by: Jens Axboe <[email protected]>
This commit is contained in:
Yasuaki Ishimatsu 2016-11-16 08:26:11 -07:00 • committed by Jens Axboe
commit 92153d30c7
2 changed files with 2 additions and 1 deletions

View file

@ -577,6 +577,7 @@ static void null_nvm_unregister(struct nullb *nullb)
#else
static int null_nvm_register(struct nullb *nullb)
{
pr_err("null_blk: CONFIG_NVM needs to be enabled for LightNVM\n");
return -EINVAL;
}
static void null_nvm_unregister(struct nullb *nullb) {}