The patch titled gru: check for valid vma has been removed from the -mm tree. Its filename was gru-check-for-valid-vma.patch This patch was dropped because it was merged into mainline or a subsystem tree The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: gru: check for valid vma From: Jack Steiner <steiner@xxxxxxx> Fix bug caused by failure to allocate a GRU gts structure. The old code failed to handle the case where the vma was invalid. Signed-off-by: Jack Steiner <steiner@xxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- drivers/misc/sgi-gru/grufault.c | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff -puN drivers/misc/sgi-gru/grufault.c~gru-check-for-valid-vma drivers/misc/sgi-gru/grufault.c --- a/drivers/misc/sgi-gru/grufault.c~gru-check-for-valid-vma +++ a/drivers/misc/sgi-gru/grufault.c @@ -90,19 +90,22 @@ static struct gru_thread_state *gru_allo { struct mm_struct *mm = current->mm; struct vm_area_struct *vma; - struct gru_thread_state *gts = NULL; + struct gru_thread_state *gts = ERR_PTR(-EINVAL); down_write(&mm->mmap_sem); vma = gru_find_vma(vaddr); - if (vma) - gts = gru_alloc_thread_state(vma, TSID(vaddr, vma)); - if (!IS_ERR(gts)) { - mutex_lock(>s->ts_ctxlock); - downgrade_write(&mm->mmap_sem); - } else { - up_write(&mm->mmap_sem); - } + if (!vma) + goto err; + gts = gru_alloc_thread_state(vma, TSID(vaddr, vma)); + if (IS_ERR(gts)) + goto err; + mutex_lock(>s->ts_ctxlock); + downgrade_write(&mm->mmap_sem); + return gts; + +err: + up_write(&mm->mmap_sem); return gts; } _ Patches currently in -mm which might be from steiner@xxxxxxx are origin.patch -- To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html