Commit 62d3bab5 authored by Joe Thornber's avatar Joe Thornber Committed by Linus Torvalds

[PATCH] dm: allow slashes in dm device names

Allow slashes ('/') within a DM device name, but not at the beginning.

Devfs will automatically create all necessary sub-directories if a name
with embedded slashes is registered.  [Kevin Corry]
parent 62baf68a
...@@ -545,7 +545,7 @@ static inline int get_mode(struct dm_ioctl *param) ...@@ -545,7 +545,7 @@ static inline int get_mode(struct dm_ioctl *param)
static int check_name(const char *name) static int check_name(const char *name)
{ {
if (strchr(name, '/')) { if (name[0] == '/') {
DMWARN("invalid device name"); DMWARN("invalid device name");
return -EINVAL; return -EINVAL;
} }
......
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