Date: Sat, 15 Nov 2008 11:23:40 -0500 From: John Baldwin <jhb@freebsd.org> To: "Ronnel P. Maglasang" <rmaglasang@infoweapons.com> Cc: freebsd-hackers@freebsd.org, freebsd-hardware@freebsd.org Subject: Re: assigning interrupts Message-ID: <200811151123.41183.jhb@freebsd.org> In-Reply-To: <491D356A.70607@infoweapons.com> References: <491BFB68.7050405@infoweapons.com> <200811131441.16427.jhb@freebsd.org> <491D356A.70607@infoweapons.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Friday 14 November 2008 03:23:06 am Ronnel P. Maglasang wrote: > John Baldwin wrote: > > On Thursday 13 November 2008 05:03:20 am Ronnel P. Maglasang wrote: > > > >> Hi All, > >> > >> Is there a way to explicitly assign an interrupt > >> of a device? I'm running on 6.3 and the two NICs > >> share the same interrupt. Obviously this will affect > >> the performance if the NICs are exposed to heavy network > >> traffic. > >> > >> # vmstat -i > >> interrupt total rate > >> <sniff> > >> irq11: em0 vr0+ 1081099 77 > >> <sniff> > >> Total 16958562 1222 > >> > >> > >> Looking at the driver's code, I have the initial though > >> that this is the place where I can modify. > >> > >> -- > >> adapter->res_interrupt = bus_alloc_resource_any(dev, > >> SYS_RES_IRQ, &rid, RF_SHAREABLE | RF_ACTIVE); > >> -- > >> > >> I've tried changing RF_SHAREABLE to RF_ALLOCATED or other > >> values but still could not get the desired result and worst > >> the device fail to initialize. Is this possible in 6.3? > >> > > > > You can not easily assign them, no. In many cases the interrupt pins from the > > devices may be hardwired to a single input pin on an interrupt controller. > > In that case there is nothing you can do. You can read more about the gory > > details here: > > > > http://people.freebsd.org/~jhb/papers/bsdcan/2007/ > > > > > What was changed in 7.x in terms of assigning interrupts? I have another > box running on 7.0 (2 NICs). I noticed there are no devices sharing > interrupts. But if 6.x is installed on the same box (previous installation), > the two NICs will share the same interrupt. I'm now looking at the drivers. > I assume this is not NIC-firmware related. MSI. Newer 6.x (6.4, possibly 6.3; if not by default on 6.3 then it can be enabled on 6.3 via 'hw.pci.enable_msi=1' tunable) will do it as well. -- John Baldwin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200811151123.41183.jhb>