Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 21 Sep 2003 21:05:39 +0800
From:      Clive Lin <clive@tongi.org>
To:        Andrew Snow <als@kanji.com.au>
Cc:        freebsd-scsi@freebsd.org
Subject:   Re: ibm x345 w/ serveraid-5i + freebsd ips driver dramas
Message-ID:  <20030921130539.GA64930@fatpipi.cirx.org>
In-Reply-To: <3F64E50E.2040608@kanji.com.au>
References:  <3F64E50E.2040608@kanji.com.au>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Sep 15, 2003 at 08:00:46AM +1000, Andrew Snow wrote:
> Problem 2: (the biggest problem)
> 
> While the drive size is reported correctly, the geometry is wrong...
> 472 cyls/254 heads/63 sectors = 7552944 sectors (3687MB) ?!
> 
> When setting the BIOS to "non-extended" (2GB max) support mode, freebsd 
> then thinks this is the geometry:
> 1846 cyls/128 heads/32 sectors = 7561216 sectors (3692MB).
> 
> So I tested a few alternate geometries instead and even though there 
> were no error messages, it seemed to get reset to what FreeBSD was 
> reporting, no matter how many ways I tried to use the fdisk utility.

Hi,

    I have a quick fix for this problem.

--- sys/dev/ips/ips_disk.c~~    Sun Sep 21 19:04:44 2003
+++ sys/dev/ips/ips_disk.c      Sun Sep 21 20:29:18 2003
@@ -139,7 +139,7 @@
                dsc->ipsd_disk.d_fwsectors = IPS_COMP_SECTORS;
        }
        dsc->ipsd_disk.d_sectorsize = IPS_BLKSIZE;
-       dsc->ipsd_disk.d_mediasize = totalsectors * IPS_BLKSIZE;
+       dsc->ipsd_disk.d_mediasize = (long long) totalsectors * IPS_BLKSIZE;
        disk_create(dsc->unit, &dsc->ipsd_disk, 0, NULL, NULL);
 
        device_printf(dev, "Logical Drive  (%dMB)\n",

    The (long long) casting might not be suitable on other
platform. It works for me on a dual XEON x225 box, which has a
ServeRAID 5i.

Regards,
Clive



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