From 68ec2949ad3411aa8a684dfca2cae90cbe202675 Mon Sep 17 00:00:00 2001 From: Hans Petter Selasky Date: Fri, 11 Mar 2022 17:37:46 +0100 Subject: [PATCH] lindebugfs: The Linux file operations use negative return values in the kernel. Fix sign. MFC after: 1 week Sponsored by: NVIDIA Networking --- sys/compat/lindebugfs/lindebugfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/compat/lindebugfs/lindebugfs.c b/sys/compat/lindebugfs/lindebugfs.c index 9507cded9eb..cbfdfbbce87 100644 --- a/sys/compat/lindebugfs/lindebugfs.c +++ b/sys/compat/lindebugfs/lindebugfs.c @@ -152,12 +152,12 @@ debugfs_fill(PFS_FILL_ARGS) if (d->dm_fops->read) rc = d->dm_fops->read(&lf, NULL, len, &off); else - rc = ENODEV; + rc = -ENODEV; } else { if (d->dm_fops->write) rc = d->dm_fops->write(&lf, buf, len, &off); else - rc = ENODEV; + rc = -ENODEV; } if (d->dm_fops->release) d->dm_fops->release(&vn, &lf);