From patchwork Wed Dec 11 23:34:40 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geoff Levand X-Patchwork-Id: 3328971 Return-Path: X-Original-To: patchwork-linux-kbuild@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 1BAA3C0D4A for ; Wed, 11 Dec 2013 23:34:45 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 47C1C20808 for ; Wed, 11 Dec 2013 23:34:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2A1DB20806 for ; Wed, 11 Dec 2013 23:34:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751544Ab3LKXel (ORCPT ); Wed, 11 Dec 2013 18:34:41 -0500 Received: from merlin.infradead.org ([205.233.59.134]:46061 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751379Ab3LKXel (ORCPT ); Wed, 11 Dec 2013 18:34:41 -0500 Received: from geoff by merlin.infradead.org with local (Exim 4.80.1 #2 (Red Hat Linux)) id 1VqtIe-0004Ic-6G; Wed, 11 Dec 2013 23:34:40 +0000 Message-Id: In-Reply-To: References: From: Geoff Levand Patch-Date: Thu, 14 Nov 2013 12:26:25 -0800 Subject: [PATCH 1/3] kbuild: Fix debugging info generation for .S files To: Michal Marek Cc: linux-kbuild@vger.kernel.org, David Howells Date: Wed, 11 Dec 2013 23:34:40 +0000 Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Change the debuging info generation flag in KBUILD_AFLAGS from '-gdwarf-2' to '-Wa,--gdwarf-2'. This will properly generate the debugging info for .S files when CONFIG_DEBUG_INFO=y. It seems current gcc does not pass a '--gdwarf-2' option on to the assembler when '-gdwarf-2' is on its command line (note the differece in the gcc and as flags). This change provides the correct assembler flag to gcc, and so does not rely on gcc to emit a flag for the assembler. Signed-off-by: Geoff Levand for Huawei, Linaro --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 890392f..7308a6f 100644 --- a/Makefile +++ b/Makefile @@ -619,7 +619,7 @@ endif ifdef CONFIG_DEBUG_INFO KBUILD_CFLAGS += -g -KBUILD_AFLAGS += -gdwarf-2 +KBUILD_AFLAGS += -Wa,--gdwarf-2 endif ifdef CONFIG_DEBUG_INFO_REDUCED