From patchwork Thu Apr 19 06:36:17 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Vinod Koul X-Patchwork-Id: 10349163 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 4471B6023A for ; Thu, 19 Apr 2018 06:32:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3607024603 for ; Thu, 19 Apr 2018 06:32:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2AAE326253; Thu, 19 Apr 2018 06:32:09 +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=-2.9 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, 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 3725B24603 for ; Thu, 19 Apr 2018 06:32:08 +0000 (UTC) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 5B6492676B3; Thu, 19 Apr 2018 08:31:59 +0200 (CEST) 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 DD05A26765F; Thu, 19 Apr 2018 08:31:55 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by alsa0.perex.cz (Postfix) with ESMTP id 73B422672B4 for ; Thu, 19 Apr 2018 08:31:53 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 18 Apr 2018 23:31:52 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.48,467,1517904000"; d="scan'208";a="49074191" Received: from vkoul-udesk7.iind.intel.com ([10.223.84.143]) by orsmga001.jf.intel.com with ESMTP; 18 Apr 2018 23:31:50 -0700 From: Vinod Koul To: alsa-devel@alsa-project.org Date: Thu, 19 Apr 2018 12:06:17 +0530 Message-Id: <1524119780-21206-2-git-send-email-vinod.koul@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1524119780-21206-1-git-send-email-vinod.koul@intel.com> References: <1524119780-21206-1-git-send-email-vinod.koul@intel.com> MIME-Version: 1.0 Cc: Vinod Koul , Katsuhiro Suzuki Subject: [alsa-devel] [PATCH 2/5] cplay: remove dead code codec_name_from_id() 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: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP The codec_name_from_id() was added but never used so remove it and eliminate unused function warning cplay.c:103:20: warning: ‘codec_name_from_id’ defined but not used [-Wunused-function] We can take from git if user appears Signed-off-by: Vinod Koul --- CC: Katsuhiro Suzuki src/utils/cplay.c | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/src/utils/cplay.c b/src/utils/cplay.c index 98d71a2199da..b02644a3f2ea 100644 --- a/src/utils/cplay.c +++ b/src/utils/cplay.c @@ -100,20 +100,6 @@ static const struct { }; #define CPLAY_NUM_CODEC_IDS (sizeof(codec_ids) / sizeof(codec_ids[0])) -static const char *codec_name_from_id(unsigned int id) -{ - static char hexname[12]; - int i; - - for (i = 0; i < CPLAY_NUM_CODEC_IDS; ++i) { - if (codec_ids[i].id == id) - return codec_ids[i].name; - } - - snprintf(hexname, sizeof(hexname), "0x%x", id); - return hexname; /* a static is safe because we're single-threaded */ -} - static void usage(void) { int i;