mirror of
https://github.com/hardkernel/linux.git
synced 2026-03-24 19:40:21 +09:00
Merge pull request #340 from epicfrequency/patch-1
ALSA: usb-audio: Eliminate noise at the start of DSD playback.
This commit is contained in:
@@ -592,7 +592,21 @@ static int data_ep_set_params(struct snd_usb_endpoint *ep,
|
||||
|
||||
ep->datainterval = fmt->datainterval;
|
||||
ep->stride = frame_bits >> 3;
|
||||
ep->silence_value = pcm_format == SNDRV_PCM_FORMAT_U8 ? 0x80 : 0;
|
||||
|
||||
switch (pcm_format) {
|
||||
case SNDRV_PCM_FORMAT_U8:
|
||||
ep->silence_value = 0x80;
|
||||
break;
|
||||
case SNDRV_PCM_FORMAT_DSD_U8:
|
||||
case SNDRV_PCM_FORMAT_DSD_U16_LE:
|
||||
case SNDRV_PCM_FORMAT_DSD_U32_LE:
|
||||
case SNDRV_PCM_FORMAT_DSD_U16_BE:
|
||||
case SNDRV_PCM_FORMAT_DSD_U32_BE:
|
||||
ep->silence_value = 0x69;
|
||||
break;
|
||||
default:
|
||||
ep->silence_value = 0;
|
||||
}
|
||||
|
||||
/* assume max. frequency is 25% higher than nominal */
|
||||
ep->freqmax = ep->freqn + (ep->freqn >> 2);
|
||||
|
||||
Reference in New Issue
Block a user