Kernel Compilation problem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all

I was trying to add a syscall . The syscall just did copy_to_user

int mycall(struct timeval* arg)
{
	copy_to_user(arg,&xtime, sizeof(struct timeval));
}

The include files for this are

#include<asm/uaccess.h>
#include<sys/time.h>
#include<linux/kernel.h>

This gives a lot of parse errors in uaccess.h and many files it includes
like sched.h etc. .. errors like semicolon missing and } missing.

Before compiling, I made certain links :

/usr/include/asm a link to /usr/src/linux/include/asm

and /usr/include/linux a link to /usr/src/linux/include/linux.

If I remove #inlcude<asm/uaccess.h> and the copy_to_user() call and put a
printk , then it works fine.

I am not able to make out what the problem is. Can anyone help me ?

Thanx
Narasimhamurthy Giri, Clemson University Computer Science Dept.
-------------------------------------------------------------------------------
Judge not lest ye be judged yourself.
-------------------------------------------------------------------------------


--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux