From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755112Ab3AOGUQ (ORCPT ); Tue, 15 Jan 2013 01:20:16 -0500 Received: from mail-pb0-f51.google.com ([209.85.160.51]:56011 "EHLO mail-pb0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754086Ab3AOGUE (ORCPT ); Tue, 15 Jan 2013 01:20:04 -0500 Date: Mon, 14 Jan 2013 22:20:04 -0800 From: Olof Johansson To: Doug Anderson Cc: linux-mmc@vger.kernel.org, linux-samsung-soc@vger.kernel.org, Thomas Abraham , Kukjin Kim , Arnd Bergmann , Will Newton , Chris Ball , Jaehoon Chung , Seungwon Jeon , linux-kernel@vger.kernel.org, Grant Likely , Rob Herring , Rob Landley , Abhilash Kesavan , Kyungmin Park , devicetree-discuss@lists.ozlabs.org, linux-doc@vger.kernel.org Subject: Re: [PATCH v4 1/5] mmc: dw_mmc: Add "disable-wp" device tree property Message-ID: <20130115062004.GA19801@quad.lixom.net> References: <1357842269-15062-1-git-send-email-dianders@chromium.org> <1357923834-31641-1-git-send-email-dianders@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1357923834-31641-1-git-send-email-dianders@chromium.org> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jan 11, 2013 at 09:03:50AM -0800, Doug Anderson wrote: > The "disable-wp" property is used to specify that a given SD card slot > doesn't have a concept of write protect. This eliminates the need for > special case code for SD slots that should never be write protected > (like a micro SD slot or a dev board). > > The dw_mmc driver is special in needing to specify "disable-wp" > because the lack of a "wp-gpios" property means to use the special > purpose write protect line. On some other mmc devices the lack of > "wp-gpios" means that write protect should be disabled. > > Signed-off-by: Doug Anderson > Acked-by: Seungwon Jeon Acked-by: Olof Johansson Nit below. > @@ -825,7 +828,13 @@ static int dw_mci_get_ro(struct mmc_host *mmc) > struct dw_mci_board *brd = slot->host->pdata; > > /* Use platform get_ro function, else try on board write protect */ > - if (brd->quirks & DW_MCI_QUIRK_NO_WRITE_PROTECT) > + > + /* > + * NOTE: DW_MCI_QUIRK_NO_WRITE_PROTECT will be removed in a future > + * patch in the series once reference to it is removed. > + */ > + if ((brd->quirks & DW_MCI_QUIRK_NO_WRITE_PROTECT) || > + (slot->quirks & DW_MCI_SLOT_QUIRK_NO_WRITE_PROTECT)) Given that it never worked properly, you could have nuked it first and avoid the extra churn. Still, not a strong enough reason to respin the series, IMHO. -Olof