ia64/xen-unstable

changeset 17586:cc953475ab14

x86 hvm: Warn only once per time source when the periodic tiemout is
set 'too small'.
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
author Keir Fraser <keir.fraser@citrix.com>
date Tue May 06 16:20:54 2008 +0100 (2008-05-06)
parents a95c2e36d6fd
children 9d84c12de877
files xen/arch/x86/hvm/vpt.c xen/include/asm-x86/hvm/vpt.h
line diff
     1.1 --- a/xen/arch/x86/hvm/vpt.c	Tue May 06 16:20:24 2008 +0100
     1.2 +++ b/xen/arch/x86/hvm/vpt.c	Tue May 06 16:20:54 2008 +0100
     1.3 @@ -338,9 +338,9 @@ void create_periodic_time(
     1.4      /* Periodic timer must be at least 0.9ms. */
     1.5      if ( (period < 900000) && !one_shot )
     1.6      {
     1.7 -        gdprintk(XENLOG_WARNING,
     1.8 -                 "HVM_PlatformTime: program too small period %"PRIu64"\n",
     1.9 -                 period);
    1.10 +        if ( !test_and_set_bool(pt->warned_timeout_too_short) )
    1.11 +            gdprintk(XENLOG_WARNING, "HVM_PlatformTime: program too "
    1.12 +                     "small period %"PRIu64"\n", period);
    1.13          period = 900000;
    1.14      }
    1.15  
     2.1 --- a/xen/include/asm-x86/hvm/vpt.h	Tue May 06 16:20:24 2008 +0100
     2.2 +++ b/xen/include/asm-x86/hvm/vpt.h	Tue May 06 16:20:54 2008 +0100
     2.3 @@ -78,6 +78,7 @@ struct periodic_time {
     2.4      bool_t one_shot;
     2.5      bool_t do_not_freeze;
     2.6      bool_t irq_issued;
     2.7 +    bool_t warned_timeout_too_short;
     2.8  #define PTSRC_isa    1 /* ISA time source */
     2.9  #define PTSRC_lapic  2 /* LAPIC time source */
    2.10      u8 source;                  /* PTSRC_ */