diff options
| author | Trond Myklebust <trond.myklebust@primarydata.com> | 2016-07-24 12:51:10 -0400 |
|---|---|---|
| committer | Trond Myklebust <trond.myklebust@primarydata.com> | 2016-07-24 12:51:10 -0400 |
| commit | dc05973b288a5226bb7e56afd6c2fa07560a907c (patch) | |
| tree | 2e1eade8b6010ff4c844341fdeec9ee966d75ac7 /kernel/kcov.c | |
| parent | 297fae4d0bee5d683533f3324baf1b363e7b48bf (diff) | |
| parent | e7bdea7750eb2a64aea4a08fa5c0a31719c8155d (diff) | |
Merge commit 'e7bdea7750eb'
Needed in order to work on top of pNFS changes in Linus' upstream kernel.
Diffstat (limited to 'kernel/kcov.c')
| -rw-r--r-- | kernel/kcov.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/kernel/kcov.c b/kernel/kcov.c index a02f2dddd1d7..8d44b3fea9d0 100644 --- a/kernel/kcov.c +++ b/kernel/kcov.c @@ -264,7 +264,12 @@ static const struct file_operations kcov_fops = { static int __init kcov_init(void) { - if (!debugfs_create_file("kcov", 0600, NULL, NULL, &kcov_fops)) { + /* + * The kcov debugfs file won't ever get removed and thus, + * there is no need to protect it against removal races. The + * use of debugfs_create_file_unsafe() is actually safe here. + */ + if (!debugfs_create_file_unsafe("kcov", 0600, NULL, NULL, &kcov_fops)) { pr_err("failed to create kcov in debugfs\n"); return -ENOMEM; } |
