file - sys_chmod not work (linux) -


its driver init code:

int res; int gpio_major=102; struct class *device_class = class_create(this_module, "gpio");  gpio_direction_input(s5pv210_gpj2(7)); gpio_direction_input(s5pv210_gpj3(0)); gpio_direction_input(s5pv210_gpj3(1));   res = register_chrdev(gpio_major, "gpio", &gpio_fops); device_create(device_class, null, mkdev(gpio_major, 0) , null, "gpio");  sys_chmod("/dev/gpio", 777);   return 0; 

i want add mod 777 driver file , compile with: crw------ default owner can access. why sys_chmod("/dev/gpio", 777) not works?


Comments

Popular posts from this blog

xml - Extract substrings with XSLT -

math - "ELO Rating" and how does "TSR Rating" work? -

How can do a tuple comparison in coffeescript similar to that in python? -