xen/arch/x86/io_apic.c: let custom parameter parsing routines return errno
authorJuergen Gross <jgross@suse.com>
Wed, 23 Aug 2017 17:34:00 +0000 (19:34 +0200)
committerJan Beulich <jbeulich@suse.com>
Fri, 25 Aug 2017 14:15:36 +0000 (16:15 +0200)
Modify the custom parameter parsing routines in:

xen/arch/x86/io_apic.c

to indicate whether the parameter value was parsed successfully.

Signed-off-by: Juergen Gross <jgross@suse.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/io_apic.c

index 2838f6bd99017a52d7bde6cd006218102fa2c0b8..f767c4560cd9cd009b4dae7b58686bccd4dab9e8 100644 (file)
@@ -1581,7 +1581,7 @@ static unsigned int startup_level_ioapic_irq(struct irq_desc *desc)
     return 0; /* don't check for pending */
 }
 
-static void __init setup_ioapic_ack(char *s)
+static int __init setup_ioapic_ack(const char *s)
 {
     if ( !strcmp(s, "old") )
     {
@@ -1594,7 +1594,12 @@ static void __init setup_ioapic_ack(char *s)
         ioapic_ack_forced = true;
     }
     else
+    {
         printk("Unknown ioapic_ack value specified: '%s'\n", s);
+        return -EINVAL;
+    }
+
+    return 0;
 }
 custom_param("ioapic_ack", setup_ioapic_ack);