237 2YTK6QJM5XL6ISDC22KNAJAVHUQMOWWHXJDNU4Q 2YTK6QJM5XL6ISDC22KNAJAVHUQMOWWHXJDNU4Q


driver x_open,x_release work, x_ioctl,x_write don't The HyperNews Linux KHG Discussion Pages driver x_open,x_release work, x_ioctl,x_write don'tForum: The Linux Kernel Hackers' GuideDate: Tue, 31 Mar 1998 19:41:58 GMTFrom: Carl Schwartz <schwcarl@e-z.net>Using RedHat 5.0 and following KHG I performed the following steps in developing a driver 'x': 1) created x.o with gcc -O -DMODULE -D__KERNEL__ 2) created /dev/x crw-r--r-- 126 0 3) insmod ./x.o 4) lsmod listed it but ksyms did not 5) user root: fildef = open('/dev.x',O_RDWR); (fildef = 17) 6) user root:ioctl(fildef,_IOW(126,1,sizeof(daud)),(int)&daud) returns -1 as well as does all other ioctl's and write's I try from user app and do not print "printk's".7) rmmod removes it OK. It seems that 'open' and 'release' are the only functions that work (perform as expected and "printk's" work).I copied device file_operations, ioctl and write parameter lists from KHG, basically replacing 'foo' with 'x'.I copied 'x.o' to /lib/modules/2.0.31/char and added 'alias char-major-126 x' to conf.module. Depmod -a does not add it to modules.dep and Modprobe doesn't know that 'x' exists. Messages Inline: Outline: 1. Depmod Unresolved symbols? by Carl Schwartz to: "driver x_open,x_release work, x_ioctl,x_write don't" i

Wyszukiwarka

Podobne podstrony:
236 237
237 244
237 240
highwaycode pol c11 niekozystne warunki atmosferyczne (s 77 79, r 229 237)
02 (237)
04 (237)
wypadek w drodze 2002 237 2015
237 288 (2)
237 241 nzy7nut6uvkrol7hvl5apc6lmy3hzuyvgwlf4lq
MAKIJAŻ 237 KARNAWAŁOWY
05 (237)

więcej podobnych podstron