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=-8.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS 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 C3709C433E1 for ; Thu, 14 May 2020 11:26:23 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 9B50E20727 for ; Thu, 14 May 2020 11:26:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726190AbgENL0X (ORCPT ); Thu, 14 May 2020 07:26:23 -0400 Received: from mga01.intel.com ([192.55.52.88]:35176 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726056AbgENL0W (ORCPT ); Thu, 14 May 2020 07:26:22 -0400 IronPort-SDR: ZmwZzeHN14KIJYkoNZ6u8t72slnvL8kj2RV8dl6rEKgDE5O02sYdfmek13PeZ5VQn11U9A3ICy kVqaUJMFeRcQ== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 May 2020 04:26:22 -0700 IronPort-SDR: +jfDun7cOEjJ/dNmFy7jyIpp1N07moS8qViN2jFj9nFLdqUijfTUpompb60TjJ87ofQ9AwFqrA k0dHHnJhWC6w== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,391,1583222400"; d="scan'208";a="262807125" Received: from apogrebi-mobl2.ger.corp.intel.com ([10.249.39.119]) by orsmga003.jf.intel.com with ESMTP; 14 May 2020 04:26:14 -0700 Message-ID: <5e66f2d3e3f2c6af4bafd25f0d228774b8302e8d.camel@linux.intel.com> Subject: Re: [PATCH v8 1/8] tpm: tpm_tis: Make implementation of read16, read32 and write32 optional From: Jarkko Sakkinen To: amirmizi6@gmail.com, Eyal.Cohen@nuvoton.com, oshrialkoby85@gmail.com, alexander.steffen@infineon.com, robh+dt@kernel.org, benoit.houyere@st.com, mark.rutland@arm.com, peterhuewe@gmx.de, christophe-h.richard@st.com, jgg@ziepe.ca, arnd@arndb.de, gregkh@linuxfoundation.org Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-integrity@vger.kernel.org, oshri.alkoby@nuvoton.com, tmaimon77@gmail.com, gcwilson@us.ibm.com, kgoldman@us.ibm.com, Dan.Morav@nuvoton.com, oren.tanami@nuvoton.com, shmulik.hager@nuvoton.com, amir.mizinski@nuvoton.com Date: Thu, 14 May 2020 14:26:14 +0300 In-Reply-To: <20200512141431.83833-2-amirmizi6@gmail.com> References: <20200512141431.83833-1-amirmizi6@gmail.com> <20200512141431.83833-2-amirmizi6@gmail.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.36.1-2 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2020-05-12 at 17:14 +0300, amirmizi6@gmail.com wrote: > From: Amir Mizinski > > Only tpm_tis can use memory-mapped I/O, which is truly mapped into > the kernel's memory space. Therefore, using ioread16/ioread32/iowrite32 > turns into a straightforward pointer dereference. > Every other driver requires more complicated operations to read more than > one byte at a time and will just fall back to read_bytes/write_bytes. > Therefore, move this common code out of tpm_tis_spi and into tpm_tis_core > so that it is used automatically when low-level drivers do not implement > the specialized methods. > > Co-developed-by: Alexander Steffen > Signed-off-by: Alexander Steffen > Signed-off-by: Amir Mizinski > Reviewed-by: Jarkko Sakkinen OK, so I applied this one: http://git.infradead.org/users/jjs/linux-tpmdd.git/commit/fa05dc792ea02043f3c21467cb4485a38ac19bdf I.e. no need to carry this one any more in the series. Sorry that I haven't done this before (should have). /Jarkko