From patchwork Mon Aug 16 16:25:00 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julia Lawall X-Patchwork-Id: 119731 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o7GGQaBU010297 for ; Mon, 16 Aug 2010 16:26:53 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754796Ab0HPQZE (ORCPT ); Mon, 16 Aug 2010 12:25:04 -0400 Received: from mgw2.diku.dk ([130.225.96.92]:34668 "EHLO mgw2.diku.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754654Ab0HPQZC (ORCPT ); Mon, 16 Aug 2010 12:25:02 -0400 Received: from localhost (localhost [127.0.0.1]) by mgw2.diku.dk (Postfix) with ESMTP id 7C98119BE5F; Mon, 16 Aug 2010 18:25:01 +0200 (CEST) Received: from mgw2.diku.dk ([127.0.0.1]) by localhost (mgw2.diku.dk [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 25053-13; Mon, 16 Aug 2010 18:25:00 +0200 (CEST) Received: from nhugin.diku.dk (nhugin.diku.dk [130.225.96.140]) by mgw2.diku.dk (Postfix) with ESMTP id 7866619BE21; Mon, 16 Aug 2010 18:25:00 +0200 (CEST) Received: from ask.diku.dk (ask.diku.dk [130.225.96.225]) by nhugin.diku.dk (Postfix) with ESMTP id DE6A76DF894; Mon, 16 Aug 2010 18:23:33 +0200 (CEST) Received: by ask.diku.dk (Postfix, from userid 3767) id 5A8EC200C3; Mon, 16 Aug 2010 18:25:00 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by ask.diku.dk (Postfix) with ESMTP id 49C57200BD; Mon, 16 Aug 2010 18:25:00 +0200 (CEST) Date: Mon, 16 Aug 2010 18:25:00 +0200 (CEST) From: Julia Lawall To: Steve Wise , Roland Dreier , Sean Hefty , Hal Rosenstock , linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [PATCH 2/16] drivers/infiniband/hw/cxgb4: Remove unnecessary error code assignment Message-ID: MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Mon, 16 Aug 2010 16:26:54 +0000 (UTC) diff --git a/drivers/infiniband/hw/cxgb4/qp.c b/drivers/infiniband/hw/cxgb4/qp.c index 93f6e5b..73e00ed 100644 --- a/drivers/infiniband/hw/cxgb4/qp.c +++ b/drivers/infiniband/hw/cxgb4/qp.c @@ -130,11 +130,9 @@ static int create_qp(struct c4iw_rdev *rdev, struct t4_wq *wq, /* build fw_ri_res_wr */ wr_len = sizeof *res_wr + 2 * sizeof *res; - skb = alloc_skb(wr_len, GFP_KERNEL); - if (!skb) { - ret = -ENOMEM; + skb = alloc_skb(wr_len, GFP_KERNEL | __GFP_NOFAIL); + if (!skb) goto err7; - } set_wr_txq(skb, CPL_PRIORITY_CONTROL, 0); res_wr = (struct fw_ri_res_wr *)__skb_put(skb, wr_len);