From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-ed1-f45.google.com (mail-ed1-f45.google.com [209.85.208.45]) (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 856AC33506F for ; Fri, 23 Jan 2026 10:05:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.45 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769162765; cv=none; b=RkpXI57P3KIFHsI8ac8DvUA+HFDpggKQnrNTyPduXd6iZF5EZbgG/WzNZDV/fxuLgJmh0MUg84hNNRaGvNqf4XkpAFgYZDuHm9QzRktziHqQW3TXfHDg6W128LWRuUJe0nVoAYRwJ1XlqRnqvac8BUzYLEEY8vzdFNFDQ0UC6Xw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769162765; c=relaxed/simple; bh=ZixxmyDJK1TZsGAkuoNjkGaPnXKebF+tiR5kAJ33kxo=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=utrbumrwcCJQJNpzCYvXv+Dly8Nr03rn9tR02qbkiVjOsZITUDB5hsGpYfxs72kOOpzbxp8E70P8Fkoezp5xRz/GeHZt2UwunsGszuU3CFQsiNdCzKvghvpu5gelUVpKIAswv0v6+rd5exhitPSyy3UnM6f5UbWStW/dd/JDeO4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=igLVGsme; arc=none smtp.client-ip=209.85.208.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="igLVGsme" Received: by mail-ed1-f45.google.com with SMTP id 4fb4d7f45d1cf-652fdd043f9so3563198a12.1 for ; Fri, 23 Jan 2026 02:05:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1769162742; x=1769767542; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=0OPAhEHcnzFb1q5rx6RdDHI02f+ORuOWyrLORsemtx8=; b=igLVGsmebSjYnnV4fLKGgiFpRf696iQgjuYDpOoHpWxKgte0+9r4c7FRxNN0Nb8vQy 9U5vs3vr6rqxkLlPV0uJgmCipNtmJIYH5t0FKHrV5zdsDR6RiV+hEu2araclE3gETsMx /HvODuyV0bkp7S0Q4wELKohjvKJafyG79zNRYmerCmctgBMlH/6lKzilsiJbtKGCICRz ZskFEpDGjIlWIk18a9dCqQ8wRBreRhTqSoncTy5IYaJI1tKqvRYT5KAMa2jWbe5sCbAd S5U1wRhzyMO8khk7LA7CaKoUFwmux6HfrF+0lDsfn/NYRmixnPMoRhaj2TjCEZqySRND Nozg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1769162742; x=1769767542; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=0OPAhEHcnzFb1q5rx6RdDHI02f+ORuOWyrLORsemtx8=; b=gqGDp8vri8sAcOhTtjMuVTwXQzBHSUkab+7vJ0LMChYT5DIzNZJ6YdkChavuOOoze0 CXFFKBPNJBMzJDbxaGpgJLXdvSu5AenJJvR1lcxyN8O2h1jRF2vwXWxo/37vcPvXvSCG afYWqSuBeD1K5MjLR/o8tylRbVuxFa+Eab5+WFhNpds2vMjVRWyQJ7KLyg3x+/mEJTP6 MCh+rwqNUVnPeTVZBWBD4zx+ZrZ7UF7tsr4Xeqy++vXl3xjPaLG8YZtUY/qKzFbP3RAA sDz+UtzSAz5vt62qoMyewrWMOWT2aXVEpfoiIcfm/oO9FrMNB8c89b0LLhDu4aPU4kW0 CAPw== X-Forwarded-Encrypted: i=1; AJvYcCX/hw9p9Vr0XMnO3Sp6Fxak/HeZufYvprAO+Zi5JgOmyjKh8Z8YGoIcH8yZEYxrkAEJDt8zY1rEDqy77Wk=@vger.kernel.org X-Gm-Message-State: AOJu0YxzvtitkFyc1toW1ltqDZy3IUoho8oWNOOHXONJ6R5SA5YW+ixe 0Bv6uQaI5sxRicz8h00xbJO4TkYAdYFDJp05Jfr0uelwo1et9ZUNRgsb X-Gm-Gg: AZuq6aJYieBJdjQL6rmtI2oS2wZN9vkyeJNBqIxAQ+mXfKiSYXmEBtecWBcwih4br1f CWT69PakU2mgVuoHdhJpANqeXDmvzRuZglFJWBWUnJAvlSHg1xvQ569ahbcCUOnxRT3bRplEsdy Rms1GrfIHLNXyeD5a527AdjvHSMX2wfRRFER8BzodmCqr/W0LrEaVK98x/d0G/EsVzVH0suM6eH OypNI4X6R0U9OinAk4ITBdNqkYyvcEg1eJDQ+2+fptf5CZ62RNJabIs/ZtPe9VcMukwEPQ5mVof r828Q1ehgqz0qDoA/GTdNcNDAzSF9hYOCsRAcS+yppf9dtfYM6hPoXBfSXgmge0SZNSaMav02Hq kLwE5wm4850VKCQyWwPbxAYxIC8WMP4ECnEsdcmZps7cy9Hvtym22F8Tk7N3rxuGG565u14JMDQ arBkX/6fZC2zwU X-Received: by 2002:a17:906:ee8d:b0:b73:572d:3b07 with SMTP id a640c23a62f3a-b885accd55bmr187411866b.28.1769162741297; Fri, 23 Jan 2026 02:05:41 -0800 (PST) Received: from NB-6746.. ([188.243.183.148]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-b885b75d669sm83079366b.51.2026.01.23.02.05.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Jan 2026 02:05:40 -0800 (PST) From: Artem Shimko To: andi.shyti@kernel.org, p.zabel@pengutronix.de, mika.westerberg@linux.intel.com, andriy.shevchenko@linux.intel.com, jsd@semihalf.com Cc: Artem Shimko , linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v5 0/2] i2c: designware-platdrv: simplify reset control and error handling Date: Fri, 23 Jan 2026 13:05:34 +0300 Message-ID: <20260123100537.1429497-1-a.shimko.dev@gmail.com> X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Hello maintainers and reviewers, This series refactors the DesignWare platform I2C driver to simplify reset control management and improve error handling: Patch 1 replaces the manual reset control acquisition and deassertion with devm_reset_control_get_optional_exclusive_deasserted(), which combines both operations in a single call and leverages automatic resource management. Patch 2 follows up by refactoring the probe error handling to eliminate goto statements in favor of direct returns with dev_err_probe(), resulting in cleaner and more linear control flow. Both patches maintain functional equivalence while improving code readability and maintainability. Regards, artem Artem Shimko (2): i2c: designware-platdrv: simplify reset control i2c: designware-platdrv: refactor error handling and simplify cleanup drivers/i2c/busses/i2c-designware-platdrv.c | 41 +++++++-------------- 1 file changed, 13 insertions(+), 28 deletions(-) -- 2.43.0