From patchwork Tue Dec 12 20:52:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Abhinav Kumar X-Patchwork-Id: 177585 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:bcd1:0:b0:403:3b70:6f57 with SMTP id r17csp7995767vqy; Tue, 12 Dec 2023 12:53:38 -0800 (PST) X-Google-Smtp-Source: AGHT+IHRW+dt6jkfFEG3JBcvv7KVgEKF5OB+5OhQcibHamg62aAjx3wr+cGvjgDvAL/MjT6piCeh X-Received: by 2002:a05:6a20:7fa0:b0:18c:92f0:69c2 with SMTP id d32-20020a056a207fa000b0018c92f069c2mr4456961pzj.39.1702414417733; Tue, 12 Dec 2023 12:53:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702414417; cv=none; d=google.com; s=arc-20160816; b=fDPUCiSkDLdiyp6pKQvprxPxRtisf0dj7PCSz20d58q7l/gGdZNKF4MgIUqhIMR12L ukbXg+eDL4BTDAgjW0sUUWztsCTBI4Srbu//X8Fs6Och0MDVM52syhCfwJKyjajmoxeS enj8Ryh7sJ0RIUWamsNdTfias/K0EZhajCfLJCRi76sxJuwEeDzh4ImeHis8wRbcmTMM UyFxhlpluCQ3bWYEcfz8unDZm0H816F+lqeb1DXoSrjLJ7tnVmhOCB2jqs/XXqxDz31e kw/RNa3wDxbuaW92cgI5T+BOONlyW1VomebWn5G29GNTyhpLd6sPphUDnPpZEszPdDX2 Ir2w== 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=Y09RjMTJ4PUl9MTfFsv6b7XP1Z2Eb2/kXLl+i0I7K8U=; fh=2XyQDqDG0wz2VEIrVbLmdsbSBBAARfl7BOJG4nJ/HZo=; b=V/1bWGfnyU5b9Wqy5AOp0+mYEy5KuWsDVA9jrRZM1QZDyCkE4Grc8iY3e31e4isHdZ HyoaQAcLemEKbk/eFq4g7P+lLzRyZpVsn/XwGKvwEHzwUsIcmMGdMlbmi6y/ZFMrBnmB fB95tnQ+ZK8g+t+7i2iVjKaBiZZmXnfwHRWQwJePkS7yXZdgGChPc6jmq/MmorcXWNAP nnhBHd+FDH0llTWHZpY8cIs92AoWWAW8k+hjmilE83jDDy0+9/qwKu/Yixk+psaEuS6E yTdm+GArnrXB9yXfOFiTWFV1CwtHGGwJ8N0DKzCr0ztdys3cDvWGyto82tDx3GdNqUpu tvdg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=BJcz6bIR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 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 snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id t5-20020a6564c5000000b005c65defc409si8044999pgv.748.2023.12.12.12.53.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Dec 2023 12:53:37 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=BJcz6bIR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 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 snail.vger.email (Postfix) with ESMTP id 7134B8045BF4; Tue, 12 Dec 2023 12:53:36 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377371AbjLLUxY (ORCPT + 99 others); Tue, 12 Dec 2023 15:53:24 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37642 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377293AbjLLUxM (ORCPT ); Tue, 12 Dec 2023 15:53:12 -0500 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C4A4912A; Tue, 12 Dec 2023 12:53:18 -0800 (PST) Received: from pps.filterd (m0279862.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 3BCHjp9q013712; Tue, 12 Dec 2023 20:53:11 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=Y09RjMTJ4PUl9MTfFsv6b7XP1Z2Eb2/kXLl+i0I7K8U=; b=BJ cz6bIRmosPFdEIwt/Y2OMFrvL1wzMgo1jQjLcSNUMgdjAMXHwQd2glNcJbaPhVuX VI6CbklP+HREAZYJ9cz8Sn+gLOFSX2S4JWhefq/c34J5sgnL1ETVMotR9Exn+Uba 78DeW6XOsDtWiImRuAEb0BFzl68K6kW8z9BRhWPZFGOoh9p1CYLA9uQRfCJub100 5/pQ1gUY/x8Zqvn/Ze0iX00lgtFUMq4IXcFbW+k0pVgaw1QxhmjVNckTyFARwinO zCy+FYxRZOK1QAApVF9LkgMill5gM0Nx/vlvGPHpS1075EFDlHZd5y0IFdCTIz0S Fk7mxUaOHgdNuuEEMWeQ== Received: from nalasppmta03.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3uxru2h0k6-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 12 Dec 2023 20:53:10 +0000 (GMT) Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA03.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 3BCKrASH011053 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 12 Dec 2023 20:53:10 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; Tue, 12 Dec 2023 12:53:09 -0800 From: Abhinav Kumar To: , Rob Clark , Abhinav Kumar , Dmitry Baryshkov , Sean Paul , Marijn Suijten , David Airlie , "Daniel Vetter" CC: , , , , Subject: [PATCH v4 03/15] drm/msm/dpu: fix writeback programming for YUV cases Date: Tue, 12 Dec 2023 12:52:41 -0800 Message-ID: <20231212205254.12422-4-quic_abhinavk@quicinc.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20231212205254.12422-1-quic_abhinavk@quicinc.com> References: <20231212205254.12422-1-quic_abhinavk@quicinc.com> MIME-Version: 1.0 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: F-SLsqhzZ5tscQzRK_hNWQ9vcXUrVvDm X-Proofpoint-ORIG-GUID: F-SLsqhzZ5tscQzRK_hNWQ9vcXUrVvDm 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-09_01,2023-12-07_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 mlxscore=0 clxscore=1015 priorityscore=1501 suspectscore=0 spamscore=0 lowpriorityscore=0 bulkscore=0 mlxlogscore=999 adultscore=0 phishscore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2311290000 definitions=main-2312120161 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Tue, 12 Dec 2023 12:53:36 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1785110900250549329 X-GMAIL-MSGID: 1785110900250549329 For YUV cases, setting the required format bits was missed out in the register programming. Lets fix it now in preparation of adding YUV formats support for writeback. changes in v2: - dropped the fixes tag as its not a fix but adding new functionality Signed-off-by: Abhinav Kumar Reviewed-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c index ed0e80616129..e75995f7fcea 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c @@ -89,6 +89,9 @@ static void dpu_hw_wb_setup_format(struct dpu_hw_wb *ctx, dst_format |= BIT(14); /* DST_ALPHA_X */ } + if (DPU_FORMAT_IS_YUV(fmt)) + dst_format |= BIT(15); + pattern = (fmt->element[3] << 24) | (fmt->element[2] << 16) | (fmt->element[1] << 8) |