From: Sarah Sharp <sarah.a.sharp@linux.intel.com>
To: Xenia Ragiadakou <burzalodowa@gmail.com>
Cc: linux-usb@vger.kernel.org, Alan Stern <stern@rowland.harvard.edu>,
linux-pci@vger.kernel.org
Subject: Re: [OPW kernel] dma_set_coherent_mask
Date: Tue, 14 May 2013 22:39:11 -0700 [thread overview]
Message-ID: <20130515053911.GD17398@xanatos> (raw)
In-Reply-To: <5192F5C8.3090100@gmail.com>
On Wed, May 15, 2013 at 05:41:12AM +0300, Xenia Ragiadakou wrote:
> Hi Sarah, (again)
>
> Also I noticed that dma_set_coherent_mask() is not called somewhere,
> which according to DMA-API-HOWTO.txt, means the even if the DMA mask
> is set to 64 bits by dma_set_mask, dma_alloc_coherent and
> dma_pool_alloc wont return 64 bit addresses (32 MSbits wont be
> addressed).
Another good question for Alan, and the USB and PCI list.
(Alan, Ksenia is one of the applicants for the FOSS Outreach Program for
Women that I've been coordinating: http://kernelnewbies.org/OPWIntro)
We do allocate memory using DMA pools, and we do want 64-bit context
addresses if the xHCI host controller can handle it.
The xHCI driver calls dma_set_mask, but not dma_set_coherent_mask():
temp = xhci_readl(xhci, &xhci->cap_regs->hcc_params);
if (HCC_64BIT_ADDR(temp)) {
xhci_dbg(xhci, "Enabling 64-bit DMA addresses.\n");
dma_set_mask(hcd->self.controller, DMA_BIT_MASK(64));
} else {
dma_set_mask(hcd->self.controller, DMA_BIT_MASK(32));
}
Alan, should it be calling dma_set_coherent_mask()? I think I may have
noticed the context addresses were never 64-bit addresses, but I didn't
think to look whether the host supported 64-bit addresses. I just
assumed it could only handle 32-bit addresses.
> I hope I'm not doing a huge mistake in my reasonance, and you loose
> your time with these emails.
Nope, I want you to ask questions, so don't worry about that.
Sarah Sharp
next parent reply other threads:[~2013-05-15 5:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <5192F5C8.3090100@gmail.com>
2013-05-15 5:39 ` Sarah Sharp [this message]
2013-05-15 14:37 ` [OPW kernel] dma_set_coherent_mask Alan Stern
2013-05-15 22:42 ` Sarah Sharp
2013-05-16 14:11 ` Alan Stern
2013-05-16 17:19 ` Sarah Sharp
2013-05-22 20:43 ` Don Dutile
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130515053911.GD17398@xanatos \
--to=sarah.a.sharp@linux.intel.com \
--cc=burzalodowa@gmail.com \
--cc=linux-pci@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=stern@rowland.harvard.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).