>> > /*lowaddr*/BUS_SPACE_MAXADDR_32BIT, >> > /*highaddr*/BUS_SPACE_MAXADDR, >> >> low and high address of the region that the DMA engine cannot access. > >Meaning e.g. the 16Mbyte barrier that ISA DMA has? >For PCI this would be a 4Gb range(?).
The range could be much larger than 4GB. Remember this is a range the device *cannot* access, not a range it can access. So, the beginning of the range for an ISA device would be BUS_SPACE_MAXADDR_24BIT and the hight address would be BUS_SPACE_MAXADDR. Depending on the platform or configuration of the machine, the high address could be larger than a 32bit quantity. >> > /*maxsize*/MAXBSIZE, >> >> Maximum DMA transfer size. >> >> > /*nsegments*/AHC_NSEG, >> >> Maximum number of discontinuities in the mapped region. > >Eh.. ? > >> > /*maxsegsz*/AHC_MAXTRANSFER_SIZE, >> >> Maximum size of a segment. maxsize <= nsegments * maxsegsz. > >Eh.. ? Many DMA engines have S/G capability and so can perform a single DMA that spans multiple segments of "bus space contiguous" data. By setting these parameters, the bus_dmamap_load function can determine how best to map your transfer into bus space and will return to you an array of segments to program into your DMA hardware. >> You should use the new API if possible. > >That is what I'm planning to do. The amount of sample code in the various >drivers is rather limited as most drivers use the old code. It seems that its mostly confined to the SCSI code, but hopefully that will change over time. >So I hope you don't mind me asking some more questions, Not a problem. -- Justin To Unsubscribe: send mail to majord...@freebsd.org with "unsubscribe freebsd-hackers" in the body of the message