* [PATCH] hdspm: native float
@ 2009-04-14 17:11 Florian Faber
2009-04-16 10:01 ` Clemens Ladisch
0 siblings, 1 reply; 9+ messages in thread
From: Florian Faber @ 2009-04-14 17:11 UTC (permalink / raw)
To: alsa-devel
Adds native float support to the driver. The interface has hardware
support for CoreAudio[tm], why shouldn't jack users benefit from it.
diff a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c
13a14,16
> * Modified 2009-04-14 for native float support by Florian Faber
> * <faber@faberman.de>
> *
39a43
> #include <sound/pcm_params.h>
198a203
> #define HDSPe_FLOAT_FORMAT 0x2000000
3726a3732,3747
>
>
> /* Switch to native float format if requested */
> if (SNDRV_PCM_FORMAT_FLOAT_LE == params_format(params)) {
> if (!(hdspm->control_register & HDSPe_FLOAT_FORMAT)) {
> snd_printk(KERN_INFO "hdspm: Switching to native 32bit LE float
format.\n");
> }
> hdspm->control_register |= HDSPe_FLOAT_FORMAT;
> } else if (SNDRV_PCM_FORMAT_S32_LE == params_format(params)) {
> if (hdspm->control_register & HDSPe_FLOAT_FORMAT) {
> snd_printk(KERN_INFO "hdspm: Switching to native 32bit LE integer
format.\n");
> }
> hdspm->control_register &= ~HDSPe_FLOAT_FORMAT;
> }
> hdspm_write(hdspm, HDSPM_controlRegister, hdspm->control_register);
>
3870c3891
< .formats = SNDRV_PCM_FMTBIT_S32_LE,
---
> .formats = SNDRV_PCM_FMTBIT_S32_LE | SNDRV_PCM_FMTBIT_FLOAT_LE,
3895c3916
< .formats = SNDRV_PCM_FMTBIT_S32_LE,
---
> .formats = SNDRV_PCM_FMTBIT_S32_LE | SNDRV_PCM_FMTBIT_FLOAT_LE,
Flo
--
Machines can do the work, so people have time to think.
public key 6C002249 x-hkp://wwwkeys.eu.pgp.net
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: [PATCH] hdspm: native float
2009-04-14 17:11 [PATCH] hdspm: native float Florian Faber
@ 2009-04-16 10:01 ` Clemens Ladisch
2009-04-16 10:44 ` Florian Faber
0 siblings, 1 reply; 9+ messages in thread
From: Clemens Ladisch @ 2009-04-16 10:01 UTC (permalink / raw)
To: Florian Faber; +Cc: alsa-devel
Florian Faber wrote:
> diff a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c
Please use unified diff format and add Signed-off-by; see
linux/Documentation/SubmittingPatches.
> > * Modified 2009-04-14 for native float support by Florian Faber
> > * <faber@faberman.de>
> > *
Changelogs are now in git.
> > /* Switch to native float format if requested */
> > ...
> > hdspm_write(hdspm, HDSPM_controlRegister, hdspm->control_register);
This looks like a global change. What happens when playback and
recording want to use different formats?
Best regards,
Clemens
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] hdspm: native float
2009-04-16 10:01 ` Clemens Ladisch
@ 2009-04-16 10:44 ` Florian Faber
2009-04-16 11:48 ` Clemens Ladisch
0 siblings, 1 reply; 9+ messages in thread
From: Florian Faber @ 2009-04-16 10:44 UTC (permalink / raw)
To: Clemens Ladisch; +Cc: alsa-devel
Clemens,
> > > /* Switch to native float format if requested */
> > > ...
> > > hdspm_write(hdspm, HDSPM_controlRegister, hdspm->control_register);
> This looks like a global change. What happens when playback and
> recording want to use different formats?
It is a global change. The only use case is for jack, and jack doesn't
use different formats for input/output.
--
Flo
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] hdspm: native float
2009-04-16 10:44 ` Florian Faber
@ 2009-04-16 11:48 ` Clemens Ladisch
2009-04-16 12:12 ` Florian Faber
0 siblings, 1 reply; 9+ messages in thread
From: Clemens Ladisch @ 2009-04-16 11:48 UTC (permalink / raw)
To: Florian Faber; +Cc: alsa-devel
Florian Faber wrote:
> > > > /* Switch to native float format if requested */
> > > > ...
> > > > hdspm_write(hdspm, HDSPM_controlRegister, hdspm->control_register);
> >
> > This looks like a global change. What happens when playback and
> > recording want to use different formats?
>
> It is a global change. The only use case is for jack, and jack doesn't
> use different formats for input/output.
"Using aplay + arecord" is a second use case. :-)
Anyway, at least add a check that the formats are actually the same
(like the checks for sample rate and period size).
Best regards,
Clemens
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] hdspm: native float
2009-04-16 11:48 ` Clemens Ladisch
@ 2009-04-16 12:12 ` Florian Faber
2009-04-16 12:36 ` Takashi Iwai
2009-04-16 12:41 ` Mark Brown
0 siblings, 2 replies; 9+ messages in thread
From: Florian Faber @ 2009-04-16 12:12 UTC (permalink / raw)
To: Clemens Ladisch; +Cc: alsa-devel
Clemens,
> > It is a global change. The only use case is for jack, and jack doesn't
> > use different formats for input/output.
> "Using aplay + arecord" is a second use case. :-)
And they would willingly choose different formats?
> Anyway, at least add a check that the formats are actually the same
> (like the checks for sample rate and period size).
Ok.
I just fixed a bug regarding the clock source anyway
(LAC-live-debugging :).
--
Flo
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] hdspm: native float
2009-04-16 12:12 ` Florian Faber
@ 2009-04-16 12:36 ` Takashi Iwai
2009-04-16 12:41 ` Mark Brown
1 sibling, 0 replies; 9+ messages in thread
From: Takashi Iwai @ 2009-04-16 12:36 UTC (permalink / raw)
To: Florian Faber; +Cc: alsa-devel, Clemens Ladisch
At Thu, 16 Apr 2009 14:12:21 +0200,
Florian Faber wrote:
>
> > > It is a global change. The only use case is for jack, and jack doesn't
> > > use different formats for input/output.
> > "Using aplay + arecord" is a second use case. :-)
>
> And they would willingly choose different formats?
Possibly. It's not always the same user who play and record.
thanks,
Takashi
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] hdspm: native float
2009-04-16 12:12 ` Florian Faber
2009-04-16 12:36 ` Takashi Iwai
@ 2009-04-16 12:41 ` Mark Brown
2009-04-16 18:01 ` John Rigg
2009-04-16 18:32 ` John Rigg
1 sibling, 2 replies; 9+ messages in thread
From: Mark Brown @ 2009-04-16 12:41 UTC (permalink / raw)
To: Florian Faber; +Cc: alsa-devel, Clemens Ladisch
On Thu, Apr 16, 2009 at 02:12:21PM +0200, Florian Faber wrote:
> > > It is a global change. The only use case is for jack, and jack doesn't
> > > use different formats for input/output.
> > "Using aplay + arecord" is a second use case. :-)
> And they would willingly choose different formats?
A moderately common case is recording voice quality audio (at 8kHz or
so) and playing back higher quality audio.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] hdspm: native float
2009-04-16 12:41 ` Mark Brown
@ 2009-04-16 18:01 ` John Rigg
2009-04-16 18:32 ` John Rigg
1 sibling, 0 replies; 9+ messages in thread
From: John Rigg @ 2009-04-16 18:01 UTC (permalink / raw)
To: alsa-devel
On Thu, Apr 16, 2009 at 01:41:59PM +0100, Mark Brown wrote:
> On Thu, Apr 16, 2009 at 02:12:21PM +0200, Florian Faber wrote:
>
> > > > It is a global change. The only use case is for jack, and jack doesn't
> > > > use different formats for input/output.
> > > "Using aplay + arecord" is a second use case. :-)
>
> > And they would willingly choose different formats?
>
> A moderately common case is recording voice quality audio (at 8kHz or
> so) and playing back higher quality audio.
Perhaps a little less common on a 64-channel MADI interface
like this :-)
John
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] hdspm: native float
2009-04-16 12:41 ` Mark Brown
2009-04-16 18:01 ` John Rigg
@ 2009-04-16 18:32 ` John Rigg
1 sibling, 0 replies; 9+ messages in thread
From: John Rigg @ 2009-04-16 18:32 UTC (permalink / raw)
To: alsa-devel
On Thu, Apr 16, 2009 at 01:41:59PM +0100, Mark Brown wrote:
> On Thu, Apr 16, 2009 at 02:12:21PM +0200, Florian Faber wrote:
>
> > > > It is a global change. The only use case is for jack, and jack doesn't
> > > > use different formats for input/output.
> > > "Using aplay + arecord" is a second use case. :-)
>
> > And they would willingly choose different formats?
>
> A moderately common case is recording voice quality audio (at 8kHz or
> so) and playing back higher quality audio.
Perhaps a little less common on a 64-channel MADI interface
like this :-)
John
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2009-04-16 18:17 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-04-14 17:11 [PATCH] hdspm: native float Florian Faber
2009-04-16 10:01 ` Clemens Ladisch
2009-04-16 10:44 ` Florian Faber
2009-04-16 11:48 ` Clemens Ladisch
2009-04-16 12:12 ` Florian Faber
2009-04-16 12:36 ` Takashi Iwai
2009-04-16 12:41 ` Mark Brown
2009-04-16 18:01 ` John Rigg
2009-04-16 18:32 ` John Rigg
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.