Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5794878ybv; Wed, 12 Feb 2020 00:04:32 -0800 (PST) X-Google-Smtp-Source: APXvYqweZLrRNVLS9Qmtef3ghNc4VZCveOp0TkS64uvuLA/alXbQj3enNcAAeq8Nq/tw0AweuCYn X-Received: by 2002:a54:4791:: with SMTP id o17mr5150136oic.70.1581494672529; Wed, 12 Feb 2020 00:04:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581494672; cv=none; d=google.com; s=arc-20160816; b=inlRPtBQ9IEjkJhEgeazWSg4nTL7xov4Af0jKxvYOmPFXV7J+dFAFHCs3E71B4Dn0m yzdfD4OZK498ZPqLDTTxiuAc42EPtgHr8GL8R9Dz6d5tdur+pKtIaCh9K3MFQkAR+pc0 o6RkHYZd5FwfDT6DbsIC+e2yU5KBXSzmTIXNqRzV5WjkxqG7wT2us0brM7lxQrPOlNSq ualoY/9I48FxEHpVvqxDA7G207yyjH1kuRSjdn4N/W++RQkRzQJaa5QgQDaYG2HK8UMc 6BFA1Y0eiLWhVA9ksOcCyOUzqua6LYzq0dEFOPCCB1O15hmTxSMbvfjPbU05wL68Go4i xX4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=ECVgvgHFKNpFfK3tEgc2bceIocAVUdU7DE70DEQvQUU=; b=kFXfXWP/kwM5aWIJVXwqTPAVZz+DEK/v3fiIrkoAJMzZl0h/svYJGs7TpJoPePtJ1i iXvHW5qmsz189wSSVSUJ+ZGACyA0TkCMrldgS7WqwJcsaWUMi+csHZoA71Ro9rrTlV7Y Qec2w80ITJPmQNwWCA+W2NAh4X9U1aY7TgtFzqtjBK4NetTYMwPu50KjAKpCin6hXaN/ evt33/osBXQCP8kqM4DNe61cYBa9gb/DGstlZiAyKz2xrqCKvKJQzOiYFYDyPT3b8Mch tkHvWZktjaHKj3EGn1fID4ORyO0xxZf/XNst/w9VpPukrBM4QzvTEtmp7niHQytvm5Ih Z6jA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=nEXsZOns; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h18si3177122otj.114.2020.02.12.00.04.15; Wed, 12 Feb 2020 00:04:32 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=nEXsZOns; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728454AbgBLIDt (ORCPT + 99 others); Wed, 12 Feb 2020 03:03:49 -0500 Received: from mail-pf1-f195.google.com ([209.85.210.195]:35579 "EHLO mail-pf1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728250AbgBLIDs (ORCPT ); Wed, 12 Feb 2020 03:03:48 -0500 Received: by mail-pf1-f195.google.com with SMTP id y73so847720pfg.2 for ; Wed, 12 Feb 2020 00:03:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=ECVgvgHFKNpFfK3tEgc2bceIocAVUdU7DE70DEQvQUU=; b=nEXsZOnsZ7JEkTVePqQYvtvHeA9oDHxSCnxk/xyxIUqftq+ukqj2a9QCXdWAxRlxJm mAQW7ysw9fg3r7TTeQZhlR6qBjlSB6fUeiuKx2IMgICmp2HVgovQ77rW3L7NEikLtKr2 /a1YNtGKop3d03I2IDh+VDWszT1pysthd/uu1GClbKy3WjJ08P0Al3ZzBho1B83C5vtl EyWEJdWv4FlAPmoas2+9L337wYdE9R+SQzvzTFcqg5bLHW9LNWcIbvHqcfJvcnMRE40l O11Y+W//f/L4dgBOhJ+/4xpOogdgqXUR+YcA5J72Jy2dLa7h8lK1sAXFm6JfBh1w3QRn qQLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=ECVgvgHFKNpFfK3tEgc2bceIocAVUdU7DE70DEQvQUU=; b=Mx6u0FinM1yzNLgognOvR2TBYir1fWKpgn0rXzSgYGah+j8h8733azZOFVQaLoIPVg sSWYNwSGTK0hlhVGiC+F++kgz8KTUphmm2zR8O/4ja2uwFgafy03fvdicY5ksgVlf8g/ QBAz/sXEzKxlkWoGdQdgMeqxHYDPwdMS3N3H29bL8aISvwpQpRZdEdBHDStWgNjf6zxK w8NXnLT/3yem3HK5xwKxBB9xbFblDxuG/UUCbJeOSd7eg7263KpYhD0zOSRgg2gyl5Gp Dzh+iSgySn5/mbyq4xJ5ia5ZA2Nbj3oiyFs5otQ5a1N39NiiM1vb74QiNj2/Mo4MHGaI 3QKA== X-Gm-Message-State: APjAAAVrJC2QSjKIGdI4QXGCB0GOOj2gjQGW11YtCcQfiCCo0nIzutsv c9sG+J+Kg9AEEz9L3EYnd613gIXEFQ4= X-Received: by 2002:aa7:8654:: with SMTP id a20mr7267615pfo.88.1581494627173; Wed, 12 Feb 2020 00:03:47 -0800 (PST) Received: from localhost ([106.51.21.91]) by smtp.gmail.com with ESMTPSA id b98sm5916627pjc.16.2020.02.12.00.03.46 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 12 Feb 2020 00:03:46 -0800 (PST) Date: Wed, 12 Feb 2020 13:33:45 +0530 From: afzal mohammed To: linux-kernel@vger.kernel.org Cc: Michal Simek , Thomas Gleixner Subject: [PATCH 07/18] microblaze: Replace setup_irq() by request_irq() Message-ID: <94d816d0a2462d748b677c05fb56d18b65e32dbc.1581478324.git.afzal.mohd.ma@gmail.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.3 (2018-01-21) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org request_irq() is preferred over setup_irq(). Existing callers of setup_irq() reached mostly via 'init_IRQ()' & 'time_init()', while memory allocators are ready by 'mm_init()'. Per tglx[1], setup_irq() existed in olden days when allocators were not ready by the time early interrupts were initialized. Hence replace setup_irq() by request_irq(). Seldom remove_irq() usage has been observed coupled with setup_irq(), wherever that has been found, it too has been replaced by free_irq(). [1] https://lkml.kernel.org/r/alpine.DEB.2.20.1710191609480.1971@nanos Signed-off-by: afzal mohammed --- Since cc'ing cover letter to all maintainers/reviewers would be too many, refer for cover letter, https://lkml.kernel.org/r/cover.1581478323.git.afzal.mohd.ma@gmail.com arch/microblaze/kernel/timer.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/arch/microblaze/kernel/timer.c b/arch/microblaze/kernel/timer.c index a6683484b3a1..f8832cf49384 100644 --- a/arch/microblaze/kernel/timer.c +++ b/arch/microblaze/kernel/timer.c @@ -161,13 +161,6 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id) return IRQ_HANDLED; } -static struct irqaction timer_irqaction = { - .handler = timer_interrupt, - .flags = IRQF_TIMER, - .name = "timer", - .dev_id = &clockevent_xilinx_timer, -}; - static __init int xilinx_clockevent_init(void) { clockevent_xilinx_timer.mult = @@ -309,7 +302,8 @@ static int __init xilinx_timer_init(struct device_node *timer) freq_div_hz = timer_clock_freq / HZ; - ret = setup_irq(irq, &timer_irqaction); + ret = request_irq(irq, timer_interrupt, IRQF_TIMER, "timer", + &clockevent_xilinx_timer); if (ret) { pr_err("Failed to setup IRQ"); return ret; -- 2.24.1