-#define PCI_TO_MEM(d, a) pci_virt_to_mem((pci_dev_t)d->priv, (a))
-#define PCI_TO_MEM_LE(d,a) (u32)(cpu_to_le32(PCI_TO_MEM(d,a)))
+static inline pci_addr_t pcnet_virt_to_mem(const struct eth_device *dev,
+ void *addr)
+{
+ pci_dev_t devbusfn = (pci_dev_t)(unsigned long)dev->priv;
+ void *virt_addr = addr;
+
+ return pci_virt_to_mem(devbusfn, virt_addr);
+}