Skip to content

Commit

Permalink
xen console: update the "to be written" count
Browse files Browse the repository at this point in the history
  • Loading branch information
palainp committed Dec 5, 2022
1 parent 17312ab commit ae02183
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions bindings/xen/console.c
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ void console_write(const char *buf, size_t len)
do
{
/* Try and put some data into the ring. */
written = console_write_some(&buf[written], len - written);
written += console_write_some(&buf[count], len);

/* Signal xenconsoled that new data is available. */
hypercall_evtchn_send(console_evtchn);
Expand All @@ -122,7 +122,6 @@ void console_write(const char *buf, size_t len)
while (ACCESS_ONCE(console_ring->out_cons) == cons)
hypercall_yield();
}

} while (written < len);

/* Wait for xenconsoled to consume all the data we gave. */
Expand Down

0 comments on commit ae02183

Please sign in to comment.