On 1/26/22 04:20, nobuta.keiya@xxxxxxxxxxx wrote: >> I have not seen any activity on that in a long time. IIRC, Julien quit RedHat. >> I don't know if anyone else has taken over this work in RedHat. >> >> Sorry, I don't have any more information. >> >> Madhavan > > Thanks for your information. > > By the way, I'm considering test code for arch_stack_walk_reliable(). > Specifically, I apply Suraj's patch to enable livepatch, and added a function > that sleeps between SYM_CODE_START and SYM_CODE_END, then livepatch > checks if the task has an unreliable stack. > For now my internal test code working correctly, but my Kconfig excludes > STACK_VALIDATION dependency. > > It seems that objtool will not be enabled yet, so I would like to test it easier. > If you are already testing with this patch, could you tell me how to do it? > > For now, I have an instrumented kernel that directly invokes arch_stack_walk_reliable() from various places in the kernel (interrupt handlers, exception handlers, ftrace entry, kprobe handler, etc). I also have a test driver to induce conditions like null pointer dereference. I use this to test different cases where arch_stack_walk_reliable() should return an error. As for livepatch testing, I have enhanced objtool and the kernel so the frame pointer can be validated dynamically rather than statically. I have tested various different livepatch selftests successfully. I have also written my own livepatch tests to add to the selftests. I am currently working on preparing an RFC patch series for review. Basically, this series implements STACK_VALIDATION in a different way. I plan to publish my work soon (hopefully Feb 2022). I was going to do in December. However, my workload in Microsoft did not permit me to do that. I am also planning to set up a github repo so people can try out my changes, if they are interested. So, stay tuned. Madhavan