From patchwork Wed Aug 2 09:56:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kate Hsuan X-Patchwork-Id: 13337981 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4EAB8C001DF for ; Wed, 2 Aug 2023 09:58:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234250AbjHBJ6y (ORCPT ); Wed, 2 Aug 2023 05:58:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55954 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234245AbjHBJ6g (ORCPT ); Wed, 2 Aug 2023 05:58:36 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C13C0B2 for ; Wed, 2 Aug 2023 02:57:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1690970271; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=GOFd9JGAsybq3+W0dWLwdnReh5Kwy01yAHdTXKRQaPk=; b=bx2CUSVDHoQSA+ThvqP77Kbp3qWKlNaid67/tAw5CohpVOq2eILxczUnKi2T6S8Jd8gpxR 3A89ivSoIcTM2p8wgDemushCd4g87XR1h79l3ebaIS50WLWzI1xDmtFyU5WE6MdlNxUHM2 VxJaL6Vd+B+INCaTbqg5mQrsIT69y/g= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-64-b7IDWI0YNF6fknKoi6LuXA-1; Wed, 02 Aug 2023 05:57:48 -0400 X-MC-Unique: b7IDWI0YNF6fknKoi6LuXA-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id B09DA856F66; Wed, 2 Aug 2023 09:57:47 +0000 (UTC) Received: from fedora.redhat.com (unknown [10.67.24.18]) by smtp.corp.redhat.com (Postfix) with ESMTP id F1B1C401DA9; Wed, 2 Aug 2023 09:57:44 +0000 (UTC) From: Kate Hsuan To: Hans de Goede , Mauro Carvalho Chehab , Sakari Ailus , Greg Kroah-Hartman , linux-media@vger.kernel.org, linux-staging@lists.linux.dev Cc: Kate Hsuan Subject: [PATCH 12/12] media: atomisp: atomisp_v4l2: Removed unnecessary code Date: Wed, 2 Aug 2023 17:56:06 +0800 Message-ID: <20230802095606.1298152-13-hpa@redhat.com> In-Reply-To: <20230802095606.1298152-1-hpa@redhat.com> References: <20230802095606.1298152-1-hpa@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Here is the last step of #ifdef ISP2401 removal work. Since the driver became generic, this part of the code was no longer needed and can be removed. Signed-off-by: Kate Hsuan --- .../staging/media/atomisp/pci/atomisp_v4l2.c | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c index c43b916a006e..ca95944388df 100644 --- a/drivers/staging/media/atomisp/pci/atomisp_v4l2.c +++ b/drivers/staging/media/atomisp/pci/atomisp_v4l2.c @@ -1206,25 +1206,6 @@ static bool is_valid_device(struct pci_dev *pdev, const struct pci_device_id *id return false; } - /* - * FIXME: - * remove the if once the driver become generic - */ - -#ifndef ISP2401 - if (IS_ISP2401) { - dev_err(&pdev->dev, "Support for %s (ISP2401) was disabled at compile time\n", - name); - return false; - } -#else - if (!IS_ISP2401) { - dev_err(&pdev->dev, "Support for %s (ISP2400) was disabled at compile time\n", - name); - return false; - } -#endif - dev_info(&pdev->dev, "Detected %s version %d (ISP240%c) on %s\n", name, pdev->revision, IS_ISP2401 ? '1' : '0', product);