Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1186163
| Path | csiph.com!aioe.org!bofh.it!news.nic.it!robomod |
|---|---|
| From | "Hon Ching(Vicky) Lo" <honclo@linux.vnet.ibm.com> |
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v4 1/2] vTPM: support little endian guests |
| Date | Thu, 16 Jul 2015 20:00:03 +0200 |
| Message-ID | <pMVBV-5ug-27@gated-at.bofh.it> (permalink) |
| References | <pCtQB-6aP-11@gated-at.bofh.it> <pLT98-1S6-11@gated-at.bofh.it> |
| X-Original-To | Peter Hüwe <PeterHuewe@gmx.de> |
| X-Helo | d28dlp01.in.ibm.com |
| X-Mailfrom | honclo@linux.vnet.ibm.com |
| X-Rcptto | linux-kernel@vger.kernel.org |
| Content-Type | text/plain; charset="UTF-8" |
| MIME-Version | 1.0 |
| X-Mailer | Evolution 2.32.3 (2.32.3-34.el6) |
| Content-Transfer-Encoding | 8bit |
| X-Tm-As-Mml | disable |
| X-Content-Scanned | Fidelis XPS MAILER |
| X-Cbid | 15071617-0005-0000-0000-00000674D8BD |
| Sender | robomod@news.nic.it |
| List-ID | <linux-kernel.vger.kernel.org> |
| X-Mailing-List | linux-kernel@vger.kernel.org |
| Approved | robomod@news.nic.it |
| Lines | 51 |
| Organization | linux.* mail to news gateway |
| X-Original-Cc | tpmdd-devel@lists.sourceforge.net, Ashley Lai <ashley@ashleylai.com>, Vicky Lo <honclo2014@gmail.com>, linux-kernel@vger.kernel.org, Joy Latten <jmlatten@linux.vnet.ibm.com> |
| X-Original-Date | Thu, 16 Jul 2015 13:54:15 -0400 |
| X-Original-Message-ID | <1437069255.29298.5.camel@vtpm2014.ibm.com> |
| X-Original-References | <1434579429-29449-1-git-send-email-honclo@linux.vnet.ibm.com> <201507132308.00824.PeterHuewe@gmx.de> |
| X-Original-Sender | linux-kernel-owner@vger.kernel.org |
| Xref | aioe.org linux.kernel:1186163 |
Show key headers only | View raw
Hi Peter, On Mon, 2015-07-13 at 23:08 +0200, Peter Hüwe wrote: > Hi Vicky, > > sorry for the late reply > > > > This patch makes the code endianness independent. We defined a > > macro do_endian_conversion to apply endianness to raw integers > > in the event entries so that they will be displayed properly. > > tpm_binary_bios_measurements_show() is modified for the display. > > > > Signed-off-by: Hon Ching(Vicky) Lo <honclo@linux.vnet.ibm.com> > > Signed-off-by: Joy Latten <jmlatten@linux.vnet.ibm.com> > > > b/drivers/char/tpm/tpm_eventlog.h index e7da086..267bfbd 100644 > > --- a/drivers/char/tpm/tpm_eventlog.h > > +++ b/drivers/char/tpm/tpm_eventlog.h > > @@ -6,6 +6,12 @@ > > #define MAX_TEXT_EVENT 1000 /* Max event string length */ > > #define ACPI_TCPA_SIG "TCPA" /* 0x41504354 /'TCPA' */ > > > > +#ifdef CONFIG_PPC64 > > +#define do_endian_conversion(x) be32_to_cpu(x) > > +#else > > +#define do_endian_conversion(x) x > > +#endif > > > Why is this macro needed? > shouldn't the be32_to_cpu macro already do correct thing? > Or am I missing something here? > > > Thanks, > Peter > The macro is defined to not do the conversion in the architecture that does not need it. Regards, Vicky -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
Re: [PATCH v4 1/2] vTPM: support little endian guests "Hon Ching(Vicky) Lo" <honclo@linux.vnet.ibm.com> - 2015-07-16 20:00 +0200 Re: [PATCH v4 1/2] vTPM: support little endian guests Peter Hüwe <PeterHuewe@gmx.de> - 2015-07-16 20:50 +0200
csiph-web