|
@@ -112,7 +112,7 @@ static int __init add_legacy_port(struct device_node *np, int want_index,
|
|
static int __init add_legacy_soc_port(struct device_node *np,
|
|
static int __init add_legacy_soc_port(struct device_node *np,
|
|
struct device_node *soc_dev)
|
|
struct device_node *soc_dev)
|
|
{
|
|
{
|
|
- phys_addr_t addr;
|
|
|
|
|
|
+ u64 addr;
|
|
u32 *addrp;
|
|
u32 *addrp;
|
|
upf_t flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST | UPF_SHARE_IRQ;
|
|
upf_t flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST | UPF_SHARE_IRQ;
|
|
|
|
|
|
@@ -143,7 +143,7 @@ static int __init add_legacy_isa_port(struct device_node *np,
|
|
u32 *reg;
|
|
u32 *reg;
|
|
char *typep;
|
|
char *typep;
|
|
int index = -1;
|
|
int index = -1;
|
|
- phys_addr_t taddr;
|
|
|
|
|
|
+ u64 taddr;
|
|
|
|
|
|
DBG(" -> add_legacy_isa_port(%s)\n", np->full_name);
|
|
DBG(" -> add_legacy_isa_port(%s)\n", np->full_name);
|
|
|
|
|
|
@@ -165,10 +165,13 @@ static int __init add_legacy_isa_port(struct device_node *np,
|
|
if (typep && *typep == 'S')
|
|
if (typep && *typep == 'S')
|
|
index = simple_strtol(typep+1, NULL, 0) - 1;
|
|
index = simple_strtol(typep+1, NULL, 0) - 1;
|
|
|
|
|
|
- /* Translate ISA address */
|
|
|
|
|
|
+ /* Translate ISA address. If it fails, we still register the port
|
|
|
|
+ * with no translated address so that it can be picked up as an IO
|
|
|
|
+ * port later by the serial driver
|
|
|
|
+ */
|
|
taddr = of_translate_address(np, reg);
|
|
taddr = of_translate_address(np, reg);
|
|
if (taddr == OF_BAD_ADDR)
|
|
if (taddr == OF_BAD_ADDR)
|
|
- return -1;
|
|
|
|
|
|
+ taddr = 0;
|
|
|
|
|
|
/* Add port, irq will be dealt with later */
|
|
/* Add port, irq will be dealt with later */
|
|
return add_legacy_port(np, index, UPIO_PORT, reg[1], taddr,
|
|
return add_legacy_port(np, index, UPIO_PORT, reg[1], taddr,
|
|
@@ -180,7 +183,7 @@ static int __init add_legacy_isa_port(struct device_node *np,
|
|
static int __init add_legacy_pci_port(struct device_node *np,
|
|
static int __init add_legacy_pci_port(struct device_node *np,
|
|
struct device_node *pci_dev)
|
|
struct device_node *pci_dev)
|
|
{
|
|
{
|
|
- phys_addr_t addr, base;
|
|
|
|
|
|
+ u64 addr, base;
|
|
u32 *addrp;
|
|
u32 *addrp;
|
|
unsigned int flags;
|
|
unsigned int flags;
|
|
int iotype, index = -1, lindex = 0;
|
|
int iotype, index = -1, lindex = 0;
|