From patchwork Wed Aug 14 15:04:04 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 13763620 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 926E7C52D7B for ; Wed, 14 Aug 2024 15:06:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Cc:To: Content-Transfer-Encoding:Content-Type:MIME-Version:Message-Id:Date:Subject: From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=9XvQrRhyjQYZnQbMs3EjboskCKHEKhPSKVqnPioFGZ4=; b=AYoa03a/R5rvP6 mXq230RVK2bTCV/5ycegUO2NlJ5g7l7xvZIAdgRes82lkEiTITp/U5TjvBuBuPFb8maOsYI5T6S5A bIQG5IxgYhvoPSeUHopy+oPcuodkU8nhmsmzCVeSdSLD0s6zG+OOGLUntEoDvn8i8aln7BtZG7GPz 58njCBeYS7WkS7cCm9SpcquYTlogTZicWdpZs2wsrFgewqvV9Bmv/bUFpISGSTh5o+P6UEqfvAE0d Kpc5w93AJPLjqrUpMEzKHbC3VUpxa6lBXb6+VdLzGie2tEYgum8iE5QKOtUA/nrJReEIHujZi72fp TEjp8zFIeVqU/r7NfgnA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1seFZW-00000007Q5E-1r8c; Wed, 14 Aug 2024 15:05:58 +0000 Received: from desiato.infradead.org ([2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1seFY1-00000007Phx-42Ea for linux-arm-kernel@bombadil.infradead.org; Wed, 14 Aug 2024 15:04:26 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Cc:To:Content-Transfer-Encoding: Content-Type:MIME-Version:Message-Id:Date:Subject:From:Sender:Reply-To: Content-ID:Content-Description:In-Reply-To:References; bh=9XvQrRhyjQYZnQbMs3EjboskCKHEKhPSKVqnPioFGZ4=; b=oczQVwRBc8MlOIVVwBTi+cetlr XKaCKj0qug5ZvDIRgW5+3y8YmJitW5Uygbrz38PwTi7IPmQ1ss+2i33pxpFvGPJcVoJgwmfSVoimT aMsjiRnR0DyRKU7smQk1Mgsn/QaB9Ri+zNxl1zGHuYxcFy9ZPPzTT5Wzd11P5nMH4UYdxfD9IpAoG 8OweH9m0NFvYGuIB/4CbPoZAsHNn3lY/8ewsrI/IX3ybFXGyfI7P9Cv2sHKMh8FnM0xQM0uP60Oer ZARi9HMVaetZMJDtxTmgKBYgVRw7VkBD+m/atnBR98nBwy8i6fmYG3J7G0oA0eKPl7G7XuC8bYumC GEb6qu5w==; Received: from mail-wm1-x336.google.com ([2a00:1450:4864:20::336]) by desiato.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1seFXw-000000085Hx-3zgl for linux-arm-kernel@lists.infradead.org; Wed, 14 Aug 2024 15:04:24 +0000 Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-42817bee9e8so49789245e9.3 for ; Wed, 14 Aug 2024 08:04:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1723647856; x=1724252656; darn=lists.infradead.org; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:from:to:cc:subject:date:message-id:reply-to; bh=9XvQrRhyjQYZnQbMs3EjboskCKHEKhPSKVqnPioFGZ4=; b=NmZ0Vcr5GRS4yiQZgTZoT0GSif5p8QfJkGlc1OEDLhkTNgOJz+qcuDMxMwl+pKekjo ogF7jpzy+8xPLkCw+S5s4BuhoMcwsp5JO2DtAbKFy7PDXS82tYy7U8HG91xwlK0au6M+ plGw9pnghj6ut7Spp2pNnTyMTyIGDKoqShQY2KSvWRyTFyOUj8ZvMboK9DhnYCv1utSv EkPJwvtBF9dbS/1o5+BWYPCDDhmEM5Sek0rbs2yyx5iD4M9ckX7YuMFpYQyAw69FijaY raAbrwy7wNFgnQkKMVyc5wHhIaN+PZWpeM/mfYHTbouXS1EK579UfeoCSOByZDiyB5Jh ePJA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723647856; x=1724252656; 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=9XvQrRhyjQYZnQbMs3EjboskCKHEKhPSKVqnPioFGZ4=; b=n1gqeQjG7VThGWxxn2JdsejqZlBr7Su3Sa7sKunEN+EFpG1Hhecd8cTEckxCyjfkvE 1/PLfKULrhMKxZIclv9DlzJ4pLO96I7lhja11sOdmOopiLfj8j1qAK0VOo4LqqwIE2e7 e2CNYgYnYJQMGDLMfP6qwMDrWULxSr3ZnfNQY3vj+EfoIEi8y9TGhAFn36Ninmyvp0DO 4ZJ6XG8rxZr3EHlzIV6onERTqTWPxNkBoTm1lgo0bo2Ms/XrYfGApBzxuOHhBxlWdKmh 7pSAQLcbuU4AX+mC6imCzAXwVLHO4OTeNEZLtn81ujVlO/TGidnDW2cdsvuCg9avSuiN zohg== X-Forwarded-Encrypted: i=1; AJvYcCXTHfnAWg9ld0tXJ7Iy8qSzcw5kc8tnztQiAOpk50an9StSNiJLLKShgdaiZLnG+s//F0nGuAQ9P91K4GmKZClarnjgaH9urrGNd1arMMPbq1wpIEQ= X-Gm-Message-State: AOJu0YyVzRr10EZyu0aUGY9TUgdaPPlnSLHmelza9ssuK6ii4nNlbu4y qBXSm0jP7Q36rI2yYrKfhHv+4l+bk78YkvAKkJNP5hUVs8SfOiYuAaQdwLtAnN4= X-Google-Smtp-Source: AGHT+IHmH/lZvjGcJ8hd1XXOkhepYdrTq38ZINMbfl6cgbN+vgIZhEXaS4U/b6MJaA+KEgX05jhvHQ== X-Received: by 2002:a05:600c:1f96:b0:426:6308:e2f0 with SMTP id 5b1f17b1804b1-429dd25f8f2mr20826075e9.26.1723647856256; Wed, 14 Aug 2024 08:04:16 -0700 (PDT) Received: from [127.0.1.1] ([178.197.215.209]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-429ded7cfbasm22313425e9.45.2024.08.14.08.04.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 08:04:15 -0700 (PDT) From: Krzysztof Kozlowski Subject: [PATCH 0/7] regulator: Use scoped device node handling to simplify error paths Date: Wed, 14 Aug 2024 17:04:04 +0200 Message-Id: <20240814-cleanup-h-of-node-put-regulator-v1-0-87151088b883@linaro.org> MIME-Version: 1.0 X-B4-Tracking: v=1; b=H4sIAGTHvGYC/x2NWwqAIBAArxL73YK9QLpK9CG51kKorBmBdPekz 4FhpkAiYUowNwWEbk4cfIWubWA7jN8J2VaGXvWj0t2I20nG54gHBoc+WMKYLxTa82muIKiVddX UgxsmqJUo5Pj5D8v6vh9oAOq5cQAAAA== To: Matti Vaittinen , Liam Girdwood , Mark Brown , Krzysztof Kozlowski , Sudeep Holla , Cristian Marussi Cc: linux-kernel@vger.kernel.org, linux-samsung-soc@vger.kernel.org, linux-arm-msm@vger.kernel.org, arm-scmi@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Krzysztof Kozlowski X-Mailer: b4 0.14.1 X-Developer-Signature: v=1; a=openpgp-sha256; l=1380; i=krzysztof.kozlowski@linaro.org; h=from:subject:message-id; bh=iH0p1V4eqat+M+Ev3ANGFPe7vqJ4jJ5CZXeTzvo7Cdg=; b=owEBbQKS/ZANAwAKAcE3ZuaGi4PXAcsmYgBmvMdmd+tmcteMBql83WlVuhACQS93WzBw8oMPj AV6xtrkFf2JAjMEAAEKAB0WIQTd0mIoPREbIztuuKjBN2bmhouD1wUCZrzHZgAKCRDBN2bmhouD 19bKD/93motsO9ftIadx261e7kNMivGz4JoHeOh1m5TRM7Kk6m2sJE4pXZaOgkXsJik6Et7Mvqd AZKA7lclS4PrvpzTrvDVPcEIv9Y7vgKxlnvLV1oQp2SCplhK0dn0PIbS760UMl5gYv/TvNCKJUe O6qbI6MF9qwoz46qgn47zFpPPV/muo0s8I1qB4IBENZLcRF390zBtn6WjoyRSrMJp7h/DT3aM5y 0hbqZCCtooU5IUPtLkRMPdSmgVhGTXzKfOoczB8oLsz7yrXW9ULE4e7rIr/PwCBsSG6WjQ7kgjV /V969nWY2hikvDHOv0hLD2RikD/HJU2umVC7z33f/SDy5XlgmnnrsXEscpSFzCo5LYFf8Qe1job v+RVCRExOdKbzAXiTNSHV/MZvKXoU24q3WxKT48raQlIvAaOX17J9u1dhptMjPeLlOuFqeb9hbd aGSg1+pkfVLP2d10TNhfFQFJ45KPV2DO4xj6ZXtRU7w9urnXFEcjWSgI64Tq94KhDdbqI2lEOTL /8+sMrdz6drAVAqYe/kIrh1LL51aZFtnYzU+qlgC0Z6/mlfncaBfiu+wgVnob4ae59v98IPm9xa fvoHAh6/EfiZ2cfLC1dhp7BKY9HzIse8L7Ia4UmDQz301tRpQbTAOmGvLcGTquOqoO4WrDHcfJw Qx63gwZEjZZsuwg== X-Developer-Key: i=krzysztof.kozlowski@linaro.org; a=openpgp; fpr=9BD07E0E0C51F8D59677B7541B93437D3B41629B X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240814_160422_886106_183C95D5 X-CRM114-Status: UNSURE ( 6.77 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi, Make code a bit smaller/simpler, with less of_node_put() thanks to cleanup.h. Best regards, Krzysztof --- Krzysztof Kozlowski (7): regulator: bd718x7: Use scoped device node handling to simplify error paths regulator: bd96801: Use scoped device node handling to simplify error paths regulator: max8997: Use scoped device node handling to simplify error paths regulator: s5m8767: Use scoped device node handling to simplify error paths regulator: qcom-rpmh: Simplify with scoped for each OF child loop regulator: qcom-smd: Simplify with scoped for each OF child loop regulator: scmi: Simplify with scoped for each OF child loop drivers/regulator/bd718x7-regulator.c | 19 ++++++------------- drivers/regulator/bd96801-regulator.c | 17 ++++++----------- drivers/regulator/max8997-regulator.c | 11 +++++------ drivers/regulator/qcom-rpmh-regulator.c | 11 +++-------- drivers/regulator/qcom_smd-regulator.c | 11 +++-------- drivers/regulator/s5m8767.c | 17 ++++++----------- drivers/regulator/scmi-regulator.c | 8 +++----- 7 files changed, 32 insertions(+), 62 deletions(-) --- base-commit: 7b3754ef5d53bb1431e25f65126280993c2e640b change-id: 20240814-cleanup-h-of-node-put-regulator-80df40883f35 Best regards,