From mboxrd@z Thu Jan 1 00:00:00 1970 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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DBA73C4332F for ; Wed, 12 Oct 2022 20:00:44 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4E2B184F26; Wed, 12 Oct 2022 21:59:17 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=suse.de header.i=@suse.de header.b="XGh6Ww9Z"; dkim=permerror (0-bit key) header.d=suse.de header.i=@suse.de header.b="UiXGq9ui"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A5B4684E95; Wed, 12 Oct 2022 21:58:52 +0200 (CEST) Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 1023C84F19 for ; Wed, 12 Oct 2022 21:58:31 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=msuchanek@suse.de Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out2.suse.de (Postfix) with ESMTP id AE79C1FF6D; Wed, 12 Oct 2022 19:58:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1665604710; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=AqJ0req/s/kWtgLtnS03h+SiWZzn0ijg+LzNs+fysMs=; b=XGh6Ww9Z85teMm/Anct1lutA2oz/RIkuPHYPFiMUfG7Wddab1pS5Z1lDPii6lJAoxV8tXw v5GpHmVdH8a8WpUqLJI0jbeSZsE/R5AH63Zl1HtpyxAuICPrarlpMTrjYTP2WFRHgyOye0 SznJPixSZz+V5T3Rb1bn/QIvwTTHJXw= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1665604710; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=AqJ0req/s/kWtgLtnS03h+SiWZzn0ijg+LzNs+fysMs=; b=UiXGq9uibdgr4kkB9XViBRMdj+raWJvC6TWxUz0/yCZVWUpYbRple6uyPIymFvMumQSOeL K+XyqM1NZvU8jxBQ== Received: from naga.suse.cz (unknown [10.100.224.114]) by relay2.suse.de (Postfix) with ESMTP id 8B6BD2C15A; Wed, 12 Oct 2022 19:58:30 +0000 (UTC) From: Michal Suchanek To: u-boot@lists.denx.de Cc: Michal Suchanek , Eugen Hristev , Simon Glass Subject: [PATCH v6 11/20] dm: treewide: Use uclass_next_device_err when accessing second device Date: Wed, 12 Oct 2022 21:58:00 +0200 Message-Id: X-Mailer: git-send-email 2.37.3 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean There are a couple users of uclass_next_device return value that get the first device by other means and use uclass_next_device assuming the following device in the uclass is related to the first one. Use uclass_next_device_err because the return value from uclass_next_device will be removed in a later patch. Signed-off-by: Michal Suchanek Reviewed-by: Simon Glass --- arch/arm/mach-k3/j721s2_init.c | 2 +- board/atmel/common/mac_eeprom.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-k3/j721s2_init.c b/arch/arm/mach-k3/j721s2_init.c index 12da8136f9..dd0c7ba18f 100644 --- a/arch/arm/mach-k3/j721s2_init.c +++ b/arch/arm/mach-k3/j721s2_init.c @@ -164,7 +164,7 @@ void board_init_f(ulong dummy) if (ret) panic("DRAM 0 init failed: %d\n", ret); - ret = uclass_next_device(&dev); + ret = uclass_next_device_err(&dev); if (ret) panic("DRAM 1 init failed: %d\n", ret); } diff --git a/board/atmel/common/mac_eeprom.c b/board/atmel/common/mac_eeprom.c index a723ba723c..4606008c69 100644 --- a/board/atmel/common/mac_eeprom.c +++ b/board/atmel/common/mac_eeprom.c @@ -56,7 +56,7 @@ int at91_set_eth1addr(int offset) return ret; /* attempt to obtain a second eeprom device */ - ret = uclass_next_device(&dev); + ret = uclass_next_device_err(&dev); if (ret) return ret; -- 2.37.3