Received: by 2002:a05:6a10:2785:0:0:0:0 with SMTP id ia5csp1988404pxb; Sun, 10 Jan 2021 19:33:53 -0800 (PST) X-Google-Smtp-Source: ABdhPJzN1LuoCjO/DPiyEs6DK2o4JfYt/yJoHKbG/iBQLmVN/s0rWGblONfW6b2OdoGjoWFbBbcB X-Received: by 2002:a17:907:d8e:: with SMTP id go14mr9597946ejc.472.1610336033491; Sun, 10 Jan 2021 19:33:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1610336033; cv=none; d=google.com; s=arc-20160816; b=iq+ND+Beu2N4yxvv3FojTulD4ISpDpk4LFfcXLt7BjDpGTZ5BowbvaEog6z7oSGgHu 54BaqkgrTIj9sFCwB3jIWF8nGUJLhL6yKCs8TP7mJx5AudLIXrEpPX7w7aHmlIC980CA zpblLcyU29MZDi0Phg/DT6tXawpIBnVp9fFWdIZYj+Alaho634gUlnjl2+0RJsZgax9O mO6OGOaAwZWOUDX7YEHLnIrr/HTnTLmFjmP+4AiF5GKz7nEVdO8sevTLKOFbNyrEfXbO 8nuO5Q+IN/gpLA2Tb4aM7nPZI/9QtQI1hQp17XjDVflGlIruHcgAJLDyvQdwtZFVf+s/ JhVQ== 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:subject:to:from; bh=NrjVopZV3fGNvdBEKcqrUsZdA1P2cDT0T7rn1Z64YBg=; b=1LOUH52b3ExqsoNSy6FcsIt46ElIy7h6Qmh4qezT/5KMofm9qIUALqVqUQq/cLHaN+ dal7+9kpEKYAf+vKKRKojodsV7520UspJz6YDXrTw0RVuKzyGopFV049G8S6zci00mJB 7Y+DiHxvPB/MD9FB/bovPNqRgZGkccM6l3T9Zl1L0oprlEmCUIwKL9rSbYJ6SqFTpIg0 yM/g+bNyKbP9F509cjjRn2f0f/xv4Nq/EaXQJ2UXSkKtBbHSZVq1mbHwRELEVZ5TEQxE UHF5rkXP+CeTKS4X+yS9Mi6ZVBk4gDFy5Et2IP6qwqhL/hPiEtDx3phWATNkz85bS+/a t7Kg== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t21si6294943edq.546.2021.01.10.19.33.30; Sun, 10 Jan 2021 19:33:53 -0800 (PST) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727010AbhAKDbL (ORCPT + 99 others); Sun, 10 Jan 2021 22:31:11 -0500 Received: from szxga04-in.huawei.com ([45.249.212.190]:10703 "EHLO szxga04-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725797AbhAKDbK (ORCPT ); Sun, 10 Jan 2021 22:31:10 -0500 Received: from DGGEMS402-HUB.china.huawei.com (unknown [172.30.72.58]) by szxga04-in.huawei.com (SkyGuard) with ESMTP id 4DDfMF1Nl4zl3Vd; Mon, 11 Jan 2021 11:29:13 +0800 (CST) Received: from localhost.localdomain (10.69.192.56) by DGGEMS402-HUB.china.huawei.com (10.3.19.202) with Microsoft SMTP Server id 14.3.498.0; Mon, 11 Jan 2021 11:30:25 +0800 From: Tian Tao To: , , , , , , , , Subject: [PATCH] drm/hisilicon: Use drm_crtc_mask() Date: Mon, 11 Jan 2021 11:30:18 +0800 Message-ID: <1610335818-32895-1-git-send-email-tiantao6@hisilicon.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.69.192.56] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Use drm_crtc_mask() where appropriate. Signed-off-by: Tian Tao --- drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c index c76f996..1c5f2fa 100644 --- a/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c +++ b/drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_vdac.c @@ -96,6 +96,7 @@ int hibmc_vdac_init(struct hibmc_drm_private *priv) struct drm_device *dev = &priv->dev; struct hibmc_connector *hibmc_connector = &priv->connector; struct drm_encoder *encoder = &priv->encoder; + struct drm_crtc *crtc = &priv->crtc; struct drm_connector *connector = &hibmc_connector->base; int ret; @@ -105,7 +106,7 @@ int hibmc_vdac_init(struct hibmc_drm_private *priv) return ret; } - encoder->possible_crtcs = 0x1; + encoder->possible_crtcs = drm_crtc_mask(crtc); ret = drm_simple_encoder_init(dev, encoder, DRM_MODE_ENCODER_DAC); if (ret) { drm_err(dev, "failed to init encoder: %d\n", ret); -- 2.7.4