Index: uspace/drv/bus/isa/isa.c
===================================================================
--- uspace/drv/bus/isa/isa.c	(revision 53a309ecb415a7ff296b01590de2f9ff2e5714cd)
+++ uspace/drv/bus/isa/isa.c	(revision cccd60c3524a3bb23ce0db2ce5c33c181326931e)
@@ -115,24 +115,24 @@
 }
 
-static bool isa_fun_enable_interrupt(ddf_fun_t *fnode)
-{
-	/* This is an old ugly way, copied from pci driver */
-	assert(fnode);
+static int isa_fun_enable_interrupt(ddf_fun_t *fnode, int irq)
+{
 	isa_fun_t *fun = isa_fun(fnode);
-	assert(fun);
-
 	const hw_resource_list_t *res = &fun->hw_resources;
-	assert(res);
+	bool found;
+
+	/* Check that specified irq really belongs to the function */
+	found = false;
 	for (size_t i = 0; i < res->count; ++i) {
-		if (res->resources[i].type == INTERRUPT) {
-			int rc = irc_enable_interrupt(
-			    res->resources[i].res.interrupt.irq);
-
-			if (rc != EOK)
-				return false;
-		}
-	}
-
-	return true;
+		if (res->resources[i].type == INTERRUPT &&
+		    res->resources[i].res.interrupt.irq == irq) {
+			found = true;
+			break;
+		}
+	}
+
+	if (!found)
+		return EINVAL;
+
+	return irc_enable_interrupt(irq);
 }
 
Index: uspace/drv/bus/pci/pciintel/pci.c
===================================================================
--- uspace/drv/bus/pci/pciintel/pci.c	(revision 53a309ecb415a7ff296b01590de2f9ff2e5714cd)
+++ uspace/drv/bus/pci/pciintel/pci.c	(revision cccd60c3524a3bb23ce0db2ce5c33c181326931e)
@@ -99,23 +99,24 @@
 }
 
-static bool pciintel_enable_interrupt(ddf_fun_t *fnode)
-{
-	/* This is an old ugly way */
-	assert(fnode);
+static int pciintel_enable_interrupt(ddf_fun_t *fnode, int irq)
+{
 	pci_fun_t *dev_data = pci_fun(fnode);
 	
-	size_t i = 0;
+	size_t i;
 	hw_resource_list_t *res = &dev_data->hw_resources;
-	for (; i < res->count; i++) {
+	bool found = false;
+	
+	found = false;
+	for (i = 0; i < res->count; i++) {
 		if (res->resources[i].type == INTERRUPT) {
-			int rc = irc_enable_interrupt(
-			    res->resources[i].res.interrupt.irq);
-			
-			if (rc != EOK)
-				return false;
+			found = true;
+			break;
 		}
 	}
 	
-	return true;
+	if (!found)
+		return EINVAL;
+	
+	return irc_enable_interrupt(irq);
 }
 
