From patchwork Sat Dec 21 14:43:38 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans-Frieder Vogt via B4 Relay X-Patchwork-Id: 13917856 X-Patchwork-Delegate: kuba@kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 25C7C1F37DA for ; Sat, 21 Dec 2024 14:44:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1734792253; cv=none; b=jXLqnwpV6hT1MvpVOJyImaJIroq7rvgT8VCTP+Nw6Lo2ZxNd5MXwHK+Sw1cRlRp6KpK9BogXFAcNS68SmIxgISYgIdYXs2Hy1I8OcgEyMYVEtAx8UFxjvjdyGdY+6Sx0NnRV4rkVB9IHhl/t1Aeq439EbfSWipgCVOt90xj0mG0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1734792253; c=relaxed/simple; bh=yGtVf9WHINr/QEHalRJ7Uv22rtH88YwHQu091/YTx/U=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=fT1VYzsKErE/S2LpOLebYJJyAPYXZKB46sn0aB/n/AtYh0IVSbzI1N1ZmQ+EHUfWJrBX0Io34YuqbCW+fPyuHG13vzvmgh3o8nz1/H/XsxhOS9kdfzdDZdau6aBOlBTdVeNChYaa4mNkw3dYed3OoHMIVgRd1UOJ9hlZAvqR0h8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=ep6kqGPu; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="ep6kqGPu" Received: by smtp.kernel.org (Postfix) with ESMTPS id CBFAFC4CED0; Sat, 21 Dec 2024 14:44:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1734792252; bh=yGtVf9WHINr/QEHalRJ7Uv22rtH88YwHQu091/YTx/U=; h=From:Date:Subject:References:In-Reply-To:To:Cc:Reply-To:From; b=ep6kqGPu9WPIlLMXxc87jOK7QhNc8ci2t4bKvgFaICIzVizxnPjlF4XFT3D61NOtE mY4A0gCQph+ip9dxZ/RX7U/7/6pVW1eC018dMn74moGfR1v65sLNCSj+FsPouLezNC 7KEdUzGtK4KwvUmVj4Be1tbqZGLDvOX7cSk9BjDdFsyE70hax4ftwyCH79C+gYI2IR yMIkvaSPJGsZiMH8PRzV7o9cih5qaTBxKwL0EAymFVxr2dMs8xDF2BvD/rPqhl6v+q Aw22TLYekUYL6hQZQffTLpVeLxyEEycA1Yz9ZgmiMPnZT5G+suZWRjfTFXMZ7x1GZt WdxEanHViwGMQ== Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id BEB13E7718D; Sat, 21 Dec 2024 14:44:12 +0000 (UTC) From: Hans-Frieder Vogt via B4 Relay Date: Sat, 21 Dec 2024 15:43:38 +0100 Subject: [PATCH net-next v4 3/7] net: phy: aquantia: search for firmware-name in fwnode Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20241221-tn9510-v3a-v4-3-dafff89ba7a7@gmx.net> References: <20241221-tn9510-v3a-v4-0-dafff89ba7a7@gmx.net> In-Reply-To: <20241221-tn9510-v3a-v4-0-dafff89ba7a7@gmx.net> To: Andrew Lunn , Heiner Kallweit , Russell King , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , FUJITA Tomonori , Andrew Lunn Cc: netdev@vger.kernel.org, Hans-Frieder Vogt X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1734792250; l=1169; i=hfdevel@gmx.net; s=20240915; h=from:subject:message-id; bh=40SclZxZfaIibb8b2Umar4DKAcff6S5FO3NkYM6fpnI=; b=2DmBZvW8/iDNPjkRTiJBQP8SH4M4qtFAvPm3MM65m0XOl5Ot/rJbyRS52KP/G1Mo74ok6Cqxr AZHygcGOtx/BP301FXTgy5gjjnzvdp13dMPCDp197A/3CdTQaWjUdtq X-Developer-Key: i=hfdevel@gmx.net; a=ed25519; pk=s3DJ3DFe6BJDRAcnd7VGvvwPXcLgV8mrfbpt8B9coRc= X-Endpoint-Received: by B4 Relay for hfdevel@gmx.net/20240915 with auth_id=209 X-Original-From: Hans-Frieder Vogt Reply-To: hfdevel@gmx.net X-Patchwork-Delegate: kuba@kernel.org From: Hans-Frieder Vogt Allow the firmware name of an Aquantia PHY alternatively be provided by the property "firmware-name" of a swnode. This software node may be provided by the MAC or MDIO driver. Signed-off-by: Hans-Frieder Vogt Reviewed-by: Andrew Lunn --- drivers/net/phy/aquantia/aquantia_firmware.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/net/phy/aquantia/aquantia_firmware.c b/drivers/net/phy/aquantia/aquantia_firmware.c index dab3af80593f51ff6dc670dfb54ae358c2458c40..bbbcc9736b00e1cfa193f4398889a4c172ca27a4 100644 --- a/drivers/net/phy/aquantia/aquantia_firmware.c +++ b/drivers/net/phy/aquantia/aquantia_firmware.c @@ -328,10 +328,11 @@ static int aqr_firmware_load_fs(struct phy_device *phydev) const char *fw_name; int ret; - ret = of_property_read_string(dev->of_node, "firmware-name", - &fw_name); - if (ret) + ret = device_property_read_string(dev, "firmware-name", &fw_name); + if (ret) { + phydev_err(phydev, "failed to read firmware-name: %d\n", ret); return ret; + } ret = request_firmware(&fw, fw_name, dev); if (ret) {