Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp1673378ybt; Mon, 15 Jun 2020 06:38:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxuH3aodBbg0KcjbHJY4w7OuAA3p53ym7dTbTxy6tuyGsh18UmC6PA2Vgmpd0gCCfsH7fhf X-Received: by 2002:a17:906:7208:: with SMTP id m8mr26612665ejk.544.1592228336386; Mon, 15 Jun 2020 06:38:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592228336; cv=none; d=google.com; s=arc-20160816; b=qZ+71uUFGzI+NW5svaOKIzS/vN7qUMhp48P9wsNpX3EbCYYUgjffWjXlomkfUxDQtD hFmqbWVbWSdjdbwNnvq94YtkT1b5Qs9SUHmYh0OZkBbcVONxeoKPJZuH/SgCGJyPIDbo FZpvsW/fJlKV2jxT9ePRvnWX6GkqqYOPHzof376h2GiKtL4GBOrIpE9we6gHZdVfUXGA 6568LsUtn6dStxjzUa7cTBi0VWUKjYAdw4T7RziEYwJeDrEQqynqBQcFZKkSs+bmtJ53 6a4LORtbAdf0Om3D/yrABlK8r1OtPvRbx2Gw7QXPcMffrkL89NPwT2cNmqSyJ7fH3N40 GF8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=AhiJlbtzdjmAgARjRUOdTDK4cyx+n2CxBOLoASsjkfY=; b=xhVUL4nRuR7iwY+8QV9wp+WDUUCz+O45xM3AvLYS7HwfvtA2xkhxo1j9wA5GnAdzme CsxUDOuPdyhkEl3H9o3G03ooSu6uYaFpKy8oi4BIOOjIJ9tXsQvlV4lSyPlnXiJC7Dri GHH/8r1CTMi6wcBIy4grM2yDcoNeFFU8TAtZ9PzbareUfnTulT/MdjpYxIISxhyl5XlW 6mhuZP2Z7R8UozDxl6TcQiT3e6LCHdWKbXbjaiQP06z0EV++ZkcdocBxWL7K6O6IjbnB tiMmjcRB6gnvi+c+3f/SGpzin/7h3VxOQPKAIJSsZZA7YzKeep7oC+Wu5xYx6vb8zyrc G1YA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Gukh6y5L; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g12si9119268ejx.161.2020.06.15.06.38.33; Mon, 15 Jun 2020 06:38:56 -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; dkim=pass header.i=@kernel.org header.s=default header.b=Gukh6y5L; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730477AbgFONgt (ORCPT + 99 others); Mon, 15 Jun 2020 09:36:49 -0400 Received: from mail.kernel.org ([198.145.29.99]:43166 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730109AbgFONgt (ORCPT ); Mon, 15 Jun 2020 09:36:49 -0400 Received: from localhost (fw-tnat.cambridge.arm.com [217.140.96.140]) (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 25A9E207D3; Mon, 15 Jun 2020 13:36:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592228208; bh=Hs7nuZ6Ujtne3R8pyXXb7XHOf/MxT4zald4XbINg9kg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Gukh6y5LOywbiptR4BP1qZMvMTmpFHvYXpm1nVZvZ9nV80CgKS9R0DTuQq3twmQrp U81TWQ1d3ltRvFYFgLou3mfE6NzIwPBeuXEvuhmp3YivqKtbeeG+suvV19pr/yOZ3B 4c30at3Lxnycj3JIwevk+++E03O+4Cx6BKNdY2kQ= Date: Mon, 15 Jun 2020 14:36:46 +0100 From: Mark Brown To: Vladimir Oltean Cc: Marc Kleine-Budde , Krzysztof Kozlowski , Thomas Gleixner , Vladimir Oltean , linux-spi , lkml , Wolfram Sang , stable@vger.kernel.org, Pengutronix Kernel Team Subject: Re: [PATCH v2 1/3] spi: spi-fsl-dspi: Fix external abort on interrupt in exit paths Message-ID: <20200615133646.GU4447@sirena.org.uk> References: <1592208439-17594-1-git-send-email-krzk@kernel.org> <20200615123052.GO4447@sirena.org.uk> <20200615131006.GR4447@sirena.org.uk> <20200615132441.GS4447@sirena.org.uk> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="i483Pv/KqyjCUwB1" Content-Disposition: inline In-Reply-To: X-Cookie: Offer may end without notice. User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --i483Pv/KqyjCUwB1 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Mon, Jun 15, 2020 at 04:29:15PM +0300, Vladimir Oltean wrote: > On Mon, 15 Jun 2020 at 16:24, Mark Brown wrote: > > I see - this could be fixed by having the interrupt handler bounce the > > clock on, there's a little overhead from that but hopefully not too > > much. That should also help with the remove case I guess so long as the > > clock is registered before the interrupt is requested? > Doesn't this mean that we risk leaving the clock enabled during suspend? If we suspend with the interrupt handler running but IIRC the suspend sequence will allow interrupt handlers to complete. > Is there any function in the SPI core that quiesces any pending > transactions, and then stops the controller? I would have expected > spi_controller_suspend to do that, but I'm not sure (it doesn't look > like it). spi_stop_queue() should do this (but will time out if the queue is too busy). It doesn't stop new transactions being issued, I'm guessing because that'll most likely cause more problems than it solves but that code predates my involvement. --i483Pv/KqyjCUwB1 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAl7neW0ACgkQJNaLcl1U h9Awewf/S60KrRHANcrt8yuP4f/0IVWXkNY5EEnxhSNYxYSGJpNXf0W4HNqSe1Yq 4VO4Wb4cRXKId51u9uCltVuOosIyMMxtIGfT6qE+KS9yj/J7i0fwx/es5ULmYudk ncz1FbnZSCiK7vpBqsfwrzHeXBBTAOnnJplWozejxLXhec2fLPwhA0kU68AGyQFw QOaKoRUJSejGltsnaPCdmi7d+h4ET165V3NZyZ/WMfq36yq9oF4IHsTnIMydZaz4 5svVPIKpqUobu/52IVDZ9Yn/SWkyWvLXKT6yVDKplLzCntW5SL8ihBWAMGS+zfgS rXihk1/dR5lRMfaFiEsMricY8Xaa8A== =bZvG -----END PGP SIGNATURE----- --i483Pv/KqyjCUwB1--