Re: [PATCH] drm/i915: Disable kmem_caches when KASAN is enabled

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Mar 15, 2017 at 01:14:50PM +0200, Mika Kuoppala wrote:
> Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> writes:
> 
> > On Wed, Mar 15, 2017 at 11:46:24AM +0200, Mika Kuoppala wrote:
> >> Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> writes:
> >> 
> >> > kasan is very good at detecting use-after-free. However, our requests
> >> > are allocated from a rcu-typesafe slab that is important for performance
> >> > but makes kasan less effective. When enabling kasan we are intentionally
> >> > looking for memory errors, disable the use of our caches to improve the
> >> > likelihood of kasan spotting a bug.
> >> >
> 
> I didn't notice anything except the typo in the desc. Until
> someone makes a kmem_cache kasan aware, this patch would
> be useful if and when someone does kasan runs with our driver.
> 
> The name could be DEBUG_KMEM_CACHE_DISABLE. It is more logical
> wrt to content of the patch. However perhaps the current name
> is more practical.

I was contemplating the possibility of sticking other tests under here
if kasan (or memdebug in general) has some more debugging aides.
 
> Reviewed-by: Mika Kuoppala <mika.kuoppala@xxxxxxxxx>

I'm sitting on the fence for this atm, until kasan is enabled in the CI
farm and then we can decide what is the best approach.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux