xen/pciback: Fix error return code in xen_pcibk_attach()
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>
Sun, 20 Jul 2014 05:46:01 +0000 (13:46 +0800)
committerDavid Vrabel <david.vrabel@citrix.com>
Fri, 1 Aug 2014 14:44:46 +0000 (15:44 +0100)
Fix to return -EFAULT from the error handling case instead of 0 when
version mismatch with pcifront.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Reviewed-by Jan Beulich <jbeulich@suse.com>
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
drivers/xen/xen-pciback/xenbus.c

index 4a7e6e0a5f4c602ad280ffe5b258bd5fc44ed5f9..c214daab482910b203b436520d876a618ffcca9b 100644 (file)
@@ -174,6 +174,7 @@ static int xen_pcibk_attach(struct xen_pcibk_device *pdev)
                                 "version mismatch (%s/%s) with pcifront - "
                                 "halting " DRV_NAME,
                                 magic, XEN_PCI_MAGIC);
+               err = -EFAULT;
                goto out;
        }