patch for ALSA MMAP_COMPLEX support

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

patch for ALSA MMAP_COMPLEX support

Frank van de Pol-3

Please find attached a small patch against CVS which adds support for the
ALSA MMAP_COMPLEX access method.

* capture/playback_interleave_skip is now defined per channel instead of
  globally for the driver
* SND_PCM_ACCESS_MMAP_COMPLEX is accepted in case non-interleaved or
  interleaved acces is not possible and handled as interleaved.

Cheers,
Frank.


--
+---- --- -- -  -   -    -
| Frank van de Pol                  -o)    A-L-S-A
| [hidden email]              /\\  Sounds good!
| http://www.alsa-project.org      _\_v
| Linux - Why use Windows if we have doors available?

mmap_complex.patch (7K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: patch for ALSA MMAP_COMPLEX support

Paul Davis
On Fri, 2005-08-12 at 19:14 +0200, Frank van de Pol wrote:

 .... the patch i've had on my TODO list for years

THANKS!

I'd like to see 3 reports of this not affecting things on at least one PCI and at least one USB interface,
and then I'll commit it. Count me as responsible for 1 of those minimum 3 reports.

--p




-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Jackit-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jackit-devel
Reply | Threaded
Open this post in threaded view
|

Re: patch for ALSA MMAP_COMPLEX support

Lee Revell
On Fri, 2005-08-12 at 16:10 -0400, Paul Davis wrote:
> On Fri, 2005-08-12 at 19:14 +0200, Frank van de Pol wrote:
>
>  .... the patch i've had on my TODO list for years
>
> THANKS!
>
> I'd like to see 3 reports of this not affecting things on at least one PCI and at least one USB interface,
> and then I'll commit it. Count me as responsible for 1 of those minimum 3 reports.

This is great news from ALSA's perspective too as this is the first
actual use of MMAP_COMPLEX that I know of.  Until now there was no good
answer to "what is MMAP_COMPLEX for"?

Lee



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Jackit-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jackit-devel
Reply | Threaded
Open this post in threaded view
|

Re: patch for ALSA MMAP_COMPLEX support

Paul Davis
In reply to this post by Frank van de Pol-3
On Fri, 2005-08-12 at 19:14 +0200, Frank van de Pol wrote:
> Please find attached a small patch against CVS which adds support for the
> ALSA MMAP_COMPLEX access method.
>
> * capture/playback_interleave_skip is now defined per channel instead of
>   globally for the driver
> * SND_PCM_ACCESS_MMAP_COMPLEX is accepted in case non-interleaved or
>   interleaved acces is not possible and handled as interleaved.

Test #1 done (RME HDSP and intel ICH). No problems.

I also have a couple of other pending patches waiting (the jack frame
timer offset cmdline argument; total latency figures from jack_lsp;
changes to configure.ac to support gcc4 and systems where the compiler
and processor differ on MMX/SSE support). So please test this patch and
let me know.

--p




-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Jackit-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jackit-devel
Reply | Threaded
Open this post in threaded view
|

Re: patch for ALSA MMAP_COMPLEX support

Frank van de Pol-3
In reply to this post by Lee Revell
On Fri, Aug 12, 2005 at 04:14:43PM -0400, Lee Revell wrote:
> This is great news from ALSA's perspective too as this is the first
> actual use of MMAP_COMPLEX that I know of.  Until now there was no good
> answer to "what is MMAP_COMPLEX for"?

The MMAP_COMPLEX is used for alsa devices that have their sample data
neither in non-interleaved (eg. the hammerfall cards) or interleaved (most
consumer cards and ice1712 based cards).

Though the MMAP_COMPLEX seems to be very rare for hardware, it is commonly
seen using the ALSA multi device: when binding multiple cards which have a
native interleaved format, the resulting multi device will consists of
multiple (non-interleaved) blocks of data in the soundcard's native format.
In my test case (with multiple ice1712 boards) the MMAP_COMPLEX structure
consisted of 3 non-interleaved blocks of 12 channel interleaved 32 bit data.

The current weel-known workaround to make Jack handle above scenario would
be to create an additional alsa device using the 'route' plugin, resulting
in unneeded (matrix mixing) processing in the driver. Unfortunate this did
not work for me, so I decided to have a look at implementing MMAP_COMPLEX
support :-)


while I have no intention to bring in 'works for me' votes regarding my own
patch, I'd like to share the configurations I've tested:

- ice1712 OK (terratec phase88, ews88d; tested on amd64)
- via82xx OK (epox 8hda3+ onboard; tested on amd64)
- cs46xx  OK (turtle beach santa cruz; tested on intel p4)
- multi   OK (alsa multi device with 2xews88d + 1xphase 88; tested on amd64)

No isa/usb/firewire hardware available here, so I'm looking forward for your
experiences too.

Frank.  

--
+---- --- -- -  -   -    -
| Frank van de Pol                  -o)    A-L-S-A
| [hidden email]              /\\  Sounds good!
| http://www.alsa-project.org      _\_v
| Linux - Why use Windows if we have doors available?


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Jackit-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jackit-devel