Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai-l3A5Bk7waGM@public.gmane.org>
To: Clemens Ladisch <clemens-P6GI/4k7KOmELgA04lAiVw@public.gmane.org>
Cc: Alan Stern
	<stern-nwvwT67g6+6dFdvTe/nMLpVzexx5G7lz@public.gmane.org>,
	alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw@public.gmane.org,
	Torsten Schenk <torsten.schenk-ytc+IHgoah0@public.gmane.org>,
	linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [alsa-devel] [PATCH] 6fire: fix URB transfer buffer for midi output
Date: Thu, 08 Aug 2013 09:28:45 +0200	[thread overview]
Message-ID: <s5hsiykabf6.wl%tiwai@suse.de> (raw)
In-Reply-To: <520345CB.3030307-P6GI/4k7KOmELgA04lAiVw@public.gmane.org>

At Thu, 08 Aug 2013 09:16:27 +0200,
Clemens Ladisch wrote:
> 
> Takashi Iwai wrote:
> > Alan Stern wrote:
> >> A buffer _can_ be in the middle of a kmalloc'ed space, but the CPU must
> >> not access any of the fields around it that might occupy the same cache
> >> line while the buffer is being used for DMA.
> >
> > Hrm, but does the kmalloc buffer always guarantee such cache line
> > exclusiveness...?  I thought a simple one like SLOB doesn't care.
> 
> Documentation/DMA-API-HOWTO.txt says:
> |  Architectures must ensure that kmalloc'ed buffer is
> |  DMA-safe. Drivers and subsystems depend on it. If an architecture
> |  isn't fully DMA-coherent (i.e. hardware doesn't ensure that data in
> |  the CPU cache is identical to data in main memory),
> |  ARCH_DMA_MINALIGN must be set so that the memory allocator
> |  makes sure that kmalloc'ed buffer doesn't share a cache line with
> |  the others.

Ah, good, thanks!


Takashi
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2013-08-08  7:28 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-07 14:51 [PATCH] 6fire: fix URB transfer buffer for midi output Torsten Schenk
     [not found] ` <20130807165149.188c4b16297be52c0630a18f-ytc+IHgoah0@public.gmane.org>
2013-08-07 16:34   ` Takashi Iwai
     [not found]     ` <s5hli4d5uj7.wl%tiwai-l3A5Bk7waGM@public.gmane.org>
2013-08-07 17:38       ` Alan Stern
     [not found]         ` <Pine.LNX.4.44L0.1308071334590.886-100000-IYeN2dnnYyZXsRXLowluHWD2FQJk+8+b@public.gmane.org>
2013-08-08  6:03           ` Takashi Iwai
2013-08-08  7:16             ` Clemens Ladisch
     [not found]               ` <520345CB.3030307-P6GI/4k7KOmELgA04lAiVw@public.gmane.org>
2013-08-08  7:28                 ` Takashi Iwai [this message]
2013-08-11  9:11             ` [PATCH 1/2] 6fire: make buffers DMA-able (pcm) Torsten Schenk
2013-08-12  9:37               ` Takashi Iwai

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=s5hsiykabf6.wl%tiwai@suse.de \
    --to=tiwai-l3a5bk7wagm@public.gmane.org \
    --cc=alsa-devel-K7yf7f+aM1XWsZ/bQMPhNw@public.gmane.org \
    --cc=clemens-P6GI/4k7KOmELgA04lAiVw@public.gmane.org \
    --cc=linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=stern-nwvwT67g6+6dFdvTe/nMLpVzexx5G7lz@public.gmane.org \
    --cc=torsten.schenk-ytc+IHgoah0@public.gmane.org \
    /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