Oliver Lehmann wrote: > I've attached the patch for sens_it87.c
Which was broken.... I attached the correct one. -- Oliver Lehmann http://www.pofo.de/ http://wishlist.ans-netz.de/
--- sens_it87.c.orig 2003-10-13 09:11:20.000000000 +0200 +++ sens_it87.c 2010-01-07 19:55:47.000000000 +0100 @@ -41,7 +41,9 @@ #define IT87_TEMP(nr) (0x29 + (nr)) #define IT87_VOLT(nr) (0x20 + (nr)) #define IT87_FAN(nr) (0x0D + (nr)) +#define IT87_FANX(nr) (0x18 + (nr)) #define IT87_FANDIV 0x0B +#define IT87_FANDIV16 0x0C static int it87_probe(LM_METHODS *); static float it87_temp(LM_METHODS *, int); @@ -151,13 +153,26 @@ fac = 0.016 * 1.68; break; case 4: +#ifdef IT8720 + fac = 0.016 * 5.524; +#else fac = 0.016 * 3.80; +#endif break; case 5: +#ifdef IT8720 + fac = - 0.016 * 5.524; +#else fac = - 0.016 * 3.477; +#endif break; case 6: +#ifdef IT8720 + fac = - 0.016 * 2.31; +#else fac = - 0.016 * 1.505; +#endif + } return (float) method->Read(IT87_VOLT(no)) * fac; @@ -191,6 +206,7 @@ if (no < 0 || 2 < no) return 0xFFFF; +#ifndef IT8720 n = method->Read(IT87_FANDIV); div[0] = n & 0x07; div[1] = (n >> 3) & 0x07; @@ -210,6 +226,17 @@ } else if (r == 0) { return 0xFFFF; } +#else + div[no] = 1; + method->Write(0x0C,1|0x07); + n = method->Read(IT87_FANDIV16); + if(n & 0x07) { + r = method->Read(IT87_FAN(no)); + r |= method->Read(IT87_FANX(no))<<8; + } + if(r == 0 || r == 0xFFFF) + return 0xFFFF; +#endif return 1350000 / (r * (1 << div[no])); }
_______________________________________________ freebsd-stable@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-stable To unsubscribe, send any mail to "freebsd-stable-unsubscr...@freebsd.org"