Linux - KernelThis forum is for all discussion relating to the Linux kernel.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
We have an embedded device with an ARM9 processor running Linux 2.6.13 kernel. This device communicates with a PC via a USB connection. (PC is USB host, and ARM9 is USB device). We use the Serial Gadget driver (g_serial.ko) which makes it possible to communicate over usb via /dev/ttygserial.
I have a process that every second tries to open /dev/ttygserial. Until the device has been connected to a PC, open(/dev/ttygserial,…) returns with the error “device is not connected”. When the device is connected to a PC, and even if it is disconnected again, open(/dev/ttygserial,..) returns successfully.
I have another process continuously reading data over ttyS3.
My problem is that every time the first process fails to open /dev/ttygserial, data read over ttyS3 is damaged. So every second the data from ttyS3 is damaged, and there is CRC errors.
It seems like open(/dev/ttygserial,…) returns failure until some initialization has been done. Maybe the initialisation done by gs_setup(..) (located in drivers/usb/gadget/serial.c). gs_setup(..) is is not invoked until the USB cable is connected.
I hope somebody can help me out. I’ve worked on this problem for almost two weeks now.