From patchwork Thu May 16 11:13:54 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viktor Mitin X-Patchwork-Id: 10946395 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C206D1515 for ; Thu, 16 May 2019 11:16:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B134728B4B for ; Thu, 16 May 2019 11:16:19 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A5A1A28B4C; Thu, 16 May 2019 11:16:19 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.7 required=2.0 tests=AC_FROM_MANY_DOTS,BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 5CF0928B4D for ; Thu, 16 May 2019 11:16:19 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1hRELG-0000G0-Bo; Thu, 16 May 2019 11:14:30 +0000 Received: from us1-rack-dfw2.inumbo.com ([104.130.134.6]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1hRELE-0000Fq-NG for xen-devel@lists.xenproject.org; Thu, 16 May 2019 11:14:28 +0000 X-Inumbo-ID: c4537352-77cb-11e9-8980-bc764e045a96 Received: from mail-lj1-x242.google.com (unknown [2a00:1450:4864:20::242]) by us1-rack-dfw2.inumbo.com (Halon) with ESMTPS id c4537352-77cb-11e9-8980-bc764e045a96; Thu, 16 May 2019 11:14:27 +0000 (UTC) Received: by mail-lj1-x242.google.com with SMTP id w1so2761504ljw.0 for ; Thu, 16 May 2019 04:14:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=mrM64QavtG0E6aPUOqGHW/JfhU5OFNkQecULLeg6t6A=; b=a6G264RmUdFcmcx6+C4XEIydvKUTgnbdNNZIxZ2VEiMw6w43+ss3wZT3HqN+/92CyE RM2PkoPMd4+l525PINm9m+Y/vlgh6l8aOLdNeWgtnLX1JkfJ9/rOD04IJXhB0M1ve1EC q3iFuWysqxQCR4FAoHQkUBOJxlS7QQSPzYA7vK7xEPOOmrfcL1irgrqQEKUV1tNei5Gu +oWB8ftrSIOtW28ran18rNh6aDutfDsb96zj8uDgKDwBKZcrDGIkRYSk/69lfOhHeUZz KcqUlkeDf4TpAFUvg2qBbT8QKXmL6T93r1paEF3kG0bSRcvHYqXGK5kss5Lcv8JDcIxP /vDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=mrM64QavtG0E6aPUOqGHW/JfhU5OFNkQecULLeg6t6A=; b=OI1sCW2KvvcUItgfsbjhZt9QEgTnEIJGPfmdK+6SSUHxGpL+NznyZBdTWhpKJIWr5H QLIoI2u+zRIERQM2pQyBaSFYCOvg7VNStN34bTycRiUBxqJ8D8FiMOij8VTPIz1Trk1o p4CqCEPrzhXNVr3k2+qZ4hSIJP3oZAWZC1ytP6zALumdVQfc5THB64byXZhH/+pjxNIg CIbdoDxbIUrG5JH7n7PLkH+PPtTzPPfH7WQvn81eaz1UvJ4oqF/lk+whrvnWmSQu0I3X qUNiU2IrWYlYXJr1MXnjAqiYSim2kO+fEmL1oWMoJzfA5kF4331xuQUtkaSfY2NKQ9pR 54+A== X-Gm-Message-State: APjAAAVNID4tWtPJSHbjxI1eU2kgBduvwG8Unm4m79IhXs4YKVWTEVVJ 7hVfXC/Tu8x7FeFa/Vh2QguKpDAbN5M= X-Google-Smtp-Source: APXvYqylQqn0WPgfL9mqZ2udu5sFrrSTQMwbZKf3bYgpra19UnI+Nh39yG8mi9hZ2+2+bCPeM/Xwdw== X-Received: by 2002:a2e:7f13:: with SMTP id a19mr23666364ljd.35.1558005265949; Thu, 16 May 2019 04:14:25 -0700 (PDT) Received: from 3489.kyiv.epam.com (ll-74.141.223.85.sovam.net.ua. [85.223.141.74]) by smtp.gmail.com with ESMTPSA id 10sm826369ljv.47.2019.05.16.04.14.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 16 May 2019 04:14:25 -0700 (PDT) From: Viktor Mitin To: xen-devel@lists.xenproject.org Date: Thu, 16 May 2019 14:13:54 +0300 Message-Id: <20190516111354.15195-1-viktor.mitin.19@gmail.com> X-Mailer: git-send-email 2.17.1 Subject: [Xen-devel] [PATCH] coverage: GCC coverage libfdt Makefile fix X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Julien Grall , Stefano Stabellini , Wei Liu , Viktor Mitin MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP The patch resolves 'xencov' crashes in case of Aarch64. All the .init.* sections are stripped after boot, it means that anything in .init.data cannot be accessed anymore. The build system explicitly compiles any .init binary without gcov option. The problem is coming from libfdt. The entire library is moved to .init using: $(OBJCOPY) $(foreach s,$(SECTIONS),--rename-section .$(s)=.init.$(s)) $< $@ So we need to tell the top Makefile to filter out libfdt. Reported-by: Viktor Mitin Signed-off-by: Julien Grall Tested-by: Viktor Mitin Reviewed-by: Wei Liu Acked-by: Andrew Cooper --- xen/common/libfdt/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/xen/common/libfdt/Makefile b/xen/common/libfdt/Makefile index d81f54b6b8..c075bbf546 100644 --- a/xen/common/libfdt/Makefile +++ b/xen/common/libfdt/Makefile @@ -3,6 +3,7 @@ include Makefile.libfdt SECTIONS := text data $(SPECIAL_DATA_SECTIONS) obj-y += libfdt.o +nocov-y += libfdt.o CFLAGS += -I$(BASEDIR)/include/xen/libfdt/