From patchwork Mon Mar 20 14:40:20 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alan Cox X-Patchwork-Id: 9634331 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 07DB16020B for ; Mon, 20 Mar 2017 14:43:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EDFA31FF26 for ; Mon, 20 Mar 2017 14:43:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E2EDA2003F; Mon, 20 Mar 2017 14:43:15 +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=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5061E27F17 for ; Mon, 20 Mar 2017 14:43:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754486AbdCTOnK (ORCPT ); Mon, 20 Mar 2017 10:43:10 -0400 Received: from mga11.intel.com ([192.55.52.93]:3893 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753184AbdCTOmE (ORCPT ); Mon, 20 Mar 2017 10:42:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=intel.com; i=@intel.com; q=dns/txt; s=intel; t=1490020923; x=1521556923; h=subject:from:to:date:message-id:in-reply-to:references: mime-version:content-transfer-encoding; bh=bzkzP3v/YvosGTBI8A863wy6HoZHK+EVBEARdo2WI3U=; b=RUbc/kVZ/Jp3PNmz8+0t+7JTIWm5Pmbc5qLlvTvCEqeULD5B8DGehlMt T5BVIQsHsq5Hjt7/+SolZmuOIlrRpw==; Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 20 Mar 2017 07:40:23 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.36,194,1486454400"; d="scan'208";a="62683148" Received: from acox1-desk1.ger.corp.intel.com ([10.252.22.109]) by orsmga002.jf.intel.com with ESMTP; 20 Mar 2017 07:40:21 -0700 Subject: [PATCH 09/24] atomisp: remove another pair of 2400/2401 differences From: Alan Cox To: greg@kroah.com, linux-media@vger.kernel.org Date: Mon, 20 Mar 2017 14:40:20 +0000 Message-ID: <149002081364.17109.298566334102301120.stgit@acox1-desk1.ger.corp.intel.com> In-Reply-To: <149002068431.17109.1216139691005241038.stgit@acox1-desk1.ger.corp.intel.com> References: <149002068431.17109.1216139691005241038.stgit@acox1-desk1.ger.corp.intel.com> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The first of these checks the PCI identifier in order to decide what to do so needs no ifdef. The other is simply a variation on what is dumped for debug - so favour dumping the most. Signed-off-by Alan Cox --- .../media/atomisp/pci/atomisp2/atomisp_cmd.c | 7 ------- .../atomisp/pci/atomisp2/atomisp_dfs_tables.h | 4 ---- 2 files changed, 11 deletions(-) diff --git a/drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c b/drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c index d97a8df..08da8ea 100644 --- a/drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c +++ b/drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c @@ -263,12 +263,10 @@ int atomisp_freq_scaling(struct atomisp_device *isp, return -EINVAL; } -#ifdef ISP2401 if ((isp->pdev->device & ATOMISP_PCI_DEVICE_SOC_MASK) == ATOMISP_PCI_DEVICE_SOC_CHT && ATOMISP_USE_YUVPP(asd)) isp->dfs = &dfs_config_cht_soc; -#endif if (isp->dfs->lowest_freq == 0 || isp->dfs->max_freq_at_vmin == 0 || isp->dfs->highest_freq == 0 || isp->dfs->dfs_table_size == 0 || !isp->dfs->dfs_table) { @@ -654,13 +652,8 @@ irqreturn_t atomisp_isr(int irq, void *dev) } atomisp_eof_event(asd, eof_event.event.exp_id); -#ifndef ISP2401 - dev_dbg(isp->dev, "%s EOF exp_id %d\n", __func__, - eof_event.event.exp_id); -#else dev_dbg(isp->dev, "%s EOF exp_id %d, asd %d\n", __func__, eof_event.event.exp_id, asd->index); -#endif } irq_infos &= ~IA_CSS_IRQ_INFO_ISYS_EVENTS_READY; diff --git a/drivers/staging/media/atomisp/pci/atomisp2/atomisp_dfs_tables.h b/drivers/staging/media/atomisp/pci/atomisp2/atomisp_dfs_tables.h index dfb94e6..204d941 100644 --- a/drivers/staging/media/atomisp/pci/atomisp2/atomisp_dfs_tables.h +++ b/drivers/staging/media/atomisp/pci/atomisp2/atomisp_dfs_tables.h @@ -340,7 +340,6 @@ static const struct atomisp_freq_scaling_rule dfs_rules_cht[] = { .run_mode = ATOMISP_RUN_MODE_PREVIEW, }, { -#ifdef ISP2401 .width = 1280, .height = 720, .fps = ISP_FREQ_RULE_ANY, @@ -386,7 +385,6 @@ static const struct atomisp_freq_scaling_rule dfs_rules_cht_soc[] = { .run_mode = ATOMISP_RUN_MODE_PREVIEW, }, { -#endif .width = ISP_FREQ_RULE_ANY, .height = ISP_FREQ_RULE_ANY, .fps = ISP_FREQ_RULE_ANY, @@ -403,7 +401,6 @@ static const struct atomisp_dfs_config dfs_config_cht = { .dfs_table_size = ARRAY_SIZE(dfs_rules_cht), }; -#ifdef ISP2401 static const struct atomisp_dfs_config dfs_config_cht_soc = { .lowest_freq = ISP_FREQ_100MHZ, .max_freq_at_vmin = ISP_FREQ_356MHZ, @@ -412,5 +409,4 @@ static const struct atomisp_dfs_config dfs_config_cht_soc = { .dfs_table_size = ARRAY_SIZE(dfs_rules_cht_soc), }; -#endif #endif /* __ATOMISP_DFS_TABLES_H__ */