kern/71321: [PATCH] Add nForce2 ata support for MSI K7N2 Delta2
Platinum
Jeremy Messenger
mezz at FreeBSD.org
Thu Sep 2 16:40:06 PDT 2004
>Number: 71321
>Category: kern
>Synopsis: [PATCH] Add nForce2 ata support for MSI K7N2 Delta2 Platinum
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Thu Sep 02 23:40:05 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator: Mezz
>Release: FreeBSD 5.2-CURRENT i386
>Organization:
>Environment:
System: FreeBSD ns1.mezzweb.com 5.2-CURRENT FreeBSD 5.2-CURRENT #0: Tue Mar 30
01:17:23 CST 2004 mezz at mezz.mezzweb.com:/usr/src/sys/i386/compile/BSDROCKS i386
Don't mind above; I have tested this patch on my another machine that has
nForce2 with FreeBSD 5.3-BETA2.
>Description:
Add nForce2 ata support for MSI K7N2 Delta2 Platinum (MS-6570E-010).
http://www.msicomputer.com/product/p_spec.asp?model=K7N2_Delta2_Platinum&class=mb
- Ultra DMA 66/100/133 master mode PCI EIDE controller
- Two IDE controller on the nVIDIA® nForce2 Gigabit MCP chipset
provides IDE HDD/CDROM with PIO, Bus Master and Ultra DMA133/100/66
operation modes
- Can connect up to four IDE devices
pciconf:
===========================================
atapci0 at pci0:9:0: class=0x01018a card=0x57001462 chip=0x008510de rev=0xa3 hdr=0x00
vendor = 'NVIDIA Corporation'
device = 'MCP2S Parallel ATA Controller'
class = mass storage
subclass = ATA
===========================================
Before dmesg:
===========================================
atapci0: <GENERIC ATA controller> port 0xf000-0xf00f,0x376,0x170-0x177,0x3f6,0x1f0-0x1f7 at device 9.0 on pci0
ata0: channel #0 on atapci0
ata1: channel #1 on atapci0
ad0: 114473MB <ST3120026A/8.54> [232581/16/63] at ata0-master UDMA33
ATAPI_RESET time = 150us
acd0: CDRW <LITE-ON COMBO SOHC-5232K/NK07> at ata1-master UDMA33
Mounting root from ufs:/dev/ad0s1a
===========================================
After dmesg:
===========================================
atapci0: <nVidia nForce2 UDMA133 controller> port 0xf000-0xf00f,0x376,0x170-0x177,0x3f6,0x1f0-0x1f7 at device 9.0 on pci0
ata0: channel #0 on atapci0
ata1: channel #1 on atapci0
ad0: 114473MB <ST3120026A/8.54> [232581/16/63] at ata0-master UDMA100
ATAPI_RESET time = 170us
ata1-master: DMA limited to UDMA33, non-ATA66 cable or device
acd0: CDRW <LITE-ON COMBO SOHC-5232K/NK07> at ata1-master UDMA33
Mounting root from ufs:/dev/ad0s1a
===========================================
Before 'atacontrol mode N':
===========================================
# atacontrol mode 0
Master = UDMA33
Slave = BIOSPIO
# atacontrol mode 1
Master = UDMA33
Slave = BIOSPIO
===========================================
After 'atacontrol mode N':
===========================================
# atacontrol mode 0
Master = UDMA100
Slave = BIOSPIO
# atacontrol mode 1
Master = UDMA33 <-- It's correct, cable is 33 and I need to buy a new one.
Slave = BIOSPIO
===========================================
If there is anything else you need to know such as 'boot -v' or whatever, just
let me know.
>How-To-Repeat:
n/a
>Fix:
Heh, I don't know if you will like the name 'ATA_NFORCE2_MCP2S'. I just took
the 'MCP2S' from the pciconf to create a different name than just 'ATA_NFORCE2'.
--- ata-nforce2.diff begins here ---
--- sys/dev/ata/ata-pci.h.orig Thu Sep 2 17:43:39 2004
+++ sys/dev/ata/ata-pci.h Thu Sep 2 17:54:46 2004
@@ -129,6 +129,7 @@
#define ATA_NVIDIA_ID 0x10de
#define ATA_NFORCE1 0x01bc10de
#define ATA_NFORCE2 0x006510de
+#define ATA_NFORCE2_MCP2S 0x008510de
#define ATA_NFORCE3 0x00d510de
#define ATA_PROMISE_ID 0x105a
--- sys/dev/ata/ata-chipset.c.orig Thu Sep 2 17:45:13 2004
+++ sys/dev/ata/ata-chipset.c Thu Sep 2 17:54:43 2004
@@ -1104,6 +1104,7 @@
static struct ata_chip_id ids[] =
{{ ATA_NFORCE1, 0, AMDNVIDIA, NVIDIA|AMDBUG, ATA_UDMA5, "nVidia nForce" },
{ ATA_NFORCE2, 0, AMDNVIDIA, NVIDIA|AMDBUG, ATA_UDMA6, "nVidia nForce2" },
+ { ATA_NFORCE2_MCP2S, 0, AMDNVIDIA, NVIDIA|AMDBUG, ATA_UDMA6, "nVidia nForce2" },
{ ATA_NFORCE3, 0, AMDNVIDIA, NVIDIA, ATA_UDMA6, "nVidia nForce3" },
{ 0, 0, 0, 0, 0, 0}};
char buffer[64];
--- ata-nforce2.diff ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-bugs
mailing list