[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20170920062934.GD6298@jagdpanzerIV.localdomain>
Date: Wed, 20 Sep 2017 15:29:34 +0900
From: Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>
To: Minchan Kim <minchan@...nel.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
linux-kernel@...r.kernel.org, kernel-team <kernel-team@....com>,
Sergey Senozhatsky <sergey.senozhatsky@...il.com>
Subject: Re: [PATCH v2] zram: fix null dereference of handle
On (09/20/17 15:02), Minchan Kim wrote:
> For the testing, I found handle passed to zs_map_object in __zram_bvec_read
> is NULL so that kernel goes the Oops by pin_object.
>
> The reason is there is no routine to check the slot's freeing
> after getting the slot's lock. This patch fixes it.
>
> * From v1:
> * remove unlikely branch - Sergey
> * In !handle case, use 0 instead of zram_get_element - Sergey
>
> Fixes: 1f7319c74275 ("zram: partial IO refactoring")
> Cc: Sergey Senozhatsky <sergey.senozhatsky@...il.com>
> Signed-off-by: Minchan Kim <minchan@...nel.org>
Reviewed-by: Sergey Senozhatsky <sergey.senozhatsky.work@...il.com>
-ss
Powered by blists - more mailing lists