summaryrefslogtreecommitdiffstats
path: root/sys/sys/module.h
Commit message (Collapse)AuthorAgeFilesLines
* - Lock down the ``module'' structure by adding an SX lock that is used byarr2002-03-181-0/+9
| | | | | | | | | all the global bits of ``module'' data. This commit adds a few generic macros, MOD_SLOCK, MOD_XLOCK, etc., that are meant to be used as ways of accessing the SX lock. It is also the first step in helping to lock down the kernel linker and module systems. Reviewed by: jhb, jake, smp@
* Fix syntax error, where this was not compile tested after style(9)'ing.obrien2002-03-011-1/+1
|
* - Style(9) makeover.arr2002-02-281-85/+80
| | | | Reviewed by: chris, mike
* Use protected variables names in prototypes visible to the userland asdd2001-09-091-4/+4
| | | | per style(9) and most other header files in sys/.
* Constify the module name. This silences a few warnings ("initializationdes2001-06-191-2/+2
| | | | | | | discards qualifier"), and probably adds a few where module names are compared to or passed as non-const strings. Not-objected-to-by: bde
* First round implementation of a fine grain enhanced module to modulepeter2000-04-291-0/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | version dependency system. This isn't quite finished, but it is at a useful stage to do a functional checkpoint. Highlights: - version and dependency metadata is gathered via linker sets, so things are handled the same for static kernels and code built to live in a kld. - The dependencies are at module level (versus at file level). - Dependencies determine kld symbol search order - this means that you cannot link against symbols in another file unless you depend on it. This is so that you cannot accidently unload the target out from underneath the ones referencing it. - It is flexible enough that we can put tags in #include files and macros so that we can get decent hooks for enforcing recompiles on incompatable ABI changes. eg: if we change struct proc, we could force a recompile for all kld's that reference the proc struct. - Tangled dependency references at boot time are sorted. Files are relocated once all their dependencies are already relocated. Caveats: - Loader support is incomplete, but has been worked on seperately. - Actual enforcement of the version number tags is not active yet - just the module dependencies are live. The actual structure of versioning hasn't been agreed on yet. (eg: major.minor, or whatever) - There is some backwards compatability for old modules without metadata but I'm not sure how good it is. This is based on work originally done by Boris Popov (bp@freebsd.org), but I'm not sure he'd recognize much of it now. Don't blame him. :-) Also, ideas have been borrowed from Mike Smith.
* Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL"peter1999-12-291-3/+3
| | | | | | is an application space macro and the applications are supposed to be free to use it as they please (but cannot). This is consistant with the other BSD's who made this change quite some time ago. More commits to come.
* modfind(char *) -> modfind(const char *)brian1999-11-161-1/+1
| | | | Ok'd by: dfr
* $Id$ -> $FreeBSD$peter1999-08-281-1/+1
|
* First stages of a module dependency cleanup. This part fixes apeter1999-05-081-4/+3
| | | | | | | | | | | | particularly annoying hack, namely having the linker bash the moduledata to set the container pointer, preventing it being const. In the process, a stack of warnings were fixed and will probably allow a revisit of the const C_SYSINIT() changes. This explicitly registers modules in files or preload areas with the module system first, and let them initialize via SYSINIT/DECLARE_MODULE later in their SI_ORDER_xxx order. The kludge of finding the containing file is no longer needed since the registration of modules onto the modules list is done in the context of initializing the linker file.
* More -Wall / -Wcast-qual cleanup. Also, EXEC_SET can't usedillon1999-01-291-6/+2
| | | | | C_DECLARE_MODULE due to the linker_file_sysinit() function making modifications to the data.
* Have EXEC_SET use C_DECLARE_MODULE instead of DECLARE_MODULE.dillon1999-01-291-3/+7
| | | | | | | | Add C_DECLARE_MODULE - same as DECLARE_MODULE but uses C_SYSINIT instead of SYSINIT. The C_ items are going to be used for items passing const data to sysinit.
* Fix warnings in preparation for adding -Wall -Wcast-qual to thedillon1999-01-271-2/+2
| | | | kernel compile
* Fix warnings preparing for -Wall -Wcast-qualdillon1999-01-271-2/+2
| | | | | Also disable one usb module in LINT due to fatal compilation errors, temporary.
* Implement a mechanism for a module to report a small amount of moduledfr1999-01-091-1/+14
| | | | | specific data back to the user via kldstat(2). Use that mechanism in the syscall handler to report the syscall number used.
* My changes to the new device interface:wollman1998-11-141-9/+9
| | | | | | | | | | | | | | - Interface wth the new resource manager. - Allow for multiple drivers implementing a single devclass. - Remove ordering dependencies between header files. - Style cleanup. - Add DEVICE_SUSPEND and DEVICE_RESUME methods. - Move to a single-phase interrupt setup scheme. Kernel builds on the Alpha are brken until Doug gets a chance to incorporate these changes on that side. Agreed to in principle by: dfr
* A hook for storing the origin of a module, this is important whenpeter1998-10-091-4/+6
| | | | it's being registered in sorted sysinit sequence and not in load order.
* Add initial support for the FreeBSD/alpha kernel. This is very much adfr1998-06-101-2/+3
| | | | | | | | | | work in progress and has never booted a real machine. Initial development and testing was done using SimOS (see http://simos.stanford.edu for details). On the SimOS simulator, this port successfully reaches single-user mode and has been tested with loads as high as one copy of /bin/ls :-). Obtained from: partly from NetBSD/alpha
* make a couple functions static...jmg1997-10-241-3/+3
| | | | | also change module_register_static to module_register_init as this function initalizes the module for both dynamic and static modules...
* This is the kernel linker. To use it, you will first need to applydfr1997-05-071-0/+107
the patches in freefall:/home/dfr/ld.diffs to your ld sources and set BINFORMAT to aoutkld when linking the kernel. Library changes and userland utilities will appear in a later commit.
OpenPOWER on IntegriCloud