LinuxAnswers - the LQ Linux tutorial section.
Go Back > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Linux - Kernel This forum is for all discussion relating to the Linux kernel.


  Search this Thread
Old 12-16-2010, 11:55 PM   #1
LQ Newbie
Registered: Dec 2010
Posts: 4

Rep: Reputation: 0
Unhappy add a system call in 2.6.36 kernel

im facing this problem..

i want to add a new system following this guide .

in this step 6 he said add __NR_mycall to some number, in unistd.h...

My problem here is..
1) in include/asm/unistd.h there are are around 1079 calls for different hardwares. and the __NR_SYSCALLS is also defined many places...

I dont know where to add my new system call....

and another qn is ..

whether the number for syscall in unistd.h and arch/x86/syscall_32.s both should be same?or they can be different...please help me out here...

Thanks in advance
Old 12-17-2010, 08:02 AM   #2
Registered: Jan 2005
Location: Midwest USA, Central Illinois
Distribution: SlackwareŽ
Posts: 12,029
Blog Entries: 16

Rep: Reputation: 1681Reputation: 1681Reputation: 1681Reputation: 1681Reputation: 1681Reputation: 1681Reputation: 1681Reputation: 1681Reputation: 1681Reputation: 1681Reputation: 1681

I moved your thread to Linux - Kerne for better exposure in order to get responses that will aid.
Old 12-17-2010, 11:13 AM   #3
Deep Narayan Dubey
LQ Newbie
Registered: Dec 2010
Location: Allahabad, India
Posts: 11

Rep: Reputation: 8
I think the guide you have mentioned above is written for the earlier linux kernel version. In linux-2.6.32 there is no such file but there is a file name include/asm-generic/ for implementing the system call you have to make change in arch/x86/include/asm/unistd_32.h if you are using i386 processor. For further help you can see on the following links-


Edit: Please don't post duplicates that differ only in the links you provide -- use the "Edit" feature if that was an accident. Merged your posts.

Last edited by archtoad6; 12-17-2010 at 08:30 PM. Reason: Merge & explain


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
What is the best method to add system call in linux kernel? vrrathod Linux - Kernel 2 10-30-2009 02:37 AM
How to add a system call in 2.6.x kernel SungWon Chung Linux - Kernel 2 11-26-2007 10:32 PM
I want add my own system call using LKM (loadable kernel module)... raga4223688 Linux - Software 1 03-07-2007 08:21 AM
Add New System Call in RH9 kernel-2.4.20-8 kamal_h_mehta Programming 0 04-08-2006 09:51 AM
how to add another system call in to the kernel?? Pratik H Pandya Programming 1 03-26-2006 03:02 AM

All times are GMT -5. The time now is 10:28 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration