Incorrect AIA mtopi handling without an IMSIC
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 45/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Estancado
- Stack tecnológico
- c
- Área
- operating-systems
Línea de trabajo
Comienza reproduciendo el fallo en la rama local de RVVM con la compatibilidad con AIA habilitada, IMSIC y APLIC/PLIC desactivados, y usando la IPI de CLINT heredada. Rastrea cómo OpenSBI maneja la interrupción local no gestionada y la distinción de los CSR mtopi/stopi frente a mtopei/stopei; se considera terminado cuando esta configuración ya no se bloquea y sigue siendo coherente con la especificación RISC-V AIA.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
The RISC-V AIA specification introduces a couple of new CSRs, and mandates that mtopei & stopei CSRs are ONLY present whenever there is AIA implemented, and an RISC-V IMSIC present in the system, but other CSRs may exist even without an IMSIC:
OpenSBI apparently assumes that IMSIC must be present whenever mtopi CSR is available instead of mtopei... and crashes whenever the guest uses legacy CLINT for IPI.
[ 0.103777] smp: Bringing up secondary CPUs ...
sbi_trap_error: hart0: trap0: unhandled local interrupt (error -1006)
sbi_trap_error: hart0: trap0: mcause=0x8000000000000003 mtval=0x0000000000000000
sbi_trap_error: hart0: trap0: mepc=0xffffffff80b4d2f8 mstatus=0x0000000a00000920
sbi_trap_error: hart0: trap0: ra=0xffffffff80b4d2ec sp=0xffffffc600003de0
sbi_trap_error: hart0: trap0: gp=0xffffffff82321198 tp=0xffffffff82325cc0
sbi_trap_error: hart0: trap0: s0=0xffffffc600003e10 s1=0xffffffff8235d3c8
sbi_trap_error: hart0: trap0: a0=0x000000000210f673 a1=0xffffffffffffffff
sbi_trap_error: hart0: trap0: a2=0x0000000000000015 a3=0x0000000000f5b338
sbi_trap_error: hart0: trap0: a4=0x0000000000000004 a5=0x000000000c800000
sbi_trap_error: hart0: trap0: a6=0x000000000200eeed a7=0xffffffff82786b60
sbi_trap_error: hart0: trap0: s2=0x0000000000000004 s3=0xffffffff8235d3c8
sbi_trap_error: hart0: trap0: s4=0x0000000000000000 s5=0x0000000000000000
sbi_trap_error: hart0: trap0: s6=0xffffffd602d50500 s7=0xffffffff80e00128
sbi_trap_error: hart0: trap0: s8=0x0000000000000000 s9=0x0000000000000001
sbi_trap_error: hart0: trap0: s10=0x0000000000000000 s11=0x0000000000000000
sbi_trap_error: hart0: trap0: t0=0x0000000000000040 t1=0x0000000000000000
sbi_trap_error: hart0: trap0: t2=0xffffffffffffffff t3=0x0000000000000002
sbi_trap_error: hart0: trap0: t4=0x0000000000000402 t5=0xffffffd602d53a68
sbi_trap_error: hart0: trap0: t6=0xffffffd602d53a70
This happens on a local RVVM branch that introduces RISC-V AIA support, and IMSIC+APLIC/PLIC supposed to be toggled, but AIA support in the CPU remains (That is, mtopi and stopi are still available, but mtopei / stopei are not).
Judging by the spec, it should be legal, but OpenSBI crashes unless I workaround it (By making mtopi unavailable too), so I think it is worth reporting.
- Lenguaje dominante
- C
- Estrellas
- 1.6k
- Forks
- 734
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de riscv-software-src/opensbi
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
riscv-software-src/opensbi#425 ·
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
riscv-software-src/opensbi#424 · 1 comentario ·
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
riscv-software-src/opensbi#439 ·
-
sbi_trap_redirect() does not clear SPELP when the interrupted context had no landing pad expectedAbierto
Dificultad 3/5 1-2 días Aptitud para principiantes 67/100
riscv-software-src/opensbi#438 ·
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 35/100
riscv-software-src/opensbi#436 · 3 comentarios ·
Todos los issues de riscv-software-src/opensbi
Issues similares
-
area/docdb kind/failing-test priority/medium status/awaiting-triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
yugabyte/yugabyte-db#39462 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
libreswan/libreswan#3185 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
Los mantenedores suelen responder en 3 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
-
[SDL3pp] update to 0.12.0Abiertocategory:port-update
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 2 días