I m making device driver in linux by using FEDORA CORE 1, but when i was
compiling the following module :

 //*******************  Start  ******************//

#define MODULE
#include <linux/module.h>
#include<linux/fs.h>
static int lp_open(struct inode * inode, struct file * file);

static struct file_operations lp_fops =
 {
  owner:        THIS_MODULE,
  open: lp_open,
 };

int init_module(void)

 {    int resinit;
      printk("<0>HI DEAR MODULE HAS BEEN INSERTED ONCE\n");
      resinit = register_chrdev(252, "SATENDRA PRATAP", &lp_fops);
      return 0;
 }

void cleanup_module(void)
{
    int resclean;
    printk("<0>BYE DEAR unloading.......\n");
    resclean = unregister_chrdev(252, "SATENDRA PRATAP");
    if(resclean<0)
         printk("<0>ERROR  OCCURED unregistering return < 0 \n");
}




               //************END*****************//

I was getting the error.PLEASE help me as soon as possible.

_______________________________________________
ilugd mailinglist -- [EMAIL PROTECTED]
http://frodo.hserus.net/mailman/listinfo/ilugd
Archives at: http://news.gmane.org/gmane.user-groups.linux.delhi 
http://www.mail-archive.com/[EMAIL PROTECTED]/

Reply via email to