From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 615E1168B4 for ; Mon, 8 May 2023 09:51:14 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DC743C433EF; Mon, 8 May 2023 09:51:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1683539474; bh=8r1z6+zlLX5kZZjRsnVMbks8vuLgQJO5hKGKMtuVvsk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ShLJpGOZExj2gGh9Gm4x/L0REDvp02hLntO8W8P1RH6/a3cvfnY8PzQefMyVqEXn+ 32KEvkkuRoXm/+481biBAFXl7sA85C5MmADhbh3gmn1aW5oASmFv7qm58EUvzHuv9A bc8BbPYsjKc5JGumdRNRhySm6b3ftprOeo7fjOo8= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Randy Dunlap , Fabio Estevam , Richard Weinberger , Anton Ivanov , Johannes Berg , linux-um@lists.infradead.org, Mimi Zohar Subject: [PATCH 6.1 029/611] IMA: allow/fix UML builds Date: Mon, 8 May 2023 11:37:51 +0200 Message-Id: <20230508094422.701491705@linuxfoundation.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230508094421.513073170@linuxfoundation.org> References: <20230508094421.513073170@linuxfoundation.org> User-Agent: quilt/0.67 Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Randy Dunlap commit 644f17412f5acf01a19af9d04a921937a2bc86c6 upstream. UML supports HAS_IOMEM since 0bbadafdc49d (um: allow disabling NO_IOMEM). Current IMA build on UML fails on allmodconfig (with TCG_TPM=m): ld: security/integrity/ima/ima_queue.o: in function `ima_add_template_entry': ima_queue.c:(.text+0x2d9): undefined reference to `tpm_pcr_extend' ld: security/integrity/ima/ima_init.o: in function `ima_init': ima_init.c:(.init.text+0x43f): undefined reference to `tpm_default_chip' ld: security/integrity/ima/ima_crypto.o: in function `ima_calc_boot_aggregate_tfm': ima_crypto.c:(.text+0x1044): undefined reference to `tpm_pcr_read' ld: ima_crypto.c:(.text+0x10d8): undefined reference to `tpm_pcr_read' Modify the IMA Kconfig entry so that it selects TCG_TPM if HAS_IOMEM is set, regardless of the UML Kconfig setting. This updates TCG_TPM from =m to =y and fixes the linker errors. Fixes: f4a0391dfa91 ("ima: fix Kconfig dependencies") Cc: Stable # v5.14+ Signed-off-by: Randy Dunlap Cc: Fabio Estevam Cc: Richard Weinberger Cc: Anton Ivanov Cc: Johannes Berg Cc: linux-um@lists.infradead.org Signed-off-by: Mimi Zohar Signed-off-by: Greg Kroah-Hartman --- security/integrity/ima/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/security/integrity/ima/Kconfig +++ b/security/integrity/ima/Kconfig @@ -8,7 +8,7 @@ config IMA select CRYPTO_HMAC select CRYPTO_SHA1 select CRYPTO_HASH_INFO - select TCG_TPM if HAS_IOMEM && !UML + select TCG_TPM if HAS_IOMEM select TCG_TIS if TCG_TPM && X86 select TCG_CRB if TCG_TPM && ACPI select TCG_IBMVTPM if TCG_TPM && PPC_PSERIES 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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1EB20C7EE23 for ; Mon, 8 May 2023 10:40:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=roPgLwi/GS/YjJQ92z0YFpXt/76TisDmIhfsWVmvt00=; b=pR/en+meDM8Ea0 7M7sRo4L9L+4T1u/0vfoLeGO/wn1pAfw9zIQIe2uC1fGyazWDmkyr6Nsrt4GDS/Sj+aIWLOxE3RSy 7jqIc6KTh3O+U3Gmuj960Eu6qGXXhMO8yrSDJ6sq6FUeI28PpGC9r9wV0bBAg6R63JEQ2OTn8PJwp xuSIoGhxTojXwbWz5AhvpF82MFN4Iu/zTgiItJzwC1ayJZStGh5mJiPiBXYtuEiOnF6EzDTqA6E/w My2XvDxqkfdjHK7Vl7Plrhc1enRs++c1UTjn1O1Xenpfq74hOLbO2/W1Pn6qPpgkOYxK7hmVPQXIA ZfLusVkg4UHEiGIG64vA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pvyIH-000Jvo-2f; Mon, 08 May 2023 10:40:37 +0000 Received: from desiato.infradead.org ([2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pvyIG-000Jv1-0j for linux-um@bombadil.infradead.org; Mon, 08 May 2023 10:40:36 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Content-Transfer-Encoding:Content-Type :MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: Sender:Reply-To:Content-ID:Content-Description; bh=BJbGACP6tfuYkpQIJttBxGgFEu8rMmOMAAji2QQJ0Hw=; b=iSD71POlTGwZDPGJSox5gVlZK3 jDXrCGmkDcGyVxhwMX9f2cdmTLBYA9WGHCusmvAVQgJ8lfWhPOz9EfMj2cYQbhMA8+8EpAic+KKGr TS+rDNjRL7nat6wvbfKGwM8jLv9oDIg/QMOPLNemtUqafemKknel28rfQodKt8JJGaAXUwxkijF+3 LPLDBGoaJt0VtsQfCEvW6Rth/3O6pEL6SqkYspXsMKla+Fleg3CL8anyy+q4Ki9XAoFDKeF2BYrt/ ZQy/oNXrQgsGAHBkxOjS5SCia20OJms+1uY2YRXMkj728kd/zRx8HKy3ZTC+7wQUzfew+zNp2af4u 7iLVY6Zg==; Received: from dfw.source.kernel.org ([2604:1380:4641:c500::1]) by desiato.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pvxWX-0057Pb-2I for linux-um@lists.infradead.org; Mon, 08 May 2023 09:51:19 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id CC7FF621B7; Mon, 8 May 2023 09:51:14 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DC743C433EF; Mon, 8 May 2023 09:51:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1683539474; bh=8r1z6+zlLX5kZZjRsnVMbks8vuLgQJO5hKGKMtuVvsk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ShLJpGOZExj2gGh9Gm4x/L0REDvp02hLntO8W8P1RH6/a3cvfnY8PzQefMyVqEXn+ 32KEvkkuRoXm/+481biBAFXl7sA85C5MmADhbh3gmn1aW5oASmFv7qm58EUvzHuv9A bc8BbPYsjKc5JGumdRNRhySm6b3ftprOeo7fjOo8= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Randy Dunlap , Fabio Estevam , Richard Weinberger , Anton Ivanov , Johannes Berg , linux-um@lists.infradead.org, Mimi Zohar Subject: [PATCH 6.1 029/611] IMA: allow/fix UML builds Date: Mon, 8 May 2023 11:37:51 +0200 Message-Id: <20230508094422.701491705@linuxfoundation.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230508094421.513073170@linuxfoundation.org> References: <20230508094421.513073170@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230508_105117_943289_F076E273 X-CRM114-Status: GOOD ( 12.10 ) X-BeenThere: linux-um@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-um" Errors-To: linux-um-bounces+linux-um=archiver.kernel.org@lists.infradead.org From: Randy Dunlap commit 644f17412f5acf01a19af9d04a921937a2bc86c6 upstream. UML supports HAS_IOMEM since 0bbadafdc49d (um: allow disabling NO_IOMEM). Current IMA build on UML fails on allmodconfig (with TCG_TPM=m): ld: security/integrity/ima/ima_queue.o: in function `ima_add_template_entry': ima_queue.c:(.text+0x2d9): undefined reference to `tpm_pcr_extend' ld: security/integrity/ima/ima_init.o: in function `ima_init': ima_init.c:(.init.text+0x43f): undefined reference to `tpm_default_chip' ld: security/integrity/ima/ima_crypto.o: in function `ima_calc_boot_aggregate_tfm': ima_crypto.c:(.text+0x1044): undefined reference to `tpm_pcr_read' ld: ima_crypto.c:(.text+0x10d8): undefined reference to `tpm_pcr_read' Modify the IMA Kconfig entry so that it selects TCG_TPM if HAS_IOMEM is set, regardless of the UML Kconfig setting. This updates TCG_TPM from =m to =y and fixes the linker errors. Fixes: f4a0391dfa91 ("ima: fix Kconfig dependencies") Cc: Stable # v5.14+ Signed-off-by: Randy Dunlap Cc: Fabio Estevam Cc: Richard Weinberger Cc: Anton Ivanov Cc: Johannes Berg Cc: linux-um@lists.infradead.org Signed-off-by: Mimi Zohar Signed-off-by: Greg Kroah-Hartman --- security/integrity/ima/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/security/integrity/ima/Kconfig +++ b/security/integrity/ima/Kconfig @@ -8,7 +8,7 @@ config IMA select CRYPTO_HMAC select CRYPTO_SHA1 select CRYPTO_HASH_INFO - select TCG_TPM if HAS_IOMEM && !UML + select TCG_TPM if HAS_IOMEM select TCG_TIS if TCG_TPM && X86 select TCG_CRB if TCG_TPM && ACPI select TCG_IBMVTPM if TCG_TPM && PPC_PSERIES _______________________________________________ linux-um mailing list linux-um@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-um