Lines Matching refs:pem_pci

42 	struct thunder_pem_pci *pem_pci = (struct thunder_pem_pci *)cfg->priv;  in thunder_pem_bridge_read()  local
53 writeq(read_val, pem_pci->pem_reg_base + PEM_CFG_RD); in thunder_pem_bridge_read()
54 read_val = readq(pem_pci->pem_reg_base + PEM_CFG_RD); in thunder_pem_bridge_read()
82 writeq(0x70, pem_pci->pem_reg_base + PEM_CFG_RD); in thunder_pem_bridge_read()
83 tmp_val = readq(pem_pci->pem_reg_base + PEM_CFG_RD); in thunder_pem_bridge_read()
111 read_val = pem_pci->ea_entry[0]; in thunder_pem_bridge_read()
114 read_val = pem_pci->ea_entry[1]; in thunder_pem_bridge_read()
117 read_val = pem_pci->ea_entry[2]; in thunder_pem_bridge_read()
217 struct thunder_pem_pci *pem_pci = (struct thunder_pem_pci *)cfg->priv; in thunder_pem_bridge_write() local
234 writeq(where_aligned, pem_pci->pem_reg_base + PEM_CFG_RD); in thunder_pem_bridge_write()
235 read_val = readq(pem_pci->pem_reg_base + PEM_CFG_RD); in thunder_pem_bridge_write()
243 writeq(where_aligned, pem_pci->pem_reg_base + PEM_CFG_RD); in thunder_pem_bridge_write()
244 read_val = readq(pem_pci->pem_reg_base + PEM_CFG_RD); in thunder_pem_bridge_write()
282 writeq(write_val, pem_pci->pem_reg_base + PEM_CFG_WR); in thunder_pem_bridge_write()
308 struct thunder_pem_pci *pem_pci; in thunder_pem_init() local
311 pem_pci = devm_kzalloc(dev, sizeof(*pem_pci), GFP_KERNEL); in thunder_pem_init()
312 if (!pem_pci) in thunder_pem_init()
315 pem_pci->pem_reg_base = devm_ioremap(dev, res_pem->start, 0x10000); in thunder_pem_init()
316 if (!pem_pci->pem_reg_base) in thunder_pem_init()
326 pem_pci->ea_entry[0] = lower_32_bits(bar4_start) | 2; in thunder_pem_init()
327 pem_pci->ea_entry[1] = lower_32_bits(res_pem->end - bar4_start) & ~3u; in thunder_pem_init()
328 pem_pci->ea_entry[2] = upper_32_bits(bar4_start); in thunder_pem_init()
330 cfg->priv = pem_pci; in thunder_pem_init()