From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 F3C143E639E for ; Mon, 1 Jun 2026 18:22:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780338158; cv=none; b=A55JhSIjvkVHUGsUSRGoKaHOfGzW1XVuXsAKrjRhyxSqUwPh0dgmLKjzRHW0LU6lh7YWurjeASbl2zXs97XPEf9d5H0WGCcE+/q5Ga1jLAmmng6Eh/FpNbV0IBU/JAP8aXyFgaIoWBG3lO17ImfXJOGumDb2zTMMHIJgUkM5goU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780338158; c=relaxed/simple; bh=Q0VBfssifErgdqVQOL9DdzlVcV8Q1BsKWkErX6gR83s=; h=Message-ID:Date:MIME-Version:Subject:To:References:From: In-Reply-To:Content-Type; b=EszYlTrPE39qvSWbo5spYTNyO43IuTi+hkZhuvj6c13dK9CiDyEq4ZbhAMajMNpvB+bTWN96KhQmutNxUXSXH1/Q2pKUJGr1Z8imv4uaWe6LVcfwNaOyV5mdsnWPcQx2WuYPqlcUPQUTKjoF2KgG4urSOBrGUahBCedjgtvYgmM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=QVjdv6Da; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=IrxghAaI; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="QVjdv6Da"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="IrxghAaI" Received: from pps.filterd (m0279864.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 651FVIdU144977 for ; Mon, 1 Jun 2026 18:22:36 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= G7prPtOABqDadqiRplnkx+h7C6pmAJpXpIH0GVEtePw=; b=QVjdv6DaIaOykkrh EBFFhhhy39i1Wobp77SJnPRz4Ii62Ny0n4/RgeysjYfI6xWsO2PQSKyixtj3uETh M+WuruyY26mb/yq3E5N3kVTz8CcuIUc8U8hZkgfct0nGDd7/R47KWTVOKIdbx3pQ zv3KKaFDvIi52g6ysZ87NVzPJtvq4VVxy6V93ZXcsPFGFgHhFN1yRHfYT4wP8VGT tj0RnOjClI5rnDyWv/fyb5PhSk1VoD3tmNMtLFMFg9AE+0m9HacTGOZil3vN5nHt cLgTHGbcF1eapXwkhGXWMKAiHW1gnUhqdVWr2dUisKG+F/Issqu583l93JPEtFxI yKl0NQ== Received: from mail-dy1-f198.google.com (mail-dy1-f198.google.com [74.125.82.198]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4eh6sttdtn-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Mon, 01 Jun 2026 18:22:36 +0000 (GMT) Received: by mail-dy1-f198.google.com with SMTP id 5a478bee46e88-304d8613efbso5008415eec.1 for ; Mon, 01 Jun 2026 11:22:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1780338155; x=1780942955; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:user-agent:mime-version:date:message-id:from :to:cc:subject:date:message-id:reply-to; bh=G7prPtOABqDadqiRplnkx+h7C6pmAJpXpIH0GVEtePw=; b=IrxghAaIkRqsYQ8aeqAW80Q+QCCIWWPfiRw41vuj3aJqSPMe7wXU0ysELuh/lYLQQk O8yL1c53GUvDrxXFqL2xLq7QrKaD9zba2MT1qX7wX73ZZP356oP6JWY+1Tf/Z7h+20Sa l6sn6svsGVWhOYmIVhBrSeh6NBBxEph1GgSbBx0z2n6i/CLHw3sBabXgN32OWosRFVs0 FAp3YLkud2KzsAlDCROG4TMdZMNbQsVWwezq0RuEl5QJME9DxeNKj0LAvDhgCFqZHJWT +LPt0vjRtjzfgOtmobU2EFn/4NgMQe1jcBwNOutdCQshADsuEY9Dq2bpwigHYNlgclKg pK3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1780338155; x=1780942955; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=G7prPtOABqDadqiRplnkx+h7C6pmAJpXpIH0GVEtePw=; b=RlJwUflkww9QWG+O3WhFGAkRGURivNNXRgBaOQ4hcZzeV4uj8iXhTpRM78bCnwwLxT JgCCcI61tzH9m1MOj8rBhrPZw4+pTntzyF0WrPfc7iz7SW+cCLb0ryRFEX68d2OFdn8c AgYS5q9ZwV4HuFoUBYsph2BZ3PNlgLTvJJjTi4h0WsE816vqKj/ZFMsa/GnRoSAZUe/C SdZhwcu+ONkoYt0I7zZ/v76/xIU3gkmd6lmfeF30kofu741iqQRWnuS/aCvynKNDo7mi xmc0Bnpqa7sUKXgi9m9rbLPi4vC3elZ1PEWqjdm4LjNqqpZCogzsgn5KWWnCJIudxNb8 RGzQ== X-Forwarded-Encrypted: i=1; AFNElJ+LtKCYvzn1CyQfaKvidNQ18kXKeyndLWe/8CQHvCPLKvYkelGu+KE+D4xGYabddrhxBQL/vbclV0asIEc=@vger.kernel.org X-Gm-Message-State: AOJu0YyT+xNDd4ELCInaiiL0sTTFWm5TAXB0MtmEznGJhfW6+15oawSt yJKpG9tJU9AR78cotioCf3/l/IlORl6BcgjBx8TH0tNe6EFHPXfdnaujU6Zx76NMML+iYqeAycO wzWYzBHjXefzaRqOxCvC/IddrTqmspKdVae+BhKZOTVx1A/iO0GV7Rvw12QRMRRUIWE0= X-Gm-Gg: Acq92OFhdfyl0kseLQyj2ThyvGVOXq+3CgZs3K9X5AEzssiFnLXO4HscTtXr5ph935+ gtwCv0vdsqGIjMHde7kHoThcyrbdCPNkRurzFi80zDfiJ6Nybccn6q4D1l9Bl8lmVoeHnRDPxc8 1NUHiWUonx2Np9zV7+kj2S8nnIhUKYyTlp568kEBCkR2ya7IEG65XbRAmpHw0odNzypxCo22dIB oFeKImiRol+jHcNx27aHJr/62ST7wWDU8iQgTd7OkiXs/dU3OVhEOwTkLQr1SzJb1ajPTDEAE5G 9KYUgrHeCYdchi2SOghu/FbJhjfTt1LH/fPHOJohyExRIDJV14qCoES27RQOml1DkFLgN5EzNgE W5t8DsK1zkP0V9ireK5bp7ZbzaXjACENr4105Zejz4VyMK2bZvNTUcfXOUow35Z9gA+RAdrqCbs Kl03yGU9yj1lk= X-Received: by 2002:a05:7300:f18f:b0:2f5:285c:4374 with SMTP id 5a478bee46e88-304fa75bd1dmr5800032eec.35.1780338155251; Mon, 01 Jun 2026 11:22:35 -0700 (PDT) X-Received: by 2002:a05:7300:f18f:b0:2f5:285c:4374 with SMTP id 5a478bee46e88-304fa75bd1dmr5799996eec.35.1780338154665; Mon, 01 Jun 2026 11:22:34 -0700 (PDT) Received: from [10.62.37.26] (i-global254.qualcomm.com. [199.106.103.254]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-304ed5d5385sm9402462eec.28.2026.06.01.11.22.33 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 01 Jun 2026 11:22:34 -0700 (PDT) Message-ID: <215786e4-e85c-4af0-9993-5c6331c87817@oss.qualcomm.com> Date: Mon, 1 Jun 2026 11:22:33 -0700 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] media: qcom: camss: csid: Consolidate CSI2_RX_CFG0_PHY_SEL_BASE_IDX definition To: hangxiang.ma@oss.qualcomm.com, Loic Poulain , Robert Foss , Todor Tomov , Bryan O'Donoghue , Vladimir Zapolskiy , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org References: <20260601-camss-macro-v1-1-cabf1fb99241@oss.qualcomm.com> Content-Language: en-US From: Vijay Kumar Tumati In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNjAxMDE4MSBTYWx0ZWRfX+acLuA/CRl+c xon6KphGfQlD8NI/ZNjLjqQsF9qPcuaPWNXa35OEEz0dM3DhlpcuU6M+bX0ddsE67fNiTXTK77L i5+BlS61fuPNTgsKq9cuobfqQnv33AR1NTThnf32HpIuxxmm5y8a5hl8Xba3ofGU0CtzURMc79k oO4+lU2oiNy3SIGHeq6SHbOptEVftDkc8TaIoOHPRuhh7YCvpryEDl1wlV/X0omKcCfAPeZTVsX naJqqkMbWS0o43rHA+3VF8P7Ib9ZKozdR1TuojKQxBf85cfDjCHGL4Y9RaxrwMwwTaBVswcDMwP zY2sz0seXt2twujL2H622rfJPXN5Fmg7RXbSaOUgRbsk4vJPZQIJFKqORfkzebFfY4hQJBoekbw 40rpA50ljAoHt4xTWpcl8DNh/7gaULG/bQ+Paph77Y8g6AWv2sl5TjwWMEWTIlxBFQ8ZF7RxPgA qflIvCiTcfa3gdm80Pg== X-Proofpoint-ORIG-GUID: I3syZ6L-L4XcQq4nIfYa-LVdKZ8em5eM X-Authority-Analysis: v=2.4 cv=HrNG3UTS c=1 sm=1 tr=0 ts=6a1dcdec cx=c_pps a=wEP8DlPgTf/vqF+yE6f9lg==:117 a=JYp8KDb2vCoCEuGobkYCKw==:17 a=IkcTkHD0fZMA:10 a=FelO9ux0wxsA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=DJpcGTmdVt4CTyJn9g5Z:22 a=EUspDBNiAAAA:8 a=Gk2RreO4ThQZDhZWC3YA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=bBxd6f-gb0O0v-kibOvt:22 X-Proofpoint-GUID: I3syZ6L-L4XcQq4nIfYa-LVdKZ8em5eM X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1143,Hydra:6.1.125,FMLib:17.12.100.49 definitions=2026-06-01_05,2026-05-28_03,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 suspectscore=0 lowpriorityscore=0 bulkscore=0 clxscore=1015 impostorscore=0 adultscore=0 malwarescore=0 phishscore=0 spamscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2605210000 definitions=main-2606010181 Hi Hangxiang, On 6/1/2026 8:13 AM, hangxiang.ma@oss.qualcomm.com wrote: > On 6/1/26 11:04 PM, Loic Poulain wrote: >> On Mon, Jun 1, 2026 at 4:44 PM Hangxiang Ma >> wrote: >> > >> > Move the duplicate CSI2_RX_CFG0_PHY_SEL_BASE_IDX definition from >> > camss-csid-680.c and camss-csid-gen3.c into the shared camss-csid.h >> > header. This eliminates redundancy and makes the constant available >> > to future CSID implementations. >> >> Taking that direction, I don’t think this is the only instance of >> redundancy, so why single out this one in particular? Should we >> consider one-line cleanups across all similar cases? Also, other CSID >> drivers follow the same pattern but use different identifiers for that >> define (e.g. csid-340). >> >> Also, introducing such low-level, register-aligned naming >> (CSI2_RX_CFG0_PHY...)  in what is supposed to be a generic >> CSID header doesn’t seem appropriate. >> >> Regards, >> Loic >> >> >> >> > >> > Signed-off-by: Hangxiang Ma >> > --- >> > Move the duplicate CSI2_RX_CFG0_PHY_SEL_BASE_IDX definition from >> > camss-csid-680.c and camss-csid-gen3.c into the shared camss-csid.h >> > header. This eliminates redundancy and makes the constant available >> > to future CSID implementations. >> > --- >> >   drivers/media/platform/qcom/camss/camss-csid-680.c  | 1 - >> >   drivers/media/platform/qcom/camss/camss-csid-gen3.c | 1 - >> >   drivers/media/platform/qcom/camss/camss-csid.h      | 2 ++ >> >   3 files changed, 2 insertions(+), 2 deletions(-) >> > >> > diff --git a/drivers/media/platform/qcom/camss/camss-csid-680.c b/ >> drivers/media/platform/qcom/camss/camss-csid-680.c >> > index 345a67c8fb94..bf7164085ddb 100644 >> > --- a/drivers/media/platform/qcom/camss/camss-csid-680.c >> > +++ b/drivers/media/platform/qcom/camss/camss-csid-680.c >> > @@ -101,7 +101,6 @@ >> >   #define >> CSI2_RX_CFG0_DL2_INPUT_SEL                      12 >> >   #define >> CSI2_RX_CFG0_DL3_INPUT_SEL                      16 >> >   #define >> CSI2_RX_CFG0_PHY_NUM_SEL                        20 >> > -#define >> CSI2_RX_CFG0_PHY_SEL_BASE_IDX                   1 >> >   #define >> CSI2_RX_CFG0_PHY_TYPE_SEL                       24 >> >   #define >> CSI2_RX_CFG0_TPG_MUX_EN                         BIT(27) >> >   #define >> CSI2_RX_CFG0_TPG_MUX_SEL                        GENMASK(29, 28) >> > diff --git a/drivers/media/platform/qcom/camss/camss-csid-gen3.c b/ >> drivers/media/platform/qcom/camss/camss-csid-gen3.c >> > index 0fdbf75fb27d..da9458cd178b 100644 >> > --- a/drivers/media/platform/qcom/camss/camss-csid-gen3.c >> > +++ b/drivers/media/platform/qcom/camss/camss-csid-gen3.c >> > @@ -105,7 +105,6 @@ >> >   #define CSID_RDI_IRQ_SUBSAMPLE_PERIOD(rdi)     (csid_is_lite(csid) >> && IS_CSID_690(csid) ?\ >> >                                                          (0x34C + >> 0x100 * (rdi)) :\ >> >                                                          (0x54C + >> 0x100 * (rdi))) >> > -#define CSI2_RX_CFG0_PHY_SEL_BASE_IDX  1 >> > >> >   static void __csid_configure_rx(struct csid_device *csid, >> >                                  struct csid_phy_config *phy, int vc) >> > diff --git a/drivers/media/platform/qcom/camss/camss-csid.h b/ >> drivers/media/platform/qcom/camss/camss-csid.h >> > index 5296b10f6bac..059ac94ad1be 100644 >> > --- a/drivers/media/platform/qcom/camss/camss-csid.h >> > +++ b/drivers/media/platform/qcom/camss/camss-csid.h >> > @@ -27,6 +27,8 @@ >> >   /* CSID hardware can demultiplex up to 4 outputs */ >> >   #define MSM_CSID_MAX_SRC_STREAMS       4 >> > >> > +/* CSIPHY to hardware PHY selector mapping */ >> > +#define CSI2_RX_CFG0_PHY_SEL_BASE_IDX 1 >> >   #define CSID_RESET_TIMEOUT_MS 500 >> > >> >   enum csid_testgen_mode { >> > >> > --- >> > base-commit: 697a0e31ee66f5ddb929c09895139779fff33f20 >> > change-id: 20260601-camss-macro-3d40c4d4e90d >> > >> > Best regards, >> > -- >> > Hangxiang Ma >> > >> > Thanks Loic, Bryan pointed this out in last review cycle and suggested > to split it as a standalone series. This idea comes from KNP series as I > was once suggested to move this macro into one common header to remove > redundancy. I think your are correct after fully consideration. I will > make changes only for KNP and put it in driver. > > Best regards, > Hangxiang > So this patch is not necessary any more, is it? If there is anything specifically to be done to withdraw this, just for it to be clear to Bryan, can you please? Thanks, Vijay.