Author: carl Date: Thu Sep 5 23:02:43 2013 New Revision: 255275 URL: http://svnweb.freebsd.org/changeset/base/255275
Log: Simplifying bus alloc resource call since we only need the default values. Approved by: jimharris Sponsored by: Intel Modified: head/sys/dev/ntb/ntb_hw/ntb_hw.c Modified: head/sys/dev/ntb/ntb_hw/ntb_hw.c ============================================================================== --- head/sys/dev/ntb/ntb_hw/ntb_hw.c Thu Sep 5 23:00:59 2013 (r255274) +++ head/sys/dev/ntb/ntb_hw/ntb_hw.c Thu Sep 5 23:02:43 2013 (r255275) @@ -340,8 +340,8 @@ static int map_mmr_bar(struct ntb_softc *ntb, struct ntb_pci_bar_info *bar) { - bar->pci_resource = bus_alloc_resource(ntb->device, SYS_RES_MEMORY, - &bar->pci_resource_id, 0, ~0, 1, RF_ACTIVE); + bar->pci_resource = bus_alloc_resource_any(ntb->device, SYS_RES_MEMORY, + &bar->pci_resource_id, RF_ACTIVE); if (bar->pci_resource == NULL) return (ENXIO); @@ -356,9 +356,8 @@ map_memory_window_bar(struct ntb_softc * { int rc; - bar->pci_resource = bus_alloc_resource(ntb->device, - SYS_RES_MEMORY, &bar->pci_resource_id, 0, ~0, 1, - RF_ACTIVE); + bar->pci_resource = bus_alloc_resource_any(ntb->device, + SYS_RES_MEMORY, &bar->pci_resource_id, RF_ACTIVE); if (bar->pci_resource == NULL) return (ENXIO); _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"