|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Minios-devel] [UNIKRAFT PATCHv5 45/46] plat/kvm: Implement time_block_until for arm64
Hi Simon,
> -----Original Message-----
> From: Simon Kuenzer <simon.kuenzer@xxxxxxxxx>
> Sent: 2018年9月6日 22:47
> To: Wei Chen (Arm Technology China) <Wei.Chen@xxxxxxx>; minios-
> devel@xxxxxxxxxxxxxxxxxxxx
> Cc: Kaly Xin (Arm Technology China) <Kaly.Xin@xxxxxxx>; nd <nd@xxxxxxx>
> Subject: Re: [Minios-devel] [UNIKRAFT PATCHv5 45/46] plat/kvm: Implement
> time_block_until for arm64
>
>
>
> On 10.08.2018 09:08, Wei Chen wrote:
> > From: Wei Chen <Wei.Chen@xxxxxxx>
> >
> > As we haven't implement full functions for timer for arm64.
> > But this function is needed by Unikraft. So we impplement
> > a temporary function to make compiler happy.
> >
> > Signed-off-by: Wei Chen <Wei.Chen@xxxxxxx>
> > ---
> > plat/common/arm/time.c | 11 +++++++++++
> > 1 file changed, 11 insertions(+)
> >
> > diff --git a/plat/common/arm/time.c b/plat/common/arm/time.c
> > index 1829938..7deb745 100644
> > --- a/plat/common/arm/time.c
> > +++ b/plat/common/arm/time.c
> > @@ -33,6 +33,7 @@
> > */
> > #include <uk/assert.h>
> > #include <uk/plat/time.h>
> > +#include <uk/arch/atomic.h>
> > #include <cpu.h>
> >
> > static uint64_t boot_ticks;
> > @@ -136,6 +137,16 @@ static int generic_timer_init(void)
> > return 0;
> > }
> >
> > +long sched_have_pending_events;
> > +
> > +void time_block_until(__snsec until)
> > +{
> > + while ((__snsec) ukplat_monotonic_clock() < until) {
> > + if (ukarch_test_and_clr_bit(0, &sched_have_pending_events))
> > + break;
> > + }
>
> Ouhh, busy polling. This is fine to do for now, a comment would be nice.
Ok, I will add a comment for it in next version.
>
> > +}
> > +
> > struct ukplat_time_ops arch_timer_ops = {
> > .init = generic_timer_init,
> > .monotonic = generic_timer_monotonic,
> >
_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |