From: Andrew Cooper <andrew.cooper3@citrix.com>
To: "Xu, Quan" <quan.xu@intel.com>, Olaf Hering <olaf@aepfle.de>
Cc: Daniel De Graaf <dgdegra@tycho.nsa.gov>,
"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>
Subject: Re: stubdom vtpm build failure in staging
Date: Thu, 12 Feb 2015 17:40:29 +0000 [thread overview]
Message-ID: <54DCE58D.5040102@citrix.com> (raw)
In-Reply-To: <945CA011AD5F084CBEA3E851C0AB28890E8955D7@SHSMSX101.ccr.corp.intel.com>
On 12/02/15 17:24, Xu, Quan wrote:
>
>
>> -----Original Message-----
>> From: xen-devel-bounces@lists.xen.org
>> [mailto:xen-devel-bounces@lists.xen.org] On Behalf Of Xu, Quan
>> Sent: Friday, February 13, 2015 12:57 AM
>> To: Olaf Hering
>> Cc: xen-devel@lists.xen.org
>> Subject: Re: [Xen-devel] stubdom vtpm build failure in staging
>>
>> Sorry for that. Read the other thread of email, it looks that some maintainers are
>> working for this issue.
>> And I am working for 'Xen stubdom vTPM for HVM virtual machine' v4 patches.
>> There are a lot of modifications.
>>
>> I will be out of office from Feb. 16th to Feb. 26th for Chinese New Year. I plan to
>> summit v4 patches Before Feb. 16, and fix this issue after Feb. 26th.
>>
>> --Quan
>>
>>
>>> -----Original Message-----
>>> From: Olaf Hering [mailto:olaf@aepfle.de]
>>> Sent: Wednesday, February 11, 2015 11:21 PM
>>> To: Xu, Quan
>>> Cc: xen-devel@lists.xen.org
>>> Subject: Re: [Xen-devel] stubdom vtpm build failure in staging
>>>
>>> On Wed, Jan 28, Xu, Quan wrote:
>>>
>>>> Thanks, I will check and fix it tomorrow. It is 23:12 PM Pacific time now.
>>> Any progress?
>>> These typedefs are duplicated in stubdom/vtpmmgr/tcg.h and supported
>>> compilers do not cope with current staging:
>>>
>>> # for i in `grep -w typedef stubdom/vtpmmgr/tcg.h | sed -n '/;/{s@^.*
>>> @@;s@;@@p}'` # do
>>> # if test -n "`git grep -wn $i|grep -w typedef|grep -v
>>> stubdom/vtpmmgr/tcg.h`"
>>> # then
>>> # echo $i
>>> # fi
>>> # done
>>>
>>> BYTE
>>> BOOL
>>> UINT16
>>> UINT32
>>> UINT64
>>> TPM_HANDLE
>>> TPM_ALGORITHM_ID
>>>
>>> TPMI_RH_HIERARCHY_AUTH and TPM_ALG_ID are defined twice in the same
>>> file.
>>>
>>> This change works for me:
>>>
>>> ---
>>> stubdom/vtpmmgr/odd_types.h | 11 +++++++++++
>>> stubdom/vtpmmgr/tcg.h | 9 +--------
>>> stubdom/vtpmmgr/tpm2_types.h | 11 +----------
>>> 3 files changed, 13 insertions(+), 18 deletions(-) create mode
>>> 100644 stubdom/vtpmmgr/odd_types.h
>>>
>>> diff --git a/stubdom/vtpmmgr/odd_types.h b/stubdom/vtpmmgr/odd_types.h
>>> new file mode 100644 index 0000000..d72da9b
>>> --- /dev/null
>>> +++ b/stubdom/vtpmmgr/odd_types.h
>>> @@ -0,0 +1,11 @@
>>> +#ifndef VTPM_ODD_TYPES
>>> +#define VTPM_ODD_TYPES 1
>>> +typedef unsigned char BYTE;
>>> +typedef unsigned char BOOL;
>>> +typedef uint16_t UINT16;
>>> +typedef uint32_t UINT32;
>>> +typedef uint64_t UINT64;
>>> +typedef UINT32 TPM_HANDLE;
>>> +typedef UINT32 TPM_ALGORITHM_ID;
>>> +#endif
>>> +
>>> diff --git a/stubdom/vtpmmgr/tcg.h b/stubdom/vtpmmgr/tcg.h index
>>> 7321ec6..cac1bbc 100644
>>> --- a/stubdom/vtpmmgr/tcg.h
>>> +++ b/stubdom/vtpmmgr/tcg.h
>>> @@ -401,16 +401,10 @@
>>>
>>>
>>> // *************************** TYPEDEFS
>>> ********************************* -typedef unsigned char BYTE;
>>> -typedef unsigned char BOOL; -typedef uint16_t UINT16; -typedef
>>> uint32_t UINT32; -typedef uint64_t UINT64;
>>> -
>>> +#include "odd_types.h"
> I think it is just for gcc backward compatibility. IMHO, That does seem pretty strange.
> cc Daniel who is the maintainer of vTPM / XSM.
>
> -Quan
Redefining an identifier in the same scope is violation of the C spec.
Newer GCC tolerates bad code which redundantly declares identifiers, but
even newer GCC will still emit a diagnostic in -pedantic mode.
This build breakage needs fixing, and not just in the name of backwards
compatibility.
~Andrew
next prev parent reply other threads:[~2015-02-12 17:40 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-28 15:08 stubdom vtpm build failure in staging Olaf Hering
2015-01-28 15:13 ` Xu, Quan
2015-02-11 15:20 ` Olaf Hering
2015-02-12 16:56 ` Xu, Quan
2015-02-12 17:24 ` Xu, Quan
2015-02-12 17:40 ` Andrew Cooper [this message]
2015-02-13 2:07 ` Xu, Quan
2015-02-25 13:54 ` Ian Campbell
2015-02-27 15:07 ` Xu, Quan
2015-03-11 10:51 ` Ian Campbell
2015-03-12 1:46 ` Xu, Quan
2015-03-12 9:42 ` Ian Campbell
2015-03-12 15:44 ` Xu, Quan
2015-03-13 13:30 ` Olaf Hering
2015-03-13 15:39 ` Xu, Quan
2015-01-28 15:24 ` Ian Campbell
2015-01-29 7:34 ` Xu, Quan
2015-01-29 8:27 ` Olaf Hering
2015-01-29 9:22 ` Xu, Quan
2015-01-29 9:36 ` Olaf Hering
2015-01-29 10:27 ` Olaf Hering
2015-01-29 10:46 ` Ian Campbell
2015-01-30 8:09 ` Olaf Hering
2015-01-30 10:39 ` Ian Campbell
2015-01-30 11:03 ` Jan Beulich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=54DCE58D.5040102@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=dgdegra@tycho.nsa.gov \
--cc=olaf@aepfle.de \
--cc=quan.xu@intel.com \
--cc=xen-devel@lists.xen.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.