Message ID | 20231208050641.32582-2-quic_abhinavk@quicinc.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:bcd1:0:b0:403:3b70:6f57 with SMTP id r17csp5249089vqy; Thu, 7 Dec 2023 21:07:18 -0800 (PST) X-Google-Smtp-Source: AGHT+IFgSojpKUcBHPFar5p2MVLkcbuaKRcwrLwc51+kz/MA7zp5VpNhMv7lIyfP0AksgJtu0vCt X-Received: by 2002:a05:6870:5ba3:b0:1fa:16f4:7f3f with SMTP id em35-20020a0568705ba300b001fa16f47f3fmr4206372oab.43.1702012038188; Thu, 07 Dec 2023 21:07:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702012038; cv=none; d=google.com; s=arc-20160816; b=YnPT/MSfco42/ZfnTb6AuKWEu/7z9aCivXDpbrkYDWCQteHF4Uakh+AGC2Ge84KEBl bAoHHPIrf/4YXjQa4YUIUwRQIEoMVMSSbkQ9wenS9zeMmFpO0pzstw58k7J/gU5AjsUm iU8nH7QSkZxnuyir9qus5tT21YKJBftjHt5FqwWZVQ/HO4FB7jj1uvnO0ZcL4eCFWRL+ Rx712Y3dNeNV6dSfFN6OEDWuesKBKxV8dwS6kGQMLxOPfgEjbWDCXPTbVfnGHPxhOqZ7 HVIaQlDUfv67o9vIzWSrSbwafJvRyWbvZ2+rdGOk2EUdfxVelkeAbEkamKsr5zXJ27GH R7FA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=WlKCC3O3gzfemEY03xFX4nrmIBBKRuJwsSR/+mvebUA=; fh=bCPr6FtHW7vqpnFZy/5ChZdmzRzyfr1lCT+1Yh+hWj4=; b=EbJMKJ4vH+Sqbx8VANMIEINOnzc0HoTed9rLavkfFGtsYix9dfXRpXHe6bi4WAWV1f dPRkbmCXqmdjdnsNTKQoc3iJAFWPORKxars572xF6jz5rroyp3RxWBji01rc04ykqxHK OiDBcJLXwWnoxhH3/M15nCJ09D57jS7MnUPoFKgutVQq3ScZMD6ig3RuFMxh3xBISXcH WQZb8ACm8SDIOv+CgA2EJL/YjHVFcXS5BrTEq7aTBpsCB3/2a6nyxUILll2Aq6TdfCf5 tR0jjhXSTsgt8cIenFYZ4AVs6wqcKjzq0ppyI58SRqDjislPZO55SuVVgBeL3bKDsrHl odww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=EaZVM3cQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id k12-20020a6568cc000000b0056f7f18bbfdsi876679pgt.632.2023.12.07.21.07.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Dec 2023 21:07:18 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=EaZVM3cQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 9C922816F0F7; Thu, 7 Dec 2023 21:07:15 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230451AbjLHFHE (ORCPT <rfc822;chrisfriedt@gmail.com> + 99 others); Fri, 8 Dec 2023 00:07:04 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45868 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229476AbjLHFHC (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Fri, 8 Dec 2023 00:07:02 -0500 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DF71C10F1; Thu, 7 Dec 2023 21:07:08 -0800 (PST) Received: from pps.filterd (m0279862.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 3B84rY3w030356; Fri, 8 Dec 2023 05:07:00 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : content-type; s=qcppdkim1; bh=WlKCC3O3gzfemEY03xFX4nrmIBBKRuJwsSR/+mvebUA=; b=EaZVM3cQpJTUMx+jA4Ow7ngr5TX75EnN1VjHEHLYXu0H0gxt68KLAJp2+KtdDt4f6NnK KYt9Ww95FTpOWHNtIK3VeuaciO6kSPA2zZ89Sm52CvcFcV9Xxpe3+6wmX2PDMeZfad6Y tTPBCX3BhKSR9DwKrcDaVbLBh+p6EXBxWf5ky0ZF1H1BDTJxqiHb+lAhcHAd7N333waM +BBDfQGRmsRpWGWU4kE+3MgQ1ozK6bj4YnZw6mdUmK5GtowA9CqkM7sdElMloLd1BMYM EBeAl1F4NtGwTsZFk4m/ZGJEBPKwvZ6sfqE7KP1fBsK859/bf9rAIRIEMhUKU1Ho2JGL mw== Received: from nalasppmta01.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3uubd82k2p-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 08 Dec 2023 05:07:00 +0000 Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA01.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 3B856xkk006516 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 8 Dec 2023 05:06:59 GMT Received: from abhinavk-linux.qualcomm.com (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Thu, 7 Dec 2023 21:06:59 -0800 From: Abhinav Kumar <quic_abhinavk@quicinc.com> To: <freedreno@lists.freedesktop.org>, Rob Clark <robdclark@gmail.com>, Abhinav Kumar <quic_abhinavk@quicinc.com>, Dmitry Baryshkov <dmitry.baryshkov@linaro.org>, Sean Paul <sean@poorly.run>, Marijn Suijten <marijn.suijten@somainline.org>, David Airlie <airlied@gmail.com>, "Daniel Vetter" <daniel@ffwll.ch> CC: <dri-devel@lists.freedesktop.org>, <quic_jesszhan@quicinc.com>, <quic_parellan@quicinc.com>, <linux-arm-msm@vger.kernel.org>, <linux-kernel@vger.kernel.org> Subject: [PATCH v2 01/16] drm/msm/dpu: add formats check for writeback encoder Date: Thu, 7 Dec 2023 21:06:26 -0800 Message-ID: <20231208050641.32582-2-quic_abhinavk@quicinc.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20231208050641.32582-1-quic_abhinavk@quicinc.com> References: <20231208050641.32582-1-quic_abhinavk@quicinc.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.80.80.8] X-ClientProxiedBy: nasanex01a.na.qualcomm.com (10.52.223.231) To nalasex01a.na.qualcomm.com (10.47.209.196) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: CPnwYZW7izGZUNZmoHC3Cd4Uh8FjwDx9 X-Proofpoint-ORIG-GUID: CPnwYZW7izGZUNZmoHC3Cd4Uh8FjwDx9 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.997,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-12-08_01,2023-12-07_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 clxscore=1015 suspectscore=0 mlxlogscore=827 impostorscore=0 phishscore=0 lowpriorityscore=0 adultscore=0 malwarescore=0 mlxscore=0 spamscore=0 priorityscore=1501 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311290000 definitions=main-2312080038 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 07 Dec 2023 21:07:15 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1784688975392688621 X-GMAIL-MSGID: 1784688975392688621 |
Series |
[v2,01/16] drm/msm/dpu: add formats check for writeback encoder
|
|
Commit Message
Abhinav Kumar
Dec. 8, 2023, 5:06 a.m. UTC
In preparation for adding more formats to dpu writeback add format validation to it to fail any unsupported formats. changes in v2: - correct some grammar in the commit text Fixes: d7d0e73f7de3 ("drm/msm/dpu: introduce the dpu_encoder_phys_* for writeback") Signed-off-by: Abhinav Kumar <quic_abhinavk@quicinc.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c | 7 +++++++ 1 file changed, 7 insertions(+)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c index bb94909caa25..91b1967cf566 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c @@ -272,6 +272,7 @@ static int dpu_encoder_phys_wb_atomic_check( { struct drm_framebuffer *fb; const struct drm_display_mode *mode = &crtc_state->mode; + int ret; DPU_DEBUG("[atomic_check:%d, \"%s\",%d,%d]\n", phys_enc->hw_wb->idx, mode->name, mode->hdisplay, mode->vdisplay); @@ -308,6 +309,12 @@ static int dpu_encoder_phys_wb_atomic_check( return -EINVAL; } + ret = drm_atomic_helper_check_wb_encoder_state(phys_enc->parent, conn_state); + if (ret < 0) { + DPU_ERROR("invalid pixel format %p4cc\n", &fb->format->format); + return ret; + } + return 0; }