public inbox for linux-ia64@vger.kernel.org
 help / color / mirror / Atom feed
From: ebiederm@xmission.com (Eric W. Biederman)
To: linux-ia64@vger.kernel.org
Subject: Re: NULL pointer in ia64/irq_chip-mask/unmask function (V3)
Date: Wed, 07 Mar 2007 23:18:59 +0000	[thread overview]
Message-ID: <m1y7m8abh8.fsf@ebiederm.dsl.xmission.com> (raw)
In-Reply-To: <200703072138.l27LcRVE022938@agluck-lia64.sc.intel.com>

"Luck, Tony" <tony.luck@intel.com> writes:

> This patch now has an extra piece for the SGI specific
> occurance of the same context (as noted by Eric).  Just
> posting here in case I misunderstood, or mis-typed while
> applying. Now supplying no-op functions for SN usage.


Looks ok to me.

> -Tony
>
> From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
>
>     [IA64] fix NULL pointer in ia64/irq_chip-mask/unmask function
>     
>     This patch fixes boot failure because irq_desc->mask() is NULL.
>     
>     - Added mask/unmask functions to ia64's irq desc function table.
>     - rename hw_interrupt_type to irq_chip. hw_interrupt_type is old name.
>     - Tony: Added same change to arch/ia64/sn/kernel/irq.c as pointed out
>       by Eric Biederman ... mask/unmask functions there can be no-op.
>     
>     Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
>     Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
>     Signed-off-by: Tony Luck <tony.luck@intel.com>
>
> diff --git a/arch/ia64/kernel/iosapic.c b/arch/ia64/kernel/iosapic.c
> index d6aab40..dcfbf3e 100644
> --- a/arch/ia64/kernel/iosapic.c
> +++ b/arch/ia64/kernel/iosapic.c
> @@ -446,7 +446,7 @@ #define iosapic_enable_level_irq	unmask_
>  #define iosapic_disable_level_irq	mask_irq
>  #define iosapic_ack_level_irq		nop
>  
> -struct hw_interrupt_type irq_type_iosapic_level = {
> +struct irq_chip irq_type_iosapic_level = {
>  	.name =		"IO-SAPIC-level",
>  	.startup =	iosapic_startup_level_irq,
>  	.shutdown =	iosapic_shutdown_level_irq,
> @@ -454,6 +454,8 @@ struct hw_interrupt_type irq_type_iosapi
>  	.disable =	iosapic_disable_level_irq,
>  	.ack =		iosapic_ack_level_irq,
>  	.end =		iosapic_end_level_irq,
> +	.mask =		mask_irq,
> +	.unmask =	unmask_irq,
>  	.set_affinity =	iosapic_set_affinity
>  };
>  
> @@ -493,7 +495,7 @@ #define iosapic_enable_edge_irq		unmask_
>  #define iosapic_disable_edge_irq	nop
>  #define iosapic_end_edge_irq		nop
>  
> -struct hw_interrupt_type irq_type_iosapic_edge = {
> +struct irq_chip irq_type_iosapic_edge = {
>  	.name =		"IO-SAPIC-edge",
>  	.startup =	iosapic_startup_edge_irq,
>  	.shutdown =	iosapic_disable_edge_irq,
> @@ -501,6 +503,8 @@ struct hw_interrupt_type irq_type_iosapi
>  	.disable =	iosapic_disable_edge_irq,
>  	.ack =		iosapic_ack_edge_irq,
>  	.end =		iosapic_end_edge_irq,
> +	.mask =		mask_irq,
> +	.unmask =	unmask_irq,
>  	.set_affinity =	iosapic_set_affinity
>  };
>  
> diff --git a/arch/ia64/sn/kernel/irq.c b/arch/ia64/sn/kernel/irq.c
> index 8c5bee0..8d2a1bf 100644
> --- a/arch/ia64/sn/kernel/irq.c
> +++ b/arch/ia64/sn/kernel/irq.c
> @@ -205,7 +205,17 @@ static void sn_set_affinity_irq(unsigned
>  		(void)sn_retarget_vector(sn_irq_info, nasid, slice);
>  }
>  
> -struct hw_interrupt_type irq_type_sn = {
> +static void
> +sn_mask_irq(unsigned int irq)
> +{
> +}
> +
> +static void
> +sn_unmask_irq(unsigned int irq)
> +{
> +}
> +
> +struct irq_chip irq_type_sn = {
>  	.name		= "SN hub",
>  	.startup	= sn_startup_irq,
>  	.shutdown	= sn_shutdown_irq,
> @@ -213,6 +223,8 @@ struct hw_interrupt_type irq_type_sn = {
>  	.disable	= sn_disable_irq,
>  	.ack		= sn_ack_irq,
>  	.end		= sn_end_irq,
> +	.mask		= sn_mask_irq,
> +	.unmask		= sn_unmask_irq,
>  	.set_affinity	= sn_set_affinity_irq
>  };
>  

  parent reply	other threads:[~2007-03-07 23:18 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-07 21:38 NULL pointer in ia64/irq_chip-mask/unmask function (V2) Luck, Tony
2007-03-07 22:20 ` Eric W. Biederman
2007-03-07 23:05 ` NULL pointer in ia64/irq_chip-mask/unmask function (V3) Luck, Tony
2007-03-07 23:18 ` Eric W. Biederman [this message]
2007-03-12 18:56 ` Jay Lan
2007-03-13  0:02 ` Prarit Bhargava

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m1y7m8abh8.fsf@ebiederm.dsl.xmission.com \
    --to=ebiederm@xmission.com \
    --cc=linux-ia64@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox