Date: Sat, 29 Jul 2006 23:50:51 GMT From: John Birrell <jb@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 102749 for review Message-ID: <200607292350.k6TNopdh069467@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=102749 Change 102749 by jb@jb_freebsd2 on 2006/07/29 23:50:38 Add a console method to allow atomic writes of strings to reduce the amount of interleaving of console output. Affected files ... .. //depot/projects/dtrace/src/sys/sys/cons.h#3 edit Differences ... ==== //depot/projects/dtrace/src/sys/sys/cons.h#3 (text+ko) ==== @@ -45,6 +45,7 @@ typedef int cn_getc_t(struct consdev *); typedef int cn_checkc_t(struct consdev *); typedef void cn_putc_t(struct consdev *, int); +typedef void cn_puts_t(struct consdev *, char *, int); struct consdev { cn_probe_t *cn_probe; @@ -59,6 +60,8 @@ /* kernel "return char if available" interface */ cn_putc_t *cn_putc; /* kernel putchar interface */ + cn_puts_t *cn_puts; + /* write one or more characters */ struct tty *cn_tp; /* tty structure for console device */ short cn_pri; /* pecking order; the higher the better */ void *cn_arg; /* drivers method argument */ @@ -80,9 +83,10 @@ #ifdef _KERNEL -#define CONS_DRIVER(name, probe, init, term, getc, checkc, putc, dbctl) \ +#define CONS_DRIVER(name, probe, init, term, getc, checkc, putc, puts, \ + dbctl) \ static struct consdev name##_consdev = { \ - probe, init, term, getc, checkc, putc \ + probe, init, term, getc, checkc, putc, puts \ }; \ DATA_SET(cons_set, name##_consdev) @@ -93,6 +97,7 @@ .cn_term = name##_cnterm, \ .cn_getc = name##_cngetc, \ .cn_putc = name##_cnputc, \ + .cn_puts = name##_cnputs, \ }; \ DATA_SET(cons_set, name##_consdev) @@ -106,6 +111,7 @@ int cncheckc(void); int cngetc(void); void cnputc(int); +void cnputs(char *, int); int cnunavailable(void); #endif /* _KERNEL */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200607292350.k6TNopdh069467>