155ae1aabSRicardo Labiaga /****************************************************************************** 255ae1aabSRicardo Labiaga 355ae1aabSRicardo Labiaga (c) 2008 NetApp. All Rights Reserved. 455ae1aabSRicardo Labiaga 555ae1aabSRicardo Labiaga NetApp provides this source code under the GPL v2 License. 655ae1aabSRicardo Labiaga The GPL v2 license is available at 755ae1aabSRicardo Labiaga http://opensource.org/licenses/gpl-license.php. 855ae1aabSRicardo Labiaga 955ae1aabSRicardo Labiaga THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 1055ae1aabSRicardo Labiaga "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 1155ae1aabSRicardo Labiaga LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 1255ae1aabSRicardo Labiaga A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR 1355ae1aabSRicardo Labiaga CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 1455ae1aabSRicardo Labiaga EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 1555ae1aabSRicardo Labiaga PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 1655ae1aabSRicardo Labiaga PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 1755ae1aabSRicardo Labiaga LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 1855ae1aabSRicardo Labiaga NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 1955ae1aabSRicardo Labiaga SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 2055ae1aabSRicardo Labiaga 2155ae1aabSRicardo Labiaga ******************************************************************************/ 2255ae1aabSRicardo Labiaga 2355ae1aabSRicardo Labiaga /* 2455ae1aabSRicardo Labiaga * Functions and macros used internally by RPC 2555ae1aabSRicardo Labiaga */ 2655ae1aabSRicardo Labiaga 2755ae1aabSRicardo Labiaga #ifndef _NET_SUNRPC_SUNRPC_H 2855ae1aabSRicardo Labiaga #define _NET_SUNRPC_SUNRPC_H 2955ae1aabSRicardo Labiaga 306951867bSBenny Halevy #include <linux/net.h> 316951867bSBenny Halevy 326951867bSBenny Halevy /* 336951867bSBenny Halevy * Header for dynamically allocated rpc buffers. 346951867bSBenny Halevy */ 356951867bSBenny Halevy struct rpc_buffer { 366951867bSBenny Halevy size_t len; 376951867bSBenny Halevy char data[]; 386951867bSBenny Halevy }; 396951867bSBenny Halevy 4055ae1aabSRicardo Labiaga static inline int rpc_reply_expected(struct rpc_task *task) 4155ae1aabSRicardo Labiaga { 4255ae1aabSRicardo Labiaga return (task->tk_msg.rpc_proc != NULL) && 4355ae1aabSRicardo Labiaga (task->tk_msg.rpc_proc->p_decode != NULL); 4455ae1aabSRicardo Labiaga } 4555ae1aabSRicardo Labiaga 464cfc7e60SRahul Iyer int svc_send_common(struct socket *sock, struct xdr_buf *xdr, 474cfc7e60SRahul Iyer struct page *headpage, unsigned long headoffset, 484cfc7e60SRahul Iyer struct page *tailpage, unsigned long tailoffset); 494cfc7e60SRahul Iyer 50*80df9d20SStanislav Kinsbursky int rpc_clients_notifier_register(void); 51*80df9d20SStanislav Kinsbursky void rpc_clients_notifier_unregister(void); 5255ae1aabSRicardo Labiaga #endif /* _NET_SUNRPC_SUNRPC_H */ 5355ae1aabSRicardo Labiaga 54