From mboxrd@z Thu Jan 1 00:00:00 1970 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 968F01F4631 for ; Tue, 18 Nov 2025 13:16:46 +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=1763471808; cv=none; b=IzqhWAO1VN1aUL0RRk5zw84b1osw0zNoh7GBHqkESVHPljiVh68O142DJj5ZsoxuQ4S461Bpofui4Zin1P5CUIB7P1HpvyIcUmx6e3bxr2473G+24RqDvzShI6SBJiTgdhzBE804s/1N+arSB8PZnbYlr6hemnsap70Yd71/XoU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763471808; c=relaxed/simple; bh=IYyCQBbQx5iNoD9ar31eDdTc6JzOFM0fqyyF2d5D2ro=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=U+J7GeYcS/UV5J3Eo2VfTbKxrTCcTpOVX5RHxkxgPlYjTA3cRxq1uugYcDcsp5JO5yLLOGpuAlS9e7uqrJnr6x/0J0BV9wxezlxbiuyhOJhJrsWxHTAI4NbMLXxfmJlsGOljXX84UA9H1QekJMn8W3BpNE1pKFNFFBhBq9tko9A= 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=RXsOXp37; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=AWg8qzmL; arc=none smtp.client-ip=205.220.180.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="RXsOXp37"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="AWg8qzmL" Received: from pps.filterd (m0279873.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 5AI6fQP72343376 for ; Tue, 18 Nov 2025 13:16:45 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= 0YSs840Tv6aayGg2mERf7onDh3YO3dD48rnX/9yjp7o=; b=RXsOXp37RSTC97vQ Juhe4elufpGNs11EZb8u6A4tv4dm+cx9wJgFcf5zwzCRKJfk/OODh4TuaPBcwrrj HJGAu4oJUY6+qk0H7IqUXgi6hfNuN1CWRDgyiKtgrbL/ZeV8RkKXFoqmnGmUUAcK yqPrM5vCR8HPP1SqLDCLYL7BqLJUWkQEPHu+M6MzGIb50uNRRCC3gksvbodGnMvs OQXABlSofd/BP+lEuZmzhVzUcg0w7XB35adEhbrmxClxvFsEVY4A35qBqR8MYAgW 4weDDjb+gM/SvLc4subdYr/s4W1uVRVbHniK8YxpQ2W+G9zoZWvdfLI0NO2e44ZR vCzMgA== Received: from mail-qt1-f197.google.com (mail-qt1-f197.google.com [209.85.160.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4agkrn14gf-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Tue, 18 Nov 2025 13:16:45 +0000 (GMT) Received: by mail-qt1-f197.google.com with SMTP id d75a77b69052e-4ee00f2b7d7so12853651cf.0 for ; Tue, 18 Nov 2025 05:16:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1763471805; x=1764076605; 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=0YSs840Tv6aayGg2mERf7onDh3YO3dD48rnX/9yjp7o=; b=AWg8qzmLQGJD38AUUpjpJduSpFLW/ZBJeaqBupIinmt1tz1bj4QHKBRaGIBdLPjT/O 0K7ewlqTBdRDxrG+FgswQSZ27ALZBmUUusUcgIe+7YmBs3uV7XtNEJgvHm3Z1IQtPa8h UZfl+wakMVN/Lv/YAm9202ZvAgmwMa5T3Tal4rZNJP+O2AhcPUhjvQ2X9JdIe23a/kmq kJeD+cv/ULm1K5wR8JNUosQqXTPH1AhSKPe3VjrdfN51p9SWgW9+Q8NIEUtQUx3LO/OB NMO738VLB864IN6oDsmPOAMBTralHtVnlLKlTajcU/6NK2IAlcYjy/WPdNnYO2oo7sLF NWTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763471805; x=1764076605; 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=0YSs840Tv6aayGg2mERf7onDh3YO3dD48rnX/9yjp7o=; b=Ly7CCSxPGSiwsKzuFH+ndcea8yvRLQRkuEdp+9pb8tTysAwpZk8H+UgYZPU5k730K5 SLw38ntBFcqTO58mxCqmNJqTEJKZYnexwXHl/hzdPLhXU+r06BjNnvZDyF9lELch6Hnp LnETr/E1d5/EFSloAPFEP6vK9NOMKglIMpB5SSPZZvZIZ6Lq/YOxl8gu/KRMT3D+U6X0 ls3Z7BjUSq+5cGBdyf7LeFwL93/GLXQiWfoNUsD1fzHLi/WwIkKjWes28ioMJhI7Q17H Podc99uLXZvYMCqF8gX1bVCweTdIwrmqphGofi2vUI0EKm49IZXy1LWO4tYJplm3HVDU Txvw== X-Forwarded-Encrypted: i=1; AJvYcCVykmIZBW2vqGJQgG7m23avVks0wIDh6vootXGj8p2ouKGVzu1ct17FRdANg44U4zY/rthms/r6v1gOir8=@vger.kernel.org X-Gm-Message-State: AOJu0YwHDcb33uEHFGo2OiO3yWTQ96TdhfP2Q/2ksz+g8PgUfnDulAE2 8kLf/E35mjDLGM/aRIQJirQwwp9tuOgjuwu/kL3mSCQIaZGHKoEB12/j1ZqHZwx2iNy6ltPxzrp fXJZFgokFLgBthavuW/ud8vvo76vP895Bf4I9GisGDgMmbRN3XYXIBUiagzZx7fra9lU= X-Gm-Gg: ASbGncvWTxfJGLx2VKDJN+cnHP+1E+15KRKJFA2TOwdvgpewyJshyIplgTfkku9dEAB OUN4zJTjkkhMELa0J5vRYzS4+XBHSrJgBEJ1WrUnEhiiCLYf0dEoSSJaQz31u3p5XytxHLf5Xvk M1bY5nFe2hHAKFekKiYP8/AR7phHaL1QUSurCKoguJyofLr7CMa5d+eiZ/LAjKkjlVyzWW65c7T tDpTQo6Zz3jA9D3eYaPSZ9f1sGedWXjdnu8ndd/4NL1esNGjY16v+pffcV4KKEoYVVkFQhZxDmh 3ibavN4J9FHFEw5NELHRMsfaa22fvw14oXC2n1eX+vi7pGZnGCyqP0FFp5WVLJKW7INTviMZWL6 ORtaL2k4aIwzXzs2TsLOJ7VIT/veVJ7IeGBTBZc6/wXjUqd7kcsJ4foU5oMPU1F+BcWc= X-Received: by 2002:a05:622a:148a:b0:4ee:2580:9bc5 with SMTP id d75a77b69052e-4ee313e2b25mr24446431cf.2.1763471804627; Tue, 18 Nov 2025 05:16:44 -0800 (PST) X-Google-Smtp-Source: AGHT+IFshTGk6lqIuLNizEgCY3WNoeQjl06HSDq6hGVEM6YywvaCRzNbnZt8BmoRY3rV8STR1AEZRw== X-Received: by 2002:a05:622a:148a:b0:4ee:2580:9bc5 with SMTP id d75a77b69052e-4ee313e2b25mr24446041cf.2.1763471804127; Tue, 18 Nov 2025 05:16:44 -0800 (PST) Received: from [192.168.119.202] (078088045245.garwolin.vectranet.pl. [78.88.45.245]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-b7359bfb238sm1268467766b.14.2025.11.18.05.16.42 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 18 Nov 2025 05:16:43 -0800 (PST) Message-ID: Date: Tue, 18 Nov 2025 14:16:41 +0100 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 01/10] soc: qcom: aoss: Use __cleanup() for device_node pointers To: Dmitry Baryshkov , Krzysztof Kozlowski Cc: Kathiravan Thirumoorthy , Bjorn Andersson , Konrad Dybcio , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org References: <20251117-cleanup_node_put-v1-0-5f107071d171@oss.qualcomm.com> <20251117-cleanup_node_put-v1-1-5f107071d171@oss.qualcomm.com> <9c10881d-d5c4-4e60-8960-2ead76c63a2d@kernel.org> Content-Language: en-US From: Konrad Dybcio In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Proofpoint-GUID: phcQZXvfN660kpJB8nNFUNmCQYRucFAT X-Proofpoint-ORIG-GUID: phcQZXvfN660kpJB8nNFUNmCQYRucFAT X-Proofpoint-Spam-Details-Enc: AW1haW4tMjUxMTE4MDEwNiBTYWx0ZWRfX1Mh42wH10cUg ILL8zPS0liEkFdO93GSTOwNWqcL0zyM8QI6jw0G227rDS/+OLyaD62aNZs5RVQkTpzRnKIvhx57 6eKH6tbKJ87oknaKybMZIuwGdqucE+rNlU+Df/jeR0D7VyY0F/AwT8d5G1IFmnzkrN2iVCzd2s8 lX4TxtUj0sFUnk1HS9hOTO4DEXJmKPp7luxJeDwTtUPbSEE5jIM8YJzf+NKdp/7lku/5ZkgzHzO RwtqurVPnvw6qMV+QMlWuiVZu/LzisV1zurE7wSxNoXH+lwSmY1Q6UP9V2cB2rZjLOyBpyCAYSN XVm0X/zIGfwmoGDsDza6Lxj5vWeW3NzWRek157+bOHYWZbOShzazUEcmJci5xppteJZx86U/crE xyZdchlmpuPM4tK3CHi2fTUYUfYe9g== X-Authority-Analysis: v=2.4 cv=L+kQguT8 c=1 sm=1 tr=0 ts=691c71bd cx=c_pps a=EVbN6Ke/fEF3bsl7X48z0g==:117 a=FpWmc02/iXfjRdCD7H54yg==:17 a=IkcTkHD0fZMA:10 a=6UeiqGixMTsA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=EUspDBNiAAAA:8 a=Mqc5ooSUfjBGwrODpf4A:9 a=QEXdDO2ut3YA:10 a=a_PwQJl-kcHnX1M80qC6:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1121,Hydra:6.1.9,FMLib:17.12.100.49 definitions=2025-11-17_04,2025-11-18_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 suspectscore=0 malwarescore=0 lowpriorityscore=0 clxscore=1015 bulkscore=0 adultscore=0 spamscore=0 phishscore=0 priorityscore=1501 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2510240001 definitions=main-2511180106 On 11/18/25 1:52 PM, Dmitry Baryshkov wrote: > On Tue, Nov 18, 2025 at 01:32:51PM +0100, Krzysztof Kozlowski wrote: >> On 18/11/2025 13:25, Dmitry Baryshkov wrote: >>> On Tue, Nov 18, 2025 at 12:39:51PM +0100, Krzysztof Kozlowski wrote: >>>> On 17/11/2025 12:35, Konrad Dybcio wrote: >>>>> On 11/17/25 5:51 AM, Kathiravan Thirumoorthy wrote: >>>>>> Make use of the __cleanup() attribute for device_node pointers to simplify >>>>>> resource management and remove explicit of_node_put() calls. >>>>>> >>>>>> Signed-off-by: Kathiravan Thirumoorthy >>>>>> --- >>>>> >>>>> Reviewed-by: Konrad Dybcio >>>> >>>> This is obviously wrong and not helpful patch. >>> >>> Describing why it is wrong would be helpful (or having a pointer to an >>> explanation). Bear in mind people who read email archives and find this >>> very brief note. >> >> I gave some rationale in other patches, but summarizing: >> 1. It is against cleanup.h - author did not bother to read it - which >> clearly asks for constructor with declaration. This was discussed many >> times in the list, including many bugs and explicit checkpatch warning >> (on LKML) because people don't bother to read cleanup.h. Looks like I didn't read it either.. now that I did, I see that _free(x) = NULL is somewhat of an anti-pattern, but none of these patches seem to introduce any bugs related to it >> 2. It makes simple get+put code complicated, not simpler. Here I tend to disagree.. >> 3. It grows the scope of OF reference without benefits. This makes sense Ultimately as you've noticed, this is mostly a cosmetic change and I don't mind it going either way Konrad >> 4. This driver was already reviewed and simplified so author should go >> back and think why this was left alone (would save a lot of trouble). > > Thanks! >