From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 05989C433EF for ; Thu, 4 Nov 2021 11:06:17 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id BDADA611AE for ; Thu, 4 Nov 2021 11:06:16 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org BDADA611AE Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=nxp.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:In-Reply-To:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=nYJTCAnR50lu7w+IjmzSBh+xV7/7Lf0XW0NG2hHw1lg=; b=WDG4CAbWUQNJq7 LvzE8Dyurm9DJPvR/evvKJtgA1/SFxDYA4RP1qkC33xAUVrXaH/stUui/pNddDPmOLyHQUAadzdqa jYc03gXGFhhJZw7M8S9WcqwqMJDXOhZsyCOC8k+Gqpt0idYuIrc7lBb0dhybmp2GjtrhGYxw1qAYf cz+rHwt30hkwX/eKswXNsINl7Hm/70QvnYyamLnQNm72BdUbdq9hWYcMKJAnuFi4JTbsuFB962/He A3yuAxugWLsWDuk3p+rXDlemNIwdyDZuQR5Lniz5aIc7hJo/rbtZtKrIxv2FCj5I2SOwa5xZSoBvu XtPKyxFpt6BEXM29xJGg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1miaXz-008eRn-SR; Thu, 04 Nov 2021 11:04:44 +0000 Received: from mail-eopbgr50043.outbound.protection.outlook.com ([40.107.5.43] helo=EUR03-VE1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1miaXw-008eQh-9h for linux-arm-kernel@lists.infradead.org; Thu, 04 Nov 2021 11:04:42 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RLFK6CQfoMrKV4yBhx++qrCsZFTATvUMU7xmfEiokN+Ulp7I6EWUzMuCW3CtJ0HnX+D4J0blV1L5tK0zdNGud557W5u/PWKfSg9cDcJMDdlctAIsx2a2b1wsUppbHwA9MZUlJ7w4NQKMxn5dbSQBzAGi88840+QgLcv62gY3DE/pmFD//FvxLVEfRESxDt/0b3eQH4tl+VdMV4xFGt7YG7c4I/Bi2fqt9rbr4wJ5NUV3nyWcJMStm+AOkUrulDpjOARQt+krzrSbwQwXmwTCUpeeyQ0LQdPTG1mAyU8QqBFRQahxphR+q5ms/1578pYexbkiY8uY1Xa3jB2/Uct/2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zIc2gXzwUVtCSMIj0944M23G7zX+0St4SJjJ1xXoeQM=; b=eo6MFpSq9XAE0WBXZklvWYWUKz9hirzUsqg6BPRUwINZ7GjvA5gTTaegtYSvpi2rvKl0ngLOSDWxyd4Ybq696z4y8ysXmWTVGoRK3ERU/U3gCqjLgwwvy0yZajU3etKh2OgZVmtlLtwXnXAnLj4ERCappDhk+ht57ZB0W6Gx+F0ELoQDCKUmnnQR8/K08d78b68SqO6a3rKW5EnAl9kJGM1usBSFgWU8YteKA6QwPIzLuIl8Vfn0LD9J72eh4GFtiE39TJLQnJtslgcZTJinS+9gHIbuBd/ur5VqRUJqqec/0vfodNJqPt+j76nqvZ6muvNR3KUqguoAQQgQAlsSvA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=zIc2gXzwUVtCSMIj0944M23G7zX+0St4SJjJ1xXoeQM=; b=WdnpMFjD6RNNfyzcvJuhZGo6vNBdJS7/KKyQkqtbNFmOF6TIB1J/HYK0NknlcF8yNuYQN/YD30RrBFGzubS2rb1bdUCbGcKVoYHGT0lUorDM4a4Kv89Ay8I7yta39zoVMXO/P8FygnEppXqpRIxtLZVvr8FM/nKw/vjXWyXZfis= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nxp.com; Received: from VI1PR04MB4688.eurprd04.prod.outlook.com (2603:10a6:803:6a::30) by VI1PR04MB3069.eurprd04.prod.outlook.com (2603:10a6:802:9::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4649.18; Thu, 4 Nov 2021 11:04:33 +0000 Received: from VI1PR04MB4688.eurprd04.prod.outlook.com ([fe80::885c:ddee:c614:9787]) by VI1PR04MB4688.eurprd04.prod.outlook.com ([fe80::885c:ddee:c614:9787%7]) with mapi id 15.20.4649.021; Thu, 4 Nov 2021 11:04:33 +0000 Date: Thu, 4 Nov 2021 13:04:31 +0200 From: Abel Vesa To: Martin Kepplinger Cc: Alexander Stein , linux-arm-kernel@lists.infradead.org Subject: Re: cpuidle on i.MX8MQ Message-ID: References: <9888688de870690d13f9d60f873fc8c1244dd58e.camel@ew.tq-group.com> <71bf7c49bf7cb68d8b7a0177648bce37dd4f5d73.camel@puri.sm> Content-Disposition: inline In-Reply-To: <71bf7c49bf7cb68d8b7a0177648bce37dd4f5d73.camel@puri.sm> X-ClientProxiedBy: VI1PR08CA0183.eurprd08.prod.outlook.com (2603:10a6:800:d2::13) To VI1PR04MB4688.eurprd04.prod.outlook.com (2603:10a6:803:6a::30) MIME-Version: 1.0 Received: from ryzen (188.26.41.202) by VI1PR08CA0183.eurprd08.prod.outlook.com (2603:10a6:800:d2::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4669.10 via Frontend Transport; Thu, 4 Nov 2021 11:04:33 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 34d04a73-e97a-4010-9807-08d99f82e1d9 X-MS-TrafficTypeDiagnostic: VI1PR04MB3069: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:9508; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: KWBkj5CVa0X3f+BdnWUGbO/sq99hEdXr5giZpHCLPfrrttKOqTMVzcbEWQX8Y76ou8938tharcd421HenUKRf8I/q4IqrvF6zvvkF02nmRR4uFop5io6gjDu2G5TUUxWCxEEKQpNGlUUXzrNKDz5apUrLCYWiV6tTr4e871Inz8pl94oXz7aN0PrufJvVKEdlTiY7WlZI1jSZim/WflJfua/xKVgfk9lqZDYk0VGKETfwF7MmrjptJuvWZp+wio2a4z4/rVwPSlQf+/MVH90269VDakExArla+ObkfQaam8XhEgiS6UXQvPqAKzcty3Wcaif1bGK8R+Hb/HE2opNCRxsoYekjbrg/yZgSTT7SiCb0DGxpUnOG3siqNphMo0UAT58XSQEICEB8BnL9wFcuYz5NWJ/LpqKTD95HTIYNC3t/Ahq19tJn0Ys4qoFwcT7UodZtoO5AiiAxFkL3kSTbiOm2aw3pk7pnpgpJK0jkH1o4ZGgV43F+2s7NBRGiiJ9KHdf6SpotKLMzDRweDZs5B76X2fu2Nv2mWTHCbUcYJlngs/D6SaRMobds9As3mrWKta2c7fvUXA2vd515mb22JOl0hnBjSkkjEnErSADcuwPFl95dq7F6PNjcEyv6tGdlrYtM8ip1nenFVxvP/tRBD6Vqt9F7CJMNs5SYaS7XO78/t+dzwbnvCCIvt7Wvpr/0XBscbGBZwN2siVhxbIrD5Ofw8a2BvJYN1LU47mKs9+QY8F1lIkqU6CwQ9/iAAqEZUj1LHQ827vvWilSr0/NVWMUd6s/Dh/k8ww3HxpkJznzif0CzJm3YG0Ln+8IrqrA X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:VI1PR04MB4688.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(4636009)(366004)(6496006)(66556008)(53546011)(508600001)(38350700002)(66946007)(4326008)(66476007)(52116002)(5660300002)(316002)(9576002)(8936002)(33716001)(956004)(26005)(38100700002)(186003)(86362001)(2906002)(8676002)(966005)(9686003)(55016002)(6916009)(44832011)(83380400001)(67856001); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?tYLujZtWEHUWP/BipsUfF4J9S+xwpxTKA+G+N+jLBxLxJWQyG2Nyk1JadpZQ?= =?us-ascii?Q?8p09vmLSCeFsqksYSrz1cJXZf+07ddzenjx534PMukiA7XJ6VqwLYpcoJlPy?= =?us-ascii?Q?9r09H+bHKZALRkOeS+Fj2EtHa2IWmbRQJ44hrIvLp5LcmQUpT32VUKgD+sQq?= =?us-ascii?Q?76mzvl5jIAArtZe8Jio2gX7LTniqUrg9QWh1w4yltAdtled9RsmkpC8Y9P7o?= =?us-ascii?Q?4CW6weIqLgoPj9G0Y2nzKr7dYDN62T5DS97ugUodTAI2pS13IrXiIGSSy3b8?= =?us-ascii?Q?Ugp8l7olJa1dws0OYODmESxdk+DhBg3th7HHhvBHGMC3XH15igMJWfY/q1q1?= =?us-ascii?Q?tN5fgOeTE131xnMJYrRWhF7QlQkOvFqixRzrjSU0j7MVxj3VLQ75arUqlcy/?= =?us-ascii?Q?C2kSduzO6lGN3+qvFIlteT087CsbyQBrmU6FMfzalPuHJARNG+Am/hToyHzb?= =?us-ascii?Q?al/g6V7RH/N4qRex1891g5mY2aw//Hi1Tm9PqrgstIPRK1+LFCDdWltYigPf?= =?us-ascii?Q?u3ejSuYRrGjR9f090/Qy5qaOQgFUtajM62UaEVjuFZgq4J64UsPxlA23FUK9?= =?us-ascii?Q?+F0spzg4KvLa427PGsKD9nhs8T2eWVaow505ZOXcNNTD2W39OoenHMbGEpnW?= =?us-ascii?Q?FthOVWHOUFw4n/H/LOcJai2WB9YiU+IRpIAlYFIHLyXeiQl0+cbFt1CiKuJ9?= =?us-ascii?Q?qlZs/6kIZTlrd3CIiD27O0zi3HJcjLFQ3Pe8TRQ/vPYKzaSyT+qh24K/HdEj?= =?us-ascii?Q?72GELo+K4R+dbiYMWZMpIYjNyM8Meu4IKL+rw04r43bUYR41uIqhivpCMB8e?= =?us-ascii?Q?2mP3OSVtOt76oNeDJup56CdkFtcRC3bFUMxF6973e3mVnaWSNoe4/mmb+5X6?= =?us-ascii?Q?mSeU3sGv4kuYcnNrIJw7OlCIfeFDkUAE+jkNXleL6cq2jYgf5FKUcO3AdLf3?= =?us-ascii?Q?BooeEaxgg0lB+MdnSfZYnWEnLUJwpLbyF4vQ0V44sTFK0BwGHkfthblsYFpc?= =?us-ascii?Q?OazYhh0RzQV2WAx7DcRw+AA/wLb4JGsX8a8JdMSAcd/w1BhDTgogG/45WP46?= =?us-ascii?Q?r0924aWNCVMuqQ7FziySqI3sBF0tPiXLIReL+2xwp+HZPFfRYYDk0QMDg8+9?= =?us-ascii?Q?ZY5XwxyHD/HDT+B0uDgzX4LGJyTzlR47FIlFNTDw6fwX7pnLk98TAfK5P5/p?= =?us-ascii?Q?ENKln7VD/9C+CvgrRTftEFg6nj1FLzJZaXwe3sVwe1HR6FzJMgfTqXZhpueQ?= =?us-ascii?Q?stb3o982K9hQZWzhzOEy+UnL2lIYXqiNMGrHnOZ9yP7NAtUUO24V5xUgnqbq?= =?us-ascii?Q?h/Ap1jxSIV1sY4ndmrIPlu0ePpwmw0+ksgBWQwuJcHbauezQ+I72FnfR+3mF?= =?us-ascii?Q?4o751WKm/GAUWNos3JSbqSHmuEVWxFQEXs4kuugHpBZXeorVyV+Ucu/zD9H+?= =?us-ascii?Q?0iiPtIrzgjZGn4AjA1n0vnxvkZkxWu6+Mmfy163uByG0WWt1KV9na7SXeagu?= =?us-ascii?Q?+C7CkyC7ME3xx0+CT+JeUmwOhjf1eh1HmxzHKQdyDJaGYHPwU0ceJkS+Iupy?= =?us-ascii?Q?NJRjLhc0W8HTbDBcNq3L3M/w+OERoxzPkv9dGzPgjri/aJL+FQDrSkQdN60j?= =?us-ascii?Q?dTExZUbn9ZExxyluk7rQtHQ=3D?= X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 34d04a73-e97a-4010-9807-08d99f82e1d9 X-MS-Exchange-CrossTenant-AuthSource: VI1PR04MB4688.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Nov 2021 11:04:33.7072 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: soojsqKYlZNEeGlkKT37Z7RfeW42z3D0va88xr2YMqk+31yntxwM10pNZ3Smt2KXpceK3GSBiHsXL/xU1iHJqA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR04MB3069 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211104_040440_453601_2D3E891D X-CRM114-Status: GOOD ( 28.40 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 21-11-03 13:09:15, Martin Kepplinger wrote: > Am Dienstag, dem 02.11.2021 um 11:55 +0100 schrieb Alexander Stein: > > Hello, > > > > I was hit by the errata e11171 on imx8mq on our custom board. I found > > [1] from over 2 years ago, and the even older patchset [2]. > > Is there some final conclusion or fix regarding this errata? From > > what > > I understand the proposed change is apparently not acceptable in > > mainline for several reasons. I'm wondering what's the current > > status. Unfortunately, there is not gonna be an upstream solution for this errata. Long story short, the SOC is missing wakeup lines from gic to gpc. This means the IPIs are affected. So, knowing all that, in order to wake up a core, you need to write a bit in some register in gpc. The SW workaround (non upstreamable) I provided does exactly that by hijacking the gic_raise_softirq __smp_cross_call handler and registers a wrapper over it which also calls into ATF (using SIP) and wakes up that specific core by writing into the gpc register. There is no other possible way to wake up a core on 8MQ. > > As suggested at that time, the only solution (right now) is to > > disable > > cpuidle on imx8mq? > > Yes, the vendor actually suggests that, but you can use the mentioned hack. > > Best regards, > > Alexander > > > > [1] https://lkml.org/lkml/2019/6/10/350 > > [2] https://lkml.org/lkml/2019/3/27/542 > > > > Hi Alexander, hi Abel, > > At this point my understanding is basically the same. We carry (a > slight variation of) the above in our tree ever since in oder to have > the cpu-sleep sleep state. Not using it is not acceptable to us :) > > Until now there's one internal API change we need to revert (bring > back) in order for this to work. For reference, this is our current > implementation: > > https://source.puri.sm/martin.kepplinger/linux-next/-/compare/0b90c3622755e0155632d8cc25edd4eb7f875968...ce4803745a180adc8d87891d4ff8dff1c7bd5464 > > Abel, can you still say that, in case this solution won't apply anymore > in the future, that you would be available to create an update? > I'll try to find a workaround soon, based on the same general idea behind the current one you guys are using. I'll do this in my own time since the company does not allocate resources for 8MQ cpuidle support anymore. > Can you even imagine a possibly acceptable solution for mainline to > this? Nothing is completely set in stone with Linux :) I believe Marc was pretty clear about not accepting such a workaround (and, TBH, it makes perfect sense not to). Since I don't think there is any other way that would go around the gic driver, I believe this has hit an end when it comes to upstream support. Sorry about that. I'm open to any suggestions though. > > thank you very much, > > martin > > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel