Commit 2e8a5e48 authored by Joe Thornber's avatar Joe Thornber Committed by Linus Torvalds

[PATCH] dm: REMOVE_ALL parameter checking

No need to validate the parameters if we are doing a
REMOVE_ALL command.
parent 29cf6024
...@@ -986,6 +986,10 @@ static int copy_params(struct dm_ioctl *user, struct dm_ioctl **param) ...@@ -986,6 +986,10 @@ static int copy_params(struct dm_ioctl *user, struct dm_ioctl **param)
static int validate_params(uint cmd, struct dm_ioctl *param) static int validate_params(uint cmd, struct dm_ioctl *param)
{ {
/* Ignores parameters */
if (cmd == DM_REMOVE_ALL_CMD)
return 0;
/* Unless creating, either name of uuid but not both */ /* Unless creating, either name of uuid but not both */
if (cmd != DM_DEV_CREATE_CMD) { if (cmd != DM_DEV_CREATE_CMD) {
if ((!*param->uuid && !*param->name) || if ((!*param->uuid && !*param->name) ||
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment