Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp2164032ybe; Tue, 3 Sep 2019 08:51:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqwGvuenywk+52qIK/k7qkgZiD1+Ri42yaaTNghLtIEBb2t9GYDQ1qO9Su3+fCbz8rUnYBgB X-Received: by 2002:a17:90a:1b0d:: with SMTP id q13mr769170pjq.102.1567525919153; Tue, 03 Sep 2019 08:51:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567525919; cv=none; d=google.com; s=arc-20160816; b=CWwAA0CKgyEWkddw6UKWBBOqSV6mrnsQFCx9cguosxazEQ0Zesa2yF+OYrONdvEqdc TwitYK5bpIcgRjF5e+7OXRxX0ikNgRxNF+Quw3YL+xk+uCy+ejKPI9iDZz1/RLAqEisy b1m2U6uKxfjt3ZcoptkctvD/Wg/mC46+MmgeiNgzmPP+Yoj70x8KQebEWZW8s1jbPucT TdRkSSlbpHlQ2enOiMoy17Sx4CnthrfXrQ1b0aQ0NHKk3q75FYLms5bnhqx0BESrxuGJ np0eaSazoCbjPsUZ5d9i5T0ut3RPnXomdBrKQTBRL232Z7dw1tjXq5rwlMemsS4G4hor Co0Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:subject:message-id:date:from :mime-version:dkim-signature; bh=i8XrzJqX/k14d/NNyJqP2fuyq+Gn/gMNB5vapsoUn58=; b=mhAyFbTPC12jx9FBPapJefGrhsxv9PIOjUDJxKveQ1UpqmkGNxacyHCBkfgaK7pXsZ NNtTU/RcoZQbVzwTmOfFR9IDXcEG215XcJsnpbOCvh93Vi+16B9NRnU4uCUQjUdXX9l1 RISts0bzeS5B8lICBcB87W29UQWbIh5t5wyJKatrJ5q4SHyoeHUw2o8andOJyMfxuzNA ZX+LI51L+kPTX7WG6BSGPmsbMGzBM1CLib1AYPzefGdcmYDB2MZCSpvKtnAFZn2nj3gf 9h1S+SBNnukO7TUzjgLXle1edCklBJo6A/nIKz54K8eSJnyLxzOanKxD/rSJWDk2soNK k01Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lonelycoder.com header.s=google header.b=UgVPPHBy; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l70si14766279pge.446.2019.09.03.08.51.43; Tue, 03 Sep 2019 08:51:59 -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=@lonelycoder.com header.s=google header.b=UgVPPHBy; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729715AbfICPuh (ORCPT + 99 others); Tue, 3 Sep 2019 11:50:37 -0400 Received: from mail-ot1-f47.google.com ([209.85.210.47]:42244 "EHLO mail-ot1-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727667AbfICPug (ORCPT ); Tue, 3 Sep 2019 11:50:36 -0400 Received: by mail-ot1-f47.google.com with SMTP id c10so5877465otd.9 for ; Tue, 03 Sep 2019 08:50:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lonelycoder.com; s=google; h=mime-version:from:date:message-id:subject:to; bh=i8XrzJqX/k14d/NNyJqP2fuyq+Gn/gMNB5vapsoUn58=; b=UgVPPHBy7wPMXgWT0jSZjefR28XGx4gtdEcliXDELdGOyuWUfLGaQi196Es/6Aab7e UCaGsyvJgZ0adWE8GYH9jZFJ10G6e73ruDZeGltRV3bRc3Szj9eH8BAjef7iBIBZG3sT Ilc0DG0V3WcdWZXcwKOl83ia5gb3U5Xdwl1DWM5+FKF8P/R7sVDHG1NkvkbgZquVrhKi G+vM4/VrdK8HA2AimQnFyz5sfIiPubj6M4PoBt9YWxYO5YuaAjf+MkuF8bU8LD2QOmrH Jr/yQP6SdiegTLH++cc4BWfHCTmDjoRJZh1+bQZQNowRYkl43A/As+siwv/Z/00K9AV0 ywgQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=i8XrzJqX/k14d/NNyJqP2fuyq+Gn/gMNB5vapsoUn58=; b=geKtE6eK3acdyUnliglqR1HRVcBYs/ScD5S7/iermqRPY5wsdfZhedjkEPvj8q5JBY KyBb3RP7WH5cRwBj7UTuQmX1IhFOdD95aTb8NV/EqJR2/1HEpE9L+pRSLhIuZyBP2zX9 4KWcJ8YBjUt17gWSWDJ9R2iE7m+tTTNhdU+FXM4gO+TsnRlNFNcoowrcL0h5WN+aS9r1 nKGA5i/IC97NU6no3uMJwR2fkzLRk7Rd7szOdM232zFXMM+FPlYxw/HhcGsNxO0FCaYd 0x+rmjpdXikM1HoyHbBXpo1+9pjhv6cgnykd2hquPQZ7KW/Wnk0WKyf3/K9t8qmgcy8i w5Uw== X-Gm-Message-State: APjAAAWudf4mkN86BdBkNO6aur8+pVhx/za9gCyGPG0uGsyINM2UMGEJ FgL2YeDHpa+OXxwgr85FU7Z/M0D+XyiqpzcvunCtvSFS75w= X-Received: by 2002:a9d:4d0e:: with SMTP id n14mr4209186otf.285.1567525835588; Tue, 03 Sep 2019 08:50:35 -0700 (PDT) MIME-Version: 1.0 From: Andreas Smas Date: Tue, 3 Sep 2019 08:50:25 -0700 Message-ID: Subject: x86/purgatory: undefined symbol __stack_chk_fail To: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, For me, kernels built including this commit b059f801a937 (x86/purgatory: Use CFLAGS_REMOVE rather than reset KBUILD_CFLAGS) results in kexec() failing to load the kernel: kexec: Undefined symbol: __stack_chk_fail kexec-bzImage64: Loading purgatory failed Can be seen: $ readelf -a arch/x86/purgatory/purgatory.ro | grep UND 0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND 51: 0000000000000000 0 NOTYPE GLOBAL DEFAULT UND __stack_chk_fail Using: gcc version 7.4.0 (Ubuntu 7.4.0-1ubuntu1~18.04.1) Adding -ffreestanding or -fno-stack-protector to ccflags-y in arch/x86/purgatory/Makefile fixes the problem. Not sure which would be preferred.