From mboxrd@z Thu Jan 1 00:00:00 1970 To: 9fans@cse.psu.edu From: nemo@gsyc.escet.urjc.es MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Message-Id: <20010206081448.34C55199EA@mail.cse.psu.edu> Subject: [9fans] tiny fix for Eric's patch: 9pcfs on 4G IDE disks Date: Tue, 6 Feb 2001 09:27:12 -0500 Topicbox-Message-UUID: 5a49321c-eac9-11e9-9e20-41e7f4b1d025 If any of you plan to use >4G disks with the nice patch made by Eric Dorman to run 9pcfs on IDE disks: Replace in plan9pc/devata.c long atasize( Device *d ) { Drive *dp; dp = d->private; return (cp->cap * 512) / RBUFSIZE; } with long atasize( Device *d ) { Drive *dp; dp = d->private; return (dp->cap / RBUFSIZE * 512); } Otherwise, an overflow leaves the device w/ just 1k blocks or so. After changing this, I'm running it smoothly with the device "ch0fh2" (two 4G ide disks). PS: Thanks Eric for your nice patch