From patchwork Sun Dec 21 17:58:47 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rickard Strandqvist X-Patchwork-Id: 5524551 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 6CBA89F2F7 for ; Sun, 21 Dec 2014 17:56:19 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 92ABF20117 for ; Sun, 21 Dec 2014 17:56:18 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B6BED2011D for ; Sun, 21 Dec 2014 17:56:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752870AbaLUR4D (ORCPT ); Sun, 21 Dec 2014 12:56:03 -0500 Received: from mail-wi0-f182.google.com ([209.85.212.182]:65299 "EHLO mail-wi0-f182.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752041AbaLUR4B (ORCPT ); Sun, 21 Dec 2014 12:56:01 -0500 Received: by mail-wi0-f182.google.com with SMTP id h11so6079270wiw.15 for ; Sun, 21 Dec 2014 09:56:00 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=QM2vBUhmE5E099wkBnknRBP3PpIQfv1cr/fk2c9i9ig=; b=bujsUhzuf+/m6n5M9nrybxXOQfShJZXfW8WQD2Dd58NgzcNu5GmErgwB2L1n9DWjkQ vd3abefu6SaRkrtiHJQcnT7O19/wwbjd2woa+wItaDUxK9aGFVNGUPH6NFLBOxKaeWNl DsKyEraqIK6VGFah5xzS9pC6JXi9grtjLCKvdSdrjC2qSal2yAFIUy+lnGwNHvZ3hGpO lhNehQmSu+JXM0SWbVvPl3WMDYLv7Br+doYkNTI5AEfZQCwCGBkgOgfAKs/gb5yVAICe 06VpgBQIC/LQIWj4QgFWWIFFaWN/eRrgvKrg3MXbbGyvmE0COnwe5juYi8WPBNtLrIy2 oCVw== X-Gm-Message-State: ALoCoQlhSrXTkNO/wUHGwtMxvV0F21d6vrO+xfwkfxKf7r//hi8QB16Zik5GngIlHGkBXXVwpSrE X-Received: by 10.180.198.52 with SMTP id iz20mr24693437wic.60.1419184560025; Sun, 21 Dec 2014 09:56:00 -0800 (PST) Received: from localhost.localdomain (h-246-111.a218.priv.bahnhof.se. [85.24.246.111]) by mx.google.com with ESMTPSA id s9sm10265117wiz.12.2014.12.21.09.55.59 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 21 Dec 2014 09:55:59 -0800 (PST) From: Rickard Strandqvist To: Ismael Luceno , Mauro Carvalho Chehab Cc: Rickard Strandqvist , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] media: pci: solo6x10: solo6x10-enc.c: Remove unused function Date: Sun, 21 Dec 2014 18:58:47 +0100 Message-Id: <1419184727-11224-1-git-send-email-rickard_strandqvist@spectrumdigital.se> X-Mailer: git-send-email 1.7.10.4 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable 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 Remove the function solo_s_jpeg_qp() that is not used anywhere. This was partially found by using a static code analysis program called cppcheck. Signed-off-by: Rickard Strandqvist --- drivers/media/pci/solo6x10/solo6x10-enc.c | 35 ----------------------------- drivers/media/pci/solo6x10/solo6x10.h | 2 -- 2 files changed, 37 deletions(-) diff --git a/drivers/media/pci/solo6x10/solo6x10-enc.c b/drivers/media/pci/solo6x10/solo6x10-enc.c index d19c0ae..6b589b8 100644 --- a/drivers/media/pci/solo6x10/solo6x10-enc.c +++ b/drivers/media/pci/solo6x10/solo6x10-enc.c @@ -175,41 +175,6 @@ out: return 0; } -/** - * Set channel Quality Profile (0-3). - */ -void solo_s_jpeg_qp(struct solo_dev *solo_dev, unsigned int ch, - unsigned int qp) -{ - unsigned long flags; - unsigned int idx, reg; - - if ((ch > 31) || (qp > 3)) - return; - - if (solo_dev->type == SOLO_DEV_6010) - return; - - if (ch < 16) { - idx = 0; - reg = SOLO_VE_JPEG_QP_CH_L; - } else { - ch -= 16; - idx = 1; - reg = SOLO_VE_JPEG_QP_CH_H; - } - ch *= 2; - - spin_lock_irqsave(&solo_dev->jpeg_qp_lock, flags); - - solo_dev->jpeg_qp[idx] &= ~(3 << ch); - solo_dev->jpeg_qp[idx] |= (qp & 3) << ch; - - solo_reg_write(solo_dev, reg, solo_dev->jpeg_qp[idx]); - - spin_unlock_irqrestore(&solo_dev->jpeg_qp_lock, flags); -} - int solo_g_jpeg_qp(struct solo_dev *solo_dev, unsigned int ch) { int idx; diff --git a/drivers/media/pci/solo6x10/solo6x10.h b/drivers/media/pci/solo6x10/solo6x10.h index 72017b7..ad5afc6 100644 --- a/drivers/media/pci/solo6x10/solo6x10.h +++ b/drivers/media/pci/solo6x10/solo6x10.h @@ -399,8 +399,6 @@ int solo_eeprom_write(struct solo_dev *solo_dev, int loc, __be16 data); /* JPEG Qp functions */ -void solo_s_jpeg_qp(struct solo_dev *solo_dev, unsigned int ch, - unsigned int qp); int solo_g_jpeg_qp(struct solo_dev *solo_dev, unsigned int ch); #define CHK_FLAGS(v, flags) (((v) & (flags)) == (flags))