Module Name: src Committed By: snj Date: Sun Mar 28 16:44:23 UTC 2010
Modified Files: src/sys/external/bsd/drm/dist/bsd-core [netbsd-5]: drm_pci.c Log Message: Pull up following revision(s) (requested by mrg in ticket #1346): sys/external/bsd/drm/dist/bsd-core/drm_pci.c: revision 1.8 fix some confusion between highest DMA address and the boundary not to be crossed in a transfer, back out previous fixes which only added to the confusion To generate a diff of this commit: cvs rdiff -u -r1.4.10.1 -r1.4.10.2 \ src/sys/external/bsd/drm/dist/bsd-core/drm_pci.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/external/bsd/drm/dist/bsd-core/drm_pci.c diff -u src/sys/external/bsd/drm/dist/bsd-core/drm_pci.c:1.4.10.1 src/sys/external/bsd/drm/dist/bsd-core/drm_pci.c:1.4.10.2 --- src/sys/external/bsd/drm/dist/bsd-core/drm_pci.c:1.4.10.1 Sat Jun 20 23:36:59 2009 +++ src/sys/external/bsd/drm/dist/bsd-core/drm_pci.c Sun Mar 28 16:44:23 2010 @@ -110,9 +110,10 @@ return NULL; } #elif defined(__NetBSD__) - dmah->tag = dev->pa.pa_dmat; + KASSERT(maxaddr >= 0xffffffffUL); /* no way to tell bus_dma_alloc */ + dmah->tag = dev->pa.pa_dmat; /* use 32-bit DMA tag */ - if ((ret = bus_dmamem_alloc(dmah->tag, size, align, maxaddr, + if ((ret = bus_dmamem_alloc(dmah->tag, size, align, 0, dmah->segs, 1, &nsegs, BUS_DMA_WAITOK)) != 0) { printf("drm: Unable to allocate %zu bytes of DMA, error %d\n", size, ret);