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 X-Spam-Level: X-Spam-Status: No, score=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 904E0C433B4 for ; Wed, 12 May 2021 08:51:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 60143613B9 for ; Wed, 12 May 2021 08:51:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230473AbhELIxG (ORCPT ); Wed, 12 May 2021 04:53:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42508 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230295AbhELIxE (ORCPT ); Wed, 12 May 2021 04:53:04 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1ABDCC061574 for ; Wed, 12 May 2021 01:51:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=/MqLJ4rj5L9md7sMeoP8AyNO73HQlye6pz1itww7fL0=; b=VH7QEH+8UXpc3iQM9a9fSnn8j9 ydrqlOcHTf/nuBBN6RYNYWugp5wJry3Pq3ucdVgzZHOXD5owD43L8bVJkWC/n8dZPrD7OPlT41by0 qOtDPCblF2WKGl8eruNFA3LckTJmeynOg7tPf9jtkMRbeDWZ0ycfH0wyQJpK/wrFLA5y9TV/mP5xF DHv200DgV9vIiybbWAI6SNzleG0yHr2ZJOZjro0EGefQT7A37crZm1UI40x1fdVnm+Y3C/WmhMRel Q/Hf325Ekd4sVcQcM5USRQmiKZA1Y1vNzgHVYf2UonpMatEb8D7v20dR1r3nhjcUQA3z1lNISxtLF +QcoHrYQ==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94 #2 (Red Hat Linux)) id 1lgkZ6-0086jG-0Y; Wed, 12 May 2021 08:50:32 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 76E3C3001E1; Wed, 12 May 2021 10:49:59 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 5D35B29CB9DBF; Wed, 12 May 2021 10:49:59 +0200 (CEST) Date: Wed, 12 May 2021 10:49:59 +0200 From: Peter Zijlstra To: Thomas Gleixner Cc: Lai Jiangshan , LKML , x86@kernel.org, Joerg Roedel , Borislav Petkov Subject: Re: [patch 1/2 v2] x86/cpu: Init AP exception handling from cpu_init_secondary() Message-ID: References: <20210507110210.147106915@linutronix.de> <20210507114000.429303187@linutronix.de> <87wns8ko48.ffs@nanos.tec.linutronix.de> <87k0o6gtvu.ffs@nanos.tec.linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87k0o6gtvu.ffs@nanos.tec.linutronix.de> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 10, 2021 at 11:29:25PM +0200, Thomas Gleixner wrote: > +#ifdef CONFIG_SMP > +void cpu_init_secondary(void) > +{ /* * Relies on the BP having set-up the IDT tables, which * are loaded on this CPU in the below * cpu_init_exception_handling(). */ > + cpu_init_exception_handling(); > + cpu_init(); > +} > +#endif Or something along those lines? It took me a little to figure out why start_secondary() didn't have idt_setup_traps(), hopefully something like this will avoid a little future confusion.