static void qpci_spapr_io_writel(QPCIBus *bus, void *addr, uint32_t value)

{

    QPCIBusSPAPR *s = container_of(bus, QPCIBusSPAPR, bus);

    uint64_t port = (uintptr_t)addr;

    value = bswap32(value);

    if (port < s->pio.size) {

        writel(s->pio_cpu_base + port, value);

    } else {

        writel(s->mmio_cpu_base + port, value);

    }

}

static void qpci_spapr_io_writel(QPCIBus *bus, void *addr, uint32_t value)

{

    QPCIBusSPAPR *s = container_of(bus, QPCIBusSPAPR, bus);

    uint64_t port = (uintptr_t)addr;

    value = bswap32(value);

    if (port < s->pio.size) {

        writel(s->pio_cpu_base + port, value);

    } else {

        writel(s->mmio_cpu_base + port, value);

    }

}

static void FUNC_0(QPCIBus *VAR_0, void *VAR_1, uint32_t VAR_2)

{

    QPCIBusSPAPR *s = container_of(VAR_0, QPCIBusSPAPR, VAR_0);

    uint64_t port = (uintptr_t)VAR_1;

    VAR_2 = bswap32(VAR_2);

    if (port < s->pio.size) {

        writel(s->pio_cpu_base + port, VAR_2);

    } else {

        writel(s->mmio_cpu_base + port, VAR_2);

    }

}

static void FUNC_0(QPCIBus *VAR_0, void *VAR_1, uint32_t VAR_2)
{ QPCIBusSPAPR *s = container_of(VAR_0, QPCIBusSPAPR, VAR_0); uint64_t port = (uintptr_t)VAR_1; VAR_2 = bswap32(VAR_2); if (port < s->pio.size) { writel(s->pio_cpu_base + port, VAR_2); } else { writel(s->mmio_cpu_base + port, VAR_2); } }