bao-project / bao-demos

A guide on how to build and use a set of Bao guest configurations for various platforms
Other
33 stars 37 forks source link

feat(ipc_interrupt): enable ipc delivery via interrupt in Linux #36

Open clachan opened 1 year ago

clachan commented 1 year ago

On success, a message like below will appear in dmesg:

[ 12.881296] ipc message: freertos has received 1 uart interrupts!

Tested:

josecm commented 1 year ago

Thanks @clachan, this is great!

But first check my comment on your bao-project/bao-hypervisor#76 PR, as this seems to depend on it. Also I'd like to try this on qemu-riscv64. I think this Linux patch is pretty architecture independent no? So I'll try to add the hypercall on your bao-project/freertos-over-bao#6 PR, test it, and come back to this PR after the two other PRs are closed.

josecm commented 1 year ago

I've tested this on qemu-aarch64. As I told you in the "interrupts offset" PR, I had to fix the baoipc interrupt ID in the dts to 20. The original value is wrong. As we weren't using the interrupt in the linux side, we didn't caught it. So this PR will have to take that into account!

josecm commented 1 year ago

I've added the support for riscv in bao-project/freertos-over-bao#6, and seems to be working nice on qemu-riscv64!

clachan commented 1 year ago

I've reverted the interrupt_offset and corrected the dts files. Please review it again.

clachan commented 1 year ago

Hi @josecm,

There are a couple of linux.dts files, do you want me to modify the irq number in them all? I don't have other hardware boards to test, but I believe all should be corrected.

josecm commented 1 year ago

There are a couple of linux.dts files, do you want me to modify the irq number in them all? I don't have other hardware boards to test, but I believe all should be corrected.

Yes, please do. This should be fixed for all armv8 platforms..

clachan commented 1 year ago

There are a couple of linux.dts files, do you want me to modify the irq number in them all? I don't have other hardware boards to test, but I believe all should be corrected.

Yes, please do. This should be fixed for all armv8 platforms..

Fixed in all Linux guests for ARM. Please review.

josecm commented 1 year ago

@clachan looks good, but I still need to test this for the aarch32 platforms (i.e. fvp). I'll try to find some time this week to push this through.

clachan commented 10 months ago

Hi @josecm, do you have update on this? Please let me know if anything I can help.

josecm commented 10 months ago

hey @clachan sorry for let this PR hanging. But I want to take time, I would need to test most platforms, to make sure your modifications are operational in all of them! Any other platform you are able to test it with would be great help. I'll ask people on our team to do it also.

clachan commented 10 months ago

@josecm, no worries. I am asking because I have developed a UIO-based interrupt mechanism based on the previous driver I want to share with the community. Thanks.