diff options
| author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2019-09-16 09:56:27 -0700 |
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2019-09-16 09:56:27 -0700 |
| commit | 0898782247ae533d1f4e47a06bc5d4870931b284 (patch) | |
| tree | 21f75cc590542a870f42350b9410fc0588f02b79 /lib/notifier-error-inject.c | |
| parent | 0c043d70d04711fe6c380df9065fdc44192c49bf (diff) | |
| parent | 410f25de467ee94c1a577c6ee7370c37b376c17c (diff) | |
Merge branch 'next' into for-linus
Prepare input updates for 5.4 merge window.
Diffstat (limited to 'lib/notifier-error-inject.c')
| -rw-r--r-- | lib/notifier-error-inject.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/lib/notifier-error-inject.c b/lib/notifier-error-inject.c index 3d2ba7cf83f4..21016b32d313 100644 --- a/lib/notifier-error-inject.c +++ b/lib/notifier-error-inject.c @@ -59,33 +59,22 @@ struct dentry *notifier_err_inject_init(const char *name, struct dentry *parent, err_inject->nb.priority = priority; dir = debugfs_create_dir(name, parent); - if (!dir) - return ERR_PTR(-ENOMEM); actions_dir = debugfs_create_dir("actions", dir); - if (!actions_dir) - goto fail; for (action = err_inject->actions; action->name; action++) { struct dentry *action_dir; action_dir = debugfs_create_dir(action->name, actions_dir); - if (!action_dir) - goto fail; /* * Create debugfs r/w file containing action->error. If * notifier call chain is called with action->val, it will * fail with the error code */ - if (!debugfs_create_errno("error", mode, action_dir, - &action->error)) - goto fail; + debugfs_create_errno("error", mode, action_dir, &action->error); } return dir; -fail: - debugfs_remove_recursive(dir); - return ERR_PTR(-ENOMEM); } EXPORT_SYMBOL_GPL(notifier_err_inject_init); |
