On Wed, 2008-02-27 at 06:27 -0600, Maynard Johnson wrote:
> Can't do that in the "real" code I'm developing, so I guess I'll need to
> use get_user_pages. Hmmm . . . not quite as simple to use as
> copy_from_user, and I don't see any doc on it. But at least I've found
> a couple examples in t
On Wednesday 27 February 2008, Maynard Johnson wrote:
> > Sounds to me that your kernel module will try to copy_from_user() from
> > the user context of ... insmod :-)
> >
> Yeah, that's probably the problem (along with my lack of understanding
> how VM works -- heh). I guess I was just getti
Benjamin Herrenschmidt wrote:
> On Tue, 2008-02-26 at 08:49 -0600, Maynard Johnson wrote:
>
>> 2. Compile C program as 32-bit; then run it. While the program is
>> waiting for input, obtain its PID and do 'cat /proc//maps' to
>> get
>> the address of where libc is loaded.
>> 3. From the dir w
On Tue, 2008-02-26 at 08:49 -0600, Maynard Johnson wrote:
> 2. Compile C program as 32-bit; then run it. While the program is
> waiting for input, obtain its PID and do 'cat /proc//maps' to
> get
> the address of where libc is loaded.
> 3. From the dir where you build the uaccess_test kernel mo
Nathan Lynch wrote:
> Maynard Johnson wrote:
>> static long lib_addr;
>> module_param(lib_addr, long, 0);
>
> Should be unsigned long?
Right. I switched this to 'ulong', but that didn't make a difference in
my test results.
>
__
Nathan Lynch wrote:
> Maynard Johnson wrote:
> >
> > static long lib_addr;
> > module_param(lib_addr, long, 0);
>
> Should be unsigned long?
ulong, rather, but that doesn't fix it.
In any case, lib_addr is a user virtual address; doesn't the kernel
need to do get_us
Maynard Johnson wrote:
>
> static long lib_addr;
> module_param(lib_addr, long, 0);
Should be unsigned long?
___
Linuxppc-dev mailing list
Linuxppc-dev@ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-dev
Benjamin Herrenschmidt wrote:
On Mon, 2008-02-25 at 19:47 -0600, Maynard Johnson wrote:
Hi,
I'm developing a kernel module that needs to parse the in-memory ELF
objects for a shared library (libc, to be specific). When running my
test on a 32-bit library, it works fine, but for a 64-bit libra
Maynard Johnson writes:
> I'm developing a kernel module that needs to parse the in-memory ELF
> objects for a shared library (libc, to be specific). When running my
> test on a 32-bit library, it works fine, but for a 64-bit library, the
> very first copy_from_user() fails:
> Elf64_Ehdr e
On Mon, 2008-02-25 at 19:47 -0600, Maynard Johnson wrote:
> Hi,
> I'm developing a kernel module that needs to parse the in-memory ELF
> objects for a shared library (libc, to be specific). When running my
> test on a 32-bit library, it works fine, but for a 64-bit library, the
> very first co
Hi,
I'm developing a kernel module that needs to parse the in-memory ELF
objects for a shared library (libc, to be specific). When running my
test on a 32-bit library, it works fine, but for a 64-bit library, the
very first copy_from_user() fails:
Elf64_Ehdr ehdr;
copy_from_user(&ehdr,
11 matches
Mail list logo