From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter Keilty Date: Fri, 27 Apr 2007 14:38:05 +0000 Subject: Re: [PATCH 1/3] ia64: convert to use clocksource code Message-Id: <46320ACD.6090704@hp.com> List-Id: References: <20070426202632.23343.54944.sendpatchset@rambler.zko.hp.com> <1177621673.12796.121.camel@imap.mvista.com> In-Reply-To: <1177621673.12796.121.camel@imap.mvista.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Daniel Walker Cc: linux-ia64@vger.kernel.org, John Stultz , Eric Whitney , linux-kernel@vger.kernel.org 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 > > >