# No cua* device



## Lovmy (May 25, 2011)

Hello,

I have a PC with FreeBSD 7.4.

Partial dmesg:


```
FreeBSD 7.4-RELEASE #0: Thu Mar  3 17:57:44 CET 2011
...
CPU: Intel(R) Pentium(R) 4 CPU 2.50GHz (2522.47-MHz 686-class CPU)
...
ioapic0 <Version 1.1> irqs 0-23 on motherboard
...
sio0: <16550A-compatible COM port> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0
sio0: type 16550A
sio0: [FILTER]
```

I have one serial port detected (sio0), but no cua0 device:


```
localhost# ls -l /dev/cu*
crw-rw----  1 uucp  dialer    0,  69 May 25 09:57 /dev/cuad0
crw-rw----  1 uucp  dialer    0,  70 May 25 09:57 /dev/cuad0.init
crw-rw----  1 uucp  dialer    0,  71 May 25 09:57 /dev/cuad0.lock
```

What's the problem?

Best Regards.


----------



## SirDice (May 25, 2011)

Lovmy said:
			
		

> What's the problem?


There isn't any.

What makes you think you should have a /dev/cua0?


----------



## wblock@ (May 25, 2011)

The FreeBSD 8 GENERIC kernel has only uart(4), which provides /dev/cuau0.
The FreeBSD 7 GENERIC kernel has both sio(4), which provides /dev/cuad0, and uart(4).  Evidently sio(4) gets priority.


----------



## SirDice (May 25, 2011)

Yeah, I did some digging around and it seems only really old versions of FreeBSD (2.x) used to have it.
Linux still has it which is probably where the confusion came from.


----------



## Lovmy (May 26, 2011)

Hello,

OK first serial port can be opened by:


```
open( "/dev/cuad0", O_RDWR|O_NONBLOCK|O_NOCTTY );
```

Why I have cuad0.lock? :


```
localhost# ls -l /dev/cua*
crw-rw----  1 uucp  dialer    0,  69 May 26 07:02 /dev/cuad0
crw-rw----  1 uucp  dialer    0,  70 May 26 07:02 /dev/cuad0.init
crw-rw----  1 uucp  dialer    0,  71 May 26 07:02 /dev/cuad0.lock
```

My serial port isn't used. On another forum it says it's for keyboard.

Best Regards.


----------



## SirDice (May 26, 2011)

Lovmy said:
			
		

> Why I have cuad0.lock?


Read sio(4)



> My serial port isn't used. On another forum it says it's for keyboard.


They are wrong.


----------

