Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751822AbeACGnQ (ORCPT + 1 other); Wed, 3 Jan 2018 01:43:16 -0500 Received: from mail-sn1nam02on0068.outbound.protection.outlook.com ([104.47.36.68]:24848 "EHLO NAM02-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751708AbeACGmR (ORCPT ); Wed, 3 Jan 2018 01:42:17 -0500 Authentication-Results: spf=pass (sender IP is 149.199.60.83) smtp.mailfrom=xilinx.com; vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=bestguesspass action=none header.from=xilinx.com; From: Kedareswara rao Appana To: , , , , , , , , CC: , , Subject: [PATCH v2 3/4] dmaengine: xilinx_dma: Fix warning variable prev set but not used Date: Wed, 3 Jan 2018 12:12:10 +0530 Message-ID: <1514961731-1916-4-git-send-email-appanad@xilinx.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1514961731-1916-1-git-send-email-appanad@xilinx.com> References: <1514961731-1916-1-git-send-email-appanad@xilinx.com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-RCIS-Action: ALLOW X-TM-AS-Product-Ver: IMSS-7.1.0.1224-8.2.0.1013-23568.006 X-TM-AS-User-Approved-Sender: Yes;Yes X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:149.199.60.83;IPV:NLI;CTRY:US;EFV:NLI;SFV:NSPM;SFS:(10009020)(39380400002)(376002)(346002)(396003)(39860400002)(2980300002)(438002)(189003)(199004)(316002)(478600001)(47776003)(2870700001)(39060400002)(36386004)(77096006)(54906003)(110136005)(2906002)(63266004)(81156014)(4326008)(106002)(8676002)(36756003)(50226002)(8936002)(50466002)(2950100002)(59450400001)(106466001)(23676004)(7696005)(9786002)(6666003)(76176011)(5820100001)(305945005)(356003)(5660300001)(81166006)(2201001)(7416002)(107986001);DIR:OUT;SFP:1101;SCL:1;SRVR:BN6PR02MB3265;H:xsj-pvapsmtpgw01;FPR:;SPF:Pass;PTR:unknown-60-83.xilinx.com;MX:1;A:1;LANG:en; X-Microsoft-Exchange-Diagnostics: 1;BL2NAM02FT048;1:vQK/lLWLkzQD20lvQ7JgUwM2Re58JVggdj2Sy4nlOEFjI8xxevJJm9PLTlqi0itqU2RhUP3aLc+jae5A1/7Z0di3HcdArp3ga/HBXjp3Pfq+RihpL67PC8sGmdzaTLlq X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 825dab1a-205c-4fb1-5cda-08d552751ead X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(5600026)(4604075)(4608076)(2017052603307)(7153060);SRVR:BN6PR02MB3265; X-Microsoft-Exchange-Diagnostics: 1;BN6PR02MB3265;3:FOtguct0kKsSKGs5NUBF3fOaBOHUsCJ9cOA/nFziWHiseVfeTC5mSbe3DT16aWMXPs3XfLtEsaQzUj6ZbG23Kmij9RXOAcxIkQE9D4lMydKCHqtbg8uxQSC/Hjikpxol47h5D+J19iFFy39/rdepCxoMkgDAF60lKsWhBvyi6w7KY5HFDInV62a0SiAHCkND84El8lyhqVaGMytiT2np/6qufqkUiclztvGb4wkzj4202FaVnRD1kyBtTfNVuYEkfYGmrXGRzTI+UQpnO5kd3VzOfS2RpH4AfmQ+tm4y+6TMBTbMIobiiiHgnCBYR6gzDHVp/s/TRJPHyJeHn04uCUrwOQc3iW/jsDmpQxnbK68=;25:PYNzVKInW/lla4dEjIl4tM6CVv5KNXWfTZFTETBs3lp0nsM47jb3JavRdjBEpICOhMPuLj1Wpj2HK3lsY5r8CI1+kSQJYFo/+/5cWyJIwuJ0vnuJUOYuJHliRDUkLxvil+5+t8zCkUgYXWZWcYouOUJ3B/VxKkqbQ7Bqk2/kElkiyVNQeCR3unaeSHmWubuntJsI/nPpHm20CXrugOZmfrl/LETkmLBYsSJL57x7m85Fd+HbwvnCBcRBZdSv/ypBaeAogWRBPkqrQlgf15KZWKkonIvfIv5UGkXhw4Ek5r3WXK9dnCiy+de6lRbRGxY5/bZExbf400SdhTl6CUA6SQ== X-MS-TrafficTypeDiagnostic: BN6PR02MB3265: X-Microsoft-Exchange-Diagnostics: 1;BN6PR02MB3265;31:P9jp9lRWjJ/6rFBDjtauW1fQH3Hmr+IV7OxPPkS1ABBHMfIS8xSily9UDw+Pqb7X5XVot6l4WifD8z0RHBH3lYRnHRRb4eeIaiOcwCxGHLz4WB8OFg6qZ3gh7ipikbf3on0rsJ61WZxbhxK30balJvQXQcLq0tRdyvT7PGWAXUQ06hqtYw5eNjPEI4vfHZNqO29HxwjcuojZvIjvdAOX5xr9MoRIX7KpcqloG3ZfUq4=;20:i23BjBRYupcvRDY3urd+pwS7rhcVP/PN5bTX79ZekbDwqJjdwzukLtD2q/0czeZnLzNELzGA64zwrTFo4CgA+7KwixOBYSw6EEUAvURwHma9JY2dhNjXqJSu9StaRNYAIZgRlqOMVCj7CigXrPB08QTxwSBW1sgdRAwn3VTzSNKWZc809RONwPhgzjNuoYt8E/VujsW/TKOeRE7/e1zMd1D1ERKC0CwpkxCYrhDZp3MFk8USr06upMUW28HjIkjsHfHnZkfNlfge3msU2u9L+3mXFDXKct+mNndpYM9z/ZBaN3/esqgM4oPLyPY2XbWdtZQXN5u6449Ta24EUNNB+nc1KJFAtboJWZYjdgkWtK6xYCPfX91hn7vrthFau3DWz+tndGKG7tO3wJL+hR1K/9qGASRnnZqOW6ATw2kUt/SJhmSu3V8rNfZh8uZcx+j9N4AzaJbY3Ticc1NEttX3snfHgHOjzRLEuE3LHAczxh3M5x0h3CxMN9dPhHYbutzQ X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192813158149592); X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040470)(2401047)(5005006)(8121501046)(93006095)(93004095)(3231023)(944501075)(3002001)(10201501046)(6055026)(6041268)(20161123558120)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011);SRVR:BN6PR02MB3265;BCL:0;PCL:0;RULEID:(100000803101)(100110400095);SRVR:BN6PR02MB3265; X-Microsoft-Exchange-Diagnostics: 1;BN6PR02MB3265;4:PyrVsARXZsU/Td9J7XvQTTmKB7CPJ47wlSmhCWX3tiw3aT8AxpXYCzRbNjAvZtcWVvrBAF1LDWzvmOOL45uiRjCk9Pz3Q+aLW1OjLQfqVeBO0j95YU6txR+aKgPOobE3kX5pqW/dsEAEUM8jUplQMCwYWF6tCST26gaj2kiR65RYNAX0gWonZRKkP8cv36F0D/nK9HQk/LGO6zRMmlqHqMVbRRKqUXwlAvNQYtwOxs7xkqgPwFskRo5AKNM62i8FwkaS5WTJQJw3piFCfedzJoV0r/3N+spCxXkstOEGrgwWaMxe3oTbsxxlP8/qUQfQ X-Forefront-PRVS: 0541031FF6 X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtCTjZQUjAyTUIzMjY1OzIzOm5MMkhsdTFTUURoUzE1WGJuNzJ2ZUtBdGhI?= =?utf-8?B?WU5RUjIyTk1rUGxiNmp6TXN6akRMS3JKOHIvcVNtbjF6UGkxZWdGVFVLS2xo?= =?utf-8?B?Mm1WVm53VkQycXp0bi84d2Q1WHJieVduRlFCcE9TS1VNMzFkRnk3TGNBUkFs?= =?utf-8?B?dWJUMHRCUlk5a2hxR3FEOWhQQjJDdy9wSTNhUFdWOVN5ZmM0WS9JUzV2VkVG?= =?utf-8?B?NTJBM1F0aDRtWGR3S1NYbGVpcFUxS1prY0pSZGRyV3l5SFM1WFI5VjR0Ynlz?= =?utf-8?B?WlVYeWlrTWg4eHpEYzNwZ2RJaThpRTQwdUkxaUJtVmRpKzV0dGVaZHJwU2Er?= =?utf-8?B?TFFJTmU1ZVVJMkZSWldWMVdndmkwbWVSd0NNWi96QjJiM0JUeHFiSzJsWG9u?= =?utf-8?B?dnNzOG9i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UXZTwv+H3EQI/69yHy7ty9MR SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: xilinx.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Jan 2018 06:42:12.0247 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 825dab1a-205c-4fb1-5cda-08d552751ead X-MS-Exchange-CrossTenant-Id: 657af505-d5df-48d0-8300-c31994686c5c X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=657af505-d5df-48d0-8300-c31994686c5c;Ip=[149.199.60.83];Helo=[xsj-pvapsmtpgw01] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR02MB3265 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: This patch fixes the below sparse warning in the driver drivers/dma/xilinx/xilinx_dma.c: In function ‘xilinx_vdma_dma_prep_interleaved’: drivers/dma/xilinx/xilinx_dma.c:1614:43: warning: variable ‘prev’ set but not used [-Wunused-but-set-variable] struct xilinx_vdma_tx_segment *segment, *prev = NULL; Signed-off-by: Kedareswara rao Appana --- Changes for v2: --> Improved commit message title and description as suggested by Vinod. drivers/dma/xilinx/xilinx_dma.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/dma/xilinx/xilinx_dma.c b/drivers/dma/xilinx/xilinx_dma.c index 8467671..845e638 100644 --- a/drivers/dma/xilinx/xilinx_dma.c +++ b/drivers/dma/xilinx/xilinx_dma.c @@ -1611,7 +1611,7 @@ xilinx_vdma_dma_prep_interleaved(struct dma_chan *dchan, { struct xilinx_dma_chan *chan = to_xilinx_chan(dchan); struct xilinx_dma_tx_descriptor *desc; - struct xilinx_vdma_tx_segment *segment, *prev = NULL; + struct xilinx_vdma_tx_segment *segment; struct xilinx_vdma_desc_hw *hw; if (!is_slave_direction(xt->dir)) @@ -1665,8 +1665,6 @@ xilinx_vdma_dma_prep_interleaved(struct dma_chan *dchan, /* Insert the segment into the descriptor segments list. */ list_add_tail(&segment->node, &desc->segments); - prev = segment; - /* Link the last hardware descriptor with the first. */ segment = list_first_entry(&desc->segments, struct xilinx_vdma_tx_segment, node); -- 2.7.4