'\" t .\" Title: trace_puts .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: Driver Basics .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "TRACE_PUTS" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "Driver Basics" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" trace_puts \- write a string into the ftrace buffer .SH "SYNOPSIS" .HP \w'trace_puts('u .BI "trace_puts(" "str" ");" .SH "ARGUMENTS" .PP \fIstr\fR .RS 4 the string to record .RE .SH "NOTE" .PP __trace_bputs is an internal function for trace_puts and the \fIip\fR is passed in via the trace_puts macro\&. .PP This is similar to \fBtrace_printk\fR but is made for those really fast paths that a developer wants the least amount of \(lqHeisenbug\(rq affects, where the processing of the print format is still too much\&. .PP This function allows a kernel developer to debug fast path sections that printk is not appropriate for\&. By scattering in various printk like tracing in the code, a developer can quickly see where problems are occurring\&. .PP This is intended as a debugging tool for the developer only\&. Please refrain from leaving trace_puts scattered around in your code\&. (Extra memory is used for special buffers that are allocated when \fBtrace_puts\fR is used) .SH "RETURN" .PP 0 if nothing was written, positive # if string was\&. (1 when __trace_bputs is used, strlen(str) when __trace_puts is used) .SH "COPYRIGHT" .br