Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp6467315rwb; Mon, 12 Dec 2022 02:12:54 -0800 (PST) X-Google-Smtp-Source: AA0mqf5AjBLne31rHe5n2kTQHOPCxlWr3eTJOS0ILx2U7C5Ls4CXh2Cc0vQYmZtPNqgvLZb/v1T6 X-Received: by 2002:a05:6a20:1584:b0:aa:7d04:109b with SMTP id h4-20020a056a20158400b000aa7d04109bmr27596415pzj.40.1670839974760; Mon, 12 Dec 2022 02:12:54 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670839974; cv=none; d=google.com; s=arc-20160816; b=iVgXIQfP/P90ZsMLxjkvwevy9EKyF+PReaaNzk/ZxWlruS8lPLYrHT0c+EaDselWk+ FxDTqqX1kn5zhXPOGqtjYc0KTTxnch0UuWM+czapTP/Y1cpv4UF5UdbEvVqpgphavZWd H5p2ggsXaB2ThTvhiT+RwzBseMHSQT/FMNqKsNCC60dAn+yXmNLs8wgVkGXIghUn5s55 6CNHHd6NPEzhbIpeKa/HM3MmhKbj4cNfZVPOHCQcfBZRLWc+LsIocVVmBwXxWNIi6KDE Z+KLtn0xLz2qoV3LJl4XkF0eTEMJYOXVbamxpkdwNWsq18HP3FGOuVmU5tovhCimLpAc 7iGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:organization:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=shEC8F9b1Of46qA4fKA1Y4ekGs5WEQl/i0BCnJXGOtc=; b=0lDuoilpKj8rUqkC4ZVJ8n51gDPmfm7YulDutJSF0MoL1zcnDDd94izPeU1B9rvk/G rsztSXGh8kG0knc9VxhLCcZfBwsBmJts9TMCx9mC3hUUIfb3pehyB+3SDc33g7cRKTT6 YwLybWthUC37EVZmYLY9CrNQyIkffRZDtz5nHwk3Gu6ThbP7LdqiRKg4vj7fn2A3GXBg kbPra9AvSWIQe90wfN1L9GBzh3GipWQ+aRVouVCa/3fx/8rUWjkp+0GqAYyQSq3gR/LB oq7qPWiFvWXu2eAhxogMQ8p6w1p9TfgGDs7THV90KTgqW7PjIKzKQGK68sbizN4ghDr5 gvsg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 81-20020a630554000000b004785d1e2b7bsi9175808pgf.514.2022.12.12.02.12.43; Mon, 12 Dec 2022 02:12:54 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231830AbiLLJYd (ORCPT + 75 others); Mon, 12 Dec 2022 04:24:33 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50074 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231157AbiLLJYL (ORCPT ); Mon, 12 Dec 2022 04:24:11 -0500 Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 610E7F53; Mon, 12 Dec 2022 01:24:10 -0800 (PST) X-IronPort-AV: E=McAfee;i="6500,9779,10558"; a="319665590" X-IronPort-AV: E=Sophos;i="5.96,237,1665471600"; d="scan'208";a="319665590" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Dec 2022 01:24:09 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10558"; a="736903233" X-IronPort-AV: E=Sophos;i="5.96,237,1665471600"; d="scan'208";a="736903233" Received: from smile.fi.intel.com ([10.237.72.54]) by FMSMGA003.fm.intel.com with ESMTP; 12 Dec 2022 01:24:07 -0800 Received: from andy by smile.fi.intel.com with local (Exim 4.96) (envelope-from ) id 1p4f2b-008Oim-0a; Mon, 12 Dec 2022 11:24:05 +0200 Date: Mon, 12 Dec 2022 11:24:04 +0200 From: Andy Shevchenko To: Uwe =?iso-8859-1?Q?Kleine-K=F6nig?= Cc: Jean Delvare , Sean Young , Mauro Carvalho Chehab , Thierry Reding , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pwm@vger.kernel.org, "Rafael J. Wysocki" , Len Brown , linux-acpi@vger.kernel.org Subject: Re: [PATCH] media: rc: Drop obsolete dependencies on COMPILE_TEST Message-ID: References: <20221121170911.7cd72bfc@endymion.delvare> <20221211205648.hdv5haufqwfoxzu2@pengutronix.de> <20221211231435.43c4f361@endymion.delvare> <20221212075907.4iwjsib5nrk7eqr2@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20221212075907.4iwjsib5nrk7eqr2@pengutronix.de> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-Spam-Status: No, score=-3.5 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_SOFTFAIL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Dec 12, 2022 at 08:59:07AM +0100, Uwe Kleine-K?nig wrote: > On Sun, Dec 11, 2022 at 11:14:35PM +0100, Jean Delvare wrote: > > On Sun, 11 Dec 2022 21:56:48 +0100, Uwe Kleine-K?nig wrote: > > > On Mon, Nov 21, 2022 at 05:09:11PM +0100, Jean Delvare wrote: ... > > > > - .of_match_table = of_match_ptr(pwm_ir_of_match), > > > > + .of_match_table = pwm_ir_of_match, > > > That hunk makes sense even without the Kconfig change. ACPI makes use of > > > .of_match_table, so > > > > > > .of_match_table = of_match_ptr(pwm_ir_of_match), > > > > > > is (almost?) always wrong. > > > > Should we just get rid of this macro altogether then? > > > > (Somehow I have a strange feeling that we already had this > > discussion...) > > Might be. But for me this is only second hand knowledge, too. Maybe > someone of the new recipents in this thread feels competent to comment > here?! Pros of of_match_ptr() / ACPI_PTR(): - saves a few dozens of bytes in the module ID tables - doesn't show ACPI ID for non-ACPI platform or OF ID on non-OF platforms Cons: - prevents from using OF IDs on ACPI platforms - doesn't show ACPI ID for non-ACPI platform or OF ID on non-OF platforms - makes error prone for the compiler to have the variable unused - makes code uglier (I left the second in the both because I find useful to have all supported IDs to be listed even if the system is compiled with OF/ACPI opted-out.) Personally I remove the of_match_ptr()/ACPI_PTR() from drivers that can be used on OF or ACPI platforms, which leaves us only with the drivers we are 100% sure that they won't ever be used on non-OF platforms. BUT, I do not see any sense to have of_match_ptr() that either in use, because the driver in question is 100% for OF platform, or not when it's compile tested, which means it reduces test coverage anyway. All the same for ACPI_PTR(). TL;DR: I don't see any [big] usefulness of keeping those macros. -- With Best Regards, Andy Shevchenko