Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4971081pxj; Wed, 9 Jun 2021 06:26:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy3bE/bg8E+DY1RQYuH000/b/tXAKrgypqrLAITwi9jQH6BX1+0sLVlLfXp6wsJfW1/V0jt X-Received: by 2002:aa7:d84e:: with SMTP id f14mr30718509eds.12.1623245217598; Wed, 09 Jun 2021 06:26:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623245217; cv=none; d=google.com; s=arc-20160816; b=Q0Fz62IE+oWEeTGBOi3XC1tHpguosW9CB57E1NyzQcjZu12j3QGWTxpLiDYL1Nzi8v ACQZrJXML5cGXEciLJwCvZssy60cRYmbYngjnL5+/4pVhNDuDyYm/p+dr5VZD/Uj0vJQ YwSaS6BQBqNNRlaecBZe4rbym5MIAkdPpHO8KS1T6MyetPs0QZk+czj0pv3rXIFqECY7 onc5QdCX8VBGl682n0axBgHG9PeaGGp28UbQ3R8l1vwcgJ1b4whTQem8RhpKhOVKRlta Q4JJeSGqHMpaSQHSHMehL5B6dmLXtnj3TYer2CQcQO0v8LPZhgb+BnZX49urkJv428y3 WYNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=E3rCpua38OJSdU5XyM4xtJyd6ne2BILvwlXJE/ERmyo=; b=uUAlUdCdMN0oXWaTvqkQcFmDR16KPEbB8YvYPnQpuNPF+7Znm0yopZmvqVRLLu2cFN juStJv3I5zuf5lzWQEJVwT7GMd4lLhBXGwCMyTR96XwT2g06g2zxYLc07KADKBTwWJln sZTg9hYJVGBp8d+Fp/rT7vjbeNrr9B1UGWAgOOjCWRUYO7mZRI+3NkzeI6rWkbbKUtBX MurRRazt4Fpo4hnOXZzJwAbcyRdP8MQWgk3A+8KGNKNF4fXnqmBIqvlYsoPL0EDObXWv NdRxtpdsRlL3bs14d2479xSvGi+eBDzlRhKpxvCyK17mOxbglzdu2uChBg3Rh+8dG7eK aycA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z40si2515971ede.300.2021.06.09.06.26.33; Wed, 09 Jun 2021 06:26:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237005AbhFIHGz (ORCPT + 99 others); Wed, 9 Jun 2021 03:06:55 -0400 Received: from szxga01-in.huawei.com ([45.249.212.187]:8108 "EHLO szxga01-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234657AbhFIHGy (ORCPT ); Wed, 9 Jun 2021 03:06:54 -0400 Received: from dggemv703-chm.china.huawei.com (unknown [172.30.72.56]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4G0J28721NzYsXt; Wed, 9 Jun 2021 15:02:08 +0800 (CST) Received: from dggpeml500020.china.huawei.com (7.185.36.88) by dggemv703-chm.china.huawei.com (10.3.19.46) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Wed, 9 Jun 2021 15:04:41 +0800 Received: from huawei.com (10.175.127.227) by dggpeml500020.china.huawei.com (7.185.36.88) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2176.2; Wed, 9 Jun 2021 15:04:40 +0800 From: Baokun Li To: , Vinod Koul , "Michal Simek" , Romain Perier , Allen Pais , Yu Kuai CC: , , , , , , , Hulk Robot Subject: [PATCH -next v2] dmaengine: zynqmp_dma: Use list_move_tail instead of list_del/list_add_tail Date: Wed, 9 Jun 2021 15:13:49 +0800 Message-ID: <20210609071349.1336853-1-libaokun1@huawei.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT X-Originating-IP: [10.175.127.227] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To dggpeml500020.china.huawei.com (7.185.36.88) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Using list_move_tail() instead of list_del() + list_add_tail(). Reported-by: Hulk Robot Signed-off-by: Baokun Li --- V1->V2: CC mailist drivers/dma/xilinx/zynqmp_dma.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/dma/xilinx/zynqmp_dma.c b/drivers/dma/xilinx/zynqmp_dma.c index 5fecf5aa6e85..97f02f8eb03a 100644 --- a/drivers/dma/xilinx/zynqmp_dma.c +++ b/drivers/dma/xilinx/zynqmp_dma.c @@ -434,8 +434,7 @@ static void zynqmp_dma_free_descriptor(struct zynqmp_dma_chan *chan, struct zynqmp_dma_desc_sw *child, *next; chan->desc_free_cnt++; - list_del(&sdesc->node); - list_add_tail(&sdesc->node, &chan->free_list); + list_move_tail(&sdesc->node, &chan->free_list); list_for_each_entry_safe(child, next, &sdesc->tx_list, node) { chan->desc_free_cnt++; list_move_tail(&child->node, &chan->free_list);