HomeFreeBSD

Improve sdhci slot_printf() debug printing.

Description

Improve sdhci slot_printf() debug printing.

Currently slot_printf() uses two printf() calls to print the
device-slot name, and actual message. When other printf()s are
ongoing in parallel this can lead to interleaved message on the console,
which is especially unhelpful for debugging or error messages.

Take a hit on the stack and vsnprintf() the message to the buffer.
This way it can be printed along with the device-slot name in one go
avoiding console gibberish.

Reviewed by: marius
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D19747

Details

Provenance
bzAuthored on
Reviewer
marius
Differential Revision
D19747: Improve sdhci slot_printf() debug printing.
Parents
rS348800: Introduce sim_dev and cam_sim_alloc_dev().
Branches
Unknown
Tags
Unknown