Re: [Bug 192571] zswap + zram enabled BUG

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

 



On Wed, Jan 18, 2017 at 8:17 AM, Michal Hocko <mhocko@xxxxxxxxxx> wrote:
> On Wed 18-01-17 10:39:48, Sergey Senozhatsky wrote:
>> Cc Dan
>>
>> On (01/17/17 12:22), Andrew Morton wrote:
>> > > https://bugzilla.kernel.org/show_bug.cgi?id=192571
>> > >
>> > > --- Comment #1 from Gluzskiy Alexandr <sss123next@xxxxxxx> ---
>> > > [199961.576604] ------------[ cut here ]------------
>> > > [199961.577830] kernel BUG at mm/zswap.c:1108!
>>
>> zswap didn't manage to decompress the page:
>>
>> static int zswap_frontswap_load(unsigned type, pgoff_t offset,
>>                               struct page *page)
>> {
>> ...
>>       dst = kmap_atomic(page);
>>       tfm = *get_cpu_ptr(entry->pool->tfm);
>>       ret = crypto_comp_decompress(tfm, src, entry->length, dst, &dlen);
>>       put_cpu_ptr(entry->pool->tfm);
>>       kunmap_atomic(dst);
>>       zpool_unmap_handle(entry->pool->zpool, entry->handle);
>>       BUG_ON(ret);
>>       ^^^^^^^^^^^
>
> Ugh, why do we even do that? This is not the way how to handle error
> situations. AFAIU propagating the error out wouldn't be a big deal
> because we would just fallback to regular swap, right?

yeah this function definitely should never bug; it's just a callback
from the zpool to try to write a page back to the swapcache so the
zpool can free a page.  It's definitely ok for it to return an error.

> --
> Michal Hocko
> SUSE Labs
>
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>
>

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@xxxxxxxxx.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@xxxxxxxxx";> email@xxxxxxxxx </a>



[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]