Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp884538pxb; Wed, 27 Oct 2021 14:26:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx3R5gQ8M+sZXT8U3k+XQ/ie6BCfk4w+r1ErTQXmojZduu6qTTw9CsSLm7Ol1wSgHB+9gGa X-Received: by 2002:a05:6402:1d49:: with SMTP id dz9mr474746edb.17.1635370011735; Wed, 27 Oct 2021 14:26:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635370011; cv=none; d=google.com; s=arc-20160816; b=S4hcDJ787tRjZKUNxGE4Ki7Fi75qv47AWugNB6q0RL847+aHKsPWU4J7YUpmGCJLjr 5HeHggxQLVxaOarYkyhMC+CaXuahveMYdUcIrqW5v4U8fqNzeG4WjMoIzgDKxlsFi/ze Dk3ErQX5usw64pvmVI2mxM1tKe4pYpiHpPlq15IUWrYIX82xKxUL4kkEeKkfxyutp3px 7/Vbc2o9uaD1qCCj6X+EAVZa0iQ7vH1SkkGlOrikTH/9bSB86rBueElvDzb7X/6ITYq2 NsKg4ufVg1Zj0Z6VG0WWLLZT7LeKtEa5/cmJoLhVp2jfOHcRciAlyKufJx9VMrCxTHPa hxFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :organization:in-reply-to:subject:cc:to:from; bh=r0Eh4814ju4X/EXnUO4hS7UTz+tGnSVZ7YA1WhlMGv0=; b=rzBkLXLijZpX0/B+DEtJ/F8p2BEx2ElgapujB7swoejleFaeNN2SwyASK7Ox6OaQu9 Gp5nz1rXLZ2QUpQiiQlYuWQD3AgEjHc0TtLoqNh4AKrtpMI89wrT30duNt/L/KbzcV6C sKlLfiVMzObAP7+7/1yfCT9i7t/+2aTNfY7j+0rZcJQE6yjHNIbKnaXYNhL7NBasxKC+ N/c7ukyqir+rqwFeWd3rARr24uVsQczQESnUBufnkxUQ7WRAQ2zMEUqgwMTT9Z16iCzP 7VEoa/7YVpwlvXFQcY2LHnS+RfJRQnZTs7Hp1f5of5elzVNlgoNOPQCk41fdB/pjCz9j Q7ew== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r27si1163839eda.505.2021.10.27.14.26.29; Wed, 27 Oct 2021 14:26:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242225AbhJ0Noi (ORCPT + 97 others); Wed, 27 Oct 2021 09:44:38 -0400 Received: from mga11.intel.com ([192.55.52.93]:29346 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242227AbhJ0Noh (ORCPT ); Wed, 27 Oct 2021 09:44:37 -0400 X-IronPort-AV: E=McAfee;i="6200,9189,10149"; a="227617391" X-IronPort-AV: E=Sophos;i="5.87,186,1631602800"; d="scan'208";a="227617391" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Oct 2021 06:42:04 -0700 X-IronPort-AV: E=Sophos;i="5.87,186,1631602800"; d="scan'208";a="497870033" Received: from smaharan-mobl.gar.corp.intel.com (HELO localhost) ([10.251.214.195]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Oct 2021 06:41:59 -0700 From: Jani Nikula To: Arnd Bergmann , dri-devel@lists.freedesktop.org, Joonas Lahtinen , Rodrigo Vivi , David Airlie , Daniel Vetter Cc: linux-fbdev@vger.kernel.org, intel-gfx@lists.freedesktop.org, Arnd Bergmann , Matthew Auld , Zhenyu Wang , Alex Williamson , Jason Gunthorpe , Daniele Ceraolo Spurio , linux-kernel@vger.kernel.org Subject: Re: [PATCH 3/3] [v2] i915: fix backlight configuration issue In-Reply-To: <20211027132732.3993279-3-arnd@kernel.org> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo References: <20211027132732.3993279-1-arnd@kernel.org> <20211027132732.3993279-3-arnd@kernel.org> Date: Wed, 27 Oct 2021 16:41:55 +0300 Message-ID: <87r1c6h9ek.fsf@intel.com> MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 27 Oct 2021, Arnd Bergmann wrote: > From: Arnd Bergmann > > The i915 driver can use the backlight subsystem as an option, and usually > selects it when CONFIG_ACPI is set. However it is possible to configure > a kernel with modular backlight classdev support and a built-in i915 > driver, which leads to a linker error: > > drivers/gpu/drm/i915/display/intel_panel.o: In function `intel_backlight_device_register': > intel_panel.c:(.text+0x2f58): undefined reference to `backlight_device_register' > drivers/gpu/drm/i915/display/intel_panel.o: In function `intel_backlight_device_unregister': > intel_panel.c:(.text+0x2fe4): undefined reference to `backlight_device_unregister' > > Change i915 to just 'depends on' for both BACKLIGHT_CLASS_DEVICE > and ACPI_VIDEO, which avoids a lot of the problems. > > Link: https://lore.kernel.org/all/20200108140227.3976563-1-arnd@arndb.de/ > Link: https://lore.kernel.org/all/20200417155553.675905-1-arnd@arndb.de/ > Signed-off-by: Arnd Bergmann > --- > This change depends on cleaning up drivers/video/fbdev to no longer > 'select' I2C and BACKLIGHT_CLASS_DEVICE, otherwise it causes > dependency loops. > --- > drivers/gpu/drm/i915/Kconfig | 6 ++---- > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/drivers/gpu/drm/i915/Kconfig b/drivers/gpu/drm/i915/Kconfig > index 84b6fc70cbf5..f427e6d50d9b 100644 > --- a/drivers/gpu/drm/i915/Kconfig > +++ b/drivers/gpu/drm/i915/Kconfig > @@ -3,6 +3,8 @@ config DRM_I915 > tristate "Intel 8xx/9xx/G3x/G4x/HD Graphics" > depends on DRM > depends on X86 && PCI > + depends on ACPI_VIDEO || !ACPI > + depends on BACKLIGHT_CLASS_DEVICE || !BACKLIGHT_CLASS_DEVICE > select INTEL_GTT > select INTERVAL_TREE > # we need shmfs for the swappable backing store, and in particular > @@ -16,10 +18,6 @@ config DRM_I915 > select IRQ_WORK > # i915 depends on ACPI_VIDEO when ACPI is enabled > # but for select to work, need to select ACPI_VIDEO's dependencies, ick The comment needs updating as well. Other than that, Acked-by: Jani Nikula on the series. > - select BACKLIGHT_CLASS_DEVICE if ACPI > - select INPUT if ACPI > - select ACPI_VIDEO if ACPI > - select ACPI_BUTTON if ACPI > select SYNC_FILE > select IOSF_MBI > select CRC32 -- Jani Nikula, Intel Open Source Graphics Center