Message ID | 9902bab7b9f99885e9d02c7bd4b51717f58cf894.1449056178.git.michal.simek@xilinx.com |
---|---|
State | Superseded |
Headers | show
Return-Path: <u-boot-bounces@lists.denx.de> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 47C201402DE for <incoming@patchwork.ozlabs.org>; Wed, 2 Dec 2015 22:37:27 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=monstr-eu.20150623.gappssmtp.com header.i=@monstr-eu.20150623.gappssmtp.com header.b=IiA2MRbe; dkim-atps=neutral Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 884444BA7D; Wed, 2 Dec 2015 12:37:11 +0100 (CET) X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XH6do7HejLxR; Wed, 2 Dec 2015 12:37:11 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 2191D4BA7F; Wed, 2 Dec 2015 12:36:48 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 12F664BA29 for <u-boot@lists.denx.de>; Wed, 2 Dec 2015 12:36:45 +0100 (CET) X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6JXNQnACXqMB for <u-boot@lists.denx.de>; Wed, 2 Dec 2015 12:36:44 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-wm0-f41.google.com (mail-wm0-f41.google.com [74.125.82.41]) by theia.denx.de (Postfix) with ESMTPS id 53C134BA4B for <u-boot@lists.denx.de>; Wed, 2 Dec 2015 12:36:37 +0100 (CET) Received: by wmvv187 with SMTP id v187so250343420wmv.1 for <u-boot@lists.denx.de>; Wed, 02 Dec 2015 03:36:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monstr-eu.20150623.gappssmtp.com; s=20150623; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=BrrvIVSJOXLybBm7IIr3eUAQ0At31xHLeZ+PNVrlS/o=; b=IiA2MRbeNJDpqbv64FX42Ae/t/Q3bG9EdHF8Bheqs9EeGNWYkv7FQNBOz3R5xrfOwF PBkwZAZGss9iNg/r/Uu8Y/3J6g8XVMkFvVJhLDfjAqMUvfuHVHs4f5sbrSd/7jwcJQTQ WTbAcYhk3czlUGqCq5Y5IrwfnAtqm8oWPBu/HLgclLmy3C9awb7o7ErAJAtjYGVAngvz Gn345aGL9Fgagjl6tIpwbkl3e1WZ9zgvrCPncVTJyujyIQL0sniZrrjiAhxr9ag9ZPwr gOpJNdKMVwAwZBET3AaO+qhRwqq9HVlpE9OfSD3To1v6vfBm5as2YhpZ6tPYD8V1NLYI FmDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:in-reply-to:references; bh=BrrvIVSJOXLybBm7IIr3eUAQ0At31xHLeZ+PNVrlS/o=; b=mvXsnh/PONGNJOSWRXwCKevn2x6tDTDai/aCTe+7VP/W51WQJS3hM5Qp6r4RoNfEsF D1OHvggIDr+pS08tFpep1vSGg5XE9R0TNma8nzZX/G67yQgyhPEqCm0s+E1vvPqjn/7/ BqsIUC6mgbn0nyjEWPpopIBuR7mJO3C7xNnWF4lTi09V567RlVlQdg25e4m5VRBxhNZ/ yWyHfL9aopAuZ5JyKrcOWllVI8p0KgF4kEcw6r5zOUliUlUd7l0aT1ykikjpAhvOXwTe nuOZT6crdbSY8I77M50QD336HMk5OS/c089DXDA1erCn/Ti70p0t5BIN82nwQ94+/Z0c lTvQ== X-Gm-Message-State: ALoCoQnJ/A4rarLaWxvXAgBaYhi72kUj18zDnMH7BHjqHYI03N+QbHAkAV4G4qT1Ave8QisiXYBp X-Received: by 10.28.103.84 with SMTP id b81mr4977101wmc.39.1449056197059; Wed, 02 Dec 2015 03:36:37 -0800 (PST) Received: from localhost (nat-35.starnet.cz. [178.255.168.35]) by smtp.gmail.com with ESMTPSA id c13sm30245304wmd.14.2015.12.02.03.36.36 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Wed, 02 Dec 2015 03:36:36 -0800 (PST) From: Michal Simek <michal.simek@xilinx.com> To: u-boot@lists.denx.de Date: Wed, 2 Dec 2015 12:36:17 +0100 Message-Id: <9902bab7b9f99885e9d02c7bd4b51717f58cf894.1449056178.git.michal.simek@xilinx.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <3846048879467c3510abb54b930cdc05772d469e.1449056178.git.michal.simek@xilinx.com> References: <3846048879467c3510abb54b930cdc05772d469e.1449056178.git.michal.simek@xilinx.com> In-Reply-To: <3846048879467c3510abb54b930cdc05772d469e.1449056178.git.michal.simek@xilinx.com> References: <3846048879467c3510abb54b930cdc05772d469e.1449056178.git.michal.simek@xilinx.com> Cc: Joe Hershberger <joe.hershberger@ni.com> Subject: [U-Boot] [PATCH v2 08/14] net: gem: Check if priv->phydev is valid X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.15 Precedence: list List-Id: U-Boot discussion <u-boot.lists.denx.de> List-Unsubscribe: <http://lists.denx.de/mailman/options/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=unsubscribe> List-Archive: <http://lists.denx.de/pipermail/u-boot/> List-Post: <mailto:u-boot@lists.denx.de> List-Help: <mailto:u-boot-request@lists.denx.de?subject=help> List-Subscribe: <http://lists.denx.de/mailman/listinfo/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=subscribe> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" <u-boot-bounces@lists.denx.de> |
diff --git a/drivers/net/zynq_gem.c b/drivers/net/zynq_gem.c index 86bb75905071..d5540ec2155c 100644 --- a/drivers/net/zynq_gem.c +++ b/drivers/net/zynq_gem.c @@ -329,6 +329,8 @@ static int zynq_phy_init(struct eth_device *dev) priv->phydev = phy_connect(priv->bus, priv->phyaddr, dev, priv->interface); + if (!priv->phydev) + return -ENODEV; priv->phydev->supported = supported | ADVERTISED_Pause | ADVERTISED_Asym_Pause;
Check return value. Signed-off-by: Michal Simek <michal.simek@xilinx.com> --- Changes in v2: None drivers/net/zynq_gem.c | 2 ++ 1 file changed, 2 insertions(+)