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 shelob.surriel.com (shelob.surriel.com [96.67.55.147]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 131A9C433EF for ; Mon, 11 Apr 2022 12:51:28 +0000 (UTC) Received: from localhost ([::1] helo=shelob.surriel.com) by shelob.surriel.com with esmtp (Exim 4.94.2) (envelope-from ) id 1ndtVv-0001CK-TB for kernelnewbies@archiver.kernel.org; Mon, 11 Apr 2022 08:51:27 -0400 Received: from wout5-smtp.messagingengine.com ([64.147.123.21]) by shelob.surriel.com with esmtps (TLS1.2) tls TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ndtU9-0007bz-Eh for kernelnewbies@kernelnewbies.org; Mon, 11 Apr 2022 08:49:37 -0400 Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.west.internal (Postfix) with ESMTP id 35B843201FEA; Mon, 11 Apr 2022 08:49:34 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Mon, 11 Apr 2022 08:49:34 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kroah.com; h=cc :cc:content-type:date:date:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:sender:subject :subject:to:to; s=fm1; t=1649681373; x=1649767773; bh=FplBlqht9n LiUr+CKRGXTjpe5yxAZLPTz/3XV6ALeDE=; b=IKw3FSgwXI4BrAj/nbOLj9IuwS k90hWIDozSKiuQ1OKd/o8+hRZNx96Kyi97M1F9lcJO7wigEf/wNg610TmTnmo5JO oXvOgg0/VpD/5s7+LZUOEj0QhT1HSGMu0oPYJFdluRzckyn531kpMzS6pbcN0Bfr ey9AUGl4CL8hzjmXfZS79Gys8Z13FUl5oGNgFEhrr6E8oiz5oWYKpj5LkEfzC/zG 3p+KSyw4SaSzsrwZMKIx9NdmrW1HRQylZv9Q2iz+OhUg79McsUUH1Pi4lFSgED1N pAfupLHDV3l/tjCV0m9dCUG3q4Mi0FuLG69jV1yLhXRaI0+EElybZhiCJ1vw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:date:date:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1649681373; x= 1649767773; bh=FplBlqht9nLiUr+CKRGXTjpe5yxAZLPTz/3XV6ALeDE=; b=g f0kFPjsbikz4P+QUwLOECHfUieSq/aupA+baG6bzOePKwS1jv63dxYaDe5YcJiM/ tk5g4Z9HPU7DKEbMMcWjrja9EAQ9+l9J0cUuFu6ZBEVa/Tuzfq6hvLamNK7RzHRm xSlKKQpLm73gzVroH/BmosCaC+ulEA6hCaBUyAc3aG6d6ojZ1xLGp1ea3yMTX7Y2 0f8gf1Slts5XHgmoR16D7y/mtEBTMlRRP6SKYmH+0poYG9LFj0RtXnJ3hWqUlubA AgzX2Z90ynaRh04CRD5r80WQVW+YIbxqsyidd2Oqpa93J/RWCZ83EaMYk3V3q7Wf q/9sz7aogYQuWXtr5uoTA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvvddrudekiedgheeiucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvffukfhfgggtuggjsehttdertddttddvnecuhfhrohhmpefirhgvghcu mffjuceoghhrvghgsehkrhhorghhrdgtohhmqeenucggtffrrghtthgvrhhnpeevueehje fgfffgiedvudekvdektdelleelgefhleejieeugeegveeuuddukedvteenucevlhhushht vghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehgrhgvgheskhhrohgrhh drtghomh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 11 Apr 2022 08:49:33 -0400 (EDT) Date: Mon, 11 Apr 2022 14:49:31 +0200 From: Greg KH To: Chan Kim Subject: Re: Can't understand /proc/interrupts output for GICv3 case Message-ID: References: <049201d84b04$951cbab0$bf563010$@etri.re.kr> <06c401d84da0$bc1a5ca0$344f15e0$@etri.re.kr> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <06c401d84da0$bc1a5ca0$344f15e0$@etri.re.kr> Cc: kernelnewbies@kernelnewbies.org, 'qemu-discuss' X-BeenThere: kernelnewbies@kernelnewbies.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Learn about the Linux kernel List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: kernelnewbies-bounces+kernelnewbies=archiver.kernel.org@kernelnewbies.org On Mon, Apr 11, 2022 at 09:36:14PM +0900, Chan Kim wrote: > Hi, > nobody's replying to my question.. so sad.. > I found the kernel makes an array (actually a radix tree) of 'irq_desc's. > And my hwirq (SPI 15) is assigned to one of these irq_descs while processing > device tree. > In my case it was assigned irq 6 (this irq is what is called virtual irq). > So I registered the handler by request_irq(6,...) and the interrupt works > fine. > So now my question is : how can find my irq number (correct irq_desc number) > in kernel driver module? You ask the system for it. It depends on the bus type your driver is written for for how to do this. For example, if you have a platform driver, you would call platform_get_irq(). If you are a pci driver, the irq for your device is already stored in the pci device structure passed into your probe function. What bus type is your driver written for? hope this helps, greg k-h _______________________________________________ Kernelnewbies mailing list Kernelnewbies@kernelnewbies.org https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies