LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (https://www.linuxquestions.org/questions/ubuntu-63/)
-   -   Having trouble registering a system call in ubuntu (https://www.linuxquestions.org/questions/ubuntu-63/having-trouble-registering-a-system-call-in-ubuntu-772632/)

rasbambober 12-01-2009 04:40 AM

Having trouble registering a system call in ubuntu
 
hi all,

i have kernel hacking assignments as my operating systems course ...i am trying to register a simple system call on ubuntu that simply prints with kprint stmt

Code:

#include <linux/kernel.h>

asmlinkage long sys_cs2456_test(int arg0)
{
  printk(" Hello World !");
  printk("--syscall arg %d", arg0);

  return((long) arg0);
}

i register this call in the following files ... following their syntax strictly:

arch/x86/kernel/syscall_table_32.S
and
arch/x86/include/asm/unistd_32.h

i also update the Makefile for linux with the folder for my sys call ... when i make the kernel it generates the object file but when i test the system call in user space it gives me an error that my system call is not defined.

help!!!!!!!!!!!!!!


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