1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>queue_kthread_work</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="Linux Device Drivers"><link rel="up" href="ch01s07.html" title="Internal Functions"><link rel="prev" href="API-kthread-worker-fn.html" title="kthread_worker_fn"><link rel="next" href="API-flush-kthread-work.html" title="flush_kthread_work"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center"><span class="phrase">queue_kthread_work</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="API-kthread-worker-fn.html">Prev</a> </td><th width="60%" align="center">Internal Functions</th><td width="20%" align="right"> <a accesskey="n" href="API-flush-kthread-work.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API-queue-kthread-work"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>queue_kthread_work — 2 queue a kthread_work 3 </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="funcsynopsis"><table border="0" class="funcprototype-table" summary="Function synopsis" style="cellspacing: 0; cellpadding: 0;"><tr><td><code class="funcdef">bool <b class="fsfunc">queue_kthread_work </b>(</code></td><td>struct kthread_worker * <var class="pdparam">worker</var>, </td></tr><tr><td> </td><td>struct kthread_work * <var class="pdparam">work</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer"> </div></div></div><div class="refsect1"><a name="idp1108154924"></a><h2>Arguments</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term"><em class="parameter"><code>worker</code></em></span></dt><dd><p> 4 target kthread_worker 5 </p></dd><dt><span class="term"><em class="parameter"><code>work</code></em></span></dt><dd><p> 6 kthread_work to queue 7 </p></dd></dl></div></div><div class="refsect1"><a name="idp1108157564"></a><h2>Description</h2><p> 8 Queue <em class="parameter"><code>work</code></em> to work processor <em class="parameter"><code>task</code></em> for async execution. <em class="parameter"><code>task</code></em> 9 must have been created with <code class="function">kthread_worker_create</code>. Returns <code class="constant">true</code> 10 if <em class="parameter"><code>work</code></em> was successfully queued, <code class="constant">false</code> if it was already pending. 11</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="API-kthread-worker-fn.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="ch01s07.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="API-flush-kthread-work.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="phrase">kthread_worker_fn</span> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> <span class="phrase">flush_kthread_work</span></td></tr></table></div></body></html> 12