Message ID | 20240514201429.34581-1-remi@remlab.net |
---|---|
State | New |
Headers | show |
Series | [FFmpeg-devel] lavu/riscv: fix parsing the unaligned read capability | expand |
Context | Check | Description |
---|---|---|
andriy/configure_x86 | warning | Failed to apply patch |
diff --git a/libavutil/riscv/cpu.c b/libavutil/riscv/cpu.c index 7b8aa7ac21..04ac404bbf 100644 --- a/libavutil/riscv/cpu.c +++ b/libavutil/riscv/cpu.c @@ -77,8 +77,12 @@ int ff_get_cpu_flags_riscv(void) if (pairs[1].value & RISCV_HWPROBE_EXT_ZVBB) ret |= AV_CPU_FLAG_RV_ZVBB; #endif - if (pairs[2].value & RISCV_HWPROBE_MISALIGNED_FAST) - ret |= AV_CPU_FLAG_RV_MISALIGNED; + switch (pairs[2].value & RISCV_HWPROBE_MISALIGNED_MASK) { + case RISCV_HWPROBE_MISALIGNED_FAST: + ret |= AV_CPU_FLAG_RV_MISALIGNED; + break; + default: + } } #elif HAVE_GETAUXVAL {