Re: [Xen-ia64-devel] [patch] IA64: request_irq_vector() Return an error if setup_vector() fails

2009-03-01 Thread Isaku Yamahata
Applied with trivial modificatios.

thanks,

On Tue, Feb 24, 2009 at 01:12:07PM +1100, Simon Horman wrote:
> This is consistent with the x86 version of this function.
> 
> Signed-off-by: Simon Horman 
> 
> --- 
> 
> Compile-tested only.
> 
> Index: xen-unstable.hg/xen/arch/ia64/linux-xen/irq_ia64.c
> ===
> --- xen-unstable.hg.orig/xen/arch/ia64/linux-xen/irq_ia64.c   2009-02-24 
> 09:11:25.0 +1100
> +++ xen-unstable.hg/xen/arch/ia64/linux-xen/irq_ia64.c2009-02-24 
> 13:08:42.0 +1100
> @@ -243,7 +243,7 @@ static struct irqaction ipi_irqaction = 
>  #endif
>  
>  #ifdef XEN
> -extern void setup_vector (unsigned int vec, struct irqaction *action);
> +extern int setup_vector (unsigned int vec, struct irqaction *action);
>  #endif
>  
>  void
> @@ -276,7 +276,7 @@ int request_irq_vector(unsigned int vect
>   unsigned long irqflags, const char * devname, void *dev_id)
>  {
>   struct irqaction * action;
> - int retval=0;
> + int retval;
>  
>   /*
>* Sanity-check: shared interrupts must pass in a real dev-ID,
> @@ -295,7 +295,8 @@ int request_irq_vector(unsigned int vect
>   action->handler = handler;
>   action->name = devname;
>   action->dev_id = dev_id;
> - setup_vector(vector, action);
> +
> + retval = setup_vector(vector, action);
>   if (retval)
>   xfree(action);
>  
> 
> ___
> Xen-ia64-devel mailing list
> Xen-ia64-devel@lists.xensource.com
> http://lists.xensource.com/xen-ia64-devel
> 

-- 
yamahata

___
Xen-ia64-devel mailing list
Xen-ia64-devel@lists.xensource.com
http://lists.xensource.com/xen-ia64-devel


[Xen-ia64-devel] [patch] IA64: request_irq_vector() Return an error if setup_vector() fails

2009-02-23 Thread Simon Horman
This is consistent with the x86 version of this function.

Signed-off-by: Simon Horman 

--- 

Compile-tested only.

Index: xen-unstable.hg/xen/arch/ia64/linux-xen/irq_ia64.c
===
--- xen-unstable.hg.orig/xen/arch/ia64/linux-xen/irq_ia64.c 2009-02-24 
09:11:25.0 +1100
+++ xen-unstable.hg/xen/arch/ia64/linux-xen/irq_ia64.c  2009-02-24 
13:08:42.0 +1100
@@ -243,7 +243,7 @@ static struct irqaction ipi_irqaction = 
 #endif
 
 #ifdef XEN
-extern void setup_vector (unsigned int vec, struct irqaction *action);
+extern int setup_vector (unsigned int vec, struct irqaction *action);
 #endif
 
 void
@@ -276,7 +276,7 @@ int request_irq_vector(unsigned int vect
unsigned long irqflags, const char * devname, void *dev_id)
 {
struct irqaction * action;
-   int retval=0;
+   int retval;
 
/*
 * Sanity-check: shared interrupts must pass in a real dev-ID,
@@ -295,7 +295,8 @@ int request_irq_vector(unsigned int vect
action->handler = handler;
action->name = devname;
action->dev_id = dev_id;
-   setup_vector(vector, action);
+
+   retval = setup_vector(vector, action);
if (retval)
xfree(action);
 

___
Xen-ia64-devel mailing list
Xen-ia64-devel@lists.xensource.com
http://lists.xensource.com/xen-ia64-devel