Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Nov 2009 12:06:12 -0800
From:      Artem Belevich <fbsdlist@src.cx>
To:        Norikatsu Shigemura <nork@freebsd.org>, Alexander Motin <mav@freebsd.org>
Cc:        freebsd-current@freebsd.org
Subject:   Re: How do I use NCQ of Intel X25-E(SSD) on ahci(4)?
Message-ID:  <ed91d4a80911181206s65a555c4q82f650283c5ac1e8@mail.gmail.com>
In-Reply-To: <20091119021440.560884b2.nork@FreeBSD.org>
References:  <20091119004651.7432a6e4.nork@FreeBSD.org> <4B042304.8060807@FreeBSD.org> <20091119021440.560884b2.nork@FreeBSD.org>

index | next in thread | previous in thread | raw e-mail

> --- sys/dev/ahci/ahci.c.orig    2009-11-17 22:25:07.474418000 +0900
> +++ sys/dev/ahci/ahci.c 2009-11-19 02:00:22.193688908 +0900
> @@ -779,7 +779,7 @@
>        ch->caps = ctlr->caps;
>        ch->caps2 = ctlr->caps2;
>        ch->quirks = ctlr->quirks;
> -       ch->numslots = ((ch->caps & AHCI_CAP_NCS) >> AHCI_CAP_NCS_SHIFT) + 1,
> +       ch->numslots = min(31, ((ch->caps & AHCI_CAP_NCS) >> AHCI_CAP_NCS_SHIFT) + 1),
>        mtx_init(&ch->mtx, "AHCI channel lock", NULL, MTX_DEF);
>        resource_int_value(device_get_name(dev),
>            device_get_unit(dev), "pm_level", &ch->pm_level);

The comma at the end of the "ch->numslots = ..." line looks
suspicious. Shouldn't it be ';' ?

--Artem


help

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?ed91d4a80911181206s65a555c4q82f650283c5ac1e8>