Received: by 10.192.165.156 with SMTP id m28csp1774987imm; Thu, 12 Apr 2018 03:21:00 -0700 (PDT) X-Google-Smtp-Source: AIpwx485q8DAj789gzhXku/v3pQof+dzIC4Kgp+s0aNUA6cypKWA9VbBx4qZC5alG7qcCRtp9rC8 X-Received: by 10.99.100.6 with SMTP id y6mr250957pgb.254.1523528460076; Thu, 12 Apr 2018 03:21:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523528460; cv=none; d=google.com; s=arc-20160816; b=v0IPm30U3QP+DOA0+vIpZiNsx2gLUYw6YSEKH0ycw58uPcbYpi/17Q3ZgvLmLHe4+B LjB2xPHqZXvcTw4WcLYcUrzI8vsqDw7G77zOYKJK/txZYkhOctEw4dF7Ng8QRElgBO5C ZNyeLDzbGu3smXtE9l9/55zpJZUfSMFmk3mEurD7d6DoXyuCyVXjQLdxrkQgMYEN0mMt VCRrcZV+UNb5bOe6KQWfchnxGtxORFq7e6cogriw6O8nhEcrTMl8xUYffpIFfz7l8M0F 6cjhKs7JGnIV74V8gLmqQhSRO/eFe4rO+m1ugP0M0QxYRDe3NKoGXvQZhb2mGVXIy2nc PPhQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:from:subject:references:message-id :in-reply-to:date:mime-version:dkim-signature :arc-authentication-results; bh=hLToXwmJbg1yX1jC7Gu/EfyfWfqzqbHKgkap6xjATG4=; b=pzV8wHd5hKXIPSwKlq0li4n0sZD2FV/e9Hze9v4a6wA2Z3l4bk435axGiHPqlYr12I qsAm/Jp6pw/lSlaRBvnytf3k1jM1MNrggtsVwUDiz9kptuRL1ewJN4yKHsA8MSe3Kz+g 1z3JjTpM+2DVhBN37npxK3TFy1xucUjV7gZzEu6S3A0w7F1DO+xefKDg0Zi3stppf3x0 LwPNkShfYHr7NAGxNdrbWrJZQ7esiSJ3aNl/Q2kVUeQayezkn49w7JYc5yFAJzYhcM3U UqG0BatAo14XT3oiHSe5EVjYeQwqxKHnUzLc7kC4DJ7a2NRcC1MCmwQrex3JyFu+UTCY NNPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=qGRqY4zG; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z79si2425111pfa.120.2018.04.12.03.20.23; Thu, 12 Apr 2018 03:21:00 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=qGRqY4zG; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752752AbeDLKOR (ORCPT + 99 others); Thu, 12 Apr 2018 06:14:17 -0400 Received: from mail-ua0-f202.google.com ([209.85.217.202]:34509 "EHLO mail-ua0-f202.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752656AbeDLKOO (ORCPT ); Thu, 12 Apr 2018 06:14:14 -0400 Received: by mail-ua0-f202.google.com with SMTP id c12so3266234uan.1 for ; Thu, 12 Apr 2018 03:14:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:date:in-reply-to:message-id:references:subject:from:to :cc; bh=hLToXwmJbg1yX1jC7Gu/EfyfWfqzqbHKgkap6xjATG4=; b=qGRqY4zGG0CzLp6FChP9ibhqtItRwa2Ba8Kbe65fM9FPPt8Ji0F/bam5FbEQJIrGId HJr/fiPkOjezxWh0XWl4teU0euYKsJQHcggO46zJRSWl4cUhm+faF5DtRcCv8H0o5JWM aeAF7L5ZdEmjYwk8BFz5CguG1cNfKdWRDaF6FhYJOF2RXyovZDkeUEMI8Q24+2u+NY4n nfji2bvm57JvuBiwECzoqobdezY5WLTIp8aB7PX4QnAjV89cBEb8jarltKQczBzkMIl6 6d2cdVDuIi0v1oo41dfsmDPwuld/8E9G1x/AVCYFQ4XusztZur+fvCcxGDgsFDombhP8 R2vQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:date:in-reply-to:message-id :references:subject:from:to:cc; bh=hLToXwmJbg1yX1jC7Gu/EfyfWfqzqbHKgkap6xjATG4=; b=A1BxAPm/9XoTzSmYLNY7ya5UKZ2I+PcgBIOOiG4wC3smkqTtWbQ+27UzwkiJCfoyvY Nh3lB7JguKkooBYSYJ1lo3844FJprSSJeL/FO7lIyuto32A7PXUkys/r7FsTkK0hp7/i GGqvGF3FrEP+dfgCu8YxreERlwQHGdIkV0Q4+mdGFxHmClX8lMbaW52B+S72b3OS9qPV w6fbTsDq421MOn3e98A2wt1XtYQyObzofkXMjFv3f9y+xQo53QpUgotVExUvXfEwnQCA 8sd+VZq+Viu2MfipriTBhV0xcxE1psKI20fABe+pHjxJfKaFlwaRyoIsRw3zmb+zkAqS CMag== X-Gm-Message-State: ALQs6tBhBMIDdB7YSkkZwjkR/73xwCgHpsp324s1wu+7jY1yHi3+0pNd wb1cZSduiKp306xNBGTo5qU/oFEOMw== MIME-Version: 1.0 X-Received: by 10.176.81.38 with SMTP id e35mr131835uaa.48.1523528053240; Thu, 12 Apr 2018 03:14:13 -0700 (PDT) Date: Thu, 12 Apr 2018 12:13:47 +0200 In-Reply-To: <20180412101350.210547-1-tweek@google.com> Message-Id: <20180412101350.210547-2-tweek@google.com> References: <20180412101350.210547-1-tweek@google.com> X-Mailer: git-send-email 2.17.0.484.g0c8726318c-goog Subject: [PATCH v2 1/4] tpm: Add explicit endianness cast From: Thiebaud Weksteen To: jarkko.sakkinen@linux.intel.com, nayna@linux.vnet.ibm.com, linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org, tweek@google.com Cc: linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org, Thiebaud Weksteen Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Signed-off-by: Thiebaud Weksteen --- drivers/char/tpm/tpm_eventlog_of.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/char/tpm/tpm_eventlog_of.c b/drivers/char/tpm/tpm_eventlog_of.c index 96fd5646f866..d74568d58a66 100644 --- a/drivers/char/tpm/tpm_eventlog_of.c +++ b/drivers/char/tpm/tpm_eventlog_of.c @@ -56,8 +56,8 @@ int tpm_read_log_of(struct tpm_chip *chip) * but physical tpm needs the conversion. */ if (of_property_match_string(np, "compatible", "IBM,vtpm") < 0) { - size = be32_to_cpup(sizep); - base = be64_to_cpup(basep); + size = be32_to_cpup((__be32 *)sizep); + base = be64_to_cpup((__be64 *)basep); } else { size = *sizep; base = *basep; -- 2.17.0.484.g0c8726318c-goog