Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src The piixpm(4) driver also supports AMD's HUDSON chipset's SM...



details:   https://anonhg.NetBSD.org/src/rev/06b2ae841843
branches:  trunk
changeset: 346362:06b2ae841843
user:      pgoyette <pgoyette%NetBSD.org@localhost>
date:      Sun Jul 10 04:44:47 2016 +0000

description:
The piixpm(4) driver also supports AMD's HUDSON chipset's SMBus function.

>From OpenBSD, verified.

diffstat:

 share/man/man4/piixpm.4 |   6 ++++--
 sys/dev/pci/piixpm.c    |  21 +++++++++++++++++----
 2 files changed, 21 insertions(+), 6 deletions(-)

diffs (83 lines):

diff -r 109572d129dc -r 06b2ae841843 share/man/man4/piixpm.4
--- a/share/man/man4/piixpm.4   Sun Jul 10 01:35:27 2016 +0000
+++ b/share/man/man4/piixpm.4   Sun Jul 10 04:44:47 2016 +0000
@@ -1,4 +1,4 @@
-.\" $NetBSD: piixpm.4,v 1.6 2014/03/18 18:20:39 riastradh Exp $
+.\" $NetBSD: piixpm.4,v 1.7 2016/07/10 04:44:47 pgoyette Exp $
 .\"    $OpenBSD: piixpm.4,v 1.9 2006/01/18 03:06:33 brad Exp $
 .\"
 .\" Copyright (c) 2004, 2005 Alexander Yurchenko <grange%openbsd.org@localhost>
@@ -15,7 +15,7 @@
 .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
 .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
 .\"
-.Dd March 26, 2008
+.Dd July 10, 2016
 .Dt PIIXPM 4
 .Os
 .Sh NAME
@@ -42,6 +42,8 @@
 Intel 82371AB (PIIX4), 82440MX
 .It
 Serverworks OSB4, OSB5, OSB6, HT1000SB
+.It
+AMD HUDSON
 .El
 .Sh SEE ALSO
 .Xr iic 4 ,
diff -r 109572d129dc -r 06b2ae841843 sys/dev/pci/piixpm.c
--- a/sys/dev/pci/piixpm.c      Sun Jul 10 01:35:27 2016 +0000
+++ b/sys/dev/pci/piixpm.c      Sun Jul 10 04:44:47 2016 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: piixpm.c,v 1.47 2015/12/10 05:29:41 pgoyette Exp $ */
+/* $NetBSD: piixpm.c,v 1.48 2016/07/10 04:44:47 pgoyette Exp $ */
 /*     $OpenBSD: piixpm.c,v 1.20 2006/02/27 08:25:02 grange Exp $      */
 
 /*
@@ -22,7 +22,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: piixpm.c,v 1.47 2015/12/10 05:29:41 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: piixpm.c,v 1.48 2016/07/10 04:44:47 pgoyette Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -144,6 +144,11 @@
                case PCI_PRODUCT_SERVERWORKS_HT1000SB:
                        return 1;
                }
+       case PCI_VENDOR_AMD:
+               switch (PCI_PRODUCT(pa->pa_id)) {
+               case PCI_PRODUCT_AMD_HUDSON_SMB:
+                       return 1;
+               }
        }
 
        return 0;
@@ -205,7 +210,15 @@
 
 nopowermanagement:
 
-       /* SB800 rev 0x40+ needs special initialization */
+       /* SB800 rev 0x40+ and AMD HUDSON need special initialization */
+       if (PCI_VENDOR(pa->pa_id) == PCI_VENDOR_AMD &&
+           PCI_PRODUCT(pa->pa_id) == PCI_PRODUCT_AMD_HUDSON_SMB) {
+               if (piixpm_sb800_init(sc) == 0) {
+                       goto attach_i2c;
+               }
+               aprint_normal_dev(self, "SMBus initialization failed\n");
+               return;
+       }
        if (PCI_VENDOR(pa->pa_id) == PCI_VENDOR_ATI &&
            PCI_PRODUCT(pa->pa_id) == PCI_PRODUCT_ATI_SB600_SMB &&
            PCI_REVISION(pa->pa_class) >= 0x40) {
@@ -213,7 +226,7 @@
                        sc->sc_numbusses = 4;
                        goto attach_i2c;
                }
-               aprint_normal_dev(self, "SMBus disabled\n");
+               aprint_normal_dev(self, "SMBus initialization failed\n");
                return;
        }
 



Home | Main Index | Thread Index | Old Index