Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932684AbcLHU7x (ORCPT ); Thu, 8 Dec 2016 15:59:53 -0500 Received: from mail.kernel.org ([198.145.29.136]:52896 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753644AbcLHU7M (ORCPT ); Thu, 8 Dec 2016 15:59:12 -0500 From: Stefano Stabellini To: v9fs-developer@lists.sourceforge.net Cc: sstabellini@kernel.org, ericvh@gmail.com, rminnich@sandia.gov, lucho@ionkov.net, linux-kernel@vger.kernel.org Subject: [PATCH 3/5] 9p: introduce p9_client_get_req Date: Thu, 8 Dec 2016 12:59:04 -0800 Message-Id: <1481230746-16741-3-git-send-email-sstabellini@kernel.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1481230746-16741-1-git-send-email-sstabellini@kernel.org> References: <1481230746-16741-1-git-send-email-sstabellini@kernel.org> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 891 Lines: 35 Introduce a simple helper function to only prepare a p9 client request, without any waiting involved. Currently not utilized, but it will be used by a later patch. Signed-off-by: Stefano Stabellini --- net/9p/client.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/net/9p/client.c b/net/9p/client.c index bfe1715..eb589ef 100644 --- a/net/9p/client.c +++ b/net/9p/client.c @@ -719,6 +719,18 @@ static struct p9_req_t *p9_client_prepare_req(struct p9_client *c, return ERR_PTR(err); } +static struct p9_req_t * +p9_client_get_req(struct p9_client *c, int8_t type, const char *fmt, ...) +{ + va_list ap; + struct p9_req_t *req; + + va_start(ap, fmt); + req = p9_client_prepare_req(c, type, c->msize, fmt, ap); + va_end(ap); + return req; +} + /** * p9_client_rpc - issue a request and wait for a response * @c: client session -- 1.9.1