dlm: add missing -ENOMEM if alloc_workqueue() fails
Alexander Aring
maintainerPATCH 1/1 dlm: add missing -ENOMEM if alloc_workqueue() fails
This patch sets an missing -ENOMEM as error return value when the allocation of the dlm workqueue fails.
Fixes 94e180d6255f ("dlm: async freeing of lockspace resources")
Reported-by kernel test robot <[email protected]>
Reported-by Dan Carpenter <[email protected]>
Signed-off-by Alexander Aring <[email protected]>
--- fs/dlm/main.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
fs/dlm/main.c +3 -1
@@ -53,8 +53,10 @@ static int __init init_dlm(void) goto out_user; dlm_wq =alloc_workqueue ("dlm_wq" ,0 ,0 ); -if (!dlm_wq) +if (!dlm_wq) { + error = -ENOMEM ; goto out_plock; + }printk ("DLM installed\n" );
Signature · 1 line
2.43.0