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 1970C36607D for ; Fri, 6 Feb 2026 13:15:33 +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=1770383734; cv=none; b=muidILKWvPt+OM2S0m+xcYcix3iqWVDlptQuY94XEn2LMUSfD0FEFq81NlEe7MWzaTyWsZ5m3a5tZm8EqcibH3SC2oupKBN62crMXL/hNj56r/UC/5NF8WlwtlAwkf3b3FIjiYAVK5efLlQ7TXC1rb/J99PjlIqmuSHS6nWBV6w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770383734; c=relaxed/simple; bh=OP8/OArL2cMmvjrS2BcXJQ+YVC6QxtE/6FgIyIpyXfQ=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=njfuMFGavrp1R/SLRr63rmvWuAiqsD/CktGSHiX6qPywiISjLbuEphDwqPuQeIVn3QWSRB6CJJu2kTqpKmECEmcsKN0bFLHcBGtLtBK1qQE4R2IWdhUIW8UFrN9TaLzFgjwSYIgWboOjcp56v1TtKbWeGnkE8+jo0s2mEV3q+5s= 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=M65YF92D; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=GutH41bn; 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="M65YF92D"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="GutH41bn" Received: from pps.filterd (m0279863.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 616B2mqI2938802 for ; Fri, 6 Feb 2026 13:15:33 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= HmNmeyWa+J7dZZyEeSg9GnKnpszfkH8n3cTwO4E6RzI=; b=M65YF92DxN324jlJ W7osZxwxct4DPC6cKtRVM6kQS8dSFdHbySHsE5Xn0MOQoVcmeSMdyI1oeE02vCxR 6JmADaxuUkK/uESgT0AqQ/Zthyzagr1LJvH9yiQXMmgBThDRiB/X8BjM1bOblo/B ZNSgXWVwE3AqQdJM8DAIBo1jBAQGLiROvIYdCcNG64uTSJpns6hOnA9/iCa/4GTu svURhO7ODgvTRuw7LGhSIaTmQi4O/g+lThjWlDwCHTu88ZPCa57qXUtmI04I74IK 8E8QVm94ZHqMh5GvbGddgtpr+gB8CNfZrpwHwBhY55PB11Hfia5FJ8jjCJ/DhxK9 3qXOvQ== Received: from mail-pl1-f197.google.com (mail-pl1-f197.google.com [209.85.214.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4c5f35rbnr-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Fri, 06 Feb 2026 13:15:33 +0000 (GMT) Received: by mail-pl1-f197.google.com with SMTP id d9443c01a7336-2a76f2d7744so22423535ad.3 for ; Fri, 06 Feb 2026 05:15:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1770383733; x=1770988533; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=HmNmeyWa+J7dZZyEeSg9GnKnpszfkH8n3cTwO4E6RzI=; b=GutH41bn89hK79mQ9R+vWJOwHsRzWVeBG8eXccqsXuryRZSjMCysTbVS3YI8r+nf9Z ISQJ+VnhRcWIyXh4KWDr/vvIOqn2z5YJzJFTwDKqGo3x6R7InF/P6g6M3ZiW2zEp7ydK S6+v8xpprfGORRsXXKudJUPqXqkIam+lE1MZwU5xt9zQZRnEEkYhsd9q8Lno3AH8BVld NZJyNscRBKlCL5Y9fEEhgm/9ujaBRrkuAuee6d44Xl9bTybnbxdu2trOTHHol7Cbfh7q fUp249arXJRJhcEV8t771RPSMNuRJiuhdsjwd8vGtBrIxe3FuRpHHY6jFejCke8Ez+F6 mlhA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1770383733; x=1770988533; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc: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=HmNmeyWa+J7dZZyEeSg9GnKnpszfkH8n3cTwO4E6RzI=; b=RbX6gvaKvXvoo/Z3EEeWECr5APGskIiU8OgmHKGxxnpbr7M0e9+qviVp4Svv9w4ahE i00SKOYooTgYmlK7ZGAW7WxrSKnOPKHbaHpl0P0td2cKuqjcsJjTzuW1HsJ5cxPrisvd YAqU0AM84pvpa7Sxnc+NaZVLjuJC7JokYc0Bh0NjWktBwr1rTH/wxpNY4z47dEtKQK6L EHIqhnKicC6A1LUw8WHaQw6wDB7DOSXYmM7wsaRo+xO0aMgRogybzr3oLTjzajaRUR1D +kOa0E2jOvmVXLv792mH2u72uOnjuMR8FvUTrUnZ8fWS08CmLPk3moyBFG7sLxlqPZx7 L5rA== X-Forwarded-Encrypted: i=1; AJvYcCWTuPZp8S0Y8ZW5tAB6rCMpP6HHgRvX3Ea8Jlsa1avKste3FQXcXLIxPSkZICltXj0r/Rp0Xz/3HjoCL9U=@vger.kernel.org X-Gm-Message-State: AOJu0YyaItSbzKgYWYDMq6e+W0d8oFKpZR2r8WiW5ooxquXCeT7Hivfp IEPYaryqS+Z2Ze1z4KyaOBgh2TK6xNBrOSu92+d7c920xmmXzj8NQbggDoKUNgADT9pB5Q9Qe6f am+6F9wfJ/+RjBfMzEMxxyO29T5piUPnRP/eAhPdAJG9RJGlSCNwQZZ0Cck/YgtFa5W4= X-Gm-Gg: AZuq6aI6FXhF5VFuDa/xQrPlRJxYl+3K9xch+gbm5R4jLjpevkCdjrQZZcqetB9mLyR KusXgjn5iGTQcsWUnKiTyvBRb6AYKOWmrCkJm9BR8Ar0kFAZnHJZWQrdCu1ZHIoeHrGFEhm+wNS 4PkslRheemjlSNzL8uqWRYWvQfoNPmWnb/dlFutlNFfl6qt71yXJ+jIfTCgnEwp8NKAjOk55WnK vDF3aCo1+ccvdoUm23X7GZUpPsoXnXVkenIRDE02SIWTOUgO3N33vUG54lGsOH2L4yQvUZCbdte DgECjlHZGyg9jV0mpRTOi1YxYi+9LXT/PD1qYdH8Skhd27kMhWJbJQo7+yXVqOQWg2hWCRhUnvy cfjjjl4r5T7O5S1PutynjeHlgNVQ4fHp6w4mgxh/QZg== X-Received: by 2002:a17:903:3d0f:b0:2a2:d2e7:1601 with SMTP id d9443c01a7336-2a9519428c7mr28925195ad.48.1770383732477; Fri, 06 Feb 2026 05:15:32 -0800 (PST) X-Received: by 2002:a17:903:3d0f:b0:2a2:d2e7:1601 with SMTP id d9443c01a7336-2a9519428c7mr28924715ad.48.1770383731980; Fri, 06 Feb 2026 05:15:31 -0800 (PST) Received: from [10.217.217.28] ([202.46.22.19]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2a9521f8cb6sm24970545ad.79.2026.02.06.05.15.24 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 06 Feb 2026 05:15:31 -0800 (PST) Message-ID: Date: Fri, 6 Feb 2026 18:45:22 +0530 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 V10 4/4] thermal: qcom: add support for PMIC5 Gen3 ADC thermal monitoring To: Jonathan Cameron Cc: robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, agross@kernel.org, andersson@kernel.org, lumag@kernel.org, dmitry.baryshkov@oss.qualcomm.com, konradybcio@kernel.org, daniel.lezcano@linaro.org, sboyd@kernel.org, amitk@kernel.org, thara.gopinath@gmail.com, lee@kernel.org, rafael@kernel.org, subbaraman.narayanamurthy@oss.qualcomm.com, david.collins@oss.qualcomm.com, anjelique.melendez@oss.qualcomm.com, kamal.wadhwa@oss.qualcomm.com, rui.zhang@intel.com, lukasz.luba@arm.com, devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, cros-qcom-dts-watchers@chromium.org, quic_kotarake@quicinc.com, neil.armstrong@linaro.org, stephan.gerhold@linaro.org References: <20260130115421.2197892-1-jishnu.prakash@oss.qualcomm.com> <20260130115421.2197892-5-jishnu.prakash@oss.qualcomm.com> <20260131175412.0ded39d4@jic23-huawei> Content-Language: en-US From: Jishnu Prakash In-Reply-To: <20260131175412.0ded39d4@jic23-huawei> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Proofpoint-GUID: upA0x2Qu7ZZsU1DEJ6H-Fm1zkPiqt6-H X-Proofpoint-ORIG-GUID: upA0x2Qu7ZZsU1DEJ6H-Fm1zkPiqt6-H X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwMjA2MDA5MCBTYWx0ZWRfX1623eQ5Wu8nq VkkVuwcVr5ea6pA6qSkMlj0/s6j0Tgu5kiUz+Br83glaIK7RIaCpe6zkh0z2tE0+YM6iAkA5TDw 3rq9ZqRp6p/u1YoJAAL3NPHpeCC2/7hnj0KukBwII4AhgN1/Ds3v7VA9tftPWHhsa+9HjbeMmwm GhQXQ0FXa73tKzWIpmTFryLR1jyjNTkf1UmhX/000yQdO7stZi4BK+M0v6ZYEQukeaGtnKDa5fG rzeiybmqiNxH8kdT3hoY+gBSEMTe3lmvlarWzn52roQQRSke+I0DI3IYcaubYkeMfid+jshSb9K aRZ7/L0ofddTRFdATbYSDEdcvxtPph3Op0i/YLTUPhdlgimZkazUhn/HP2uHM/40PSsC/QkHSb9 JXwJdQ0L7YQkzbngAqjL8TdoB+U/o29OUBtYrGDpHs7cOKJx/SNsRZ/gTU74q5DJ/YMYUSVHjL4 rAcVTe9RktQ6OJctaLw== X-Authority-Analysis: v=2.4 cv=ApnjHe9P c=1 sm=1 tr=0 ts=6985e975 cx=c_pps a=cmESyDAEBpBGqyK7t0alAg==:117 a=fChuTYTh2wq5r3m49p7fHw==:17 a=IkcTkHD0fZMA:10 a=HzLeVaNsDn8A:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=Mpw57Om8IfrbqaoTuvik:22 a=GgsMoib0sEa3-_RKJdDe:22 a=EUspDBNiAAAA:8 a=i0EeH86SAAAA:8 a=yfIZU4QQ0lc7Zzv-pR8A:9 a=QEXdDO2ut3YA:10 a=1OuFwYUASf3TG4hYMiVC:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1121,Hydra:6.1.51,FMLib:17.12.100.49 definitions=2026-02-06_04,2026-02-05_03,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 bulkscore=0 malwarescore=0 adultscore=0 lowpriorityscore=0 suspectscore=0 priorityscore=1501 impostorscore=0 spamscore=0 phishscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2601150000 definitions=main-2602060090 Hi Jonathan, On 1/31/2026 11:24 PM, Jonathan Cameron wrote: > On Fri, 30 Jan 2026 17:24:21 +0530 > Jishnu Prakash wrote: > >> Add support for ADC_TM part of PMIC5 Gen3. >> >> This is an auxiliary driver under the Gen3 ADC driver, which implements the >> threshold setting and interrupt generating functionalities of QCOM ADC_TM >> drivers, used to support thermal trip points. >> >> Signed-off-by: Jishnu Prakash > > Hi Jishnu. > > Some minor editorial style stuff below if you are spinning again. > Otherwise this looks good to me > > Reviewed-by: Jonathan Cameron > Given I expect this patch will go through the thermal tree and not IIO. Just to confirm, would it be fine to keep your Reviewed-by tag in place if I only make changes in this patch to address your comments, in the next patch series? > As mentioned in previous patch review, we've missed this cycle for IIO where > I'd expect to spin an immutable branch for 1-3 so we can do this early > next cycle. > > Thanks, > > Jonathan > > >> diff --git a/drivers/thermal/qcom/qcom-spmi-adc-tm5-gen3.c b/drivers/thermal/qcom/qcom-spmi-adc-tm5-gen3.c >> new file mode 100644 >> index 000000000000..882355d6606d >> --- /dev/null >> +++ b/drivers/thermal/qcom/qcom-spmi-adc-tm5-gen3.c >> @@ -0,0 +1,512 @@ >> +// SPDX-License-Identifier: GPL-2.0-only >> +/* >> + * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries. >> + */ >> + >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include > > Similar comment to previous. It's rare we need device.h > and if a forwards definition of struct device is enough it > is better to just do that. I can do that in this file. > >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> + >> +#include "../thermal_hwmon.h" > >> + >> +static void tm_handler_work(struct work_struct *work) >> +{ >> + struct adc_tm5_gen3_chip *adc_tm5 = container_of(work, struct adc_tm5_gen3_chip, >> + tm_handler_work); >> + int sdam_index = -1; >> + u8 tm_status[2] = { }; >> + u8 buf[16] = { }; >> + >> + for (int i = 0; i < adc_tm5->nchannels; i++) { > > Not that important but you've been a bit inconsistent on this style > of putting the loop iterator declaration in the for loop or not. > You could definitely do it in a few more places. I didn't comment on those > because it's a style choice, but consistency is a good idea - hence I'm > commenting here. I'll update this everywhere in both driver files and also address your other comments in the next patch series. Thanks, Jishnu > >> + struct adc_tm5_gen3_channel_props *chan_prop = &adc_tm5->chan_props[i];