int tile_console_write(const char *buf, int count)
{
	if (unlikely(use_sim_console)) {
		int i;
		for (i = 0; i < count; ++i)
			__insn_mtspr(SPR_SIM_CONTROL, SIM_CONTROL_PUTC |
				     (buf[i] << _SIM_CONTROL_OPERATOR_BITS));
		__insn_mtspr(SPR_SIM_CONTROL, SIM_CONTROL_PUTC |
			     (SIM_PUTC_FLUSH_BINARY <<
			      _SIM_CONTROL_OPERATOR_BITS));
		return 0;
	} else {
		return hv_console_write((HV_VirtAddr)buf, count);
	}
}
Exemple #2
0
static int hvc_tile_put_chars(uint32_t vt, const char *buf, int count)
{
	return hv_console_write((HV_VirtAddr)buf, count);
}