Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp2281797ybz; Thu, 30 Apr 2020 14:17:27 -0700 (PDT) X-Google-Smtp-Source: APiQypI1X3/Y5+WfLKdVxy5qJ9h5MHqvAl+O3Knbg1c1dW53Kz2JFFKjBaWplsC/MuReaUaWUIbm X-Received: by 2002:a50:b412:: with SMTP id b18mr944306edh.42.1588281447730; Thu, 30 Apr 2020 14:17:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588281447; cv=none; d=google.com; s=arc-20160816; b=dQQkz6kiHSHAz5gCOp89nHYp+jMmDCPL4IOKo0ENkcvJWvkBt+6d7iPg6rAgshGywt hiwVtIYB45kLKE+3osCuCwecBYVftn2oaLo/kzZntJs7ghteRfLpHY6rWY3EsjXWbU2l YGuDntqjyblBOV04G0hLJsWigZHpqo62ckBLGVqJHlWJyq/DoKN+1iOHscAYd5+mmvX3 VzPsRVWuq69UW3JSb4JLTCX/Olo2cDVVd3kAG95abp/ciRHx9b31iZyj3iuUO3B9pG/Z EHt/haT+VV8T1K5eqUIqE0mWKGXf4HibxpzaxeZFVNn7TqoXIZXzkOvmp1MJmXDV+ED6 W0yQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:mail-followup-to:reply-to:message-id :subject:cc:to:from:date:dkim-signature; bh=Gpgo8QhStYUhDPmOT7znh0qOxQgcHTQeTAkj6k74Xck=; b=r0pvkb/98GTazqA3fSI1ZjlVvAwHmlhjF5Ql5J5WrAqWqZ95G7KeTvxGCmYTqLf9hk yR4YwjChSQOKWyaY2jJgYH4yah4wbV4ODbUOMKG+ru9VOFzLGIaw1RntClMRnDp2BqHs 9/eYs8GyyB2bl8ys/kV9ZdWXKsw0DR21ruWopKNN+qU5D0bmMbtjGxX5JyjcgKiY6pbm Vvtny9VUD4+s67FnBp1+crKTrt+2ZxEYvFQ2Kt7C2CCyrZFOJ2R2Ky8ABKQDbmn7uLHu lJDNFImp07RGQovHjy+EicLYJGKGUa9YRbGwUem0ZHSP7VTAQHux4TB1hZ8Y+axPNPLw G53g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=PnIOo7UD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y10si504996ejw.53.2020.04.30.14.17.04; Thu, 30 Apr 2020 14:17:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=PnIOo7UD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726845AbgD3VPZ (ORCPT + 99 others); Thu, 30 Apr 2020 17:15:25 -0400 Received: from us-smtp-delivery-1.mimecast.com ([205.139.110.120]:40970 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726558AbgD3VPX (ORCPT ); Thu, 30 Apr 2020 17:15:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1588281321; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references; bh=Gpgo8QhStYUhDPmOT7znh0qOxQgcHTQeTAkj6k74Xck=; b=PnIOo7UDLGhEyKckUeVzoFRUYhig4DHPOdd4KhUWTKAKkyqhS6/pBKCCC6H40eXYQkf/rA 2VK9YkHSLR65D4XTkVygk6HtwnJg4utbKb2Nk5hbg98WesPxw15rdVXYBfhrAPy4v9jFsa DlzVik4NazzP+0SPupDvzfLJD/6Cv3k= Received: from mail-qk1-f199.google.com (mail-qk1-f199.google.com [209.85.222.199]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-232-ULd9tQIrOZOGb161MJSa3w-1; Thu, 30 Apr 2020 17:15:20 -0400 X-MC-Unique: ULd9tQIrOZOGb161MJSa3w-1 Received: by mail-qk1-f199.google.com with SMTP id a18so7905628qkl.0 for ; Thu, 30 Apr 2020 14:15:20 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:reply-to :mail-followup-to:references:mime-version:content-disposition :in-reply-to; bh=Gpgo8QhStYUhDPmOT7znh0qOxQgcHTQeTAkj6k74Xck=; b=c2DYMOPJw8ssg8k5tROj2l6VG3bt+wjnv++nR7uodjHQ9g2/oCnVDiixDcMRNdUs5T NHGejKo/0eAeoVlZmJBVWWf/v/PlUt3jT860LcYk2Qode/S7rLXC3Wh5GEcktShfCLFw baZlv0sbQlGYDMKoc93GhU6VZZr4GvCh7dm2DWQZ1jiGk2Mz5P0cRq4n1EvIzLQ6rbSH yeDjyAyM+oPkheO/f1vESQfB5rqjF3NHnzWmtWckITQFwsbbCF4qCs7kuM3cS51MCgUM F9CfCXlKjQaWc/d9lGHBxB2A+VlHxlhg6W9uaKIfKYQGg/P01nXrEsA8ZMTsqDYTC0nR xYzg== X-Gm-Message-State: AGi0PuZu9iCvSC0D30OTAmPzrnAsOWjwoJfza8dj3AiO537wmqRWAVIu wO89OqaN1i+LNbAhJkfQaAaTOe7783T+Beunkt3uW2LFhvGpoDYmITS3nN5gOsxSKkBftFAnFU2 21/FUoZcjstXT6gKbMZN5UIy9 X-Received: by 2002:a37:9b0f:: with SMTP id d15mr557167qke.62.1588281319657; Thu, 30 Apr 2020 14:15:19 -0700 (PDT) X-Received: by 2002:a37:9b0f:: with SMTP id d15mr557149qke.62.1588281319422; Thu, 30 Apr 2020 14:15:19 -0700 (PDT) Received: from localhost (ip70-163-223-149.ph.ph.cox.net. [70.163.223.149]) by smtp.gmail.com with ESMTPSA id h6sm766622qtd.79.2020.04.30.14.15.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 30 Apr 2020 14:15:18 -0700 (PDT) Date: Thu, 30 Apr 2020 14:15:16 -0700 From: Jerry Snitselaar To: Arnd Bergmann Cc: Ard Biesheuvel , Ingo Molnar , Ard Biesheuvel , Ben Dooks , Dave Young , Jarkko Sakkinen , Lukas Wunner , Lyude Paul , Matthew Garrett , Octavian Purdila , Peter Jones , Peter Zijlstra , Scott Talbert , Thomas Gleixner , linux-efi@vger.kernel.org, linux-integrity@vger.kernel.org, stable@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] efi/tpm: fix section mismatch warning Message-ID: <20200430211516.gkwaefjrzj2dypmr@cantor> Reply-To: Jerry Snitselaar Mail-Followup-To: Arnd Bergmann , Ard Biesheuvel , Ingo Molnar , Ard Biesheuvel , Ben Dooks , Dave Young , Jarkko Sakkinen , Lukas Wunner , Lyude Paul , Matthew Garrett , Octavian Purdila , Peter Jones , Peter Zijlstra , Scott Talbert , Thomas Gleixner , linux-efi@vger.kernel.org, linux-integrity@vger.kernel.org, stable@vger.kernel.org, linux-kernel@vger.kernel.org References: <20200429190119.43595-1-arnd@arndb.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Disposition: inline In-Reply-To: <20200429190119.43595-1-arnd@arndb.de> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed Apr 29 20, Arnd Bergmann wrote: >Building with gcc-10 causes a harmless warning about a section mismatch: > >WARNING: modpost: vmlinux.o(.text.unlikely+0x5e191): Section mismatch in reference from the function tpm2_calc_event_log_size() to the function .init.text:early_memunmap() >The function tpm2_calc_event_log_size() references >the function __init early_memunmap(). >This is often because tpm2_calc_event_log_size lacks a __init >annotation or the annotation of early_memunmap is wrong. > >Add the missing annotation. > >Fixes: e658c82be556 ("efi/tpm: Only set 'efi_tpm_final_log_size' after successful event log parsing") >Signed-off-by: Arnd Bergmann Minor thing, but should the Fixes be c46f3405692d ("tpm: Reserve the TPM final events table")? Or what am I missing about e658c82be556 that causes this? Just trying to understand what I did. :) Regards, Jerry >--- > drivers/firmware/efi/tpm.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/drivers/firmware/efi/tpm.c b/drivers/firmware/efi/tpm.c >index 31f9f0e369b9..55b031d2c989 100644 >--- a/drivers/firmware/efi/tpm.c >+++ b/drivers/firmware/efi/tpm.c >@@ -16,7 +16,7 @@ > int efi_tpm_final_log_size; > EXPORT_SYMBOL(efi_tpm_final_log_size); > >-static int tpm2_calc_event_log_size(void *data, int count, void *size_info) >+static int __init tpm2_calc_event_log_size(void *data, int count, void *size_info) > { > struct tcg_pcr_event2_head *header; > int event_size, size = 0; >-- >2.26.0 >