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

Unbitrot vmm LionsOS example #109

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

Unbitrot vmm LionsOS example #109

wants to merge 5 commits into from

Conversation

wom-bat
Copy link
Contributor

@wom-bat wom-bat commented Aug 30, 2024

-- Ported the console serial system to current sDDF -- Updated system files for current microkit
-- Updated README.md to match system
-- Allow local user replacement of linux and initrd to match local
(passed-through) filesystem

@wom-bat
Copy link
Contributor Author

wom-bat commented Aug 30, 2024

Note this requires a minor sddf change to get the libsddf_util_debug.a dependency tracked for serial/virt.elf and uart_driver.elf

@Ivan-Velickovic
Copy link
Collaborator

Two more things that come to mind:

  • have the example variants be built in CI, right now it's just the default one.
  • move the README to lionsos.org, I think it makes more sense to have all tutorial/example information there.

@wom-bat
Copy link
Contributor Author

wom-bat commented Aug 30, 2024

Two more things that come to mind:

* have the example variants be built in CI, right now it's just the default one.

* move the README to lionsos.org, I think it makes more sense to have all tutorial/example information there.

Sure. I'd keep the README here too though, for quick reference.

@Ivan-Velickovic
Copy link
Collaborator

They will quickly diverge though, I'd rather not duplicate it.

@wom-bat
Copy link
Contributor Author

wom-bat commented Aug 30, 2024

So the two Linux runs worked, but the MacOSX one did not.
Does MacOSX use GnuMAKE or BSD Make?

@Ivan-Velickovic
Copy link
Collaborator

They'll use GNU Make I believe.

This is the error message on macOS:

2024-08-30T05:21:23.7707830Z ld.lld -L/Users/ertos/ts-actions-runner/_work/lionsos/lionsos/microkit-sdk-1.4.1/board/odroidc4/debug/lib serial/meson/uart_driver.o -lmicrokit -Tmicrokit.ld -o uart_driver.elf
2024-08-30T05:21:23.7856290Z ld.lld: error: undefined symbol: sddf_printf_
2024-08-30T05:21:23.7856980Z >>> referenced by uart.c:229 (/Users/ertos/ts-actions-runner/_work/lionsos/lionsos/dep/sddf/drivers/serial/meson/uart.c:229)
2024-08-30T05:21:23.7857550Z >>>               serial/meson/uart_driver.o:(notified)
2024-08-30T05:21:23.7858160Z >>> referenced by uart.c:150 (/Users/ertos/ts-actions-runner/_work/lionsos/lionsos/dep/sddf/drivers/serial/meson/uart.c:150)
2024-08-30T05:21:23.7858720Z >>>               serial/meson/uart_driver.o:(handle_irq)
2024-08-30T05:21:23.7858920Z 
2024-08-30T05:21:23.7859020Z ld.lld: error: undefined symbol: _assert_fail
2024-08-30T05:21:23.7859610Z >>> referenced by uart.c:36 (/Users/ertos/ts-actions-runner/_work/lionsos/lionsos/dep/sddf/drivers/serial/meson/uart.c:36)
2024-08-30T05:21:23.7860120Z >>>               serial/meson/uart_driver.o:(set_baud)
2024-08-30T05:21:23.7860690Z >>> referenced by uart.c:62 (/Users/ertos/ts-actions-runner/_work/lionsos/lionsos/dep/sddf/drivers/serial/meson/uart.c:62)
2024-08-30T05:21:23.7861200Z >>>               serial/meson/uart_driver.o:(set_baud)
2024-08-30T05:21:23.7861870Z make[1]: *** [/Users/ertos/ts-actions-runner/_work/lionsos/lionsos/dep/sddf/drivers/serial/meson/uart_driver.mk:17: uart_driver.elf] Error 1
2024-08-30T05:21:23.7862940Z make[1]: Leaving directory '/Users/ertos/ts-actions-runner/_work/lionsos/lionsos/ci_build/vmm-virtio'
2024-08-30T05:21:23.7863680Z make: *** [Makefile:38: /Users/ertos/ts-actions-runner/_work/lionsos/lionsos/ci_build/vmm-virtio/vmdev.img] Error 2
2024-08-30T05:21:23.7880940Z ##[error]Process completed with exit code 2.

@Ivan-Velickovic
Copy link
Collaborator

Looks like the invocation of ld.lld is missing libsddf_util_debug.a.

@wom-bat
Copy link
Contributor Author

wom-bat commented Aug 30, 2024

Looks like the invocation of ld.lld is missing libsddf_util_debug.a.

It;s invoked in uart_driver.mk as

uart_driver.elf: serial/meson/uart_driver.o libsddf_util_debug.a
	$(LD) $(LDFLAGS) $^ $(LIBS) -o $@

GNUMake uses $^ to mean all dependencies; So I don't know what;s happening unless hte MacOSX version picked up an earlier sddf without this change.

-- Ported the console serial system to current sDDF
-- Updated system files for current microkit
-- Updated README.md to match system
-- Allow local user replacement of linux and initrd to match local
   (passed-through) filesystem

Signed-off-by: Peter Chubb <[email protected]>
The linux and initrd image for the VMM example are inserted from the
user's system, and should not be saved in git.

Signed-off-by: Peter Chubb <[email protected]>
The VMM example changes need the update uart_driver.mk and serial
components make snippets.

Signed-Off-By: Peter Chubb <[email protected]>
Comment on lines +5 to +6
examples/vmm/vmm/initrd.img
examples/vmm/vmm/linux
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This shouldn't be necessary.

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

Successfully merging this pull request may close these issues.

2 participants