Skip to content

Commit

Permalink
[POWERPC] Pass UPIO_TSI flag to 8259 serial driver
Browse files Browse the repository at this point in the history
The patch passes the UPIO_TSI flag to general 8259 serial driver

Signed-off-by: Roy Zang	<[email protected]>
Signed-off-by: Paul Mackerras <[email protected]>
  • Loading branch information
Zang Roy-r61911 authored and paulusmack committed Aug 23, 2006
1 parent c4342ff commit be9633e
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions arch/powerpc/kernel/legacy_serial.c
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ static int __init add_legacy_soc_port(struct device_node *np,
u64 addr;
u32 *addrp;
upf_t flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST | UPF_SHARE_IRQ;
struct device_node *tsi = of_get_parent(np);

/* We only support ports that have a clock frequency properly
* encoded in the device-tree.
Expand All @@ -134,7 +135,10 @@ static int __init add_legacy_soc_port(struct device_node *np,
/* Add port, irq will be dealt with later. We passed a translated
* IO port value. It will be fixed up later along with the irq
*/
return add_legacy_port(np, -1, UPIO_MEM, addr, addr, NO_IRQ, flags, 0);
if (tsi && !strcmp(tsi->type, "tsi-bridge"))
return add_legacy_port(np, -1, UPIO_TSI, addr, addr, NO_IRQ, flags, 0);
else
return add_legacy_port(np, -1, UPIO_MEM, addr, addr, NO_IRQ, flags, 0);
}

static int __init add_legacy_isa_port(struct device_node *np,
Expand Down Expand Up @@ -464,7 +468,7 @@ static int __init serial_dev_init(void)
fixup_port_irq(i, np, port);
if (port->iotype == UPIO_PORT)
fixup_port_pio(i, np, port);
if (port->iotype == UPIO_MEM)
if ((port->iotype == UPIO_MEM) || (port->iotype == UPIO_TSI))
fixup_port_mmio(i, np, port);
}

Expand Down

0 comments on commit be9633e

Please sign in to comment.