Hi:
        background:
I run virtio_net and virt_con in the lastest version, it is run OK, but I try 
to add another virito blk, I meet run error below:

"Unhandled offset of 0x400 of size 4, reading
Assertion failed: !"panic" 
(/home/yadong.li/seL4_vm_11/sel4_horizon/camkes-arm-vm/projects/seL4_projects_libs/libsel4vmmplatsupport/src/drivers/virtio_emul.c:
 emul_io_in: 71)"

I add print on my enviornmen, found:
********************start[0x1000], end[0x1400] /*net*/
********************start[0x1400], end[0x1800] /*con*/
********************start[0x1800], end[0x1c00] /*blk*/
---------------------------virtio_con_io_in, con = 0x55f3238, offset = 
0x400[0x1800:0x1400]
           port_no:1800 should belong "blk", but it recongnize as belong 
"con"(con may be not use the offset 0 feature), the boundary may be have some 
problem
the function:
static int alloc_free_io_port_range(vmm_io_port_list_t *io_list, ioport_range_t 
*io_range)
{
    uint16_t free_port_addr = io_list->alloc_addr;
    if (free_port_addr + io_range->size < free_port_addr) {
        /* Possible overflow */
        return -1;
    }
    io_list->alloc_addr += io_range->size;
    io_range->start = free_port_addr;
    io_range->end = free_port_addr + io_range->size;
    return 0;
}
I think "io_range->end = free_port_addr + io_range->size;" should change to 
"io_range->end = free_port_addr + io_range->size - 1;" ?
                                                                                
    Thank you very much!




_______________________________________________
Devel mailing list
Devel@sel4.systems
https://sel4.systems/lists/listinfo/devel

Reply via email to