Received: by 2002:a25:b794:0:0:0:0:0 with SMTP id n20csp779640ybh; Sat, 3 Aug 2019 09:37:03 -0700 (PDT) X-Google-Smtp-Source: APXvYqy1htmkN1PcnBgjbx5RgmH8sT3RcE7J7H5k6ckZ4RPdSu0NL9cwk6vrf+J647OGsTxuYHO6 X-Received: by 2002:a17:90a:ac0e:: with SMTP id o14mr10130353pjq.142.1564850223008; Sat, 03 Aug 2019 09:37:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564850223; cv=none; d=google.com; s=arc-20160816; b=YssIimz81Jei2f+YT372Wgv0pRmeTm8UMY25O6atai4OYU1SOFgBzja4TMQCbfV3f3 ynFd4qvk5e8kWUn+6eth4UEQHJtvF8kIQh0dTkdpyZihFV2rsacFwV1ts5VLdCmhvN3Z DTdu1CFOZEiPyQHajjc+BNJ1pikikHly2IC2i9u6yO5UIgQ8/+fjDaQxul+POx4gK1cp tRc/TeqBvhZb7gWl5cbVypQIZIPjs/RpA2NSREMV7rF0tEC6RtcNfle/mo7oIKiuju6x grWSUsMwvsIXkSG13Z32383Ydt84wzh8m3ovuP7k6VtqU9Nyke897hChfs6pBTw8chRd GqMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=m01E/00kIIUrZ+us6qTkntaWmvfO8MGjTN9DZjqTTM4=; b=mTBI0JCSmJcYK6Cgm0E/iEEyArnv5ghKdEFLBHgF33ZFdqX8z8a8gHCp7mSYm2v+VD 2VzglRbsHQbJ+wyUFPS4I8Xo6rQouXQAmGq/+mZjncp/BPaGtn1CjctRgriJjtFpyjLS Eyc7fCTa6wKJHAE506tlYG/mKwNZbovC3GXyjEqDJ1O6QV2OrjUCuHC5ubPwbqvQ8dEu TWszFDz+PLLnB8i92wCI6mrpDtywdwA3A7Hgo5pA3k2DDFzXbjc5Rc2M1K+ItRj6GD5S TZo7/O5CySQ3b7MrCg5LnJvY1k+XYsuZ5RWJVEkhHYqOKDbvHcT5TFepVSt/Ac82AT7D PRIA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=LAdAuboH; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o13si8805608pjr.101.2019.08.03.09.36.48; Sat, 03 Aug 2019 09:37:02 -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=@gmail.com header.s=20161025 header.b=LAdAuboH; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405462AbfHBRfb (ORCPT + 99 others); Fri, 2 Aug 2019 13:35:31 -0400 Received: from mail-lf1-f65.google.com ([209.85.167.65]:37246 "EHLO mail-lf1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2405108AbfHBRfa (ORCPT ); Fri, 2 Aug 2019 13:35:30 -0400 Received: by mail-lf1-f65.google.com with SMTP id c9so53435169lfh.4; Fri, 02 Aug 2019 10:35:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=m01E/00kIIUrZ+us6qTkntaWmvfO8MGjTN9DZjqTTM4=; b=LAdAuboHztw2JZLafdgtT4UzeS6mncq1WKhvo7JyiSvSF0vyS3isLkwFQqzG0jKKpk ZghWSAlT/5CZGGwhFgXqGtPeZ/LfjQlgTx3E5AghaB5qUdQ2WllUyvxX/dowJBtNzVUF LFPJAZox16R/ZWpDSEC7NHXsBN6PZ/GKBTdLJho0tEIWT25IPgejuqKDLabN5Oduz5W9 J+NyLp1voKwSQg7PL832WiDwrty7Ea7e/JIL8zXVZi8+0azrxZ/SaJl3NnRYEOqC0Q2T kitin+A76BSUfE/SmIkMmNN7vsk/R+p/oEvwqRn0PS1Bmn7/FfSWmtkm6jj996+GQ/vO Znpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=m01E/00kIIUrZ+us6qTkntaWmvfO8MGjTN9DZjqTTM4=; b=MdsEwqFyq51tlP5dAb9bd6aO14lQA7WrbHVNkEdb9KpM3Kqvk8Ji1wmnE0sX/0Wc5V ubWvNluJinZ2R/wtgfps+nH0t/pCU0OZwjVQjcnSiuIDKR+FEDgwyOXymcNy1A+bIckQ +iXhkue4Eg5JsqOyViuLyeh5sjKlDtL141tWwQbQKCuJszwtPS5+idZm88jgvsEbA1XK Lbd7J1HJrDzzIzm0VPM6HmcVpjCwR+ZswuVCBh0PV4A/21LoGFz022ElmxyuwiSc+IqH h4HbknOCSyMzhMUHYd0kFmKNKypiEHX/Aw23Qtzdk5yIJ95YhYfiJSkMyqy2XzyI7RC2 +OGA== X-Gm-Message-State: APjAAAVV3jzPiImSAD0Em0NK8btqk/mNmHp2+sPUuvlDbPo31w5NNdb4 0AZFczMrLA5E2OAUmZpIvtvSPwN2 X-Received: by 2002:ac2:50c4:: with SMTP id h4mr62216920lfm.104.1564767327937; Fri, 02 Aug 2019 10:35:27 -0700 (PDT) Received: from [192.168.2.145] (ppp91-78-220-99.pppoe.mtu-net.ru. [91.78.220.99]) by smtp.googlemail.com with ESMTPSA id k12sm12901127lfc.8.2019.08.02.10.35.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 02 Aug 2019 10:35:26 -0700 (PDT) Subject: Re: [PATCH V6 01/21] irqchip: tegra: Do not disable COP IRQ during suspend To: Peter De Schrijver Cc: Sowjanya Komatineni , thierry.reding@gmail.com, jonathanh@nvidia.com, tglx@linutronix.de, jason@lakedaemon.net, marc.zyngier@arm.com, linus.walleij@linaro.org, stefan@agner.ch, mark.rutland@arm.com, pgaikwad@nvidia.com, sboyd@kernel.org, linux-clk@vger.kernel.org, linux-gpio@vger.kernel.org, jckuo@nvidia.com, josephl@nvidia.com, talho@nvidia.com, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org, mperttunen@nvidia.com, spatra@nvidia.com, robh+dt@kernel.org, devicetree@vger.kernel.org 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> <20190802130537.GB3883@pdeschrijver-desktop.Nvidia.com> From: Dmitry Osipenko Message-ID: Date: Fri, 2 Aug 2019 20:35:25 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 MIME-Version: 1.0 In-Reply-To: <20190802130537.GB3883@pdeschrijver-desktop.Nvidia.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 02.08.2019 16:05, Peter De Schrijver пишет: > On Thu, Jul 25, 2019 at 01:59:09PM +0300, Dmitry Osipenko wrote: >> 25.07.2019 13:38, Peter De Schrijver пишет: >>> 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 пишет: >>>>>> On Mon, Jul 22, 2019 at 12:54:51PM +0300, Dmitry Osipenko wrote: >>>>>>> >>>>>>> All Tegra SoCs support SC7, hence the 'supports_sc7' and the comment >>>>>>> doesn't sound correct to me. Something like 'firmware_sc7' should suit >>>>>>> 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 then >>>>> kernel suddenly intervenes, don't you think so? >>>> >>>> Unless the code was written with this in mind. >>>> >> >> In that case, please see 1. ;) >> > > In general the kernel should not touch the COP interrupts I think. > >>> >>> Looking at this again, I don't think we need to enable the IRQ at all. >> >> Could you please clarify? The code only saves/restores COP's interrupts >> context across suspend-resume. > > The sc7 entry firmware doesn't use interrupts. Okay, it shouldn't hurt to clean up the LIC's code a tad by removing the COP's bits, will make a patch.