Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp8950864rwb; Thu, 24 Nov 2022 06:19:05 -0800 (PST) X-Google-Smtp-Source: AA0mqf5IBhv7iVSHOInSWA67XupNPvQfsQfcbQul9jvNdWzekztn4Mj2334MIolM4aqNEQOj/e8K X-Received: by 2002:a17:902:e492:b0:17f:72c3:8922 with SMTP id i18-20020a170902e49200b0017f72c38922mr14454743ple.167.1669299545122; Thu, 24 Nov 2022 06:19:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669299545; cv=none; d=google.com; s=arc-20160816; b=awBMUATGM7MKUCMQ6/v1BqOiCORpCI+fEGcEGJBYvI3ueBT3JHgJWI15jlnxoikvQK Zo8sch9bkg46H2/cWLvsz0CcQfIY2Tl+Qk+CiKjo1xpbDC7RWorl/jtdbLzNgNAfjBHO uWVO2IxY87Vx18nFR0iF3m1Csh8VqyOeTHLzHZc1CCZ8W81FSXq/0PDeJEczyEbwfr3I L4kWN7G/e1H3YAqT2x+M+XzISzZH+LDSQ+xoHmfXsTYKLlpQpETIxFvTJUvUt9jwXMZq pdDwPLxUL+LMhZKi7JYhHYD+XYiHf8i+gLZA+tvrVThgQWfZ6adcnnq9sE2fq+J9ZNAC Frfw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:ui-outboundreport:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=ptF3+UGs4RT73xf2t1eIkj3kEEU2mVqh+94Ww0mBJ/Y=; b=Cv6Jxnn3HF4H5EOXK/3HtpIUUc6ZCPFz/z+ogTHTnbU7qKD4f4njyV8NGDUoB+9PC9 Vc2FsLW9lOr9WCqDQs7exnMM1/fdo0liy3KGdn3Fn+dQ/cTkB/+xxNfhFCTr4ojeOD6L 3xYx7Lw/yFgzSaJoxKLLjMk04xJ9MGFM07xhuwk7iFZxGajsntbth+bEDE96KLe2iru5 oh57eEADTRTY3buAZNfCJtWFGAXo9LsxDjjmVKCUVSHrVQeI2lciAX58cbvuxnUhaOxM 6rln7hgqoi+fJCOfQSSiXGRiusFo7O1ojJW5CHTiaoJbkaHlwpipIqwajz+I0RWcCeLm qBHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmx.de header.s=s31663417 header.b=AnW4r+Os; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmx.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 3-20020a630403000000b00477cfa47174si1532392pge.180.2022.11.24.06.18.53; Thu, 24 Nov 2022 06:19:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmx.de header.s=s31663417 header.b=AnW4r+Os; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gmx.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230233AbiKXN5J (ORCPT + 86 others); Thu, 24 Nov 2022 08:57:09 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49446 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230121AbiKXN4g (ORCPT ); Thu, 24 Nov 2022 08:56:36 -0500 Received: from mout.gmx.net (mout.gmx.net [212.227.15.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 959531144A0; Thu, 24 Nov 2022 05:56:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.de; s=s31663417; t=1669298171; bh=ptF3+UGs4RT73xf2t1eIkj3kEEU2mVqh+94Ww0mBJ/Y=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=AnW4r+OsnxZ+EYbiLrZC1GEfrkwBMKkGjVbunHu9MVuFBEg8tJv4TkeXrSLD8HVib 2pL4ZWpLDB/eD/XjdwtKOR9haHd/ygJ6ThKqgy9/vfglCvO6Pbo1kuqmRc0bZj3mQY /f8di0hXImAOFVtsTfmQx+PYBCWY2sP79gtebkLS9Z4HuOd91+qjJX3OJKePk60qeQ l8hDjg7fSqtIjxHmL9x1u2WHIQXjKaouDYKWr11xC6htp67F/b/morily0q26F37N9 RYQ40TQZ6JMYnsIVae5hINasFXYcMTIQYx0F+Yxz/OBSLs/U80QpK6RTlJydrAY71c /6JnRskhZrXug== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Received: from Venus.speedport.ip ([84.162.7.17]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MjS9I-1pLxfF1RgQ-00kulG; Thu, 24 Nov 2022 14:56:11 +0100 From: Lino Sanfilippo To: peterhuewe@gmx.de, jarkko@kernel.org, jgg@ziepe.ca Cc: stefanb@linux.vnet.ibm.com, linux@mniewoehner.de, linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org, jandryuk@gmail.com, pmenzel@molgen.mpg.de, l.sanfilippo@kunbus.com, LinoSanfilippo@gmx.de, lukas@wunner.de, p.rosenberger@kunbus.com Subject: [PATCH v11 04/14] tpm, tpm_tis: Do not skip reset of original interrupt vector Date: Thu, 24 Nov 2022 14:55:28 +0100 Message-Id: <20221124135538.31020-5-LinoSanfilippo@gmx.de> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20221124135538.31020-1-LinoSanfilippo@gmx.de> References: <20221124135538.31020-1-LinoSanfilippo@gmx.de> MIME-Version: 1.0 Content-Transfer-Encoding: base64 X-Provags-ID: V03:K1:xa3nABt20tkSDNQZTl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jbw47bupIuN4sC9OOsHMJiCZkdw9Z1qfqqNTbQROvsUxxA86weCLHZ+T9xA1Uo5gOa8ARg vMuYmSUIxQaxA1qjmg1zDKADcCxzIxg397Ivy4DzgSzzACqQg73a84aE1+/+NVZM2ZNaz8NvS OmIYpA== X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,MIME_BASE64_TEXT, RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RnJvbTogTGlubyBTYW5maWxpcHBvIDxsLnNhbmZpbGlwcG9Aa3VuYnVzLmNvbT4KCklmIGluIHRw bV90aXNfcHJvYmVfaXJxX3NpbmdsZSgpIGFuIGVycm9yIG9jY3VycyBhZnRlciB0aGUgb3JpZ2lu YWwKaW50ZXJydXB0IHZlY3RvciBoYXMgYmVlbiByZWFkLCByZXN0b3JlIHRoZSBpbnRlcnJ1cHRz IGJlZm9yZSB0aGUgZXJyb3IgaXMKcmV0dXJuZWQuCgpTaW5jZSB0aGUgY2FsbGVyIGRvZXMgbm90 IGNoZWNrIHRoZSBlcnJvciB2YWx1ZSwgcmV0dXJuIC0xIGluIGFueSBjYXNlIHRoYXQKdGhlIFRQ TV9DSElQX0ZMQUdfSVJRIGZsYWcgaXMgbm90IHNldC4gU2luY2UgdGhlIHJldHVybiB2YWx1ZSBv ZiBmdW5jdGlvbgp0cG1fdGlzX2dlbl9pbnRlcnJ1cHQoKSBpcyBub3QgbG9uZ2VyIHVzZWQsIG1h a2UgaXQgYSB2b2lkIGZ1bmN0aW9uLgoKRml4ZXM6IDExMDdkMDY1ZmRmMSAoInRwbV90aXM6IElu dHJvZHVjZSBpbnRlcm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