docs/125639: [patch] kldunloadf(2) does not mention about possible error EINVAL

Mateusz Guzik mjguzik at gmail.com
Tue Jul 15 14:40:04 UTC 2008


>Number:         125639
>Category:       docs
>Synopsis:       [patch] kldunloadf(2) does not mention about possible error EINVAL
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-doc
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          doc-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jul 15 14:40:04 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Mateusz Guzik
>Release:        8.0-CURRENT
>Organization:
>Environment:
FreeBSD eternal 8.0-CURRENT FreeBSD 8.0-CURRENT #18: Tue Jul 15 15:35:46 CEST 2008     f at eternal:/usr/obj/usr/src/sys/ETERNAL  i386

>Description:
Function kldunloadf performs the following check before calling kern_kldunload:
 if (uap->flags != LINKER_UNLOAD_NORMAL &&
            uap->flags != LINKER_UNLOAD_FORCE)
                return (EINVAL);

But this return value is not documented.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

--- lib/libc/sys/kldunload.2.orig	2008-07-15 03:11:29.000000000 +0200
+++ lib/libc/sys/kldunload.2	2008-07-15 03:21:15.000000000 +0200
@@ -67,10 +67,13 @@
 You do not have access to unlink the file from the kernel.
 .It Bq Er ENOENT
 The file was not found.
 .It Bq Er EBUSY
 You attempted to unload a file linked by the kernel.
+.It Bq Er EINVAL
+.Fn kldunloadf
+was called with invalid flags.
 .El
 .Sh SEE ALSO
 .Xr kldfind 2 ,
 .Xr kldfirstmod 2 ,
 .Xr kldload 2 ,


>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-doc mailing list