Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 16 Feb 1998 08:06:27 +0100 (MET)
From:      Luigi Rizzo <luigi@labinfo.iet.unipi.it>
To:        scottm@cs.ucla.edu (Scott Michel)
Cc:        freebsd-multimedia@FreeBSD.ORG
Subject:   Re: SNDCTL_DSP_SUBDIVIDE
Message-ID:  <199802160706.IAA27462@labinfo.iet.unipi.it>
In-Reply-To: <199802160711.XAA00606@mordred.cs.ucla.edu> from "Scott Michel" at Feb 15, 98 11:10:50 pm

next in thread | previous in thread | raw e-mail | index | archive | help
> I gave up and managed to make the linux elf rvplayer work. But still
> I'm curious as to what that ioctl is supposed to do.

basically split the buffer in a (user defined) number of blocks of
(partly) user-defined size.

It is one of the possible methods used to set the granularity of
DMA transfers. It is also used by some programs to limit
the amount of data queued in the play buffer.

<MY VIEW OF THE WORLD>
The latter is something the application should _not_ do since the
amount of kernel buffering depends on a variety of factors (audio
hw, avai. memory, CPU speed, system load, etc.) which the application
has no way to know, and is better left to the driver.

On top of this, few if any applications are prepared to handle
situations where the kernel says "sorry I cannot handle this request".

The sensible way to operate would be, in my opinion, to let the kernel
use how much buffering it decides to, and check the amount of queued
data before writing, if one really wants to keep queues short.
</MY VIEW OF THE WORLD>

For the above reasons, my driver does not fully support this call, in
that it always succeeds but it does not change the kernel buffer size.
Complete support will be trivial to add as soon as i have the time to
test it (i think it's just a couple of lines in sound.c...)

	cheers
	luigi

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-multimedia" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199802160706.IAA27462>