| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Copyright 2012 IBM Corporation |
|---|
| 3 | 4 | * |
|---|
| .. | .. |
|---|
| 7 | 8 | * Maintained by: <tpmdd-devel@lists.sourceforge.net> |
|---|
| 8 | 9 | * |
|---|
| 9 | 10 | * Read the event log created by the firmware on PPC64 |
|---|
| 10 | | - * |
|---|
| 11 | | - * This program is free software; you can redistribute it and/or |
|---|
| 12 | | - * modify it under the terms of the GNU General Public License |
|---|
| 13 | | - * as published by the Free Software Foundation; either version |
|---|
| 14 | | - * 2 of the License, or (at your option) any later version. |
|---|
| 15 | | - * |
|---|
| 16 | 11 | */ |
|---|
| 17 | 12 | |
|---|
| 18 | 13 | #include <linux/slab.h> |
|---|
| .. | .. |
|---|
| 56 | 51 | * endian format. For this reason, vtpm doesn't need conversion |
|---|
| 57 | 52 | * but physical tpm needs the conversion. |
|---|
| 58 | 53 | */ |
|---|
| 59 | | - if (of_property_match_string(np, "compatible", "IBM,vtpm") < 0) { |
|---|
| 54 | + if (of_property_match_string(np, "compatible", "IBM,vtpm") < 0 && |
|---|
| 55 | + of_property_match_string(np, "compatible", "IBM,vtpm20") < 0) { |
|---|
| 60 | 56 | size = be32_to_cpup((__force __be32 *)sizep); |
|---|
| 61 | 57 | base = be64_to_cpup((__force __be64 *)basep); |
|---|
| 62 | 58 | } else { |
|---|