Received: by 2002:a05:7412:cfc7:b0:fc:a2b0:25d7 with SMTP id by7csp1939046rdb; Tue, 20 Feb 2024 11:27:45 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWGC8IxtJn6aJ3nYmyUKhK5XCIvdZkPoF42T/QnDC4rtpyEDCfZ16LJrLbYYdfIK6bKsngNAaaaZe1FdsPkxmg3A8igyeq1qngcdhArDw== X-Google-Smtp-Source: AGHT+IEg4NRDJo1XsRaakwHvYufNs66WvlqxyyRNea12Lp/DvzEG98DP2EsOwv6xWDMjkCpIEveu X-Received: by 2002:a17:906:faca:b0:a3e:710f:32f6 with SMTP id lu10-20020a170906faca00b00a3e710f32f6mr5722735ejb.18.1708457264989; Tue, 20 Feb 2024 11:27:44 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708457264; cv=pass; d=google.com; s=arc-20160816; b=1BpqlshtNaYXliXxGsoLvTip7W94g3cxiA5x7VOZxgrsa105GH7D4uIlY7Mf0o9TAd 1O3bLOYbV5aCs8LMFCy+CBb6gD/IsoW8vSmg2V8R35M1ZIXMICcoFSP3QyzB0LLqlnAO EClIxYHu782RWcJTe+HhS6a3v9GpBLAlJPqv5CGkK/q1okqCVGWS2MUStnUlpiJw/8mD QXPX6VuBbpDT03LvunSklJl1keZfBHr2UeQPQVMj2/1K3Zv6ZcbbkdSG0WzHhQWyBCR3 ZBkspsAaKcGqec4v3ZAnGTyQJVc0Ld21g0XMj6KhAklju51gnhhnoGPgK+sz2VkPBZpG OEhw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=Q/plVcvO1WfGsPITbLbiTiRdy4hEFuw8/6lXwDmsHPM=; fh=jOIWVLFbloxH67K7kXAsh27M26xe/eHudjR77ljIOoY=; b=U/V9ynalpFbA+OJf3y+7U1sS/WLYO4THdYVz9x6Sl4SSjL8RacTV6omvGTeUyh73qN goh+twmYuRVVnLykMGLSsVKRtMOR+wkQVwWx4aSI+M4k0cf8mN+8MuiQ1etAYiC5cXle ioa7Ww8oXlR+fGuuHVwhpEZVosj4nA3qIFjeWmZiZpVGM1Q8ldzwfCzzQVcF48kq99Bd SnhxcbiHyALJ5Ds+8q2ndb1Jv32t6OuIUctgzEyS9pZqvOQWsMgNIqhF4n7ASeU/Mhaq HxlhSsCwoLNpivB2FQvK52KW624b8KCP4hNPzuBHuV2t7gjOQNLlvfr0y8pd6+ccvlck oY9Q==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=nuplWMYP; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-kernel+bounces-73593-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-73593-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id i10-20020a170906264a00b00a3e832377c7si2324956ejc.1033.2024.02.20.11.27.44 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Feb 2024 11:27:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-73593-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=nuplWMYP; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-kernel+bounces-73593-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-73593-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 920261F255D2 for ; Tue, 20 Feb 2024 19:27:44 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id DA02B137C2B; Tue, 20 Feb 2024 19:27:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="nuplWMYP" Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7228D12F5BF for ; Tue, 20 Feb 2024 19:27:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708457255; cv=none; b=iWVBVr88cv9phXpqm+QrmAIaWWfDyG5MRyjQ+34LbiSr2XI7MI9LpLa34kGDwYYH9E3BsxXXqKzQBxLLKz8JDJAMo7ps8AlVKdlGSn1e5dytt4IAfoaOgitx2riR5vUS2ztBHVj0KK1lzXm0lAUAJ8qiD+EYwp2nDXL/Z9o6ikM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708457255; c=relaxed/simple; bh=hC88BZuqIjicZPqhBXQ/rRwSX8BaH17kZbuBFpNv1uE=; h=Message-ID:Date:MIME-Version:Subject:To:CC:References:From: In-Reply-To:Content-Type; b=puLQ0HXXO11ig0biZdU1zi0LIrRy7BbWe860yekgPeO1WC7JurfLyjovE6xQBRgPFgmVxSPikfFpXimx9L7VPEforFz68a9HXddM8D4h1/lG5zsorwuiHg7tCAciPqYhphUdEwk/1NZPusRQ241wJL1v+10ij7t1KvTABSAXkdk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=nuplWMYP; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Received: from pps.filterd (m0279869.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 41KJFiSS021818; Tue, 20 Feb 2024 19:27:21 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= message-id:date:mime-version:subject:to:cc:references:from :in-reply-to:content-type:content-transfer-encoding; s= qcppdkim1; bh=Q/plVcvO1WfGsPITbLbiTiRdy4hEFuw8/6lXwDmsHPM=; b=nu plWMYPEUkmuINkMR38btt45QYliCGPf55CFvrW3Uz83CkZcv/ITO2biVEbPeqP6P 13VJfCH2wbws0zb/6Fxt5KUV7dZCpl3VO3zAiRi4XtVdKpSaoyw7eHxM0/aQjufU fkJWURSI57zkUX4jGFri+l2a9OI6mz8SJXAbfb7Ux6+E1xZOyTo9QUfgkUBSXmug pDE8d7EsYSxKFf57o4GN9vZJ1SOXuHLY2+R0ricV4Xwvc+oHGjAhF46h1nC4wNRv UXk1auZg0QWawVpyRpk64pDfT4d7EgsvIqW/sV0KfXTutZeqVxX+4Z/BQOjs1lBf Z0tWeEGgg35BhvLZOxCA== Received: from nalasppmta03.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3wd230r0th-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 20 Feb 2024 19:27:20 +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 41KJRJue006072 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 20 Feb 2024 19:27:19 GMT Received: from [10.110.62.85] (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, 20 Feb 2024 11:27:18 -0800 Message-ID: Date: Tue, 20 Feb 2024 11:27:18 -0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: [PATCH v2] drm/dp: move intel_dp_vsc_sdp_pack() to generic helper Content-Language: en-US To: Dmitry Baryshkov CC: , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Jani Nikula , Rodrigo Vivi , Joonas Lahtinen , Tvrtko Ursulin , , , , , , , References: <20240215190834.3222812-1-quic_abhinavk@quicinc.com> From: Abhinav Kumar In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit 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-ORIG-GUID: YVP7otHqJ9hM93Bim4XH1u-F1NYtMoJb X-Proofpoint-GUID: YVP7otHqJ9hM93Bim4XH1u-F1NYtMoJb X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-02-20_06,2024-02-20_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 phishscore=0 spamscore=0 mlxscore=0 impostorscore=0 suspectscore=0 mlxlogscore=525 priorityscore=1501 clxscore=1015 lowpriorityscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2402120000 definitions=main-2402200139 On 2/20/2024 11:20 AM, Dmitry Baryshkov wrote: > On Tue, 20 Feb 2024 at 21:05, Dmitry Baryshkov > wrote: >> >> On Tue, 20 Feb 2024 at 20:53, Abhinav Kumar wrote: >>> >>> >>> >>> On 2/20/2024 10:49 AM, Dmitry Baryshkov wrote: >>>> On Thu, 15 Feb 2024 at 21:08, Abhinav Kumar wrote: >>>>> >>>>> intel_dp_vsc_sdp_pack() can be re-used by other DRM drivers as well. >>>>> Lets move this to drm_dp_helper to achieve this. >>>>> >>>>> changes in v2: >>>>> - rebased on top of drm-tip >>>>> >>>>> Acked-by: Dmitry Baryshkov >>>> >>>> v1 had an explicit comment before the ack: >>>> >>> >>> Yes, I remember the comment. I did not make any changes to v2 other than >>> just rebasing it on drm-tip to get the ack from i915 folks. >>> >>>>> From my side, with the promise of the size fixup. >>>> >>>> However I observe neither a second patch removing the size argument >>>> nor it being dropped as a part of this patch. >>>> >>> >>> Yes, now that in v2 we got the ack for this patch, I can spin a v3 with >>> the addition of the next patch to remove the size OR as another series >>> so as to not block the main series which needs this patch. >>> >>> I would prefer the latter. >> >> It doesn't work this way. The comment should have been fixed for v2. > > This probably deserves some explanation. Currently there is only one > user of this function. So it is easy to fix it. Once there are several > users, you have to fix all of them at the same time, patching > different drm subtrees. That complicates the life of maintainers. > Yes, understood. Its easier to fix it now if its really needed. Actually, I think the reason the size was passed was to make sure a valid struct dp_sdp *sdp was being passed. If we drop the size, we need to have a if (!sdp) check as there is a memset followed by dereference. So maybe, if we want to keep this API protected, its not too bad to have?