Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp1800660ybb; Thu, 26 Mar 2020 07:35:08 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuJstpj9V6EiSs31cvgx7/xl+TMrMK+YXWMQbYfTbsBDt2mKkNao7ywiPEVmM9Yc31EJrYh X-Received: by 2002:a05:6830:146:: with SMTP id j6mr6369567otp.117.1585233308155; Thu, 26 Mar 2020 07:35:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585233308; cv=none; d=google.com; s=arc-20160816; b=CoHJPuFEtn3oFv7T3XTtCIApqvEvfY1LjEmHvJ/GIy7GvTWeGlNrKHdme4GCkmTcrZ NNDrbm7McD/TRdDxWKsZN0QCfPWpZqnwEW1rJohPRYUJqqSv7HQXop109iAoOfGcAENe uCPriREGrx1Q8fu2485FWrj0o2pBfYesr2356nU8io7EKmec/FxxL6DUAAEGG/VeFn9d nPCWth0oMSgubDZfWEZ7v8B4wbL3Jola56KFSMXOA7TrWAlXxAYym+a6fcp61A/YSTQD Lgg3a61ggLRAFLZh141B+A8nAGQUVj0B1NWkMCk4Wfym/hjbhvji7QV1G5WqCwIYO9PL nhsA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=dqUa57knWjnCSzNNgyfhaDNq766HxaKLXO0WTmKC87s=; b=omMju8wlRwe7hevv33SeFVUPTKCxW72NHxTPNf/Xj+rmbC6OK/CslUcOWp6eqnPaPJ FZLx6+NeTQ9dPUhC52DCGEk2TAZwVVgvJowjAaY8Kk3T4f9cj+NHeeIC8vZYWvcaPdHh UE9pTMYhShkZGymuP2n7IQjKdk1T8BLzXGYZF5YP76W9bris3xeXaNfK+Vu2M/KnH0iU V9MalajbOH7S5hfHcAHUMWrGkwDjS5pUG0Uclx5YvmbdeYazx6y1zVNI8b3E1CiZk2Ne ZaVIuI0JAjUpog3q5mN7irQCUTvp2JYifVc9Ri5RrK8z47daFMvLSLIA0Kg0hAb5lZ+A NBiQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=iP1jZIWD; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x8si1165945otb.140.2020.03.26.07.34.55; Thu, 26 Mar 2020 07:35:08 -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=pass header.i=@kernel.org header.s=default header.b=iP1jZIWD; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728341AbgCZOcl (ORCPT + 99 others); Thu, 26 Mar 2020 10:32:41 -0400 Received: from mail.kernel.org ([198.145.29.99]:42630 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727944AbgCZOck (ORCPT ); Thu, 26 Mar 2020 10:32:40 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5ED042073E; Thu, 26 Mar 2020 14:32:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585233158; bh=2unZXsfXGiiwQhWbjl1kP114RQvv7sM/ehc4It/7EfI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=iP1jZIWDDtdVjpcWzS6bxigS02fS6kEKL1j+a4h8tVzbngrPYZixeAIuDwj8ScSyO vqYVzznYonRgx5V5CeExlKr2pgebxEgQ0Cg3Fkvdq2llY7UbFAM+DeMTax9nJadNOS 0doJMQqMbOhkJ3OeZ6TNH1yj0BxSStkdr8vFjLP0= Date: Thu, 26 Mar 2020 15:32:36 +0100 From: Greg Kroah-Hartman To: Leonard Crestez Cc: Michael Walle , "linux-serial@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Jiri Slaby , Andy Duan Subject: Re: [PATCH v2 1/2] tty: serial: fsl_lpuart: move dma_request_chan() Message-ID: <20200326143236.GA1372760@kroah.com> References: <20200325090658.25967-1-michael@walle.cc> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Mar 25, 2020 at 06:05:16PM +0000, Leonard Crestez wrote: > On 2020-03-25 11:07 AM, Michael Walle wrote: > > Move dma_request_chan() out of the atomic context. First this call > > should not be in the atomic context at all and second the > > dev_info_once() may cause a hang because because the console takes this > > spinlock, too. > > > > Fixes: 159381df1442f ("tty: serial: fsl_lpuart: fix DMA operation when using IOMMU") > > Reported-by: Leonard Crestez > > Signed-off-by: Michael Walle > > --- > > changes since v1: > > - instead of just moving the dev_info_once() out of the spinlock protected > > section, move the whole dma_request_chan(). Thanks Andy! > > > > I've tested this on my board. Andy, Leonard, can you double check it? For > > all which are not aware, this deadlock happens only if you have the kernel > > console output on the lpuart, so if someone wants to test it, make sure you > > have something like console=ttyLP0,115200. > > > > drivers/tty/serial/fsl_lpuart.c | 36 +++++++++++++++++++++------------ > > 1 file changed, 23 insertions(+), 13 deletions(-) > > Tested-by: Leonard Crestez > > Since the original commit only made it into next it might make sense to > squash the commits in the tty tree. > > This way future bisections won't get stuck on a boot failure. My tree does not rebase, sorry. And neither should any other public git tree without really really good reasons. thanks, greg k-h