4
* Copyright (C) 2002-2005 Novell/SUSE
6
* This program is free software; you can redistribute it and/or
7
* modify it under the terms of the GNU General Public License as
8
* published by the Free Software Foundation, version 2 of the
11
* $Id: syscall_query_module.c 61 2006-05-19 18:32:14Z steve-beattie $
17
#include <sys/types.h>
18
#include <linux/module.h>
21
int main(int argc, char *argv[])
25
struct module_info modinfo;
28
fprintf(stderr, "Usage: %s [module]\n",
31
} else if (argc == 1) {
32
if (query_module(NULL, QM_MODULES, &buffer, BUFSIZE,
34
fprintf(stderr, "FAIL: query_module failed - %s\n",
38
/* printf ("First module: %s\n", buffer); */
40
if (query_module(argv[1], QM_INFO, &modinfo, sizeof(modinfo),
42
fprintf(stderr, "FAIL: query_module failed - %s\n",
46
/* printf ("module %s info: address 0x%8x size %u flags 0x%8x "
55
/* printf("Kernel release version is %s\n", release); */