Received: by 2002:ac0:8845:0:0:0:0:0 with SMTP id g63csp1581259img; Wed, 27 Feb 2019 01:42:40 -0800 (PST) X-Google-Smtp-Source: AHgI3Ib4KPQG96y0/K5DtnPHmjJTh5ZWeRZ7PWuKnDp0A0cwdMSvmO2dkqhlb5PE4BdyQ8XB+9lk X-Received: by 2002:a17:902:6b03:: with SMTP id o3mr1231059plk.126.1551260560573; Wed, 27 Feb 2019 01:42:40 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551260560; cv=none; d=google.com; s=arc-20160816; b=ANgzAT8z4zbwrTC2VTZNZt4d3Ht2CfxzfrNhfQBJOWKFYVaThg6yvRFKdMBR85Om/K Obduq5L6s/8JWPd+Act1J4bvYE3Tfg+FJY7igFcuSQzE7HUE4sOZ04l7N2JY+F/e2/zV 09bNrh5e8QRnJvCR+OlIGTEY8QYDUPOlwQnMiVkUFqwjlUOfqm6Zgi6MWbMQ2DX2tUjU Lh8Ynif0H5Ls6hFq0sL89MgcUZClo3emO0/fIdrc3DXAEQMOmfLGAmsCrK6PQmPVEaI2 73fawSUeGCwwaj++sURLpBt2cuz9j//SoSQWu45EIoRI9lFY+CTiA0LGwclMt3dQohkA xEoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=Nt1fsem2OAistWQMNYOqX4SZ/P39kvVGl+EUEs6GRas=; b=vKRkYJfRGLtLR+oNxOCfsQqQ806kRL9LrpKfbZFUX1SAWc0yf4v33LVYRgJHRCBbML 6gAtAVDMYUki2EBkCzw1dYpzZcgdG3wHx7lIO2eSyLxc7bIqlUhWHnpY2UXOHZyLEwlP f0zx1JnM5O/B10F7zWyofGCQl7sWTVIaHliUARLbWuDpw9TAjm3Znxf51Cb5/EvyOlTP 2C4Gb4gsJRxXHNGeyv87iPnYkcUdnHX2Pu/DRjgGgJh+PIlu8Cju783VImg4eJz14EDh 7hqgJq65vSQINWeRC3pqHk5hMXBBM9VS308VAziEilw15csMYeHYQ1cSwEEj8uFftoNL LZ2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gvtRgHYb; 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 d12si14472127plo.143.2019.02.27.01.42.25; Wed, 27 Feb 2019 01:42:40 -0800 (PST) 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=@linaro.org header.s=google header.b=gvtRgHYb; 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 S1729812AbfB0Jka (ORCPT + 99 others); Wed, 27 Feb 2019 04:40:30 -0500 Received: from mail-ua1-f68.google.com ([209.85.222.68]:37485 "EHLO mail-ua1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725881AbfB0Jka (ORCPT ); Wed, 27 Feb 2019 04:40:30 -0500 Received: by mail-ua1-f68.google.com with SMTP id v26so14735101uap.4 for ; Wed, 27 Feb 2019 01:40:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Nt1fsem2OAistWQMNYOqX4SZ/P39kvVGl+EUEs6GRas=; b=gvtRgHYbHar2fKCRXc+2ZTaZ4nDOTSd5QdyKfoh02cPHuocYLL2p3JvLGNuK0VYjQR br2bJhXiM7tJlt0jnA295/VZ6n98JRaVbFY/AePnCrqR37hjaYFyoM4a82fR3GEUWE2R vLlJS9t2+ZVvmHfYixYukkAWElFrydbdTY37n9nObTn0vtR1KtD4is7jxC6paf1LNd55 0PzQxlA0anx1wQFJWscVfhH/di9QwbWJ/O0CyzN/OdCDd/hIX49AsN9sLkr9Ey76CJ4v cqi9xo8W/7WTu5WuMOs/Uxn3okOZr0Gu73mX8mWzd9mO5TGyl1SYSDzAKtmT76oLKcOZ wveg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Nt1fsem2OAistWQMNYOqX4SZ/P39kvVGl+EUEs6GRas=; b=fPG0E5Pv2ySpCtdbHclQJs4qCUSMz0ylzXooJUIYzVmVqsYVqmEUto8CSyOEY1eQfa s4vcbilAt+IpdQsubt721pSzbke21ye45j1nJ2QV4w3sxRADg8mxQ1wMJuArFooOwna1 4iKzAkOTjqEVybQ2Apwjb3JtoymhyHTsBRid8pvo0r9FWpCyFqZtk5kqeMcAPE8ryucQ /DDiSLWshA58FG03BDx7DIxefYPfUKEnfY9TpYn3vRslQ1qeNBILetQHpo8fWOVpZHck Djadd9SdrKOemKOw8NVX0YbbwMnP8USnhMrxq2qsCzOFsBMumWSd6FeaE+4TUBuK42KY riAQ== X-Gm-Message-State: AHQUAubilOvFE0TGtGQtd3x43/9VyEHYkw79g8jz8+v2v0JpiUjFDvoe oD5KrF1KOLOLER5TCuaa6FrH/hFq5SJtO3wlHpVaLw== X-Received: by 2002:a67:c902:: with SMTP id w2mr1243615vsk.191.1551260428723; Wed, 27 Feb 2019 01:40:28 -0800 (PST) MIME-Version: 1.0 References: <1551193825-31074-1-git-send-email-avri.altman@wdc.com> In-Reply-To: <1551193825-31074-1-git-send-email-avri.altman@wdc.com> From: Ulf Hansson Date: Wed, 27 Feb 2019 10:39:53 +0100 Message-ID: Subject: Re: [PATCH v3 0/2] mmc: core: Add SD Discard support To: Avri Altman Cc: "linux-mmc@vger.kernel.org" , Wolfram Sang , Adrian Hunter , Jaehoon Chung , Shawn Lin , Avi Shchislowski , Alex Lemberg , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 26 Feb 2019 at 16:10, Avri Altman wrote: > > SD spec v5.1 adds discard support. The flows and commands matches those > in eMMC, Which leaves to set the appropriate discard arg in CMD38 if > DISCARD_SUPPORT (b313) is set in the SD_STATUS register. > > We set this arg on card init: not in mmc_init_erase as one might expect > but arbitrarily once the card indicated its discard support. This is > because unlike erase, it doesn't really involve any logic, and we want > to avoid the unnecessary complication. > > V2->v3: > The first 2 patches in the series got accepted. > Elaborate the changelog of some of the differences between discard and > erase. Clean some inconsistency in arg checking in mmc_erase(). > Add a patch to set the timeout for sd discard. > > V1->v2: > In the first patch, assign the discard arg for SD cards as well to keep > the code consistent. Rename "discard_arg" to "erase_arg", and elaborate > the change log. > > > Avri Altman (2): > mmc: core: Add discard support to sd > mmc: core: Add sd discard timeout > > drivers/mmc/core/core.c | 15 +++++++++++---- > drivers/mmc/core/sd.c | 10 +++++++++- > include/linux/mmc/sd.h | 1 + > 3 files changed, 21 insertions(+), 5 deletions(-) > > -- > 1.9.1 > Looks good, applied for next, thanks! Kind regards Uffe