Date: Fri, 15 Dec 2006 14:55:16 GMT From: Bernd Walter <ticso@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 111741 for review Message-ID: <200612151455.kBFEtGKT049413@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=111741 Change 111741 by ticso@ticso on 2006/12/15 14:54:52 Use the next possible value for hz instead of defaulting to 128 Update tick value after modifying hz. Affected files ... .. //depot/projects/arm/src/sys/arm/at91/at91_st.c#15 edit Differences ... ==== //depot/projects/arm/src/sys/arm/at91/at91_st.c#15 (text+ko) ==== @@ -201,11 +201,14 @@ void *ih; device_t dev = timer_softc->sc_dev; + rel_value = 32768 / hz; + if (rel_value < 1) + rel_value = 1; if (32768 % hz) { - printf("Cannot get %d Hz clock; using 128Hz\n", hz); - hz = 128; + printf("Cannot get %d Hz clock; using %dHz\n", hz, 32768 / rel_value); + hz = 32768 / rel_value; + tick = 1000000 / hz; } - rel_value = 32768 / hz; /* Disable all interrupts. */ WR4(ST_IDR, 0xffffffff); /* The system timer shares the system irq (1) */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200612151455.kBFEtGKT049413>