From 81915026c1ed4d0ad427b2e4397cc2b131c2a91f Mon Sep 17 00:00:00 2001 From: Michael Lotz Date: Tue, 17 Feb 2009 21:49:34 +0000 Subject: [PATCH] Make use of the new private B_NO_HANDLED_INFO in the FreeBSD compatibility layer for now. This is a workaround and should be removed once we have proper interrupt return values from FreeBSD drivers. Should work around interrupt storms for shared interrupts with some network cards that use a FreeBSD driver. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29242 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/libs/compat/freebsd_network/Jamfile | 1 + src/libs/compat/freebsd_network/bus.c | 8 +++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/libs/compat/freebsd_network/Jamfile b/src/libs/compat/freebsd_network/Jamfile index a3b3351a88..e567690395 100644 --- a/src/libs/compat/freebsd_network/Jamfile +++ b/src/libs/compat/freebsd_network/Jamfile @@ -4,6 +4,7 @@ SubDir HAIKU_TOP src libs compat freebsd_network ; UseHeaders [ FDirName $(SUBDIR) ] : true ; UseHeaders [ FDirName $(SUBDIR) compat ] : true ; UsePrivateHeaders net ; +UsePrivateKernelHeaders ; UseHeaders $(HAIKU_PRIVATE_KERNEL_HEADERS) : true ; SubDirCcFlags [ FDefines _KERNEL=1 ] ; diff --git a/src/libs/compat/freebsd_network/bus.c b/src/libs/compat/freebsd_network/bus.c index 47762c0d25..ecccfdba75 100644 --- a/src/libs/compat/freebsd_network/bus.c +++ b/src/libs/compat/freebsd_network/bus.c @@ -17,6 +17,8 @@ #include #include +// private kernel header to get B_NO_HANDLED_INFO +#include //#define DEBUG_BUS_SPACE_RW #ifdef DEBUG_BUS_SPACE_RW @@ -313,10 +315,10 @@ bus_setup_intr(device_t dev, struct resource *res, int flags, if (filter != NULL) { status = install_io_interrupt_handler(intr->irq, - (interrupt_handler)intr->filter, intr->arg, 0); + (interrupt_handler)intr->filter, intr->arg, B_NO_HANDLED_INFO); } else if (flags & INTR_FAST) { status = install_io_interrupt_handler(intr->irq, - intr_fast_wrapper, intr, 0); + intr_fast_wrapper, intr, B_NO_HANDLED_INFO); } else { snprintf(semName, sizeof(semName), "%s intr", dev->device_name); @@ -337,7 +339,7 @@ bus_setup_intr(device_t dev, struct resource *res, int flags, } status = install_io_interrupt_handler(intr->irq, - intr_wrapper, intr, 0); + intr_wrapper, intr, B_NO_HANDLED_INFO); } if (status < B_OK) {