|
Ubox
OpenWrt core utilities
|
#include <sys/syscall.h>#include <sys/mman.h>#include <sys/utsname.h>#include <stdlib.h>#include <unistd.h>#include <sys/types.h>#include <values.h>#include <errno.h>#include <stdio.h>#include <string.h>#include <sys/stat.h>#include <fcntl.h>#include <libgen.h>#include <glob.h>#include <elf.h>#include <ctype.h>#include <libubox/avl.h>#include <libubox/avl-cmp.h>#include <libubox/utils.h>#include <libubox/ulog.h>#include <libubox/kvlist.h>#include <libubox/list.h>Go to the source code of this file.
Data Structures | |
| struct | param |
| struct | module |
| struct | module_node |
Macros | |
| #define | _GNU_SOURCE |
| #define | DEF_MOD_PATH "/modules/%s/" |
| #define | MOD_BUILTIN "modules.builtin" |
| #define | MOD_BUILTIN_MODINFO "modules.builtin.modinfo" |
| #define | MODULE_NAME_LEN (64 - sizeof(unsigned long)) |
Enumerations | |
| enum | { BUILTIN , SCANNED , PROBE , LOADED , BLACKLISTED } |
Functions | |
| static | KVLIST (options, kvlist_strlen) |
| static void | free_module (struct module *m) |
| static int | init_module_folders (void) |
| static struct module * | find_module (const char *name) |
| static void | free_modules (void) |
| static char * | get_module_path (char *name) |
| static char * | get_module_name (char *path) |
| static int | elf64_find_section (char *map, const char *section, unsigned int *offset, unsigned int *size) |
| static int | elf32_find_section (char *map, const char *section, unsigned int *offset, unsigned int *size) |
| static int | elf_find_section (char *map, const char *section, unsigned int *offset, unsigned int *size) |
| static struct module_node * | alloc_module_node (const char *name, struct module *m, bool is_alias) |
| static struct module * | alloc_module (const char *name, const char *const *aliases, int naliases, const char *depends, int size) |
| static int | scan_loaded_modules (void) |
| static char * | mmap_modinfo (const char *module, const char *name, struct stat *s, unsigned int *offset, unsigned int *size) |
| static struct module * | get_module_info (const char *module, const char *name) |
| static int | scan_builtin_modules (void) |
| static int | scan_module_folder (const char *dir) |
| static int | scan_module_folders (void) |
| static int | print_modinfo (const struct module *m) |
| static int | deps_available (struct module *m, int verbose) |
| static int | insert_module (char *path, const char *options) |
| static void | load_moddeps (struct module *_m) |
| static int | load_modprobe (bool allow_load_retry) |
| static int | print_insmod_usage (void) |
| static int | print_modprobe_usage (void) |
| static int | print_usage (char *arg) |
| static int | main_insmod (int argc, char **argv) |
| static int | main_rmmod (int argc, char **argv) |
| static int | main_lsmod (int argc, char **argv) |
| static int | main_modinfo (int argc, char **argv) |
| static int | main_modprobe (int argc, char **argv) |
| static int | main_loader (int argc, char **argv) |
| static char | weight (char c) |
| static int | avl_modcmp (const void *k1, const void *k2, void *ptr) |
| static void | load_options (void) |
| int | main (int argc, char **argv) |
Variables | |
| static struct avl_tree | modules |
| static char ** | module_folders = NULL |
| #define _GNU_SOURCE |
Definition at line 15 of file kmodloader.c.
| #define DEF_MOD_PATH "/modules/%s/" |
Definition at line 42 of file kmodloader.c.
| #define MOD_BUILTIN "modules.builtin" |
Definition at line 43 of file kmodloader.c.
| #define MOD_BUILTIN_MODINFO "modules.builtin.modinfo" |
Definition at line 44 of file kmodloader.c.
| #define MODULE_NAME_LEN (64 - sizeof(unsigned long)) |
Definition at line 46 of file kmodloader.c.
| anonymous enum |
|
static |
Definition at line 281 of file kmodloader.c.


|
static |
Definition at line 263 of file kmodloader.c.

|
static |
Definition at line 1254 of file kmodloader.c.


|
static |
Definition at line 713 of file kmodloader.c.


|
static |
|
static |
|
static |
Definition at line 235 of file kmodloader.c.


|
static |
|
static |
|
static |
Definition at line 145 of file kmodloader.c.


|
static |
Definition at line 423 of file kmodloader.c.


|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
Definition at line 781 of file kmodloader.c.


|
static |
Definition at line 805 of file kmodloader.c.


|
static |
| int main | ( | int | argc, |
| char ** | argv | ||
| ) |
Definition at line 1344 of file kmodloader.c.

|
static |
Definition at line 882 of file kmodloader.c.


|
static |
Definition at line 1135 of file kmodloader.c.


|
static |
Definition at line 985 of file kmodloader.c.


|
static |
Definition at line 1019 of file kmodloader.c.


|
static |
Definition at line 1045 of file kmodloader.c.


|
static |
Definition at line 950 of file kmodloader.c.


|
static |
Definition at line 367 of file kmodloader.c.


|
static |
|
static |
Definition at line 607 of file kmodloader.c.


|
static |
|
static |
|
static |
Definition at line 493 of file kmodloader.c.


|
static |
Definition at line 321 of file kmodloader.c.


|
static |
Definition at line 547 of file kmodloader.c.


|
static |
Definition at line 593 of file kmodloader.c.


|
inlinestatic |
|
static |
Definition at line 84 of file kmodloader.c.
|
static |
Definition at line 1 of file kmodloader.c.