From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S966053AbdGTW2s (ORCPT ); Thu, 20 Jul 2017 18:28:48 -0400 Received: from shards.monkeyblade.net ([184.105.139.130]:37166 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S966002AbdGTW2d (ORCPT ); Thu, 20 Jul 2017 18:28:33 -0400 Date: Thu, 20 Jul 2017 15:28:31 -0700 (PDT) Message-Id: <20170720.152831.802536956243282259.davem@davemloft.net> To: grygorii.strashko@ti.com Cc: j-keerthy@ti.com, linux-omap@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, johan@kernel.org, ivan.khoronzhuk@linaro.org, t-kristo@ti.com, nsekhar@ti.com Subject: Re: [PATCH] net: ethernet: ti: cpsw: Push the request_irq function to the end of probe From: David Miller In-Reply-To: <5259f0e7-cc5d-35c9-8f09-94cf7b40f653@ti.com> References: <1500550192-6550-1-git-send-email-j-keerthy@ti.com> <5259f0e7-cc5d-35c9-8f09-94cf7b40f653@ti.com> X-Mailer: Mew version 6.7 on Emacs 25.2 / 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]); Thu, 20 Jul 2017 15:28:32 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Grygorii Strashko Date: Thu, 20 Jul 2017 11:08:09 -0500 > In general patch looks good to me, but it's really unexpected to > receive IRQs while CPSW is probing ;( This is a poor expectation. Boot loaders and other entities can leave the device in any state whatsoever. Furthermore, enabling an IRQ whose handler cannot properly execute without crashing is wrong fundamentally. All data structures and state must be set up properly before the IRQ is requested. Therefore this patch is correct and I will apply it.