shithub: riscv

Download patch

ref: 1889aa50c3727e7c09da16cacfbfecd72860511b
parent: 4e8494aad79a124f2b15ede9e7873fed46e1bb0a
author: cinap_lenrek <[email protected]>
date: Sun Mar 26 12:43:32 EDT 2017

sdvirtio: return 1 for success in vioenable()/viodisable()

--- a/sys/src/9/pc/sdvirtio.c
+++ b/sys/src/9/pc/sdvirtio.c
@@ -579,7 +579,7 @@
 	snprint(name, sizeof(name), "%s (%s)", sd->name, sd->ifc->name);
 	intrenable(vd->pci->intl, viointerrupt, vd, vd->pci->tbdf, name);
 	outb(vd->port+Status, inb(vd->port+Status) | DriverOk);
-	return 0;
+	return 1;
 }
 
 static int
@@ -591,7 +591,7 @@
 	vd = sd->ctlr;
 	snprint(name, sizeof(name), "%s (%s)", sd->name, sd->ifc->name);
 	intrdisable(vd->pci->intl, viointerrupt, vd, vd->pci->tbdf, name);
-	return 0;
+	return 1;
 }
 
 static SDev*