From mboxrd@z Thu Jan 1 00:00:00 1970 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 0BF9FC2BD05 for ; Mon, 24 Jun 2024 09:15:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To: Content-Transfer-Encoding:Content-Type:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=zIgCiOqDZxFI2uuCBgUiRtGa74MvVm/3sP1dkMWF9cM=; b=wweRGhUClYGkF47nm2YduTMxus 10DytT62m13sJxk6zsKjyWt6145hpHlCHSf26CWnFbhOIDi/LUh9K9mIu6lFl9z9vc9HIP0hOyEgV q+4L+U71ARMi3GIPBftH6kx9bV0UgCPg4SyT4/njwJquLijuFA2f+qgqTrGSxOrVAXv8uVDoTt2Ro G5udZu5CaYo18cXyguhpsc6cJJ90JCfKzffq6geNFGVPhLVknNsx3GwN1dIPfgLC5bpWg9uiNrKQ4 o6j9ls5Jh690v6+sLCoKMNrNIAp7SF2jIFyZePWNK1l0S2QIhK4L5aqSiZRlFt77xznTTt0xUf8Lu iz+6lcQw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sLfn0-0000000GDD3-3ZcY; Mon, 24 Jun 2024 09:15:06 +0000 Received: from mail-wr1-x436.google.com ([2a00:1450:4864:20::436]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sLfmv-0000000GDBY-2jgB for linux-arm-kernel@lists.infradead.org; Mon, 24 Jun 2024 09:15:03 +0000 Received: by mail-wr1-x436.google.com with SMTP id ffacd0b85a97d-3649cecd396so289226f8f.1 for ; Mon, 24 Jun 2024 02:15:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; t=1719220499; x=1719825299; darn=lists.infradead.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=zIgCiOqDZxFI2uuCBgUiRtGa74MvVm/3sP1dkMWF9cM=; b=bi2pDiEsfbjIrhtUMX2vLuWNocA/cVrfw88CrfV3KwVc0ziczVQxvseOHRZvunp9o4 L+fl0b8hpMEkfzwPSo1OwlXjrO02d2t1bubk6s1rXRGy3Xxt6KQyY/DyFKvWGEiSEeqU jrG7ly6R7RVQ3ju/H2OQr1srGZS90U3uUpSSs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1719220499; x=1719825299; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=zIgCiOqDZxFI2uuCBgUiRtGa74MvVm/3sP1dkMWF9cM=; b=aKOmphzKyuqSl5uctoFzXMc1RSGwRceax5TE2/RV9oC3dEdmUCs/NT6gcwIe8o6AU7 PiDpOD6DkoajyjQrzKZfOVycMFZr2De8Sm99XSMuMahc1F1Ngbi8/16SHcI0de4repFT BFEZe/eT7NQVKq7eBJvuNx7ba41Jk/zeYEyHZMft5hJR+zKZVghhZdI/s5bblKFj863N GbkcTej7vUxEsnhRhVfJPY2V6h5CXvKE8QtI/p3y/gsa2OV/3FXf7MWGrKEUY7zLLPEA tvsUVm3bWzHFyQnGLERnBy6yzbmIeGzv7Uf0an07SGIVnu5H+d45g5hu928k1iV0pEDb nqiQ== X-Forwarded-Encrypted: i=1; AJvYcCWFvV6pQQNhP2y6uNONXmRweNf3Pl5UkwGyhxQKJi3Sam2jNy+P2s7ncF/d6BTnscNmqaSE+pjMDVd3tOAV/iUy3LP7YQ+z8AMiasxMXANuqSUBeXI= X-Gm-Message-State: AOJu0Yye3MGNw+gTGU2V3G6gtOGODmuco5Wg9aKdjao/uL6pXMaQo8k/ ELeuJwEvW/BJzuUMyKw7ji9PTX5BPdK+EGUtwdYcLdzI1RrPKChmO6DAPs2MQMA= X-Google-Smtp-Source: AGHT+IFp+gzewBfv8ZGNLpZ6eWuC39255ypBFHO9aEPFtXIzE2KwI67dNJaxBx7/okIjDFlh9K0O5A== X-Received: by 2002:a05:6000:186e:b0:360:89ff:350f with SMTP id ffacd0b85a97d-366dfa3bb87mr4226535f8f.5.1719220499230; Mon, 24 Jun 2024 02:14:59 -0700 (PDT) Received: from phenom.ffwll.local ([2a02:168:57f4:0:efd0:b9e5:5ae6:c2fa]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-3663a2f694asm9470240f8f.77.2024.06.24.02.14.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 24 Jun 2024 02:14:58 -0700 (PDT) Date: Mon, 24 Jun 2024 11:14:56 +0200 From: Daniel Vetter To: Jani Nikula Cc: dri-devel@lists.freedesktop.org, Sandy Huang , Heiko =?iso-8859-1?Q?St=FCbner?= , Andy Yan , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org Subject: Re: [PATCH 01/11] drm/rockchip: cdn-dp: get rid of drm_edid_raw() Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Operating-System: Linux phenom 6.8.9-amd64 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240624_021501_883904_1816192E X-CRM114-Status: GOOD ( 22.95 ) 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 On Tue, May 14, 2024 at 03:55:07PM +0300, Jani Nikula wrote: > The dimensions are available in display info, so there's no need for raw > EDID access. While at it, move the debug logging to where the EDID is > actually read. > > Signed-off-by: Jani Nikula > > --- > > Cc: Sandy Huang > Cc: "Heiko Stübner" > Cc: Andy Yan > Cc: Maarten Lankhorst > Cc: Maxime Ripard > Cc: Thomas Zimmermann > Cc: linux-arm-kernel@lists.infradead.org > Cc: linux-rockchip@lists.infradead.org Reviewed-by: Daniel Vetter > --- > drivers/gpu/drm/rockchip/cdn-dp-core.c | 16 ++++++---------- > 1 file changed, 6 insertions(+), 10 deletions(-) > > diff --git a/drivers/gpu/drm/rockchip/cdn-dp-core.c b/drivers/gpu/drm/rockchip/cdn-dp-core.c > index bd7aa891b839..90913fa26aad 100644 > --- a/drivers/gpu/drm/rockchip/cdn-dp-core.c > +++ b/drivers/gpu/drm/rockchip/cdn-dp-core.c > @@ -266,15 +266,6 @@ static int cdn_dp_connector_get_modes(struct drm_connector *connector) > > mutex_lock(&dp->lock); > > - if (dp->drm_edid) { > - /* FIXME: get rid of drm_edid_raw() */ > - const struct edid *edid = drm_edid_raw(dp->drm_edid); > - > - DRM_DEV_DEBUG_KMS(dp->dev, "got edid: width[%d] x height[%d]\n", > - edid->width_cm, edid->height_cm); > - > - } > - > ret = drm_edid_connector_add_modes(connector); > > mutex_unlock(&dp->lock); > @@ -369,6 +360,7 @@ static int cdn_dp_firmware_init(struct cdn_dp_device *dp) > > static int cdn_dp_get_sink_capability(struct cdn_dp_device *dp) > { > + const struct drm_display_info *info = &dp->connector.display_info; > int ret; > > if (!cdn_dp_check_sink_connection(dp)) > @@ -386,7 +378,11 @@ static int cdn_dp_get_sink_capability(struct cdn_dp_device *dp) > cdn_dp_get_edid_block, dp); > drm_edid_connector_update(&dp->connector, dp->drm_edid); > > - dp->sink_has_audio = dp->connector.display_info.has_audio; > + dp->sink_has_audio = info->has_audio; > + > + if (dp->drm_edid) > + DRM_DEV_DEBUG_KMS(dp->dev, "got edid: width[%d] x height[%d]\n", > + info->width_mm / 10, info->height_mm / 10); > > return 0; > } > -- > 2.39.2 > -- Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch