From mboxrd@z Thu Jan 1 00:00:00 1970 From: Adrian Hunter Subject: Re: [PATCH] sdhci: Add quirk and device tree parameter to force SD test mode Date: Tue, 23 Aug 2016 09:22:29 +0300 Message-ID: <684dd3fb-15ac-fa84-2f1e-89f379b5149a@intel.com> References: <1471906531-28668-1-git-send-email-zach.brown@ni.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1471906531-28668-1-git-send-email-zach.brown-acOepvfBmUk@public.gmane.org> Sender: devicetree-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Zach Brown Cc: ulf.hansson-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org, mark.rutland-5wv7dgnIgG8@public.gmane.org, robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org, linux-mmc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: linux-mmc@vger.kernel.org On 23/08/16 01:55, Zach Brown wrote: > From: Jaeden Amero > > On some devices, CD is broken so that we must force the SDHCI into test > mode and set CD, so that it always detects an SD card as present. > > In order to get a device with broken CD working, we had previously > always set the SDHCI into test mode. Unfortunately, this had the side > effect of making all SD cards used with our Linux kernels undetectable > and non-removable. > > By making this "SD test mode" setting optional via a quirk, we can avoid > this side effect for devices other than the device with broken CD. > Additionally, we add a device parameter to sdhci-pltfm to allow all > SDHCI drivers to enable this quirk. Generally new quirks are not acceptable, but I don't see how test mode helps very much since you still don't get any card detection events. If you really need test mode, please explain more about how it helps (as opposed to polling for example). -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756896AbcHWG1F (ORCPT ); Tue, 23 Aug 2016 02:27:05 -0400 Received: from mga04.intel.com ([192.55.52.120]:56579 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753781AbcHWG1D (ORCPT ); Tue, 23 Aug 2016 02:27:03 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.28,564,1464678000"; d="scan'208";a="752326849" Subject: Re: [PATCH] sdhci: Add quirk and device tree parameter to force SD test mode To: Zach Brown References: <1471906531-28668-1-git-send-email-zach.brown@ni.com> Cc: ulf.hansson@linaro.org, mark.rutland@arm.com, robh+dt@kernel.org, linux-mmc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org From: Adrian Hunter Organization: Intel Finland Oy, Registered Address: PL 281, 00181 Helsinki, Business Identity Code: 0357606 - 4, Domiciled in Helsinki Message-ID: <684dd3fb-15ac-fa84-2f1e-89f379b5149a@intel.com> Date: Tue, 23 Aug 2016 09:22:29 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <1471906531-28668-1-git-send-email-zach.brown@ni.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 23/08/16 01:55, Zach Brown wrote: > From: Jaeden Amero > > On some devices, CD is broken so that we must force the SDHCI into test > mode and set CD, so that it always detects an SD card as present. > > In order to get a device with broken CD working, we had previously > always set the SDHCI into test mode. Unfortunately, this had the side > effect of making all SD cards used with our Linux kernels undetectable > and non-removable. > > By making this "SD test mode" setting optional via a quirk, we can avoid > this side effect for devices other than the device with broken CD. > Additionally, we add a device parameter to sdhci-pltfm to allow all > SDHCI drivers to enable this quirk. Generally new quirks are not acceptable, but I don't see how test mode helps very much since you still don't get any card detection events. If you really need test mode, please explain more about how it helps (as opposed to polling for example).