From patchwork Sat Sep 13 08:56:46 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Frank_Sch=C3=A4fer?= X-Patchwork-Id: 4899461 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id D3261BEEA5 for ; Sat, 13 Sep 2014 08:55:32 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 1F3E62018B for ; Sat, 13 Sep 2014 08:55:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4EC5B2012B for ; Sat, 13 Sep 2014 08:55:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751763AbaIMIz2 (ORCPT ); Sat, 13 Sep 2014 04:55:28 -0400 Received: from mail-la0-f46.google.com ([209.85.215.46]:38954 "EHLO mail-la0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751711AbaIMIzZ (ORCPT ); Sat, 13 Sep 2014 04:55:25 -0400 Received: by mail-la0-f46.google.com with SMTP id el20so2229632lab.19 for ; Sat, 13 Sep 2014 01:55:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=from:to:cc:subject:date:message-id:mime-version:content-type :content-transfer-encoding; bh=cKjyGYqcn5XAIlz7nr0T7KWilHB5SWd1Dyvlcx21E24=; b=u+5SlVKI0p0232TzPSOSpzE8AFAufLOUAuM/sQ2Kg4nWhXK0pMSGCf6+1gz4IfG+L0 2bLzYsIOyazAhdFGicOmC7h5Nm6tiVupTn/dF+F73cISK9zxKY2/+F39aFtASSX6tK8k thGHEzPkl+9hu3dsOIgFWtP8zF7X+dcwJr5FRW2ETa9D/UpchxwQ5BTq9HQHHtFGcrQz UmaYEdTmORNWsOvn3UCxgEazLSw1ZkqURlNQicTMKHXHBUqr+5DvzNuEEdgYP7dntt1s YYBD/FsyuwXHNjg0H9on8SyleNwQ+r/0QyCQk98dO3RNrygOtMHyx+Y8TRt12kil9ZbO x67Q== X-Received: by 10.112.19.70 with SMTP id c6mr14003544lbe.20.1410598523940; Sat, 13 Sep 2014 01:55:23 -0700 (PDT) Received: from Athlon64X2-5000.site (ip-178-201-166-123.hsi08.unitymediagroup.de. [178.201.166.123]) by mx.google.com with ESMTPSA id oc1sm2133414lbb.45.2014.09.13.01.55.23 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 13 Sep 2014 01:55:23 -0700 (PDT) From: =?UTF-8?q?Frank=20Sch=C3=A4fer?= To: m.chehab@samsung.com Cc: linux-media@vger.kernel.org, =?UTF-8?q?Frank=20Sch=C3=A4fer?= Subject: [PATCH] em28xx: remove dead code line from em28xx_audio_setup() Date: Sat, 13 Sep 2014 10:56:46 +0200 Message-Id: <1410598606-889-1-git-send-email-fschaefer.oss@googlemail.com> X-Mailer: git-send-email 1.8.4.5 MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Spam-Status: No, score=-9.3 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Setting the value of the chip config register to EM28XX_CHIPCFG_AC97 in case of a read error is a leftover from the past which is no longer needed. Signed-off-by: Frank Schäfer --- drivers/media/usb/em28xx/em28xx-core.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/media/usb/em28xx/em28xx-core.c b/drivers/media/usb/em28xx/em28xx-core.c index 91ea3e4..bfe0726 100644 --- a/drivers/media/usb/em28xx/em28xx-core.c +++ b/drivers/media/usb/em28xx/em28xx-core.c @@ -516,9 +516,8 @@ int em28xx_audio_setup(struct em28xx *dev) /* See how this device is configured */ cfg = em28xx_read_reg(dev, EM28XX_R00_CHIPCFG); em28xx_info("Config register raw data: 0x%02x\n", cfg); - if (cfg < 0) { - /* Register read error? */ - cfg = EM28XX_CHIPCFG_AC97; /* Be conservative */ + if (cfg < 0) { /* Register read error */ + /* Be conservative */ dev->int_audio_type = EM28XX_INT_AUDIO_AC97; } else if ((cfg & EM28XX_CHIPCFG_AUDIOMASK) == 0x00) { /* The device doesn't have vendor audio at all */