Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1760025AbdLRSWN (ORCPT ); Mon, 18 Dec 2017 13:22:13 -0500 Received: from shards.monkeyblade.net ([184.105.139.130]:39010 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758521AbdLRSWL (ORCPT ); Mon, 18 Dec 2017 13:22:11 -0500 Date: Mon, 18 Dec 2017 13:22:09 -0500 (EST) Message-Id: <20171218.132209.907707924433000658.davem@davemloft.net> To: hpuranik@codeaurora.org Cc: netdev@vger.kernel.org, linux-kernel@vger.kernel.org, timur@codeaurora.org Subject: Re: [PATCH] net: qcom/emac: Change the order of mac up and sgmii open From: David Miller In-Reply-To: <1513576667-2967-1-git-send-email-hpuranik@codeaurora.org> References: <1513576667-2967-1-git-send-email-hpuranik@codeaurora.org> X-Mailer: Mew version 6.7 on Emacs 25.3 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Mon, 18 Dec 2017 10:22:10 -0800 (PST) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 946 Lines: 22 From: Hemanth Puranik Date: Mon, 18 Dec 2017 11:27:47 +0530 > This patch fixes the order of mac_up and sgmii_open for the > reasons noted below: > > - If open takes more time(if the SGMII block is not responding or > if we want to do some delay based task) in this situation we > will hit NETDEV watchdog > - The main reason : We should signal to upper layers that we are > ready to receive packets "only" when the entire path is initialized > not the other way around, this is followed in the reset path where > we do mac_down, sgmii_reset and mac_up. This also makes the driver > uniform across the reset and open paths. > - In the future there may be need for delay based tasks to be done in > sgmii open which will result in NETDEV watchdog > - As per the documentation the order of init should be sgmii, mac, rings > and DMA > > Signed-off-by: Hemanth Puranik Applied.