Use printk() in the driver and before you do the operation that you are trying
to debug do '# tail -f /var/log/messages >& debug.out' in another terminal
shell window.
If you are trying to write to a non-existant I2C device, then it will hang.
Hope this addresses your issue...
-- Peter
[EMAIL PROTECTED]
m.tw To:
[EMAIL PROTECTED]@Internet
cc: (bcc: Peter
Lohmann/Americas/NSC)
06/06/02 10:58 Subject: [V4L] ask debug
PM
Dear List :
I have a user-program make (SeTopBox implimented with SC1200) hang.
I use to insert macro (as follows) everywhere in user-program
openlog("",LOG_PID,LOG_USER);
syslog("LOG_INFO","file: %s line%d\n"__FILE__,__LINE__) ;
closelog();
usleep(3); // let file be fflushed before HANG
Then I reboot PC & go to /var/log to find out where it hangs.
But this time ,I traced a bug from user-program to a driver it called:
I inserted the macro (as above ) to driver , but After I made driver xxx.o &
insmod xxx.o , I got (msg as follows)
"export
openlog
export
syslog
export
closelog"
I have 2 questions to consult you :
1. Could I use openlog(),syslog(),closelog() in driver ?
2. Is there a method for dummy to know
where(from the view of source-code) it hang ?
Thanks in advance !
Henry
_______________________________________________
Video4linux-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/video4linux-list