On 17/07/18 09:35, Jan Beulich wrote:
> @@ -411,7 +410,13 @@ static int hpet_write(
>      case HPET_Tn_CFG(2):
>          tn = HPET_TN(CFG, addr);
>  
> -        h->hpet.timers[tn].config = hpet_fixup_reg(new_val, old_val, 0x3f4e);
> +        h->hpet.timers[tn].config = hpet_fixup_reg(new_val, old_val,
> +                                                   HPET_TN_LEVEL |
> +                                                   HPET_TN_ENABLE |
> +                                                   HPET_TN_PERIODIC |
> +                                                   HPET_TN_SETVAL |
> +                                                   HPET_TN_32BIT |
> +                                                   HPET_TN_ROUTE);

This can be rather better reflowed.  e.g.

diff --git a/xen/arch/x86/hvm/hpet.c b/xen/arch/x86/hvm/hpet.c
index f7ef4f7..5986d1d 100644
--- a/xen/arch/x86/hvm/hpet.c
+++ b/xen/arch/x86/hvm/hpet.c
@@ -411,7 +411,10 @@ static int hpet_write(
     case HPET_Tn_CFG(2):
         tn = HPET_TN(CFG, addr);
 
-        h->hpet.timers[tn].config = hpet_fixup_reg(new_val, old_val, 0x3f4e);
+        h->hpet.timers[tn].config = hpet_fixup_reg(
+            new_val, old_val, (HPET_TN_LEVEL | HPET_TN_ENABLE |
+                               HPET_TN_PERIODIC | HPET_TN_SETVAL |
+                               HPET_TN_32BIT | HPET_TN_ROUTE));
 
         timer_sanitize_int_route(h, tn);
 

Otherwise, Reviewed-by: Andrew Cooper <[email protected]>

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to