From: Vishwas Raman <vishwas@eternal-systems.com>
To: linux-kernel@vger.kernel.org
Subject: calling devinet_ioctl from a kernel module
Date: Tue, 07 Oct 2003 13:33:33 -0700 [thread overview]
Message-ID: <3F83231D.1080905@eternal-systems.com> (raw)
In-Reply-To: 3F7F4AFC.7000700@nodomain.org
Hello all,
I'm experiencing a kernel panic in RedHat Linux 8.0 with 2.4.20 kernel
when calling the function devinet_ioctl() with the SIOCSIFADDR command
from within a kernel module. The function is called within the scope of
userspace addressing in the following manner.
int res;
mm_segment_t oldfs = get_fs();
set_fs(get_ds());
res = devinet_ioctl(cmd,arg);
set_fs(oldfs);
This is how ipconfig.c illustrates how to use this function from within
a kernel module, see ic_dev_ioctl() function in the source file.
When running in the scope of a kgdb patched kernel, I see the kernel
panic when this function is called from within my kernel module. The
panic happens because alloc_skb is being called non-atomically from an
interrupt.
Is there anything grossly wrong that I am doing? Am I supposed to do
something else before calling this function?
Thanks,
Vishwas.
prev parent reply other threads:[~2003-10-07 20:35 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CYRo.18k.9@gated-at.bofh.it>
2003-10-04 18:39 ` Oops linux 2.4.23-pre6 on amd64 Andi Kleen
2003-10-04 19:05 ` Tony Hoyle
2003-10-04 19:18 ` Tony Hoyle
2003-10-04 20:55 ` Andi Kleen
2003-10-04 22:34 ` Tony Hoyle
2003-10-05 9:20 ` Andi Kleen
2003-10-05 9:35 ` Tony Hoyle
2003-10-05 14:29 ` Tony Hoyle
2003-10-05 15:37 ` Andi Kleen
2003-10-05 15:42 ` Tony Hoyle
2003-10-05 17:21 ` Marcelo Tosatti
2003-10-05 17:41 ` Tony Hoyle
2003-10-07 20:33 ` Vishwas Raman [this message]
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=3F83231D.1080905@eternal-systems.com \
--to=vishwas@eternal-systems.com \
--cc=linux-kernel@vger.kernel.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