Lines Matching refs:fmc
18 static uint32_t __sdb_rd(struct fmc_device *fmc, unsigned long address, in __sdb_rd() argument
21 uint32_t res = fmc_readl(fmc, address); in __sdb_rd()
27 static struct sdb_array *__fmc_scan_sdb_tree(struct fmc_device *fmc, in __fmc_scan_sdb_tree() argument
35 onew = fmc_readl(fmc, sdb_addr); in __fmc_scan_sdb_tree()
46 onew = __sdb_rd(fmc, sdb_addr + 4, convert); in __fmc_scan_sdb_tree()
62 arr->fmc = fmc; in __fmc_scan_sdb_tree()
68 __sdb_rd(fmc, sdb_addr + (i * 64) + j, convert); in __fmc_scan_sdb_tree()
79 sub = __fmc_scan_sdb_tree(fmc, subaddr, newbase, in __fmc_scan_sdb_tree()
91 int fmc_scan_sdb_tree(struct fmc_device *fmc, unsigned long address) in fmc_scan_sdb_tree() argument
94 if (fmc->sdb) in fmc_scan_sdb_tree()
96 ret = __fmc_scan_sdb_tree(fmc, address, 0 /* regs */, 0); in fmc_scan_sdb_tree()
99 fmc->sdb = ret; in fmc_scan_sdb_tree()
121 int fmc_free_sdb_tree(struct fmc_device *fmc) in fmc_free_sdb_tree() argument
123 __fmc_sdb_free(fmc->sdb); in fmc_free_sdb_tree()
124 fmc->sdb = NULL; in fmc_free_sdb_tree()
130 int fmc_reprogram(struct fmc_device *fmc, struct fmc_driver *d, char *gw, in fmc_reprogram() argument
135 ret = fmc->op->reprogram(fmc, d, gw); in fmc_reprogram()
142 ret = fmc_scan_sdb_tree(fmc, sdb_entry); in fmc_reprogram()
144 dev_err(&fmc->dev, "Can't find SDB at address 0x%x\n", in fmc_reprogram()
148 fmc_dump_sdb(fmc); in fmc_reprogram()
168 static void __fmc_show_sdb_tree(const struct fmc_device *fmc, in __fmc_show_sdb_tree() argument
183 dev_info(&fmc->dev, "SDB: "); in __fmc_show_sdb_tree()
209 dev_info(&fmc->dev, "SDB: (bridge error %li)\n", in __fmc_show_sdb_tree()
213 __fmc_show_sdb_tree(fmc, arr->subtree[i]); in __fmc_show_sdb_tree()
245 void fmc_show_sdb_tree(const struct fmc_device *fmc) in fmc_show_sdb_tree() argument
247 if (!fmc->sdb) in fmc_show_sdb_tree()
249 __fmc_show_sdb_tree(fmc, fmc->sdb); in fmc_show_sdb_tree()