| Summary: | [acpi] [patch] Add High Precision Event Timer Driver for userland timer facility | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | Base System | Reporter: | takeharu1219 | ||||||
| Component: | kern | Assignee: | freebsd-acpi (Nobody) <acpi> | ||||||
| Status: | Closed Overcome By Events | ||||||||
| Severity: | Affects Only Me | ||||||||
| Priority: | Normal | ||||||||
| Version: | 7.0-CURRENT | ||||||||
| Hardware: | Any | ||||||||
| OS: | Any | ||||||||
| Attachments: |
|
||||||||
|
Description
takeharu1219
2007-05-09 12:20:02 UTC
Responsible Changed From-To: freebsd-bugs->freebsd-acpi Over to maintainer(s). Hi, I haven't read the whole patch yet. To me line 164 (of the first patch file) seems bogus. It tries to do the right thing (read-modify-write) but actually does not. HPET_OFFSET_ENABLE is the offset in the hpet datastructure. Should be like this: val = bus_read_4(sc->mem_res, HPET_OFFSET_ENABLE); bus_write_4(sc->mem_res, HPET_OFFSET_ENABLE, val | 1); And 1 should better HPET_ENABLE_ENABLE. Line 133 of the same patch does not even try to do a read-modify-write. However the documentation is clear that it should. This all applies to the driver in -current (1.8) as well. regards Marius This PR can be closed. jhb 2008-01-16 18:47:07 UTC
FreeBSD src repository
Modified files:
sys/dev/acpica acpi_hpet.c
Added files:
sys/dev/acpica acpi_hpet.h
Log:
Add a header containing constants for the various HPET registers and their
fields and update the code to match. The PR served more as an inspiration
than providing the actual diffs.
MFC after: 1 week
PR: kern/112544
Revision Changes Path
1.14 +19 -23 src/sys/dev/acpica/acpi_hpet.c
1.1 +65 -0 src/sys/dev/acpica/acpi_hpet.h (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
State Changed From-To: open->patched Was committed to -HEAD a couple of weeks ago. State Changed From-To: patched->open Change state back to open as per jhb's request. State Changed From-To: open->feedback To jhb: there seems to have been a commit, then an MFC to RELENG_6 via 1.1.4.1 on Jan 23 2008. Is there some reason this one needs to remain open? Responsible Changed From-To: freebsd-acpi->jhb ----- Forwarded message from John Baldwin <jhb@freebsd.org> ----- The HPET contains multiple bits. One is a general count down timer that we use for timekeeping. In addition it contains a variable number of comparator registers each of which can be used to generate interrupts at varying frequencies (or one-shot interrupts, etc.). The current in-kernel HPET support only handles the count down timer. We do not have any support for the comparators. The code in the PR does include support for the comparators. However, it's aim is to export them for use by userland drivers. FreeBSD will probably end up using the HPET comparators to back deadline-style clock interrupts in place of the RTC or lapic timer at some point in which case certain pieces of this code may be useful. The commit I made just extracted a few of the changes in the original patch, it did not contain all of the changes in the patch. It is probably best to mark this as suspended and leave it as freebsd-acpi@ for now as I'm not currently planning on doing the deadline clock stuff. -- John Baldwin ----- End forwarded message ----- State Changed From-To: feedback->suspended See note from jhb in Audit-Trail. Responsible Changed From-To: jhb->freebsd-acpi We still do not provide a userland interface to HPET. But do we really want to? What kind of applications would use it and why existing userland timer facilities are not adequate for them? In any case, HPET and event timer code has been substantially re-organized in head, so the patch would have to be rebased if the submitter still want that kind of functionality. Thanks for helping FreeBSD! -- Andriy Gapon batch change: For bugs that match the following - Status Is In progress AND - Untouched since 2018-01-01. AND - Affects Base System OR Documentation DO: Reset to open status. Note: I did a quick pass but if you are getting this email it might be worthwhile to double check to see if this bug ought to be closed. HPET driver has been substantially changed. We've got userland timecounters for things like gettimeofday. HPET has long been supported as a kernel event timer. |