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 4F1A035C1BF for ; Mon, 23 Feb 2026 10:06:53 +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=1771841215; cv=none; b=dIHu6U6sTFmk6Y/C3ad1lPPO+2YE4bRusu/WnB2nY3Yp9uD3TtO1Cqjv9CTBlvieVdOSf7RYwrURoSpHr50bRnAAYzsfnxL3kBlrriUPGzwUdVXO+h4f0hZJvCN5xmyLIjH+4629fXNGAeUxMWtGYmhGvCrgMj3I0jDQvkF35K0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771841215; c=relaxed/simple; bh=5iIYYjHPNq5p0+kaAniTf6969MKCe1l8k6ebZsiec14=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=ghEVjJIC20vywI/sM2Y2gNYrBVZmGtgpl7oAiKrBQwnqgnAKs0mKUcm6fUr6ijacR19PJiDfM6hkEYv/tO9a9vYv/uy0LVllBoUEmAodKQzj9WmZYYHBbehwj8ifjnsCTSRz/S9sY/QvLjA6Z76b+oWBD+mfeg5/M2VDDlT0uG0= 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=IVBNg/7L; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=MhuGI7jm; 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="IVBNg/7L"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="MhuGI7jm" Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 61N0TdVi1921214 for ; Mon, 23 Feb 2026 10:06:52 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= g2tOlerWd4OhWfCIFMbquts3zgLhKIvbzSHxskK9mKQ=; b=IVBNg/7LpNuPIi90 lWTWC5XTxPA2FMpSWy+CHfZaqQzNSJ1lyvA1tHymG8NTfLBCdO66sUU9DbXc3oaG RR6D6qF0vNsFdIvyK7D1tw1xqy3V023NKvFczTKeVxEoI2No8iTC/6GDydGJBgrx YLpF235vAfziSZ6DKL+C3SLil8y977D/IByRTRCOOKWciX/75HGHnevU2/RvBtwj cS/M0ZfcCnmyoRgYltcfbX0S22dBacdfHho4n+ALPS/IC+RTeFAaHL4rmu6Gu6CW TXVoffHN9sXHt1Alfnd55x8e0OKwhtSn5rycbkW0Gy0ANyLsvGY3OG/RZrR22E5K 2yrWkw== Received: from mail-qk1-f198.google.com (mail-qk1-f198.google.com [209.85.222.198]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4cf5u9v9sr-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Mon, 23 Feb 2026 10:06:51 +0000 (GMT) Received: by mail-qk1-f198.google.com with SMTP id af79cd13be357-8c711251ac5so3609339685a.1 for ; Mon, 23 Feb 2026 02:06:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1771841211; x=1772446011; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=g2tOlerWd4OhWfCIFMbquts3zgLhKIvbzSHxskK9mKQ=; b=MhuGI7jmuQuotoaBkBxHUbiWzrGNAb4jEqiYr1WLEwsR8S7pHP7tLIG6Fxv5eko7V1 1s7rfZbHJkBMhTaRbaI5vzAE3CgnHosge47KCW0yNBwHdNfRLbRCnWedVox3b6G+nNEh ttc2BznUrQowu3N5e/U2+aa26hp9PR0kFDrIqd25NuKUHYzbgeHHsfpekIjVx3ff3clU LdF5EnSzPk7WTxxtYJxfU63IlkSxXDaqNCwjJcp963JskJ4SdxEd3fZWa+u7jmbKyTxF rnt6Kabiq46QPUNjCDNDKAZIycVmHR9RQDnBEUxyNUWXyp2j9ZwLzUJ/gVNmspORmyYw N7aA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1771841211; x=1772446011; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=g2tOlerWd4OhWfCIFMbquts3zgLhKIvbzSHxskK9mKQ=; b=MMCexAsmtRCSW6i4v3jem9sYiU/VboZvaOhLYz7tLL7TbCYftZUI8qPrT9u4Hi74vU SzRd/9zSisKpLBSKQx2DaOTr77dVuOOUs7Sk2R0za0/tWHBx8DW5mYi5F+khzisGDcjw gZBAhrwJBU7blOI0zWqqTMUMBjXcF8H6mOBRE0MMN2tdcestKWNRgZL4wKy+EsGFDmBM 4ZYcFgSEWgjHkOm0zKdSHzu4vdaHP6Pftg9ZkjClUzSN+puGdQPiUpAMouytkg90r8cq fPH2Ol4fyGTXwgWfaQFToidjo7NIhZbaMonH1xNvEAfIngf9zfRCsERiAY2KtxbDCI9S UqZw== X-Gm-Message-State: AOJu0Yx3ywuZ1next3nxs24gQYOZuMY1bP4IAT/Z+GQBSYDryX+L81tW Rq07PtTbZthaJobY715ks2N/IsC/yHicmn93/CvPptvnKbgbK7r5xPXqCPcLVJGkogqWE8DU2Rd VMpsxhPM0QF0Yi1JR0hToFd0VhzZ6hJFxJjWtOsDjd9YHZro0zZnNgzJ1l9XHEyTtchrRfvCVox I= X-Gm-Gg: AZuq6aKkbSj2HtT3s9Je6C1iX9Gpk2Gl33C1NccatMLbg8BC5QfoBUVtLzI/DaMrXse hAefaY8Jme/i4Wpgw8dbgAuu9B2WlrsJr1qGhOBrritbMon2Mg7PeqDxtn7pmBy02YOUaFhgtxn 4UBTpySkJCurBdJTUTpBd33MKhrKLZsygJ6DSmi55BADQ1H5pDq/fxE4kRzhsGQr93mX3a66XFK fbYuvx9EVYPBcX4TvKcr72AiODjARsORg9omsWi6IaR2CfTxwz4sqA9U+zy3LTAAuCIuKem9zNV HkG18CLrplp9gNbGBN4Wuev+hqAqqmXaW8yz3Z2UvOHGPBTEU8dA4DLR1ELdropEuUYVhUp0rol 9XVQ+DNKnZz9HuFavBwZv5x7vlaJix6FajhJVfTRA0aQtGjtBPGBy X-Received: by 2002:a05:620a:4542:b0:8cb:49e8:d465 with SMTP id af79cd13be357-8cb8c9cdf1amr1003567285a.1.1771841211178; Mon, 23 Feb 2026 02:06:51 -0800 (PST) X-Received: by 2002:a05:620a:4542:b0:8cb:49e8:d465 with SMTP id af79cd13be357-8cb8c9cdf1amr1003564585a.1.1771841210677; Mon, 23 Feb 2026 02:06:50 -0800 (PST) Received: from brgl-qcom.local ([2a01:cb1d:dc:7e00:bd71:422c:5e83:8b37]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-43970d54760sm18288885f8f.35.2026.02.23.02.06.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Feb 2026 02:06:50 -0800 (PST) From: Bartosz Golaszewski Date: Mon, 23 Feb 2026 11:06:25 +0100 Subject: [PATCH v2 12/14] reset: convert the core API to using firmware nodes Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20260223-reset-core-refactor-v2-12-5e5a7289190c@oss.qualcomm.com> References: <20260223-reset-core-refactor-v2-0-5e5a7289190c@oss.qualcomm.com> In-Reply-To: <20260223-reset-core-refactor-v2-0-5e5a7289190c@oss.qualcomm.com> To: Krzysztof Kozlowski , Philipp Zabel Cc: linux-kernel@vger.kernel.org, Bartosz Golaszewski X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=11270; i=bartosz.golaszewski@oss.qualcomm.com; h=from:subject:message-id; bh=5iIYYjHPNq5p0+kaAniTf6969MKCe1l8k6ebZsiec14=; b=owEBbQKS/ZANAwAKAQWdLsv/NoTDAcsmYgBpnCaqmYmqTdgwEuwu9Z4M6CLq1UYsnL20VX4jr NTcCcGNMPWJAjMEAAEKAB0WIQSR5RMt5bVGHXuiZfwFnS7L/zaEwwUCaZwmqgAKCRAFnS7L/zaE w20xD/0TGHwWYLZrD5gkwti7WAEGz4+UyF+8J0EJBXzGdP3+/N9K4nGPmZGWRkturA89yR4OZkG P/MMG/5ABb7R0Kw/F/B3RDF7CHwDoW0FUIRBZHZTSfgeRhSsBWUcr+QClKQzOyGJOKnDTk1SB+h cvjEfNriDJ9C9B1nrSWpIC49RDfdXZ0+lOpHlQZNDQa95OINAaUJWFUOIwZgH8+eZDPuzSdF37V OeycdTll0r0iI0WeXGPO5UE6WLAS9R5XC9Pjf2HrQAvpK+P/v9mEy50iSsSKe3Dini6itjw0df4 ZXWkIN2oJxwtqg1hqn+DiRC1uIHhXINcgPNpTBmVPSgjQUf0giC29Q/3XnWlCXFeWAwcjdUP4+F LuL9QqkenYUaoLlRosnjl0NN+MhvPwc9pN6uwcUAfqQka+3vaeQC8h80g1Xc+qBJfTN9nAPjUOg u/b/IVlbomV2mIHK44hEeCLzhmIt8DjBFwUGhFafLyg5LTjjorwTcukL38LvigsEC0IZlPpaM0t FbwkJnBXs4PYErXU8nPnDgywDW064b0s0gEvicFFzYvJVz1K2wfuEewxXiaYWCWnPjbljZyS4N6 ytNIFhvzACeO35Ov69D34Vmw1fK4fY4C33X6ba9i4C6ssQ36szZf8MQ7tAnvdOQiwGigMsyRb20 Nhokme1OW+PqeUA== X-Developer-Key: i=bartosz.golaszewski@oss.qualcomm.com; a=openpgp; fpr=169DEB6C0BC3C46013D2C79F11A72EA01471D772 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwMjIzMDA4NiBTYWx0ZWRfX1NOFCEnwIM5g K492jI68tN7MEWwe4OzsT81eTuRXFgI7nl4bwct64EYPgH9Kwk6CYGQp2X2VhHTSmDztV+aTYjg PAHkYKQ2Mctqd71J1wvli5k7zhDj5VA/5qN7g0RTID/ViyjDUz8c729Zuor9gkz3KYPnX/DDarZ Ns67oE8yH5n3jplF6vch8FJ/igYSn/L5f7fsyqF+w6D2RjFWZrUjiMi//kP41BxQKtXRMdfCm3C W9IgLekprvBT4vGZdl6shFZCHTxfbrYlN9KsLcozKH1yFle/idZuMinV++FdEM+5pUjTo4iSSnY pl086heIH9CTPeLtmSbf0RGWfYru7ogsySTJQ5flrcYCPNhLJ160VVRjLFvFkjB225CWGyK7hvz NpoMdPujBpKm9hcjmXNvoONx3oYAH1BhRj5Rg/d7jUj9nniBZNbwoqKs0Z58slY9iaHDA/0w9r9 p5CIeNrX8cDuuFISv2g== X-Proofpoint-GUID: wWfmMtFGLavENmQvH9bRckf3ZQoBf3Oj X-Proofpoint-ORIG-GUID: wWfmMtFGLavENmQvH9bRckf3ZQoBf3Oj X-Authority-Analysis: v=2.4 cv=RpDI7SmK c=1 sm=1 tr=0 ts=699c26bc cx=c_pps a=qKBjSQ1v91RyAK45QCPf5w==:117 a=xqWC_Br6kY4A:10 a=IkcTkHD0fZMA:10 a=HzLeVaNsDn8A:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=3WHJM1ZQz_JShphwDgj5:22 a=EUspDBNiAAAA:8 a=jmokhBh6uMhyoXQoT5cA:9 a=QEXdDO2ut3YA:10 a=NFOGd7dJGGMPyQGDc5-O: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-23_02,2026-02-20_04,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 adultscore=0 suspectscore=0 clxscore=1015 spamscore=0 bulkscore=0 impostorscore=0 phishscore=0 lowpriorityscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2602130000 definitions=main-2602230086 In order to simplify the commit converting the internals of reset core to using firmware nodes, first convert the user-facing API. Modify the signature of the core consumer functions but leave the specialized wrappers as is to avoid modifying users for now. No functional change intended. Signed-off-by: Bartosz Golaszewski --- drivers/reset/core.c | 33 ++++++++++++++++++--------------- include/linux/reset.h | 43 ++++++++++++++++++++++++++++--------------- 2 files changed, 46 insertions(+), 30 deletions(-) diff --git a/drivers/reset/core.c b/drivers/reset/core.c index b215f5a4aab3f7b625b35d183068633c9c581067..1ac68371b77101b18db5a16c6471cfffee0dce7c 100644 --- a/drivers/reset/core.c +++ b/drivers/reset/core.c @@ -1047,7 +1047,7 @@ static int __reset_add_reset_gpio_device(struct device_node *np, rgpio_dev->of_args = *args; /* * We keep the device_node reference, but of_args.np is put at the end - * of __of_reset_control_get(), so get it one more time. + * of __fwnode_reset_control_get(), so get it one more time. * Hold reference as long as rgpio_dev memory is valid. */ of_node_get(rgpio_dev->of_args.np); @@ -1101,18 +1101,19 @@ static struct reset_controller_dev *__reset_find_rcdev(const struct of_phandle_a } struct reset_control * -__of_reset_control_get(struct device_node *node, const char *id, int index, - enum reset_control_flags flags) +__fwnode_reset_control_get(struct fwnode_handle *fwnode, const char *id, int index, + enum reset_control_flags flags) { bool optional = flags & RESET_CONTROL_FLAGS_BIT_OPTIONAL; bool gpio_fallback = false; + struct device_node *node = to_of_node(fwnode); struct reset_control *rstc = ERR_PTR(-EINVAL); struct reset_controller_dev *rcdev; struct of_phandle_args args; int rstc_id; int ret; - if (!node) + if (!fwnode) return ERR_PTR(-EINVAL); if (id) { @@ -1179,7 +1180,7 @@ __of_reset_control_get(struct device_node *node, const char *id, int index, return rstc; } -EXPORT_SYMBOL_GPL(__of_reset_control_get); +EXPORT_SYMBOL_GPL(__fwnode_reset_control_get); struct reset_control *__reset_control_get(struct device *dev, const char *id, int index, enum reset_control_flags flags) @@ -1187,12 +1188,13 @@ struct reset_control *__reset_control_get(struct device *dev, const char *id, bool shared = flags & RESET_CONTROL_FLAGS_BIT_SHARED; bool acquired = flags & RESET_CONTROL_FLAGS_BIT_ACQUIRED; bool optional = flags & RESET_CONTROL_FLAGS_BIT_OPTIONAL; + struct fwnode_handle *fwnode = dev_fwnode(dev); if (WARN_ON(shared && acquired)) return ERR_PTR(-EINVAL); - if (dev->of_node) - return __of_reset_control_get(dev->of_node, id, index, flags); + if (fwnode) + return __fwnode_reset_control_get(fwnode, id, index, flags); return optional ? NULL : ERR_PTR(-ENOENT); } @@ -1454,23 +1456,24 @@ static int fwnode_reset_control_get_count(struct fwnode_handle *fwnode) } /** - * of_reset_control_array_get - Get a list of reset controls using - * device node. + * fwnode_reset_control_array_get - Get a list of reset controls using + * a firmware node. * - * @np: device node for the device that requests the reset controls array + * @fwnode: firmware node for the device that requests the reset controls array * @flags: whether reset controls are shared, optional, acquired * * Returns pointer to allocated reset_control on success or error on failure */ struct reset_control * -of_reset_control_array_get(struct device_node *np, enum reset_control_flags flags) +fwnode_reset_control_array_get(struct fwnode_handle *fwnode, + enum reset_control_flags flags) { bool optional = flags & RESET_CONTROL_FLAGS_BIT_OPTIONAL; struct reset_control_array *resets; struct reset_control *rstc; int num, i; - num = fwnode_reset_control_get_count(of_fwnode_handle(np)); + num = fwnode_reset_control_get_count(fwnode); if (num < 0) return optional ? NULL : ERR_PTR(num); @@ -1480,7 +1483,7 @@ of_reset_control_array_get(struct device_node *np, enum reset_control_flags flag resets->num_rstcs = num; for (i = 0; i < num; i++) { - rstc = __of_reset_control_get(np, NULL, i, flags); + rstc = __fwnode_reset_control_get(fwnode, NULL, i, flags); if (IS_ERR(rstc)) goto err_rst; resets->rstc[i] = rstc; @@ -1497,7 +1500,7 @@ of_reset_control_array_get(struct device_node *np, enum reset_control_flags flag return rstc; } -EXPORT_SYMBOL_GPL(of_reset_control_array_get); +EXPORT_SYMBOL_GPL(fwnode_reset_control_array_get); /** * devm_reset_control_array_get - Resource managed reset control array get @@ -1521,7 +1524,7 @@ devm_reset_control_array_get(struct device *dev, enum reset_control_flags flags) if (!ptr) return ERR_PTR(-ENOMEM); - rstc = of_reset_control_array_get(dev->of_node, flags); + rstc = fwnode_reset_control_array_get(dev_fwnode(dev), flags); if (IS_ERR_OR_NULL(rstc)) { devres_free(ptr); return rstc; diff --git a/include/linux/reset.h b/include/linux/reset.h index 44f9e3415f92c9d7591b898cdb4bf7f05f2b0568..9c391cf0c82298a06a4d84eebd293864ef8c48da 100644 --- a/include/linux/reset.h +++ b/include/linux/reset.h @@ -5,10 +5,12 @@ #include #include #include +#include #include struct device; struct device_node; +struct fwnode_handle; struct reset_control; /** @@ -84,7 +86,7 @@ int reset_control_bulk_deassert(int num_rstcs, struct reset_control_bulk_data *r int reset_control_bulk_acquire(int num_rstcs, struct reset_control_bulk_data *rstcs); void reset_control_bulk_release(int num_rstcs, struct reset_control_bulk_data *rstcs); -struct reset_control *__of_reset_control_get(struct device_node *node, +struct reset_control *__fwnode_reset_control_get(struct fwnode_handle *fwnode, const char *id, int index, enum reset_control_flags flags); struct reset_control *__reset_control_get(struct device *dev, const char *id, int index, enum reset_control_flags flags); @@ -103,7 +105,8 @@ int __devm_reset_control_bulk_get(struct device *dev, int num_rstcs, struct reset_control *devm_reset_control_array_get(struct device *dev, enum reset_control_flags flags); -struct reset_control *of_reset_control_array_get(struct device_node *np, enum reset_control_flags); +struct reset_control *fwnode_reset_control_array_get(struct fwnode_handle *fwnode, + enum reset_control_flags); int reset_control_get_count(struct device *dev); @@ -152,8 +155,8 @@ static inline int __device_reset(struct device *dev, bool optional) return optional ? 0 : -ENOTSUPP; } -static inline struct reset_control *__of_reset_control_get( - struct device_node *node, +static inline struct reset_control *__fwnode_reset_control_get( + struct fwnode_handle *fwnode, const char *id, int index, enum reset_control_flags flags) { bool optional = flags & RESET_CONTROL_FLAGS_BIT_OPTIONAL; @@ -242,7 +245,7 @@ devm_reset_control_array_get(struct device *dev, enum reset_control_flags flags) } static inline struct reset_control * -of_reset_control_array_get(struct device_node *np, enum reset_control_flags flags) +fwnode_reset_control_array_get(struct fwnode_handle *fwnode, enum reset_control_flags flags) { bool optional = flags & RESET_CONTROL_FLAGS_BIT_OPTIONAL; @@ -500,7 +503,8 @@ reset_control_bulk_get_optional_shared(struct device *dev, int num_rstcs, static inline struct reset_control *of_reset_control_get_exclusive( struct device_node *node, const char *id) { - return __of_reset_control_get(node, id, 0, RESET_CONTROL_EXCLUSIVE); + return __fwnode_reset_control_get(of_fwnode_handle(node), id, 0, + RESET_CONTROL_EXCLUSIVE); } /** @@ -520,7 +524,8 @@ static inline struct reset_control *of_reset_control_get_exclusive( static inline struct reset_control *of_reset_control_get_optional_exclusive( struct device_node *node, const char *id) { - return __of_reset_control_get(node, id, 0, RESET_CONTROL_OPTIONAL_EXCLUSIVE); + return __fwnode_reset_control_get(of_fwnode_handle(node), id, 0, + RESET_CONTROL_OPTIONAL_EXCLUSIVE); } /** @@ -545,7 +550,8 @@ static inline struct reset_control *of_reset_control_get_optional_exclusive( static inline struct reset_control *of_reset_control_get_shared( struct device_node *node, const char *id) { - return __of_reset_control_get(node, id, 0, RESET_CONTROL_SHARED); + return __fwnode_reset_control_get(of_fwnode_handle(node), id, 0, + RESET_CONTROL_SHARED); } /** @@ -562,7 +568,8 @@ static inline struct reset_control *of_reset_control_get_shared( static inline struct reset_control *of_reset_control_get_exclusive_by_index( struct device_node *node, int index) { - return __of_reset_control_get(node, NULL, index, RESET_CONTROL_EXCLUSIVE); + return __fwnode_reset_control_get(of_fwnode_handle(node), NULL, index, + RESET_CONTROL_EXCLUSIVE); } /** @@ -590,7 +597,8 @@ static inline struct reset_control *of_reset_control_get_exclusive_by_index( static inline struct reset_control *of_reset_control_get_shared_by_index( struct device_node *node, int index) { - return __of_reset_control_get(node, NULL, index, RESET_CONTROL_SHARED); + return __fwnode_reset_control_get(of_fwnode_handle(node), NULL, index, + RESET_CONTROL_SHARED); } /** @@ -1032,30 +1040,35 @@ devm_reset_control_array_get_optional_shared(struct device *dev) static inline struct reset_control * of_reset_control_array_get_exclusive(struct device_node *node) { - return of_reset_control_array_get(node, RESET_CONTROL_EXCLUSIVE); + return fwnode_reset_control_array_get(of_fwnode_handle(node), + RESET_CONTROL_EXCLUSIVE); } static inline struct reset_control * of_reset_control_array_get_exclusive_released(struct device_node *node) { - return of_reset_control_array_get(node, RESET_CONTROL_EXCLUSIVE_RELEASED); + return fwnode_reset_control_array_get(of_fwnode_handle(node), + RESET_CONTROL_EXCLUSIVE_RELEASED); } static inline struct reset_control * of_reset_control_array_get_shared(struct device_node *node) { - return of_reset_control_array_get(node, RESET_CONTROL_SHARED); + return fwnode_reset_control_array_get(of_fwnode_handle(node), + RESET_CONTROL_SHARED); } static inline struct reset_control * of_reset_control_array_get_optional_exclusive(struct device_node *node) { - return of_reset_control_array_get(node, RESET_CONTROL_OPTIONAL_EXCLUSIVE); + return fwnode_reset_control_array_get(of_fwnode_handle(node), + RESET_CONTROL_OPTIONAL_EXCLUSIVE); } static inline struct reset_control * of_reset_control_array_get_optional_shared(struct device_node *node) { - return of_reset_control_array_get(node, RESET_CONTROL_OPTIONAL_SHARED); + return fwnode_reset_control_array_get(of_fwnode_handle(node), + RESET_CONTROL_OPTIONAL_SHARED); } #endif -- 2.47.3