From patchwork Thu Dec 7 11:57:14 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jussi Laako X-Patchwork-Id: 10098521 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 8AFE060360 for ; Thu, 7 Dec 2017 11:57:35 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6DD8F2A459 for ; Thu, 7 Dec 2017 11:57:35 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6292D2A467; Thu, 7 Dec 2017 11:57:35 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A75B32A459 for ; Thu, 7 Dec 2017 11:57:34 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 273AF2670F4; Thu, 7 Dec 2017 12:57:30 +0100 (CET) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id EE85C267AE0; Thu, 7 Dec 2017 12:57:28 +0100 (CET) Received: from mail.sonarnerd.net (rankki.sonarnerd.net [194.142.149.154]) by alsa0.perex.cz (Postfix) with ESMTP id 060322670BC for ; Thu, 7 Dec 2017 12:57:26 +0100 (CET) Received: from porkkala.uworld (porkkala.uworld [IPv6:fc00::2]) by mail.sonarnerd.net (Postfix) with ESMTP id AA4642310A4; Thu, 7 Dec 2017 13:57:25 +0200 (EET) From: Jussi Laako To: perex@perex.cz, alsa-devel@alsa-project.org Date: Thu, 7 Dec 2017 13:57:14 +0200 Message-Id: <1512647834-24554-1-git-send-email-jussi@sonarnerd.net> X-Mailer: git-send-email 2.7.4 Cc: Jussi Laako Subject: [alsa-devel] [PATCH] alsa-utils: aplay: Adjust sample rate limits to support newer hardware X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP There are number of devices that support up to 384 kHz sampling rate and some devices up to 768 kHz sampling rate. This patch increases sanity check limit to 768k in order to support testing of such hardware. Signed-off-by: Jussi Laako --- aplay/aplay.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/aplay/aplay.c b/aplay/aplay.c index dbae17c..6b740c2 100644 --- a/aplay/aplay.c +++ b/aplay/aplay.c @@ -635,10 +635,10 @@ int main(int argc, char *argv[]) error(_("invalid rate argument '%s'"), optarg); return 1; } - if (tmp < 300) + if (tmp < 1000) tmp *= 1000; rhwparams.rate = tmp; - if (tmp < 2000 || tmp > 192000) { + if (tmp < 2000 || tmp > 768000) { error(_("bad speed value %i"), tmp); return 1; }