diff options
author | Alexander Aring <aahringo@redhat.com> | 2023-08-01 14:09:42 -0400 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2023-08-10 10:33:03 -0500 |
commit | 8c95006d55726eeebf3b863335accfba50d4bc8f (patch) | |
tree | d2dc2c1b1ec85f630895eb063470f199cd97b020 /fs/dlm | |
parent | 67b5da9a40fc984d25bda90a918e490e8c2555b7 (diff) |
fs: dlm: add plock dev tracepoints
I currently debug nfs plock handling and introduce those two tracepoints
for getting more information about what is happening there if the user
space reads plock operations from kernel and writing the result back.
Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>
Diffstat (limited to 'fs/dlm')
-rw-r--r-- | fs/dlm/plock.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/dlm/plock.c b/fs/dlm/plock.c index 5c2cc8d940ef..00e1d802a81c 100644 --- a/fs/dlm/plock.c +++ b/fs/dlm/plock.c @@ -11,6 +11,8 @@ #include <linux/dlm_plock.h> #include <linux/slab.h> +#include <trace/events/dlm.h> + #include "dlm_internal.h" #include "lockspace.h" @@ -509,6 +511,8 @@ static ssize_t dev_read(struct file *file, char __user *u, size_t count, if (!op) return -EAGAIN; + trace_dlm_plock_read(&info); + /* there is no need to get a reply from userspace for unlocks that were generated by the vfs cleaning up for a close (the process did not make an unlock call). */ @@ -536,6 +540,8 @@ static ssize_t dev_write(struct file *file, const char __user *u, size_t count, if (copy_from_user(&info, u, sizeof(info))) return -EFAULT; + trace_dlm_plock_write(&info); + if (check_version(&info)) return -EINVAL; |