All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Keilty <peter.keilty@hp.com>
To: Daniel Walker <dwalker@mvista.com>
Cc: linux-ia64@vger.kernel.org, John Stultz <johnstul@us.ibm.com>,
	Eric Whitney <eric.whitney@hp.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3] ia64: convert to use clocksource code
Date: Fri, 27 Apr 2007 14:38:05 +0000	[thread overview]
Message-ID: <46320ACD.6090704@hp.com> (raw)
In-Reply-To: <1177621673.12796.121.camel@imap.mvista.com>

Daniel Walker wrote:

>On Thu, 2007-04-26 at 16:26 -0400, Peter Keilty wrote:
>
>  
>
>>+        .mask           = (1LL << 40) - 1,
>>+        .mult           = 0, /*to be caluclated*/
>>+        .shift          = 16,
>>+        .is_continuous  = 1,
>> };
>>    
>>
>
>You should use CLOCKSOURCE_MASK() here ..
>
>  
>
It is correct in patch 3, I believe.

>  
>
>> 
>>diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h
>>index daa4940..a20b4d6 100644
>>--- a/include/linux/clocksource.h
>>+++ b/include/linux/clocksource.h
>>@@ -61,6 +61,9 @@ struct clocksource {
>> 	u32 shift;
>> 	unsigned long flags;
>> 	cycle_t (*vread)(void);
>>+#ifdef CONFIG_IA64
>>+	void *fsys_mmio_ptr;	/* used by fsyscall asm code */
>>+#endif
>>    
>>
>
>Could you explain in detail why this is needed?
>  
>
This ptr is needed to hold the mmio address to read the cycle value.
The fast ia64 path utilizies a special gate page which can allow user
code to execute small amount of kernel code, normal calling a function
not done and so the address is need. The fast syscall path executes on
user stack, between user/kernel state. And if the the fast path has to 
fallback
to the slow syscall code the vread will be needed and used.
Hope this helps.

>Daniel
>
>  
>

WARNING: multiple messages have this Message-ID (diff)
From: Peter Keilty <peter.keilty@hp.com>
To: Daniel Walker <dwalker@mvista.com>
Cc: linux-ia64@vger.kernel.org, John Stultz <johnstul@us.ibm.com>,
	Eric Whitney <eric.whitney@hp.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3] ia64: convert to use clocksource code
Date: Fri, 27 Apr 2007 10:38:05 -0400	[thread overview]
Message-ID: <46320ACD.6090704@hp.com> (raw)
In-Reply-To: <1177621673.12796.121.camel@imap.mvista.com>

Daniel Walker wrote:

>On Thu, 2007-04-26 at 16:26 -0400, Peter Keilty wrote:
>
>  
>
>>+        .mask           = (1LL << 40) - 1,
>>+        .mult           = 0, /*to be caluclated*/
>>+        .shift          = 16,
>>+        .is_continuous  = 1,
>> };
>>    
>>
>
>You should use CLOCKSOURCE_MASK() here ..
>
>  
>
It is correct in patch 3, I believe.

>  
>
>> 
>>diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h
>>index daa4940..a20b4d6 100644
>>--- a/include/linux/clocksource.h
>>+++ b/include/linux/clocksource.h
>>@@ -61,6 +61,9 @@ struct clocksource {
>> 	u32 shift;
>> 	unsigned long flags;
>> 	cycle_t (*vread)(void);
>>+#ifdef CONFIG_IA64
>>+	void *fsys_mmio_ptr;	/* used by fsyscall asm code */
>>+#endif
>>    
>>
>
>Could you explain in detail why this is needed?
>  
>
This ptr is needed to hold the mmio address to read the cycle value.
The fast ia64 path utilizies a special gate page which can allow user
code to execute small amount of kernel code, normal calling a function
not done and so the address is need. The fast syscall path executes on
user stack, between user/kernel state. And if the the fast path has to 
fallback
to the slow syscall code the vread will be needed and used.
Hope this helps.

>Daniel
>
>  
>

  reply	other threads:[~2007-04-27 14:38 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-04-26 20:26 [PATCH 1/3] ia64: convert to use clocksource code Peter Keilty
2007-04-26 20:26 ` Peter Keilty
2007-04-26 20:27 ` [PATCH 2/3] ia64: remove interpolater code Peter Keilty
2007-04-26 20:27   ` Peter Keilty
2007-04-26 20:52   ` john stultz
2007-04-26 20:52     ` john stultz
2007-04-26 21:47     ` David Miller
2007-04-26 21:47       ` David Miller
2007-04-26 20:27 ` [PATCH 3/3] ia64: update fsyscall for performance, enable build/run on 2.6.21-rc1 Peter Keilty
2007-04-26 20:27   ` Peter Keilty
2007-04-26 20:41 ` [PATCH 1/3] ia64: convert to use clocksource code Sam Ravnborg
2007-04-26 20:41   ` Sam Ravnborg
2007-04-26 20:48   ` john stultz
2007-04-26 20:48     ` john stultz
2007-04-26 21:07 ` Daniel Walker
2007-04-26 21:07   ` Daniel Walker
2007-04-27 14:38   ` Peter Keilty [this message]
2007-04-27 14:38     ` Peter Keilty
2007-04-27 15:35     ` Daniel Walker
2007-04-27 15:35       ` Daniel Walker
2007-04-27 15:42       ` Peter Keilty
2007-04-27 15:42         ` Peter Keilty
2007-04-27 15:48         ` Daniel Walker
2007-04-27 15:48           ` Daniel Walker
2007-04-27 16:11           ` Peter Keilty
2007-04-27 16:11             ` Peter Keilty
2007-04-27 16:32             ` Daniel Walker
2007-04-27 16:32               ` Daniel Walker
2007-05-02 17:58             ` john stultz
2007-05-02 17:58               ` john stultz
2007-05-02 19:08               ` Daniel Walker
2007-05-02 19:08                 ` Daniel Walker
2007-04-26 21:18 ` john stultz
2007-04-26 21:18   ` john stultz
2007-04-27 12:54   ` Peter Keilty
2007-04-27 12:54     ` Peter Keilty
2007-05-02 17:50     ` john stultz
2007-05-02 17:50       ` john stultz
2007-04-27  1:02 ` Chris Wright
2007-04-27  1:02   ` Chris Wright
2007-04-27 13:35   ` Peter Keilty
2007-04-27 13:35     ` Peter Keilty

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=46320ACD.6090704@hp.com \
    --to=peter.keilty@hp.com \
    --cc=dwalker@mvista.com \
    --cc=eric.whitney@hp.com \
    --cc=johnstul@us.ibm.com \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.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 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.