From patchwork Wed Jan 11 13:01:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Thomas Zimmermann X-Patchwork-Id: 13096618 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A0B63C46467 for ; Wed, 11 Jan 2023 13:04:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=OBkgh84txMeG8dQX9LDEIyJMaXHQgnEk/EhdgyzIk5o=; b=IAGr97iilarwQn fwRmIpgAYfVKKSZAiHTIY+OBfnGVrHhVfqayA7ov05KllzDoI5saEAp4l/6fhMWhV1OQYXYB8uMRu vkqcr3tq4SenUPtml6Tw3NI+381H4WsIQq7Sr+FL4tC49N7jRipJ/dMEZOKi2ldCD59tD465XADfu dn8Rp2tXh2ScK6Fv/eg3vRCN9y9mb73trdVPrCd5QLBk9ujqBqmIwgNGdWelZuOTBb/cJAQA0JVWi 5GPOWT+t7keYdGL1Ma0NMKgGK8L/mBPHARAKowjyqqUAsY5AAXzn6o4G9Xl+8wS/5Cop+S3uV1iX1 UGEQ4sQ2QBpDt0Ml7lcA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pFalY-00BPsP-4p; Wed, 11 Jan 2023 13:03:40 +0000 Received: from smtp-out2.suse.de ([2001:67c:2178:6::1d]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pFakE-00BPFW-59; Wed, 11 Jan 2023 13:02:21 +0000 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 5090568053; Wed, 11 Jan 2023 13:02:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1673442130; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eCgEoSzGQrIBgeE4VTSyVWd4/4BcVXWPRVXv3akFVwU=; b=sKI+1Pv0veSI2q+fXsLFIU7ZKXRQHAjsRXueUws1RRqBuzmlxerI7MedRD+mVvWvBLfR8b ILHPrQBFsgeEz3RQFPK8MN7oLV1XJ1ayMYzIS0apzigyIH5YZthoL9ODdAH99++WjiTmED JnI5meJLF5/gqu9gl0VXd55JmzvRgac= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1673442130; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=eCgEoSzGQrIBgeE4VTSyVWd4/4BcVXWPRVXv3akFVwU=; b=efvISctzIGyBsbLFP6t42k2pDRPfe9cGMvVA921VNaMk4fjubpKk2KBJ1/4FjjX9aTiNSZ QxC3rsIs5GYdiyBg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id F187413594; Wed, 11 Jan 2023 13:02:09 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id UGoVOlGzvmMaXAAAMHmgww (envelope-from ); Wed, 11 Jan 2023 13:02:09 +0000 From: Thomas Zimmermann To: alexander.deucher@amd.com, christian.koenig@amd.com, airlied@gmail.com, daniel@ffwll.ch, maarten.lankhorst@linux.intel.com, mripard@kernel.org, patrik.r.jakobsson@gmail.com, thierry.reding@gmail.com, sam@ravnborg.org, f.fainelli@gmail.com, james.qian.wang@arm.com, liviu.dudau@arm.com Cc: dri-devel@lists.freedesktop.org, bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, amd-gfx@lists.freedesktop.org, Thomas Zimmermann Subject: [PATCH v2 01/10] drm: Include where needed Date: Wed, 11 Jan 2023 14:01:57 +0100 Message-Id: <20230111130206.29974-2-tzimmermann@suse.de> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230111130206.29974-1-tzimmermann@suse.de> References: <20230111130206.29974-1-tzimmermann@suse.de> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230111_050218_423505_7A40C5D3 X-CRM114-Status: GOOD ( 12.47 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Include in source files that need it. Some of DRM's source code gets the backlight header via drm_crtc_helper.h and , which can leed to unnecessary recompilation. If possible, do not include drm_crtc_helper.h any longer. Signed-off-by: Thomas Zimmermann Acked-by: Christian König # amd Reviewed-by: Sam Ravnborg --- drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c | 2 +- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 + drivers/gpu/drm/gma500/backlight.c | 2 ++ drivers/gpu/drm/radeon/radeon_acpi.c | 2 +- 4 files changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c index 57b5e11446c6..f29c1d0ad4c1 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c @@ -24,6 +24,7 @@ #include #include +#include #include #include #include @@ -31,7 +32,6 @@ #include #include -#include #include "amdgpu.h" #include "amdgpu_pm.h" #include "amdgpu_display.h" diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index 1b7f20a9d4ae..55a845eb0c6d 100644 --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c @@ -67,6 +67,7 @@ #include "ivsrcid/ivsrcid_vislands30.h" #include "i2caux_interface.h" +#include #include #include #include diff --git a/drivers/gpu/drm/gma500/backlight.c b/drivers/gpu/drm/gma500/backlight.c index 577a4987b193..8711a7a5b8da 100644 --- a/drivers/gpu/drm/gma500/backlight.c +++ b/drivers/gpu/drm/gma500/backlight.c @@ -7,6 +7,8 @@ * Authors: Eric Knopp */ +#include + #include #include "psb_drv.h" diff --git a/drivers/gpu/drm/radeon/radeon_acpi.c b/drivers/gpu/drm/radeon/radeon_acpi.c index b603c0b77075..5771d1fcb073 100644 --- a/drivers/gpu/drm/radeon/radeon_acpi.c +++ b/drivers/gpu/drm/radeon/radeon_acpi.c @@ -22,6 +22,7 @@ */ #include +#include #include #include #include @@ -30,7 +31,6 @@ #include #include -#include #include #include "atom.h" From patchwork Wed Jan 11 13:01:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Zimmermann X-Patchwork-Id: 13096613 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3DC29C46467 for ; Wed, 11 Jan 2023 13:03:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=qYFAtU/mFiMMqeN/skdhEvOHChPNd0/gg0GidTieChY=; b=nCypZI/DB7IBI7 4uvymbY4xb1bzEUasWjQCMgwveSRroPDjJcczkKOzFfSa6aAX0EeDlmxYwIEMaAhBsoE5iafUHPRX VLLrXO7DdlnizZqSBUiWDuCKrXLJa4okfhQU2FoDafpjO3Do+2OZ5JcjlcYUSC1h429e7tFrrpwou 6/pyECcGqND0NLLjLyqR8jCI9i622/ID3fjKNMpH5zwMfpl05kOce3+MLmlVm4GileRxwa0UPkshG m1yPTWag5MUgHfHJb4VzfOrzJmLVsG/GFcwmrleNUc9+3F+TmNp2n8szNBG47QoEOvRKgdyUhTGy3 WVouqI/EnZWSjQ8tWaCQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pFakS-00BPO1-NF; Wed, 11 Jan 2023 13:02:32 +0000 Received: from smtp-out2.suse.de ([2001:67c:2178:6::1d]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pFakE-00BPFZ-5v; Wed, 11 Jan 2023 13:02:19 +0000 Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 9FCF97724E; Wed, 11 Jan 2023 13:02:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1673442130; h=from:from:reply-to: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=HAQ+vGdFHIOKmUMVDXoS/GsY4nkmzF3bO8yR2aLReHc=; b=TJtx2OMpuNe03r9rouzlOgGT3LhdMA5bkZhbAJEFyVcuIPAq9Amh7A60a9KL1eXSjtIcGh 24eX9NZ5dhoN10bwDwlZJ6l7GfrKxKdRvvQZpc31k51KdQXm+5JXaw0r9OArtrvcqSYKGS HflTYP/TgOgtWiPEzVIZm9oj3Rl2zBw= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1673442130; h=from:from:reply-to: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=HAQ+vGdFHIOKmUMVDXoS/GsY4nkmzF3bO8yR2aLReHc=; b=BNSAFlX6BD+SsWlmXnD//q26GovIf6uHd50DoWee7ABuEF7OwoETfNaI7mHQKlmTOFQFn0 k5Ik+V3Vjia6dGAg== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 548AF13591; Wed, 11 Jan 2023 13:02:10 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id oKKuE1KzvmMaXAAAMHmgww (envelope-from ); Wed, 11 Jan 2023 13:02:10 +0000 From: Thomas Zimmermann To: alexander.deucher@amd.com, christian.koenig@amd.com, airlied@gmail.com, daniel@ffwll.ch, maarten.lankhorst@linux.intel.com, mripard@kernel.org, patrik.r.jakobsson@gmail.com, thierry.reding@gmail.com, sam@ravnborg.org, f.fainelli@gmail.com, james.qian.wang@arm.com, liviu.dudau@arm.com Cc: dri-devel@lists.freedesktop.org, bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, amd-gfx@lists.freedesktop.org, Thomas Zimmermann Subject: [PATCH v2 02/10] drm: Include where needed Date: Wed, 11 Jan 2023 14:01:58 +0100 Message-Id: <20230111130206.29974-3-tzimmermann@suse.de> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230111130206.29974-1-tzimmermann@suse.de> References: <20230111130206.29974-1-tzimmermann@suse.de> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230111_050218_425396_237666E4 X-CRM114-Status: GOOD ( 12.51 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Include in source files that need it. Some of DRM's source code gets OF header via drm_crtc_helper.h and , which can leed to unnecessary recompilation. In drm_modes.c, add a comment on the reason for still including . The header file is required to get KHZ2PICOS(). The macro is part of the UAPI headers, so it cannot be moved to a less prominent location. v2: * include in komeda_drv.c (kernel test robot) Signed-off-by: Thomas Zimmermann --- drivers/gpu/drm/arm/display/komeda/komeda_drv.c | 1 + drivers/gpu/drm/drm_modes.c | 5 +++-- drivers/gpu/drm/panel/panel-ronbo-rb070d30.c | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_drv.c b/drivers/gpu/drm/arm/display/komeda/komeda_drv.c index 3f4e719eebd8..28f76e07dd95 100644 --- a/drivers/gpu/drm/arm/display/komeda/komeda_drv.c +++ b/drivers/gpu/drm/arm/display/komeda/komeda_drv.c @@ -6,6 +6,7 @@ */ #include #include +#include #include #include #include diff --git a/drivers/gpu/drm/drm_modes.c b/drivers/gpu/drm/drm_modes.c index be030f4a5311..40d482a01178 100644 --- a/drivers/gpu/drm/drm_modes.c +++ b/drivers/gpu/drm/drm_modes.c @@ -31,10 +31,11 @@ */ #include +#include +#include /* for KHZ2PICOS() */ #include #include -#include -#include +#include #include