Date: Tue, 21 Aug 2001 00:30:23 -0600 From: "Justin T. Gibbs" <gibbs@scsiguy.com> To: mjacob@feral.com Cc: Bill Paul <wpaul@FreeBSD.ORG>, hackers@FreeBSD.ORG, current@FreeBSD.ORG Subject: Re: Where to put new bus_dmamap_load_mbuf() code Message-ID: <200108210630.f7L6UNY90382@aslan.scsiguy.com> In-Reply-To: Your message of "Mon, 20 Aug 2001 22:53:06 PDT." <20010820225225.G39850-100000@wonky.feral.com>
next in thread | previous in thread | raw e-mail | index | archive | help
>
>Correction.
>
>This sample:
>>
>> if (bus_dma_tag_create(pci->parent_dmat, PAGE_SIZE, lim,
>> BUS_SPACE_MAXADDR, BUS_SPACE_MAXADDR, NULL, NULL, len, 1,
>> BUS_SPACE_MAXSIZE_32BIT, 0, &pci->cntrol_dmat) != 0) {
>> isp_prt(isp, ISP_LOGERR,
>> "cannot create a dma tag for control spaces");
>> free(isp->isp_xflist, M_DEVBUF);
>> free(pci->dmaps, M_DEVBUF);
>> return (1);
>> }
>>
You'll need to change the number of segments to match the max
supported by the card (or the max you will ever need). This
example made me realize that the bounce code doesn't deal with
multiple segments being copied into a single page (i.e. tracking
and using remaining free space in a page already allocated for
bouncing for a single map). I'll have to break loose some time
to fix that.
--
Justin
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200108210630.f7L6UNY90382>
