看板 FB_current 關於我們 聯絡資訊
--zYM0uCDKw75PZbzx Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jun 28, 2011 at 03:32:41PM -0700, Xin LI wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA256 >=20 > Hi, >=20 > I'd like to request for comments on the attached driver, which supports > watchdogs on several Winbond super I/O chip models and have been tested > on a few of recent Supermicro motherboards. Is there any reason this is not yet committed? Please commit, pretty please. One minor problem I found is described below. Other than that it works for me, thanks! [...] > +static void > +winbondwd_event(void *arg, unsigned int cmd, int *error) > +{ > + struct winbondwd_softc *sc =3D arg; > + unsigned char rtimeout; > + uint64_t timeout; > + > + if (cmd =3D=3D 0) > + winbondwd_set_timeout(sc, 0); > + else { > + timeout =3D (uint64_t)1 << (cmd & WD_INTERVAL); > + if (timeout < (uint64_t)0xff * 1000 * 1000 * 1000) { > + rtimeout =3D timeout / (1000 * 1000 * 1000); > + if (rtimeout =3D=3D 0) > + rtimeout =3D 0xff; > + winbondwd_set_timeout(sc, rtimeout); > + } else { > + device_printf(sc->device, > + "Value %u too big, disabling\n", cmd & WD_INTERVAL); > + /* Proposed timeout can not be satisified */ > + winbondwd_set_timeout(sc, 0); > + } You should add '*error =3D 0;' right here. Without it we return some random error, in my case watchdgod is able to arm the watchdog but exits when trying to pat it, as it gets an error, which leads to a reset short aferwards. > + } > +} --=20 Pawel Jakub Dawidek http://www.wheelsystems.com FreeBSD committer http://www.FreeBSD.org Am I Evil? Yes, I Am! http://yomoli.com --zYM0uCDKw75PZbzx Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.14 (FreeBSD) iEYEARECAAYFAk7fMeMACgkQForvXbEpPzTg4ACg6n5LNqN3cNW4yBiWZ0vTVDeB JCMAniBz2kXsKcfpyxe96ifN/roR6eHN =CqVQ -----END PGP SIGNATURE----- --zYM0uCDKw75PZbzx--