+ if (!use_addrs)
+ {
+ eacc = pci_malloc(a, sizeof(*eacc));
+
+ eacc->physmem = physmem_open(a, a->writeable);
+ if (!eacc->physmem)
+ {
+ a->debug("cannot open physcal memory: %s.", strerror(errno));
+ pci_mfree(eacc);
+ return 0;
+ }
+
+ eacc->pagesize = physmem_get_pagesize(eacc->physmem);
+ if (eacc->pagesize <= 0)
+ {
+ a->debug("Cannot get page size: %s.", strerror(errno));
+ physmem_close(eacc->physmem);
+ pci_mfree(eacc);
+ return 0;
+ }
+
+ eacc->mcfg = NULL;
+ eacc->cache = NULL;
+ a->backend_data = eacc;
+ eacc->mcfg = find_mcfg(a, acpimcfg, efisystab, use_bsd, use_x86bios);
+ if (!eacc->mcfg)
+ {
+ physmem_close(eacc->physmem);
+ pci_mfree(eacc);
+ a->backend_data = NULL;
+ return 0;
+ }
+ }
+