1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-23 16:01:42 +00:00

Recognize the SAB82532 in USIII machines.

This commit is contained in:
Marius Strobl 2005-08-07 13:37:25 +00:00
parent d11b733f41
commit 079f9edfef
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=148824
3 changed files with 5 additions and 4 deletions

View File

@ -48,10 +48,11 @@ __FBSDID("$FreeBSD$");
static int static int
puc_ebus_probe(device_t dev) puc_ebus_probe(device_t dev)
{ {
const char *nm; const char *nm, *cmpt;
nm = ofw_bus_get_name(dev); nm = ofw_bus_get_name(dev);
if (!strcmp(nm, "se")) { cmpt = ofw_bus_get_compat(dev);
if (!strcmp(nm, "se") || (cmpt != NULL && !strcmp(cmpt, "sab82532"))) {
device_set_desc(dev, "Siemens SAB 82532 dual channel SCC"); device_set_desc(dev, "Siemens SAB 82532 dual channel SCC");
return (0); return (0);
} }

View File

@ -96,7 +96,7 @@ uart_ebus_probe(device_t dev)
sc->sc_class = &uart_ns8250_class; sc->sc_class = &uart_ns8250_class;
return (uart_bus_probe(dev, 0, 0, 0, 0)); return (uart_bus_probe(dev, 0, 0, 0, 0));
} }
if (!strcmp(nm, "se")) { if (!strcmp(nm, "se") || (cmpt != NULL && !strcmp(cmpt, "sab82532"))) {
sc->sc_class = &uart_sab82532_class; sc->sc_class = &uart_sab82532_class;
error = uart_bus_probe(dev, 0, 0, 0, 1); error = uart_bus_probe(dev, 0, 0, 0, 1);
return ((error) ? error : -1); return ((error) ? error : -1);

View File

@ -216,7 +216,7 @@ uart_cpu_getdev(int devtype, struct uart_devinfo *di)
compat[0] = '\0'; compat[0] = '\0';
di->bas.regshft = 0; di->bas.regshft = 0;
di->bas.rclk = 0; di->bas.rclk = 0;
if (!strcmp(buf, "se")) { if (!strcmp(buf, "se") || !strcmp(compat, "sab82532")) {
di->ops = uart_sab82532_ops; di->ops = uart_sab82532_ops;
/* SAB82532 are only known to be used for TTYs. */ /* SAB82532 are only known to be used for TTYs. */
if ((di->bas.chan = uart_cpu_channel(dev)) == 0) if ((di->bas.chan = uart_cpu_channel(dev)) == 0)