At 04:42 PM 7/8/02 +0000, ashish anand wrote: >Hello, > >I have recently got slave usb working on 823/850 boards.
Congratulations. Are you going to publish the code? Via this list is a good way. >now i am facing a severe problem only when klogd is started. > >problem is that , as klogd sets a console_loglevel i am >getting the prints of usb messages on screen very very >unpredictably. > >even usb stops generating receive and transmit interrupts >if i don't enforce the changes in kernel/printk.c >like below.. > >ORIGINAL CODE THAT DOESN'T WORK >---------------------------------- >if (msg_level < console_loglevel && console_drivers) > { > struct console *c = console_drivers; > while(c) { > if ((c->flags & CON_ENABLED) && c->write) > c->write(c, msg, p - msg + line_feed); > c = c->next; > } > >HACK THAT MAKES IT WORK >----------------------- >if (console_drivers) > { > struct console *c = console_drivers; > while(c) { > if ((c->flags & CON_ENABLED) && c->write) > c->write(c, msg, p - msg + line_feed); > c = c->next; > } > >point to note is that usb interrupt is among the highest priority while >the uart is quite lower one also usb generates lot of interrupts ( one >msec. SOF) > >basically it works if it is made to print on SCREEN . >also it will work when you set (KERN_EMERG) in printk. > >my interupt hasndler runs as kernel thread. >alternatively it also works when i enable the DEBUG options (lot of >printk's in usb routines) > >can any body sugest me some pointer..? If you are using the Montavista embedded kernel, I seem to recall that printk turns off interrupts while it is sending a string to the console. This could cause you to miss several usb interrupts. At 40 to 80 Mhz on an 823, Linux interrupt overhead is significant. So probably, if you have both SOF and read/write interrupts on, you are getting one interrupt with both events on by the time it gets to your isr routine. One other question, why does a device care about SOFs? The only thing I can think of is counting off 3ms without a SOF so you can suspend. But for that scenario the only case you are interested in is when SOF stops, so you have to do some timer hook anyway...You cannot get an interrupt when there is no SOF.. Regards, Steve ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Oh, it's good to be a geek. http://thinkgeek.com/sf _______________________________________________ [EMAIL PROTECTED] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel