From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Message-ID: <55823878.7050108@huawei.com> Date: Thu, 18 Jun 2015 11:18:16 +0800 From: Zefan Li MIME-Version: 1.0 To: Adrian Knoth CC: , , , Takashi Iwai Subject: Re: [PATCH 3.4 035/172] ALSA: hdspm - Constrain periods to 2 on older cards References: <1434443587-4599-1-git-send-email-lizf@kernel.org> <1434443826-4929-35-git-send-email-lizf@kernel.org> <557FF02B.1080209@drcomp.erfurt.thur.de> In-Reply-To: <557FF02B.1080209@drcomp.erfurt.thur.de> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: >> @@ -6042,6 +6042,12 @@ static int snd_hdspm_capture_open(struct snd_pcm_substream *substream) >> snd_pcm_hw_constraint_minmax(runtime, >> SNDRV_PCM_HW_PARAM_PERIOD_SIZE, >> 64, 8192); >> + snd_pcm_hw_constraint_minmax(runtime, >> + SNDRV_PCM_HW_PARAM_PERIODS, >> + 2, 2); >> + snd_pcm_hw_constraint_minmax(runtime, >> + SNDRV_PCM_HW_PARAM_PERIODS, >> + 2, 2); >> break; >> } > > This is not correct, those lines need to go to two different functions > (snd_hdspm_playback_open and snd_hdspm_capture_open). > > Here is how the patch should look like: > Now fixed. Thanks for review the patch.