Tom Chen <mailto:chento...@hotmail.com> wrote:
> Hi Liu Jiang,
> 
> Excellent infomation. However, it isn't realistic to let users "hack"
> Solaris system and this method may not work later.
> 
> I keep wondering why getting a few more MSI-X interrupt vectors is so
> difficult on Solaris?  this is very easy on many other OSs.
This is because interrupt vector is a spare resource and the way to manage
it in current Solaris is not flexible enough. So the simplest way is to limit
maximum vectors allocated to one device.
Sure, need enhancement here:)


> 
> Tom
> 
> 
> ----- Original Message -----
> From: "Liu, Jiang" <jiang....@intel.com>
> To: "Tom Chen" <chento...@hotmail.com>; "Aubrey Li"
> <aub...@opensolaris.org> Cc: <opensolaris-discuss@opensolaris.org>
> Sent: Tuesday, March 17, 2009 9:08 PM
> Subject: RE: [osol-discuss] MSIX interrupt allocation
> 
> 
> Hi Tom,
> On onnv build version with IRM(interrupt resouce management), there is
> special code to
> support "#msix-request" device property on SPARC system as defined in
> PSARC/2007/453 :
> uint_t
> i_ddi_get_msix_alloc_limit(dev_info_t *dip)
> {
>         uint_t  msix_alloc_limit = ddi_msix_alloc_limit;
> 
> #if defined(__sparc)
>         if (ddi_prop_exists(DDI_DEV_T_ANY, dip, DDI_PROP_NOTPROM |
>             DDI_PROP_DONTPASS, "#msix-request")) {
>                 msix_alloc_limit = MAX(DDI_MAX_MSIX_ALLOC,
>                     ddi_msix_alloc_limit);
>         }
> #endif
> 
>         return (msix_alloc_limit);
> }
> 
> That onepager has been obsoleted IRM project. Currently IRM is only
> supported on SPARC
> too.  On x86 system, there is another hardcoded logic which causes
> limitation on maximum allocable
> MSI-X interrupt for a single device.  Please refer to
> uts/common/os/ddi_intr_impl.c, there is code for it:
> #if defined(__i386) || defined(__amd64)
> /*
>  * MSI-X allocation limit.
>  */
> uint_t          ddi_msix_alloc_limit = DDI_DEFAULT_MSIX_ALLOC;
> #endif
> 
> #if defined(__i386) || defined(__amd64)
>         /* Global tunable workaround */
>         if (type == DDI_INTR_TYPE_MSIX) {
>                 navail = MIN(nintrs, ddi_msix_alloc_limit);
>         }
> #endif
> 
> To allocate more than two MSI-X interrupts for a device on x86
> system, you may use kmdb or
> /etc/system to override value of ddi_msix_alloc_limit.(I haven't test
> it, just in theory it should work.)
> Thanks!
> 
> Tom Chen <> wrote:
>> Hi Aubrey,
>> 
>> I follow the way the nxge driver does, ie.  add:
>> (void) ddi_prop_create(DDI_DEV_T_NONE, dip, DDI_PROP_CANSLEEP,
>> "#msix-request", NULL, 0); 
>> 
>> See the link.
>> http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/uts/common/io/nxge/nxge_main.c#6700
>> 
>> 
>> 
>> However, on my x86 server running nv107 OS, the number of MSI
>> interrupts I can get remains 2.
>> 
>> 
>> 
>> I am wondering if this method obsolete?
>> 
>> 
>> 
>> Tom
>> 
>> 
>> ----- Original Message -----
>> From: "Aubrey Li" <aub...@opensolaris.org>
>> To: "Tom Chen" <chento...@hotmail.com>
>> Cc: <opensolaris-discuss@opensolaris.org>
>> Sent: Tuesday, March 17, 2009 12:26 AM
>> Subject: Re: [osol-discuss] MSIX interrupt allocation
>> 
>> 
>> Hi Tom,
>> 
>> Which build are you using?
>> Please take a look at PSARC/2007/453 MSI-X interrupt limit override.
>> 
>> Thanks,
>> -Aubrey
>> Intel OpenSolaris Team
>> 
>> On Tue, Mar 17, 2009 at 8:38 AM, Tom Chen <chento...@hotmail.com>
>> wrote:
>>> Hi,
>>> 
>>> I am using ddi_intr_alloc to allocate MSIX interrupt handles, I am
>>> requesting 9, however, why the actual number is always 2 on both
>>> Sparc and x86 machines? 
>>> 
>>> intr_type=DDI_INTR_TYPE_MSIX;
>>> /*
>>> * Get number of supported interrupts
>>> */
>>> rc = ddi_intr_get_nintrs(devinfo, intr_type, &count); /*
>>> * Get number of available interrupts
>>> */
>>> rc = ddi_intr_get_navail(devinfo, intr_type, &avail);
>>> request=9;
>>> rc = ddi_intr_alloc(devinfo, qlge->htable, intr_type, 0,
>>> request, &actual, DDI_INTR_ALLOC_NORMAL);
>>> 
>>> why the actual is always 2?
>>> 
>>> Tom
>>> --
>>> This message posted from opensolaris.org
>>> _______________________________________________
>>> opensolaris-discuss mailing list
>>> opensolaris-discuss@opensolaris.org
>>> 
>> 
>> _______________________________________________
>> opensolaris-discuss mailing list
>> opensolaris-discuss@opensolaris.org
> 
> Liu Jiang (Gerry)
> OpenSolaris, OTC, SSG, Intel

Liu Jiang (Gerry)
OpenSolaris, OTC, SSG, Intel
_______________________________________________
opensolaris-discuss mailing list
opensolaris-discuss@opensolaris.org

Reply via email to