Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1982413yba; Tue, 2 Apr 2019 21:44:14 -0700 (PDT) X-Google-Smtp-Source: APXvYqw5BY3pClZjPt+Q8LZtntrFShPJmlD+GUh1xkWxG2ThKwNyhO9Wv98Y7XftqkPVM1n0+Nok X-Received: by 2002:aa7:8a92:: with SMTP id a18mr73532599pfc.218.1554266654546; Tue, 02 Apr 2019 21:44:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554266654; cv=none; d=google.com; s=arc-20160816; b=vv+VwpAZte8TA2kFp7mMIbESEHihif2ePqbPS1O6emrs385ceBwmddHClJ9Qd0XQd3 kt2zq585myS55URAfxl4Qq+euSCT7KvW5e6mjACynvrmdDxd59WZY3kPChKV7d2S9n3U 3A3lQEGcMKyKkVTmt24ZQWpr04x/zYG5kb/OviG33Yhhf1XMWvcsPVES2hE147PXAYjg i3MPdlEtQzy2CSQ6j3J+6ddqrxigimZdVTtrjhtWSDQqMGI3z2e8TwlJcjRw7zPP1ffX d9SLps1qsiZ2rlXvFdZBEAqHYjCPejvThOXnAJbhUuou4TXaju6wguUZ0Bs01a9bgrSG HeIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:message-id:in-reply-to:subject:cc:to :from:dkim-signature; bh=NPeduGz+9mec+3IumoCAqAM0ew2GTeDpO/fBBwD4BzI=; b=O6atsj3PWMhkX07v5WKUcQHyJoHmLOJFsIAC2zrhB1PKTLoIaUZpyid7xcqpAZWG2A VC4yvQ1uN7b4TvVlPq53kFcJ6tARLDq0wmAZ1VGpSIYqHmwuUpAR3dhcm5shPSKw+Cye yCl+cdEw4aNeSj9yWA5etQ/HUYt0kdWzagidyaJW9wX3AVBolQr4DXjzgQdr3LGtaVNW tg/Am5iIOpYOQL5N5VDVIA9Ys4T/5ll14FQ/+hTWyv/f0gMBYkBaAmNzqxdQem+9eVLI s7VblmiJFA93vstCircq1gWbnryd7B7gy7CgTwVjkiIhqYtnhTs/Kkl50Dtn0bGEVp2R mF2A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=va9nuMp8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c24si5427454plo.220.2019.04.02.21.43.59; Tue, 02 Apr 2019 21:44:14 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=va9nuMp8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728793AbfDCEm3 (ORCPT + 99 others); Wed, 3 Apr 2019 00:42:29 -0400 Received: from heliosphere.sirena.org.uk ([172.104.155.198]:40584 "EHLO heliosphere.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728764AbfDCEm3 (ORCPT ); Wed, 3 Apr 2019 00:42:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=Date:Message-Id:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner: List-Archive; bh=NPeduGz+9mec+3IumoCAqAM0ew2GTeDpO/fBBwD4BzI=; b=va9nuMp87KKl H9Oyv7t5rWCetz87+yn7B6tUwChLvcGOmJPoTSrKx5RJ0UeE24xUXPcVwdYr0Srzwl+RwpH5zqlkz nNtjEC22Oj4kdugBPdjSiVlc0E744J2/f9yhm6cTkbJFoOXmELTalWItoOE6XD2Sg0T81JG6x6r/v 2UJuE=; Received: from [147.50.13.10] (helo=finisterre.ee.mobilebroadband) by heliosphere.sirena.org.uk with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hBXjE-00040V-L9; Wed, 03 Apr 2019 04:42:24 +0000 Received: by finisterre.ee.mobilebroadband (Postfix, from userid 1000) id E7247440083; Wed, 3 Apr 2019 05:42:21 +0100 (BST) From: Mark Brown To: Clark Wang Cc: Mark Brown , "broonie@kernel.org" , "linux-spi@vger.kernel.org" , "linux-kernel@vger.kernel.org" , linux-spi@vger.kernel.org Subject: Applied "spi: lpspi: add missing complete in abort func at dma mode" to the spi tree In-Reply-To: <20190402124609.22157-1-xiaoning.wang@nxp.com> X-Patchwork-Hint: ignore Message-Id: <20190403044221.E7247440083@finisterre.ee.mobilebroadband> Date: Wed, 3 Apr 2019 05:42:21 +0100 (BST) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The patch spi: lpspi: add missing complete in abort func at dma mode has been applied to the spi tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark From 8863eca8c46affaa91ae35390b00358b925483eb Mon Sep 17 00:00:00 2001 From: Clark Wang Date: Tue, 2 Apr 2019 12:45:53 +0000 Subject: [PATCH] spi: lpspi: add missing complete in abort func at dma mode Add the missing complete operations for dma_completion to fix the problem of blocking at the wait_for_completion_interruptible() function when use spi_slave_abort(). Signed-off-by: Clark Wang Signed-off-by: Mark Brown --- drivers/spi/spi-fsl-lpspi.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/drivers/spi/spi-fsl-lpspi.c b/drivers/spi/spi-fsl-lpspi.c index 4de8eb378752..2ad9d6262c2b 100644 --- a/drivers/spi/spi-fsl-lpspi.c +++ b/drivers/spi/spi-fsl-lpspi.c @@ -482,7 +482,13 @@ static int fsl_lpspi_slave_abort(struct spi_controller *controller) spi_controller_get_devdata(controller); fsl_lpspi->slave_aborted = true; - complete(&fsl_lpspi->xfer_done); + if (!fsl_lpspi->usedma) + complete(&fsl_lpspi->xfer_done); + else { + complete(&fsl_lpspi->dma_tx_completion); + complete(&fsl_lpspi->dma_rx_completion); + } + return 0; } -- 2.20.1