troubleshooting Question

Linux serial ports from Kernel space

Avatar of CrypToniC
CrypToniCFlag for Sweden asked on
Linux OS Dev
6 Comments1 Solution2868 ViewsLast Modified:
Hi

How can I access the serial port from kernel space ? (from a driver)

From user space it's just like fd=open("/dev/ttyS0", ... )

But from kernel space it seems more difficult. I had a look at the Axis bluetooth implementation and they use
a whole complex thingy called ttys (via termios.h) ?
Can someone explain why tty's are used ?

What I want to do is not far from the Axis solution i.e.
ppp over my_driver out on the serial port for further processing. The problem is that I do not understand the while tty concept, neighter can I find any doc about it.

Thanx
BTW this is my very first driver :)
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 6 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 6 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros