56 ringbuf_write_overwrite(
kmsg, 1, &c);
72 ringbuf_write_overwrite(
kmsg, len, s);
89 char *enc =
"0123456789ABCDEF";
95 buf[--i] = enc[val & 0xF];
105 char *enc =
"0123456789ABCDEF";
110 buf[--i] = enc[val&0xF];
121 if (!val) { buf[9] =
'0';
return puts(&buf[9]); }
124 buf[--i] = val%10 +
'0';
125 val = (val-val%10)/10;
135 if (!val) { buf[19] =
'0';
return puts(&buf[19]); }
138 buf[--i] = val%10 +
'0';
139 val = (val-val%10)/10;
151 buf[--i] =
'0' + (val & 1);
231 ret +=
putc(*(--fmt));
int earlycon_putc(char c)
Writes a character on the early console.
int earlycon_puts(char *s)
Writes a string on the early console.
static int putc(char c)
Writes one character of a message.
void earlycon_disable()
Stops sending the kernel's messages to the early console, once a real console has taken over.
static int putx(uint32_t val)
Writes a 32-bit number in hexadecimal, without leading zeros.
static int putlx(uint64_t val)
Writes a 64-bit number in hexadecimal, all 16 digits.
void printk_console(void(*write)(const char *s, size_t len))
Registers the console that the kernel's messages are written to, besides the message buffer.
int printk(const char *fmt,...)
Writes a kernel message, to the message buffer and the consoles.
static void(*) console_write(const char *s, size_t len)
static int puts(char *s)
Writes a string of a message ("(null)" for NULL).
int vprintk(const char *fmt, va_list args)
Writes a kernel message, with its arguments in a va_list.
static int putud(uint32_t val)
Writes an unsigned 32-bit number in decimal.
static int putul(uint64_t val)
Writes an unsigned 64-bit number in decimal.
static int putb(uint8_t val)
Writes a byte in binary, all 8 digits.
signed long long int int64_t
unsigned long long int uint64_t