From patchwork Tue Jul 9 12:59:30 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 13727865 Received: from mail-ej1-f46.google.com (mail-ej1-f46.google.com [209.85.218.46]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7D91715AD83 for ; Tue, 9 Jul 2024 12:59:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.46 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1720529998; cv=none; b=i1xWHhtglSfp76wM4S+QPuhz57qOFs/XB57NRUNnyKsL+Qa7/ig+7IJY57YTevI9wgWLeKDKy6UvQumhmJsTIlkX14l/8X7iDkTCBd5MAFJrfiekyL/LWMr+9ZkXIM4h/cHsBHYK/PqzhWMlizVHbIJNRE/g5UOuqSq0M573Sgc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1720529998; c=relaxed/simple; bh=kgvsfjbzeej3OYxVir+9/eTJEO88akNuKkqf+hwCQrw=; h=From:Subject:Date:Message-Id:MIME-Version:Content-Type:To:Cc; b=SmiH76KrZymIFfsJXZ2blc537wVGuTKYAJ7rXmB1McCovi4bPbQYInOdkgcfewk71Dm2FdH9dfewSEWDYd79eB516tGKzm+UAEv8a3ID5Cpo6ZRyGqvbh28+3Fw6SEQczWP4oeQGKiZG7HMc8oXwMC4kWot2YFhT67OvS2xkaQI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=p2Q5aNL/; arc=none smtp.client-ip=209.85.218.46 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="p2Q5aNL/" Received: by mail-ej1-f46.google.com with SMTP id a640c23a62f3a-a7527afa23cso639997666b.2 for ; Tue, 09 Jul 2024 05:59:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1720529994; x=1721134794; darn=lists.linux.dev; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:from:to:cc:subject:date:message-id:reply-to; bh=zyMaA2ktAP79nx6/5Mxk0l1yWWoFwZUP+h8kjbjB7+c=; b=p2Q5aNL/P3OmndYI4CVcHYHW5hu5DIWjDQERm3L1CzVVdRpgGOzart06b+nq2nEA5i /sSPuiTPmNfCdxy1g8XjTqaWMVjVkOCx3nJ67Xhj+PKA+Dmqt55sQFH94rarRcQZDFUe pY3uK0+MjJX34LNauuixtw3GmsfmTZ+yx7SnKBMUHrCKSV1wVY2iLVZi2WPjnD5xls4N tKCZmfR48s1BcgoyRZKazzb4MVy+KavYQZz2HfpdohnRZk5LQ7gtRWLLpKVL6/U31/2f fRIKZGECgem5qkLNqwYZQgUl18RMLuI/65d2KHo4AcuwU1JR3gKa9+OyypRBJdK+YPEq Eg+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1720529994; x=1721134794; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=zyMaA2ktAP79nx6/5Mxk0l1yWWoFwZUP+h8kjbjB7+c=; b=rW8Yvuq9NPqVVoMyfatSMoeuYC+MMoeoJEHSVMyYpBBbYr1xUcFsEB3QQ9raM4Z1Eo S+fp8L8ipH7hhtJEm5eHTjMvW9oreDkaDu7Oigzlk4zsO9vHeCnKITzI3FzWOQ5lTMoT Hz3Fpc65dkRh0HPNHKyv1rvIzkYVBsVWutTCtRIt91W1yhkLjbrk+eJjT1yvqg3Bxpfm wL9lIoWqqEtkw5HoRmu229oR97O38gQV8M2RHBaJVuefbJX3IruQrSaGmBmik+a5NC9P NtttvvKeg2KTH4GxW5DDLO7z4JCXLYy0FCvJALHWdGCgGXrF5c81FFo5Ghv65iWgiuRn jqEw== X-Forwarded-Encrypted: i=1; AJvYcCUWBWo4JWChklzEe74jJC4BiQHzfkhxI/UZ34BLVh8d+3NIX4tLE+i16IZ8Pa+P0GU14ss1l/IDt8wAnMEznngwEgb4 X-Gm-Message-State: AOJu0YxE2d/WjUzaNueh2j5CbfkijdA7fbJHXddhmzlHYxYxHDVV6Up7 lPWkkglg4sb+p/MSGqKUVfJqUF8JBorLJK2PUZpcYNuXNAUaGVFxG/i8AaJO1hg= X-Google-Smtp-Source: AGHT+IFQIeObXuWwjzPQ5P94Pal4hLbHGTYuZ6cJpzJB5yZLLI58o/F8sFx6F5zODpmX82oPOJ7QOQ== X-Received: by 2002:a17:906:68c9:b0:a77:e48d:bb2 with SMTP id a640c23a62f3a-a780b6b17cfmr198118866b.17.1720529993825; Tue, 09 Jul 2024 05:59:53 -0700 (PDT) Received: from [127.0.1.1] ([178.197.219.137]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a780a6e157bsm76643166b.80.2024.07.09.05.59.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Jul 2024 05:59:53 -0700 (PDT) From: Krzysztof Kozlowski Subject: [PATCH 00/12] thermal/drivers: simplify probe() Date: Tue, 09 Jul 2024 14:59:30 +0200 Message-Id: <20240709-thermal-probe-v1-0-241644e2b6e0@linaro.org> Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-B4-Tracking: v=1; b=H4sIADI0jWYC/6tWKk4tykwtVrJSqFYqSi3LLM7MzwNyDHUUlJIzE vPSU3UzU4B8JSMDIxMDcwNL3ZKM1KLcxBzdgqL8pFTdRHMTcwND49QUI4sUJaCegqLUtMwKsHn RsbW1AIrkdShfAAAA To: "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Florian Fainelli , Ray Jui , Scott Branden , Broadcom internal kernel review list , Bartlomiej Zolnierkiewicz , Krzysztof Kozlowski , Alim Akhtar , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Amit Kucheria , Thara Gopinath Cc: linux-pm@vger.kernel.org, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-samsung-soc@vger.kernel.org, imx@lists.linux.dev, linux-arm-msm@vger.kernel.org, stable@vger.kernel.org, Krzysztof Kozlowski X-Mailer: b4 0.14.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1663; i=krzysztof.kozlowski@linaro.org; h=from:subject:message-id; bh=kgvsfjbzeej3OYxVir+9/eTJEO88akNuKkqf+hwCQrw=; b=owEBbQKS/ZANAwAKAcE3ZuaGi4PXAcsmYgBmjTQ5RRSnjbiXlLPhl5LMO5ohaeNBNwWB8vx7W nTbN1nTmLCJAjMEAAEKAB0WIQTd0mIoPREbIztuuKjBN2bmhouD1wUCZo00OQAKCRDBN2bmhouD 1wRbD/4zSxySS/s259DEhJkaDdc25d/x90eolV0xLjn69nZ8s0mzMdnlWQ4MIZZBUVetoXQq0rA UAhaAB2ZuzW4bnol7GTHITMuTSEE3ACJ0Vx0cae5TvQ4uK5LItk9N8xvQRsH/z9GBIyfWs55B7E 8z+yRBcm/B79zJPKMNLikxQs3y1GZy7Tip8LpRaQCvJ/X/tpx4ZffAMMcklbUBaA4PvNczr31MM j278W4BnIuJsg32T8+FAHLXVz0XTc34BzqYcgdFlC8eCsN6usty2kRrgmwNI1AElEdK/PIf9L5w +uMCWChYVNtW0Rrq+eF95VI0hXgdgGynF3417buGiRaYhLr3WP3zPc/tm/Qby+d4SvYXya6d1ii WX+ytupuXnatXPeMuUFJs1pZ78ZcVzED7NAILN+09KyXdgnzeuq9Py7V7F0T4yH3VQQM69N4Z6S RKGJ+b1wlcFwfnAMjZqYV9MZOJbKtp+VQZD/bESWhBq+NVECBwdnKQM/Ty8SkW7cKQ1GG5LvLfo fFiNLDcQEoMyRaF0Mor1lZYcGGKO+GUFafTA92oL6eUjBIKtWNJd99xa0a7i6WnA9za/aF1Jhor IwQOu/FpEkFjyMZZYlJjLlr5d2DMIC4TlAlVp9d3KrB1XxeAoJoeHeIu8Y7wPXNL0wVd7Foetw8 MrCiqIxYJ4hW7eA== X-Developer-Key: i=krzysztof.kozlowski@linaro.org; a=openpgp; fpr=9BD07E0E0C51F8D59677B7541B93437D3B41629B Simplify error handling in probe() and also fix one possible issue in remove(). Best regards, Krzysztof --- Krzysztof Kozlowski (12): thermal/drivers/broadcom: fix race between removal and clock disable thermal/drivers/broadcom: simplify probe() with local dev variable thermal/drivers/broadcom: simplify with dev_err_probe() thermal/drivers/exynos: simplify probe() with local dev variable thermal/drivers/exynos: simplify with dev_err_probe() thermal/drivers/hisi: simplify with dev_err_probe() thermal/drivers/imx: simplify probe() with local dev variable thermal/drivers/imx: simplify with dev_err_probe() thermal/drivers/qcom-spmi-adc-tm5: simplify with dev_err_probe() thermal/drivers/qcom-tsens: simplify with dev_err_probe() thermal/drivers/generic-adc: simplify probe() with local dev variable thermal/drivers/generic-adc: simplify with dev_err_probe() drivers/thermal/broadcom/bcm2835_thermal.c | 49 +++++++-------------------- drivers/thermal/hisi_thermal.c | 9 ++--- drivers/thermal/imx_thermal.c | 42 +++++++++++------------ drivers/thermal/qcom/qcom-spmi-adc-tm5.c | 9 ++--- drivers/thermal/qcom/tsens.c | 8 ++--- drivers/thermal/samsung/exynos_tmu.c | 54 +++++++++++++----------------- drivers/thermal/thermal-generic-adc.c | 27 +++++++-------- 7 files changed, 76 insertions(+), 122 deletions(-) --- base-commit: 2e0171396caa83c9d908ba2676ba59bce333b550 change-id: 20240709-thermal-probe-a747013ed28d Best regards,