Received: by 10.192.165.148 with SMTP id m20csp3065235imm; Mon, 7 May 2018 06:07:47 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpfT20zn7LazqkR0/n22NQKZZp7IrdLJqlZhZt0ja8FA/isnL1jehuK2ZEx5q+KBY9abhSz X-Received: by 2002:a65:4a02:: with SMTP id s2-v6mr29905363pgq.265.1525698467221; Mon, 07 May 2018 06:07:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1525698467; cv=none; d=google.com; s=arc-20160816; b=sknf/dGXazsTyui0B3BE1m0SiSFqaEdi8cVP394gXFO7SPA9zp0pDRKtGPnUqDV7MY 8gCr+JLFhBBgVdJ+W2zTgn+JM4HF6o0czuoqu0XhD50QdEJ3DBjEUCNvOIhxfs0kHd6P SNQEY3JhWX/to1SlNA/aAhWeRdmoH78P/+aPr4iEUXyrisrSPlY+4D5Wc3YYGlv5GGNX HTyeMsS5Vk/+Jyp2IVzuP2BM++YPpS1YXSZ6A3tkqjA57oyBqyKTQpelPaG/eAioLZmA 0LhvSaV8N4EzafJQGaVh5ry5Ti7pEHR76P6xPr5LqccOYpZbnC4AFPZ6J6DVLPzIJHsm L2Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=UUNt3kaYOwO9qqUr/Yv18DF4//Te7HokOzf6Ss5GQfc=; b=U9F65gZ9PgMK2fLS9qSBdFVR9940wVrfF04zP28S7Wc/TkY2nL9RlhknchHvYwyYft FMllyjbqUvru4ZSfrPlOg++9oBD0oQAl0GStnbIg7n6bmCS6ANbB8RaIRDnXWDbzXpr9 JdWgNsd3tw/y9VviXxqyjOJJLtvxNCfHFxHC1B5noDUVcAT6whhfl/8t78xoq6rrFDhA fENxrBy5wR3J1VkZm9b5HsEjn0/eiTzXZluvXFN0Fs7cPoXw06WxbB9W3p1iXrpPK+7f G7Im1vviTYXPRqt0p9YGm1yFz0tkON+AiEwieQDIzaxxkH6LPNSQqjcqLpgxsK3CEZBU 3hhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lightnvm-io.20150623.gappssmtp.com header.s=20150623 header.b=izcchdoK; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b15-v6si17829397pgs.110.2018.05.07.06.07.32; Mon, 07 May 2018 06:07:47 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@lightnvm-io.20150623.gappssmtp.com header.s=20150623 header.b=izcchdoK; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752178AbeEGNFo (ORCPT + 99 others); Mon, 7 May 2018 09:05:44 -0400 Received: from mail-lf0-f66.google.com ([209.85.215.66]:45127 "EHLO mail-lf0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751951AbeEGNFl (ORCPT ); Mon, 7 May 2018 09:05:41 -0400 Received: by mail-lf0-f66.google.com with SMTP id y14-v6so40136086lfy.12 for ; Mon, 07 May 2018 06:05:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lightnvm-io.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=UUNt3kaYOwO9qqUr/Yv18DF4//Te7HokOzf6Ss5GQfc=; b=izcchdoKLxNLOWEDLPHouXOwosnkkLQ3CJrkCH2F0ePU9ZfqWc9H1e2gXnxdi31OaT gNaPpbtcIjFaHe2zw69vJdGkJQvNGBr37U+6iMMal9yu+NVO19bt1HdCx+v1S2xFC/KN GmXubAM1/PCj6KCULoWD9iQfzxD8gF4CilPsjiIyh9l7mvlsfcBHMV6AbBnTZJYoo/nr JtvGEL4zZPZzL2M7B0Rbqh7CGyh2gEMw9FOc7/Lhr7q4vSB/wg3OBwQ40BLzFWWm9MvP l/QxNsJu4eXLW6EEP0Xb5trxkW1lV8/Z7o3BZ5Whqe4aThaJGGKHrAf9AtYSyTYMDeIU 9y0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=UUNt3kaYOwO9qqUr/Yv18DF4//Te7HokOzf6Ss5GQfc=; b=Dwmby4Ap9BL1+WBDAIF2lXWQ2i15uuKuLr6uYmN1bN84BjvHOMjgbw67YfXrGKhied Zdl9qyPVgN4Oq+FoYgRz4gyfjSUlczk//nHK9yeQMh8+PeJpxcD/8U4F0Kny9LJ9gYQ0 BMIkdV/JcQrB9fk568fclRUkJKThD6YUD+c2ZX84SiJDFA8nhyLG/apye+1HLu8Bif91 T/M9Nk59A1zcOGhpT4Z7RKjyY+CHPI1nVFnsK/W+URvZ6kAiewgI9n3WN1+stsULFDh3 MemNqzG97mcEN+gfGRWCcNKu6cwWcjY6GTMiOqxSmfT2QKA9/FPivWyjq+o/9lctiyZC 8SOA== X-Gm-Message-State: ALQs6tC9Cw7W1ovMadWmnNPgZg3hril1xSpQoCbxM06IYhyqBWA2KQNi pXu7zKCu8UupA1DBWqmI5rhQQw== X-Received: by 2002:a2e:934f:: with SMTP id m15-v6mr10037530ljh.39.1525698340113; Mon, 07 May 2018 06:05:40 -0700 (PDT) Received: from [192.168.0.10] (95-166-82-66-cable.dk.customer.tdc.net. [95.166.82.66]) by smtp.googlemail.com with ESMTPSA id l6-v6sm4289789ljj.30.2018.05.07.06.05.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 May 2018 06:05:39 -0700 (PDT) Subject: Re: [PATCH v2 0/3] Rework write error handling in pblk To: Hans Holmberg Cc: linux-block@vger.kernel.org, Javier Gonzales , linux-kernel@vger.kernel.org, Hans Holmberg References: <1524548732-4326-1-git-send-email-hans.ml.holmberg@owltronix.com> From: =?UTF-8?Q?Matias_Bj=c3=b8rling?= Message-ID: Date: Mon, 7 May 2018 15:05:38 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: <1524548732-4326-1-git-send-email-hans.ml.holmberg@owltronix.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-GB Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/24/2018 07:45 AM, Hans Holmberg wrote: > From: Hans Holmberg > > This patch series fixes the(currently incomplete) write error handling > in pblk by: > > * queuing and re-submitting failed writes in the write buffer > * evacuating valid data data in lines with write failures, so the > chunk(s) with write failures can be reset to a known state by the fw > > Lines with failures in smeta are put back on the free list. > Failed chunks will be reset on the next use. > > If a write failes in emeta, the lba list is cached so the line can be > garbage collected without scanning the out-of-band area. > > Changes in V2: > - Added the recov_writes counter increase to the new path > - Moved lba list emeta reading during gc to a separate function > - Allocating the saved lba list with pblk_malloc instead of kmalloc > - Fixed formatting issues > - Removed dead code > > Hans Holmberg (3): > lightnvm: pblk: rework write error recovery path > lightnvm: pblk: garbage collect lines with failed writes > lightnvm: pblk: fix smeta write error path > > drivers/lightnvm/pblk-core.c | 52 +++++++- > drivers/lightnvm/pblk-gc.c | 102 +++++++++------ > drivers/lightnvm/pblk-init.c | 47 ++++--- > drivers/lightnvm/pblk-rb.c | 39 ------ > drivers/lightnvm/pblk-recovery.c | 91 ------------- > drivers/lightnvm/pblk-rl.c | 29 ++++- > drivers/lightnvm/pblk-sysfs.c | 15 ++- > drivers/lightnvm/pblk-write.c | 269 ++++++++++++++++++++++++++------------- > drivers/lightnvm/pblk.h | 36 ++++-- > 9 files changed, 384 insertions(+), 296 deletions(-) > Applied for 4.18.