hw/timer/hpet: Fix comment about capabilities register
authorZhao Liu <zhao1.liu@intel.com>
Tue, 26 Nov 2024 16:30:45 +0000 (00:30 +0800)
committerMichael Tokarev <mjt@tls.msk.ru>
Sat, 28 Dec 2024 11:42:52 +0000 (14:42 +0300)
HPETState.capability stores the emulated value for "general capabilities
and id register" instead of "main counter register".

Fix the comment to accurately reflect this.

Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Reviewed-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
hw/timer/hpet.c

index 2a45410c0da2cd85621a598a1b1a7dac4170cdc0..1c8c6c69ef5db563f6eef72862b98c0dfe467e42 100644 (file)
@@ -736,7 +736,7 @@ static void hpet_realize(DeviceState *dev, Error **errp)
         timer->state = s;
     }
 
-    /* 64-bit main counter; LegacyReplacementRoute. */
+    /* 64-bit General Capabilities and ID Register; LegacyReplacementRoute. */
     s->capability = 0x8086a001ULL;
     s->capability |= (s->num_timers - 1) << HPET_ID_NUM_TIM_SHIFT;
     s->capability |= ((uint64_t)(HPET_CLK_PERIOD * FS_PER_NS) << 32);