From: root <abz@videotron.ca>
To: linuxppc-dev@lists.linuxppc.org
Subject: First try with module: need help
Date: Mon, 24 Apr 2000 05:48:50 -0400 [thread overview]
Message-ID: <39041882.782A42CD@videotron.ca> (raw)
I try the very simple module (below) in "Linux device driver" by
Alessandro Rubini
and I get this error message:
couldn't find the kernel version the module was compiled for
even if the first line of the C source is
#define __NO_VERSION__
Do I need something special to complile the module
----------------- mod_1.c
#define MODULE
#define __NO_VERSION__
#include <linux/module.h>
#include <linux/version.h>
int init_module(void)
{
printk("<1>This is a simple module\n");
return 0;
}
void cleanup_module(void)
{
printk("<1>The simple module is done\n");
}
----------------- to compile
if test -f ./mod
then
rm ./mod
fi
gcc -c mod_1.c -o mod.o
if test -f ./mod.o
then
insmod -f mod.o
echo 'blablabla'
rmmod mod
fi
** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/
reply other threads:[~2000-04-24 9:48 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=39041882.782A42CD@videotron.ca \
--to=abz@videotron.ca \
--cc=linuxppc-dev@lists.linuxppc.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).