[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <201008302055.GEG52699.MJHtQLFOFOSFVO@I-love.SAKURA.ne.jp>
Date: Mon, 30 Aug 2010 20:55:43 +0900
From: Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
To: estellnb@...il.com
Cc: netdev@...r.kernel.org, netfilter-devel@...r.kernel.org
Subject: Re: block network access for certain users/groups
Elmar Stellnberger wrote:
> However if I compile the kernel module and try to load it that results
> in a kernel hang that I can only escape by Alt-PrnScr-S-U-B, no matter
> whether the module is loaded on boot time or in rl5. I have checked
> all required kernel options and built it like the following (using
> openSUSE 11.3):
This module is for 2.6.36 but openSUSE 11.3 uses 2.6.34 . Did you change
below spin_lock() to write_lock() and spin_unlock() to write_unlock()?
> > {
> > struct fs_struct *fs = current->fs;
> > struct vfsmount *mnt = current->nsproxy->pid_ns->proc_mnt;
> > struct path old_path;
> > struct path new_path = { mnt, mnt->mnt_root };
> > spin_lock(&fs->lock); /* was write_lock() till 2.6.35. */
> > old_path = fs->pwd;
> > fs->pwd = new_path;
> > spin_unlock(&fs->lock);
> > file = filp_open("kallsyms", O_RDONLY, 0);
> > spin_lock(&fs->lock);
> > fs->pwd = old_path;
> > spin_unlock(&fs->lock);
> > }
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists