/* We use grey instead of black to ensure we can do future scans on the same objects. If we did not do future scans these black objects could potentially contain references to newly allocated objects in the future and we'd end up with false positives.  */
static void kmemleak_clear(void)
/* We use grey instead of black to ensure we can do future scans on the same objects. If we did not do future scans these black objects could potentially contain references to newly allocated objects in the future and we'd end up with false positives.  */
static void kmemleak_clear(void)
{
	struct kmemleak_object *object;
	unsigned long flags;
	rcu_read_lock();
	list_for_each_entry_rcu(object, &object_list, object_list) {
		spin_lock_irqsave(&object->lock, flags);
		if ((object->flags & OBJECT_REPORTED) &&
		    unreferenced_object(object))
			__paint_it(object, KMEMLEAK_GREY);
		spin_unlock_irqrestore(&object->lock, flags);
	}
	rcu_read_unlock();
}