Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make no-kvm failing with "FATAL ERROR:system clock is inaccessible" #58

Closed
wjhun opened this issue Sep 4, 2018 · 6 comments
Closed

Comments

@wjhun
Copy link
Contributor

wjhun commented Sep 4, 2018

On a fresh master tree:

$ qemu-system-x86_64 -version
QEMU emulator version 2.8.1(Debian 1:2.8+dfsg-6+deb9u4)
Copyright (c) 2003-2016 Fabrice Bellard and the QEMU Project developers
$ make run-nokvm
make -f image.mk image
make[1]: warning: jobserver unavailable: using -j1. Add '+' to parent make rule.
make[1]: Entering directory '/share/src/uniboot-test2'
cd boot ; make
make[2]: Entering directory '/share/src/uniboot-test2/boot'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/share/src/uniboot-test2/boot'
cd mkfs ; make
make[2]: Entering directory '/share/src/uniboot-test2/mkfs'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/share/src/uniboot-test2/mkfs'
cd stage3 ; make
make[2]: Entering directory '/share/src/uniboot-test2/stage3'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/share/src/uniboot-test2/stage3'
cd examples ; make
make[2]: Entering directory '/share/src/uniboot-test2/examples'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/share/src/uniboot-test2/examples'
make[1]: Leaving directory '/share/src/uniboot-test2'
cp image image2
qemu-system-x86_64 -boot c -drive file=image,format=raw,if=ide -nographic -m 2G -device isa-debug-exit -drive file=image2,format=raw,if=virtio
create fs
kernel complete
pages heap: 0000000000225000, length 00000000002f8000
physical memory:
base 0000000000800000, length 000000007f600000
FATAL ERROR:system clock is inaccessible
Makefile:46: recipe for target 'run-nokvm' failed
make: [run-nokvm] Error 1 (ignored)

@convolvatron
Copy link
Contributor

i'm afraid this was intensional. without kvm we have no translation between rdtsc and
actual seconds. andrii did the first part of #24 which was to try to determine if
kvm was providing the right scaling factor for us.

the second part was to use a different time source so that we could function without hpet, which he's looking at

oddly, running without kvm seems to work. any tcp timers must be totally out of whack. i guess if there are no losses...

@wjhun
Copy link
Contributor Author

wjhun commented Sep 4, 2018

Oh, I see. But for me it's not working without kvm.

Maybe this should stay in a topic branch until it works enough to not break for the common case? Not that I can't start using kvm, but running without it shouldn't be broken in master.

@talshadow
Copy link
Contributor

@wjhun
I can suggest mark as comment this line for your test.
/uniboot/x86_64/clock.c:59

@convolvatron
Copy link
Contributor

sorry, I was totally unclear. kvm provides the clock scaling factors, so running with lvm is safe.

andrii committed a change in response to #24 which halts if the scaling factor isn't set.

without the scaling factor the clock/timers make no sense, so this seemed reasonable.

could just set the halt back to a console

in order to get a decent clock in non-kvm, we need to write a driver.

@talshadow
Copy link
Contributor

I think this issue we can close?

@wjhun
Copy link
Contributor Author

wjhun commented Sep 4, 2018

Yes, thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants