@@ -370,36 +370,6 @@ static inline bool init_task_stack_addr(const void *addr)
370370 sizeof (init_thread_union .stack ));
371371}
372372
373- /*
374- * This function is invoked with report_lock (a raw_spinlock) held. A
375- * PREEMPT_RT kernel cannot call find_vm_area() as it will acquire a sleeping
376- * rt_spinlock.
377- *
378- * For !RT kernel, the PROVE_RAW_LOCK_NESTING config option will print a
379- * lockdep warning for this raw_spinlock -> spinlock dependency. This config
380- * option is enabled by default to ensure better test coverage to expose this
381- * kind of RT kernel problem. This lockdep splat, however, can be suppressed
382- * by using DEFINE_WAIT_OVERRIDE_MAP() if it serves a useful purpose and the
383- * invalid PREEMPT_RT case has been taken care of.
384- */
385- static inline struct vm_struct * kasan_find_vm_area (void * addr )
386- {
387- static DEFINE_WAIT_OVERRIDE_MAP (vmalloc_map , LD_WAIT_SLEEP ) ;
388- struct vm_struct * va ;
389-
390- if (IS_ENABLED (CONFIG_PREEMPT_RT ))
391- return NULL ;
392-
393- /*
394- * Suppress lockdep warning and fetch vmalloc area of the
395- * offending address.
396- */
397- lock_map_acquire_try (& vmalloc_map );
398- va = find_vm_area (addr );
399- lock_map_release (& vmalloc_map );
400- return va ;
401- }
402-
403373static void print_address_description (void * addr , u8 tag ,
404374 struct kasan_report_info * info )
405375{
@@ -429,19 +399,8 @@ static void print_address_description(void *addr, u8 tag,
429399 }
430400
431401 if (is_vmalloc_addr (addr )) {
432- struct vm_struct * va = kasan_find_vm_area (addr );
433-
434- if (va ) {
435- pr_err ("The buggy address belongs to the virtual mapping at\n"
436- " [%px, %px) created by:\n"
437- " %pS\n" ,
438- va -> addr , va -> addr + va -> size , va -> caller );
439- pr_err ("\n" );
440-
441- page = vmalloc_to_page (addr );
442- } else {
443- pr_err ("The buggy address %px belongs to a vmalloc virtual mapping\n" , addr );
444- }
402+ pr_err ("The buggy address %px belongs to a vmalloc virtual mapping\n" , addr );
403+ page = vmalloc_to_page (addr );
445404 }
446405
447406 if (page ) {
0 commit comments