Opened 13 years ago

Closed 13 years ago

#289 closed enhancement (fixed)

klog's interrupt_received() routine is too heavy-weight

Reported by: Martin Decky Owned by: Martin Decky
Priority: minor Milestone: 0.5.0
Component: helenos/app/klog Version: mainline
Keywords: Cc:
Blocker for: Depends on:
See also:

Description

The kernel notifications about klog updates are totally asynchronous (i.e. the kernel does not stop writing to the klog area while the uspace klog task is reading the data).

Thus, reading the area character by character in uspace klog and writing each character to console and file synchronously in the same loop can cause frequent data loss.

In principle, there is no way how to guarantee success in all cases (by design, since the kernel should be always free to write to the klog without any waiting or allocating additional memory for a FIFO), but a more clever design of the uspace klog can probably improve the reliability.

Change History (4)

comment:1 by Martin Decky, 13 years ago

Component: unspecifiedapp/klog
Status: newaccepted

comment:2 by Jakub Jermář, 13 years ago

Milestone: 0.4.30.5.0

comment:3 by Jakub Jermář, 13 years ago

Type: defectenhancement

comment:4 by Martin Decky, 13 years ago

Resolution: fixed
Status: acceptedclosed

Most of the issues should be mitigated as of mainline,948.

Introduced changes: Automatic kernel notification masking and on-demand unmasking in uspace klog (to avoid copying the same data multiple times); producer/consumer design of uspace klog to move heavy-weight output calls to a separate fibril.

Note: See TracTickets for help on using tickets.