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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 84933C433EF for ; Thu, 2 Dec 2021 16:48:14 +0000 (UTC) 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:Cc:To:Subject:Message-ID:Date:From: In-Reply-To:References:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ejiwK4Bu4q5aRDDRzG7kC43sfcV1+cdnygN+FgpzPOs=; b=m59pvGVz9sHK/G I/yX+NoUazpmcoSUk1ulYWMdTcPdzDsCAbyaNNhvo5v5wF2s/FwFaGKH/7gduMo/mEzK2KjIS3HiF aLE4eXpG4aSImWOCLA5SmECAmH0dMHiUr+X+qV53qHKOq/us4Y7uz8Qqb0GY/+IrYIunUctczBPj1 6E6hMCMvE7gN9Ue2/69RGToDLYTAPYCTUtLzWpZVYWmxRTpouWd7T4EYEBGAipA3P0ZyRa+h5BMPE BVXT4MK2diA6fQQSDo2KkREEA4q9UhToox3cLin/2wILUwOXToj2OigsD/7gAeGC/Zas1yTMnvx8L wEIsUV9pTlxAMZtZATwA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mspET-00D3rw-C2; Thu, 02 Dec 2021 16:46:53 +0000 Received: from ams.source.kernel.org ([145.40.68.75]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1mspEP-00D3r1-CN for linux-arm-kernel@lists.infradead.org; Thu, 02 Dec 2021 16:46:51 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 9B0ECB82427 for ; Thu, 2 Dec 2021 16:46:47 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5E390C53FCC for ; Thu, 2 Dec 2021 16:46:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1638463606; bh=I1beABLRrJu1RWLqScI4yKcips9wpOPz/4hObV/U/yo=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=FxC2xERc66vyruPkMjyL2/4jHKgdiM0xzO4b3L945hoCAFrq1QBIycwWVMyeT63JS Er6FqvFrZxiawtM9ISRGGYz754kSC+zjG8wdWmiHaKp/hLZOxHMN/GIueC9UMpeamb QTUSI4dG9Az+IqB8ERW5zG14QbP/LPAI6pc5xabq8Hugz6tZCE8MtjfnZWe0iub2uy 6itCyCqveWdLr+18M0p+39SkUhjT4dQVIcNETSCJgznpgPEvs7tE1btl4jsvVD2WDM XRlUsQXA8mTo3afpN0NOV4IOlxkT45+IlF7CwcCOjPJUfbdf7uy4o04naVnkhHxPDP 96jHUKkMGiaxw== Received: by mail-oi1-f181.google.com with SMTP id m6so367281oim.2 for ; Thu, 02 Dec 2021 08:46:46 -0800 (PST) X-Gm-Message-State: AOAM531DOGCxz3KOOhqQ2WUx+QvAmxmkXjkJtNRQw5/rVohqKs9WJUwR R9v4o01q6iMDdwEEx5yA7DLGQpYluPNLqC+qdYk= X-Google-Smtp-Source: ABdhPJxB4ZMrNHHqtvB8DfF6vcmqhPScWc0tTiE0iBIrriAuxxjtWYfjQMs/vO07Z+DXkgCU6C/O6AIZh4F/GHC8koI= X-Received: by 2002:a05:6808:12:: with SMTP id u18mr5374550oic.174.1638463605648; Thu, 02 Dec 2021 08:46:45 -0800 (PST) MIME-Version: 1.0 References: <20211201110259.84857-1-vladimir.murzin@arm.com> <20211201110259.84857-2-vladimir.murzin@arm.com> <9a05bba9-8491-77c2-5cb1-f2010f05c960@arm.com> In-Reply-To: <9a05bba9-8491-77c2-5cb1-f2010f05c960@arm.com> From: Ard Biesheuvel Date: Thu, 2 Dec 2021 17:46:34 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 2/2] irqchip: nvic: Use GENERIC_IRQ_MULTI_HANDLER To: Vladimir Murzin Cc: Arnd Bergmann , Linux ARM , Russell King - ARM Linux , Mark Rutland , Marc Zyngier , Jesse Taube X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211202_084649_719560_C6E42873 X-CRM114-Status: GOOD ( 33.47 ) 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 Thu, 2 Dec 2021 at 15:12, Vladimir Murzin wrote: > > On 12/2/21 11:05 AM, Ard Biesheuvel wrote: > > On Thu, 2 Dec 2021 at 10:45, Arnd Bergmann wrote: > >> > >> On Thu, Dec 2, 2021 at 10:33 AM Vladimir Murzin wrote: > >>> > >>> On 12/2/21 9:23 AM, Arnd Bergmann wrote: > >>>> On Thu, Dec 2, 2021 at 9:35 AM Ard Biesheuvel wrote: > >>>>> > >>>>> It seems trivial enough to add that for v7m as well, so I will include > >>>>> a patch for it in my v3. But I won't be able to test it, though. > >>>> > >>>> Ok, perfect. Adding Jesse to Cc, they are in the process of adding another > >>>> Cortex-M based platform and should be able to test this by merging in your > >>>> changes from [1] after you have uploaded the latest version. > >>> > >>> I'm happy to test it as well. I'm wondering if there are specific scenarios > >>> (or maybe some tests) to consider? > >> > >> If the IRQ stacks fail in some way, it most likely won't boot at all, so as long > >> as you can get into user space, I'd be 99% confident that it's good. > >> > >> For the MMU based platforms, the series lets us detect stack overflows > >> when either the per-thread stack or the IRQ stack runs into an unmapped > >> vmalloc page, and there are some unit tests that exercise this. > >> I don't think you can do this with the MPU though, and certainly not when > >> the MPU is disabled. > >> > > > > Latest version of the code is here, if anyone wants to test it: > > https://git.kernel.org/pub/scm/linux/kernel/git/ardb/linux.git/log/?h=arm-up-ti-in-task-v3 > > > > I'm afraid it is broken (even w/o last patch). I'm getting > > [ 0.071350] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes, linear) > [ 0.071747] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes, linear) > [ 0.084497] bad: scheduling from the idle thread! > [ 0.084744] CPU: 0 PID: 0 Comm: kworker/0:0H Not tainted 5.16.0-rc1-0f57a2aad139 #2428 > [ 0.085357] Hardware name: Generic DT based system > > $ git bisect log > git bisect start > # good: [fa55b7dcdc43c1aa1ba12bca9d2dd4318c2a0dbf] Linux 5.16-rc1 > git bisect good fa55b7dcdc43c1aa1ba12bca9d2dd4318c2a0dbf > # bad: [e42c59caa4d8f37444388cc388bfc55653bf00dc] ARM: v7m: enable support for IRQ stacks > git bisect bad e42c59caa4d8f37444388cc388bfc55653bf00dc > # good: [cbf7b30e70b7e2eacebd885674675746e93583f6] ARM: entry: rework stack realignment code in svc_entry > git bisect good cbf7b30e70b7e2eacebd885674675746e93583f6 > # good: [02c0315277721c4fc2082850da0714127594473d] irqchip: nvic: Use GENERIC_IRQ_MULTI_HANDLER > git bisect good 02c0315277721c4fc2082850da0714127594473d > # good: [9cc24032abc2847a8e61e55e2ec9bd34e1eff1c4] ARM: percpu: add SMP_ON_UP support > git bisect good 9cc24032abc2847a8e61e55e2ec9bd34e1eff1c4 > # good: [8adfea395669037ee79620b8b534e101d5ce65e6] ARM: smp: defer TPIDRURO update for SMP v6 configurations too > git bisect good 8adfea395669037ee79620b8b534e101d5ce65e6 > # bad: [0f57a2aad13912dde5746ffc5f43bd46aa3d8b2d] ARM: implement THREAD_INFO_IN_TASK for uniprocessor systems > git bisect bad 0f57a2aad13912dde5746ffc5f43bd46aa3d8b2d > # first bad commit: [0f57a2aad13912dde5746ffc5f43bd46aa3d8b2d] ARM: implement THREAD_INFO_IN_TASK for uniprocessor systems > > At the first glance it seems that __switch_to in entry-v7m.S missing set_current > Thanks for testing, and thanks for bisecting. Unfortunately, I can't easily test these changes myself. Could you please check whether the following change would be sufficient to fix this? https://git.kernel.org/pub/scm/linux/kernel/git/ardb/linux.git/commit/?h=tmp Thanks, Ard. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel