Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp1466842ybi; Fri, 2 Aug 2019 16:35:10 -0700 (PDT) X-Google-Smtp-Source: APXvYqzOrYZjSXEY0TyLT41tqdGJ7ZY4ZrAYbNjNslRxqfv9jjSoo+/MR1A62E/5LCyld7Q2mWZ3 X-Received: by 2002:a63:9e56:: with SMTP id r22mr69628880pgo.221.1564788909843; Fri, 02 Aug 2019 16:35:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564788909; cv=none; d=google.com; s=arc-20160816; b=aBs91ixvCRhdxIb5un0Tojfg/SdCkMr3h8Gwv6e3jObkQIV5+duhEOJ+yLx/CsPQB9 YmX+l45cQpvqXxHyTlATZ2eJCRWSQ2n6IMYowYdyBCwxGgfFyuIsTBNTBmdTf0oo92sH NGal4mmTlk8pXK5uVxoCswfdSMv5edk5YUvoPrswlYDOBt0epkdeG4MN4mFA9UJyMwJV 9K2bUXLxuhsGziKyr7sK+sb/+jMV/ulYy62FLSoRwhGHv09micTIxaWHeyweWPJZoF5s yCXDnj5lwiq5N79eTBwFcpEi5B0DsMrKsO96WutadTko/HmnkPTvNFgdLAVOoio6q4lq J1aA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:dkim-signature:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=iWRDIXuKhFHou0kB3cN1+ZlnEuWKXRrrc3TGXxnLF+o=; b=QRbl7guQRc68/jClzzcdGy5qYuyJfbDE6aBV8teTGlZXfqOaDDItpGEKHEHe57pdDN yJJR8KdM8lIt8IJSQt0PO9y7LLLNFqD0YWmWTYDzhGAGofkbPKLYmaJUVyI1BxjN/eZC vpEmYlqX5qe9MyxqJ93o/T1RdRk6TU4F74Z+Z7COxOR8pMHwR7CpKWRdvXCvRLOR+aPe 9MaRrLAgeLsOh2dyMx/EaogDHA1AcLQ6HxI1I/vRjPUKotbIciX3/BjWPWigZ5ZryKUE yi4J98IcS4Kb3K37TXmZshGJraVyrjSsZcA4GZGiuSGvY2ceFVjhYsg1SxuV8wHRGiju aygw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b=AdtNFlSp; 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=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x3si17254198plb.164.2019.08.02.16.34.54; Fri, 02 Aug 2019 16:35:09 -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=@nvidia.com header.s=n1 header.b=AdtNFlSp; 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=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2392929AbfHBNFl (ORCPT + 99 others); Fri, 2 Aug 2019 09:05:41 -0400 Received: from hqemgate15.nvidia.com ([216.228.121.64]:4503 "EHLO hqemgate15.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388240AbfHBNFk (ORCPT ); Fri, 2 Aug 2019 09:05:40 -0400 Received: from hqpgpgate101.nvidia.com (Not Verified[216.228.121.13]) by hqemgate15.nvidia.com (using TLS: TLSv1.2, DES-CBC3-SHA) id ; Fri, 02 Aug 2019 06:05:49 -0700 Received: from hqmail.nvidia.com ([172.20.161.6]) by hqpgpgate101.nvidia.com (PGP Universal service); Fri, 02 Aug 2019 06:05:39 -0700 X-PGP-Universal: processed; by hqpgpgate101.nvidia.com on Fri, 02 Aug 2019 06:05:39 -0700 Received: from tbergstrom-lnx.Nvidia.com (172.20.13.39) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Fri, 2 Aug 2019 13:05:39 +0000 Received: by tbergstrom-lnx.Nvidia.com (Postfix, from userid 1000) id 3241140DF8; Fri, 2 Aug 2019 16:05:37 +0300 (EEST) Date: Fri, 2 Aug 2019 16:05:37 +0300 From: Peter De Schrijver To: Dmitry Osipenko CC: Sowjanya Komatineni , , , , , , , , , , , , , , , , , , , , , Subject: Re: [PATCH V6 01/21] irqchip: tegra: Do not disable COP IRQ during suspend Message-ID: <20190802130537.GB3883@pdeschrijver-desktop.Nvidia.com> References: <1563738060-30213-1-git-send-email-skomatineni@nvidia.com> <1563738060-30213-2-git-send-email-skomatineni@nvidia.com> <20190725095502.GM12715@pdeschrijver-desktop.Nvidia.com> <20190725103348.GN12715@pdeschrijver-desktop.Nvidia.com> <20190725103813.GO12715@pdeschrijver-desktop.Nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: X-NVConfidentiality: public User-Agent: Mutt/1.9.4 (2018-02-28) X-Originating-IP: [172.20.13.39] X-ClientProxiedBy: HQMAIL107.nvidia.com (172.20.187.13) To HQMAIL107.nvidia.com (172.20.187.13) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1564751149; bh=iWRDIXuKhFHou0kB3cN1+ZlnEuWKXRrrc3TGXxnLF+o=; h=X-PGP-Universal:Date:From:To:CC:Subject:Message-ID:References: MIME-Version:Content-Type:Content-Disposition: Content-Transfer-Encoding:In-Reply-To:X-NVConfidentiality: User-Agent:X-Originating-IP:X-ClientProxiedBy; b=AdtNFlSpz81uTllfhqGBNz872kPPOqcfTn2+V15vEhHh4FkLvnh20CjgOa7iI79Q3 c9KO/+NdJdsfrL1qlvKJPecqls3hOFaDMW/UhJP3MOyxh86lnQk/DCS1cCEEPVlmKU m/U2aPW0Zh3EPMU4aehJQ9iMQya/5+pAbeGoCqY7ak7If7Jhqv0qn2hfpRbOfiJ+7Y kVNE7IbZ0e/xBb8cUp+wbR2mCipkGS8mRsAaPYTnyfKOJ7RdxSDYMQ6VmJkMeExDUp 0h0WKpYxpEVnT7kSHWG2NdkzIU8wFVh351o/3Bp2PfjBMXSmurDidsUldCosbjaHMB 95SC0HDs2MYGQ== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jul 25, 2019 at 01:59:09PM +0300, Dmitry Osipenko wrote: > 25.07.2019 13:38, Peter De Schrijver =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > > On Thu, Jul 25, 2019 at 01:33:48PM +0300, Peter De Schrijver wrote: > >> On Thu, Jul 25, 2019 at 01:05:13PM +0300, Dmitry Osipenko wrote: > >>> 25.07.2019 12:55, Peter De Schrijver =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > >>>> On Mon, Jul 22, 2019 at 12:54:51PM +0300, Dmitry Osipenko wrote: > >>>>> > >>>>> All Tegra SoCs support SC7, hence the 'supports_sc7' and the commen= t > >>>>> doesn't sound correct to me. Something like 'firmware_sc7' should s= uit > >>>>> better here. > >>>>> > >>>>>> + writel_relaxed(~0ul, ictlr + ICTLR_COP_IER_CLR); > >>>>> > >>>>> Secondly, I'm also not sure why COP interrupts need to be disabled = for > >>>>> pre-T210 at all, since COP is unused. This looks to me like it was > >>>>> cut-n-pasted from downstream kernel without a good reason and could= be > >>>>> simply removed. > >>>> > >>>> I don't think we can rely on the fact that COP is unused. People can > >>>> write their own code to run on COP. > >>> > >>> 1. Not upstream - doesn't matter. > >>> > >> > >> The code is not part of the kernel, so obviously it's not upstream? > >> > >>> 2. That's not very good if something unknown is running on COP and th= en > >>> kernel suddenly intervenes, don't you think so? > >> > >> Unless the code was written with this in mind. > >> >=20 > In that case, please see 1. ;) >=20 In general the kernel should not touch the COP interrupts I think. > >=20 > > Looking at this again, I don't think we need to enable the IRQ at all. >=20 > Could you please clarify? The code only saves/restores COP's interrupts > context across suspend-resume. The sc7 entry firmware doesn't use interrupts. Peter.