The branch main has been updated by kp:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=f74397658390237200cc19cae133ea1073e7bf6d

commit f74397658390237200cc19cae133ea1073e7bf6d
Author:     Kristof Provost <[email protected]>
AuthorDate: 2021-01-11 20:23:22 +0000
Commit:     Kristof Provost <[email protected]>
CommitDate: 2021-01-12 09:33:16 +0000

    dtrace: Blacklist riscv exception handlers for fbt
    
    We can't safely instrument those exception handlers, so blacklist them.
    
    Test case: dtrace -n :::
    
    Reviewed by:            markj (previous version)
    Differential Revision:  https://reviews.freebsd.org/D27754
---
 sys/cddl/dev/fbt/riscv/fbt_isa.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/sys/cddl/dev/fbt/riscv/fbt_isa.c b/sys/cddl/dev/fbt/riscv/fbt_isa.c
index 406fcd3f9bea..659a9d44c81c 100644
--- a/sys/cddl/dev/fbt/riscv/fbt_isa.c
+++ b/sys/cddl/dev/fbt/riscv/fbt_isa.c
@@ -156,6 +156,19 @@ fbt_provide_module_function(linker_file_t lf, int symindx,
        if (fbt_excluded(name))
                return (0);
 
+       /*
+        * Some assembly-language exception handlers are not suitable for
+        * instrumentation.
+        */
+       if (strcmp(name, "cpu_exception_handler") == 0)
+               return (0);
+       if (strcmp(name, "cpu_exception_handler_user") == 0)
+               return (0);
+       if (strcmp(name, "cpu_exception_handler_supervisor") == 0)
+               return (0);
+       if (strcmp(name, "do_trap_supervisor") == 0)
+               return (0);
+
        instr = (uint32_t *)(symval->value);
        limit = (uint32_t *)(symval->value + symval->size);
 
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/dev-commits-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to