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 X-Spam-Level: X-Spam-Status: No, score=-5.5 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_PASS,URIBL_BLOCKED,USER_AGENT_MUTT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id CD9F0C43381 for ; Tue, 26 Mar 2019 11:52:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A5ACB2084B for ; Tue, 26 Mar 2019 11:52:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730133AbfCZLwz (ORCPT ); Tue, 26 Mar 2019 07:52:55 -0400 Received: from mga14.intel.com ([192.55.52.115]:14850 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726277AbfCZLwz (ORCPT ); Tue, 26 Mar 2019 07:52:55 -0400 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 26 Mar 2019 04:52:54 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,271,1549958400"; d="scan'208";a="285978682" Received: from jsakkine-mobl1.tm.intel.com (HELO localhost) ([10.237.50.182]) by orsmga004.jf.intel.com with ESMTP; 26 Mar 2019 04:52:50 -0700 Date: Tue, 26 Mar 2019 13:52:49 +0200 From: Jarkko Sakkinen To: linux-integrity@vger.kernel.org Cc: linux-security-module@vger.kernel.org, Dan Williams , stable@vger.kernel.org, James Bottomley , Mimi Zohar , David Howells , James Morris , "Serge E. Hallyn" , "open list:KEYS-TRUSTED" , open list Subject: Re: [PATCH] KEYS: trusted: allow trusted.ko to initialize w/o a TPM Message-ID: <20190326115249.GC10898@linux.intel.com> References: <20190325144735.30443-1-jarkko.sakkinen@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190325144735.30443-1-jarkko.sakkinen@linux.intel.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo User-Agent: Mutt/1.10.1 (2018-07-13) Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org On Mon, Mar 25, 2019 at 04:47:35PM +0200, Jarkko Sakkinen wrote: > Allow trusted.ko to initialize w/o a TPM. This commit adds checks to the > key type callbacks and exported functions to fail when a TPM is not > available. > > Cc: Dan Williams > Cc: stable@vger.kernel.org > Fixes: 240730437deb ("KEYS: trusted: explicitly use tpm_chip structure...") > Signed-off-by: Jarkko Sakkinen Will send a revised version: since now the key type is not registered, none of the callbacks needs the check for the chip instance. Only the exported functions should have it. /Jarkko