From patchwork Sat Oct 29 16:19:53 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wei Yongjun X-Patchwork-Id: 9403963 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5DC9A60588 for ; Sat, 29 Oct 2016 16:20:11 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4DB5929012 for ; Sat, 29 Oct 2016 16:20:07 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 40295290CD; Sat, 29 Oct 2016 16:20:07 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AC15329012 for ; Sat, 29 Oct 2016 16:20:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932352AbcJ2QUF (ORCPT ); Sat, 29 Oct 2016 12:20:05 -0400 Received: from mail-pf0-f194.google.com ([209.85.192.194]:33466 "EHLO mail-pf0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932255AbcJ2QUF (ORCPT ); Sat, 29 Oct 2016 12:20:05 -0400 Received: by mail-pf0-f194.google.com with SMTP id a136so869154pfa.0 for ; Sat, 29 Oct 2016 09:20:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=9nv0fJ2RpmdxcDn79Kv4kvIoEkasgnFS82og5NZpT1Y=; b=lA9BchXGGuqMiSJSf+oVFMmavfGCstnRnWVM4HwNyh5/ehuNyUJ0alAc4D3IM4jLcv BFMZzSnlQ2Zd+mad9Wt7RPsAOeFGHb5bA6sWsDE5ZH0fN4oHcHigd5MVaE64Xl8lIOjJ KOdCunemhcrg4V+070goAT1tNu8pYhes+WJW129K2SbwUlF1cOhe0D51aHDrzuSpizMS 0+1Fx7tY7uH2kbQoILxATZPHVoTQlqc8ynKkwx7Vc0DgO9X6/T2fpdcndn19AozT+MFk 9+4ZHQUdRvMPHiBJ591yxHdejH1O9SgAjv4fdqqJejcH40PATdL5PKYjgWqCX6KNEwqh VGOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=9nv0fJ2RpmdxcDn79Kv4kvIoEkasgnFS82og5NZpT1Y=; b=izYo2pKKKtJcoX88FaMoLGNPxUeB3WlZDutiJeh+Ad446nUX7OX3q44IlJw1iVwknb xQYGUkPvn+GF3dVQrP+rRLeWvRNLosvW5DaWRhl7kDouvbTpLyCNkbqlc0n76HMCaGy/ NpQY422zEc6rzpnobQIXzXq1FF3HpVDwbEDOkqwUfKdvSuEbVvlrkqCRdiVp4pqde02L oVO5a+MpAGt6BlUD8FbJPNnnbo912Xn0ipw+JplAkEmBxrAOjREZE4rurQOAO1WI2Xnn pf1hmdmx8onrKo4sZMWYaLhHAmM0s7/ax25gC/kCZz6yLBtkYhWu0TJNWYUyHOFPpzRz hmcA== X-Gm-Message-State: ABUngvf3JSaD3szvooOE45CnX8daE4QozmRM1/JTxrcGRBgZkwP72Vq6YD22BWodxRs+2Q== X-Received: by 10.98.14.197 with SMTP id 66mr34592342pfo.123.1477758004676; Sat, 29 Oct 2016 09:20:04 -0700 (PDT) Received: from 192.168.0.37 (ec2-52-192-197-227.ap-northeast-1.compute.amazonaws.com. [52.192.197.227]) by smtp.gmail.com with ESMTPSA id 123sm12991914pfe.41.2016.10.29.09.20.00 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 29 Oct 2016 09:20:04 -0700 (PDT) From: Wei Yongjun To: Doug Ledford , Sean Hefty , Hal Rosenstock , Ram Amrani , Rajesh Borundia Cc: Wei Yongjun , linux-rdma@vger.kernel.org Subject: [PATCH -next] qedr: Use list_move_tail instead of list_del/list_add_tail Date: Sat, 29 Oct 2016 16:19:53 +0000 Message-Id: <1477757993-32186-1-git-send-email-weiyj.lk@gmail.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Wei Yongjun Using list_move_tail() instead of list_del() + list_add_tail(). Signed-off-by: Wei Yongjun Reviewed-by: Leon Romanovsky Acked-by: Ram Amrani --- drivers/infiniband/hw/qedr/verbs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/infiniband/hw/qedr/verbs.c b/drivers/infiniband/hw/qedr/verbs.c index a615142..cdaddf9 100644 --- a/drivers/infiniband/hw/qedr/verbs.c +++ b/drivers/infiniband/hw/qedr/verbs.c @@ -2413,8 +2413,7 @@ static void handle_completed_mrs(struct qedr_dev *dev, struct mr_info *info) */ pbl = list_first_entry(&info->inuse_pbl_list, struct qedr_pbl, list_entry); - list_del(&pbl->list_entry); - list_add_tail(&pbl->list_entry, &info->free_pbl_list); + list_move_tail(&pbl->list_entry, &info->free_pbl_list); info->completed_handled++; } }