public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ren Qiaowei <qiaowei.ren@intel.com>
To: Joe Perches <joe@perches.com>
Cc: Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>,
	x86@kernel.org, linux-kernel@vger.kernel.org,
	Gang Wei <gang.wei@intel.com>
Subject: Re: [PATCH] x86, tboot: provide debugfs interfaces to access TXT log
Date: Mon, 24 Jun 2013 10:56:00 +0800	[thread overview]
Message-ID: <51C7B540.9020507@intel.com> (raw)
In-Reply-To: <1371976573.3137.20.camel@joe-AO722>

On 06/23/2013 04:36 PM, Joe Perches wrote:
> On Sun, 2013-06-23 at 15:54 +0800, Qiaowei Ren wrote:
>> These logs come from tboot (Trusted Boot, an open source,
>> pre-kernel/VMM module that uses Intel TXT to perform a
>> measured and verified launch of an OS kernel/VMM.).
> []
>> diff --git a/arch/x86/kernel/tboot.c b/arch/x86/kernel/tboot.c
> []
>> +static struct tboot_log *get_log(void)
>> +{
>> +	struct tboot_log *log;
>> +
>> +	log = (struct tboot_log *)ioremap_nocache(TBOOT_SERIAL_LOG_ADDR,
>> +						  TBOOT_SERIAL_LOG_SIZE);
>
> You might want to fix the sparse errors.
>    CHECK   arch/x86/kernel/tboot.c
> arch/x86/kernel/tboot.c:362:16: warning: cast removes address space of expression
> arch/x86/kernel/tboot.c:368:25: warning: incorrect type in argument 1 (different address spaces)
> arch/x86/kernel/tboot.c:368:25:    expected void volatile [noderef] <asn:2>*addr
> arch/x86/kernel/tboot.c:368:25:    got struct tboot_log *[assigned] log
> arch/x86/kernel/tboot.c:395:17: warning: incorrect type in argument 1 (different address spaces)
> arch/x86/kernel/tboot.c:395:17:    expected void volatile [noderef] <asn:2>*addr
> arch/x86/kernel/tboot.c:395:17:    got struct tboot_log *[assigned] log
> arch/x86/kernel/tboot.c:479:16: warning: incorrect type in assignment (different address spaces)
> arch/x86/kernel/tboot.c:479:16:    expected void *config
> arch/x86/kernel/tboot.c:479:16:    got void [noderef] <asn:2>*
> arch/x86/kernel/tboot.c:485:19: warning: incorrect type in assignment (different address spaces)
> arch/x86/kernel/tboot.c:485:19:    expected void *heap_base
> arch/x86/kernel/tboot.c:485:19:    got void [noderef] <asn:2>*
> arch/x86/kernel/tboot.c:487:17: warning: incorrect type in argument 1 (different address spaces)
> arch/x86/kernel/tboot.c:487:17:    expected void volatile [noderef] <asn:2>*addr
> arch/x86/kernel/tboot.c:487:17:    got void *config
>
>
Well, I guess that I can use iomem related interface to fix these 
warnings caused by sparse.

Thanks,
Qiaowei

  reply	other threads:[~2013-06-24  3:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-23  7:54 [PATCH] x86, tboot: provide debugfs interfaces to access TXT log Qiaowei Ren
2013-06-23  8:36 ` Joe Perches
2013-06-24  2:56   ` Ren Qiaowei [this message]
2013-06-24  4:33     ` H. Peter Anvin

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=51C7B540.9020507@intel.com \
    --to=qiaowei.ren@intel.com \
    --cc=gang.wei@intel.com \
    --cc=hpa@zytor.com \
    --cc=joe@perches.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox