From patchwork Mon Aug 27 23:33:45 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Ball X-Patchwork-Id: 1378581 Return-Path: X-Original-To: patchwork-linux-mmc@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 1C1DADF280 for ; Mon, 27 Aug 2012 23:33:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754908Ab2H0Xdt (ORCPT ); Mon, 27 Aug 2012 19:33:49 -0400 Received: from void.printf.net ([89.145.121.20]:33043 "EHLO void.printf.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754878Ab2H0Xds (ORCPT ); Mon, 27 Aug 2012 19:33:48 -0400 Received: from c-76-24-28-220.hsd1.ma.comcast.net ([76.24.28.220] helo=octavius.laptop.org) by void.printf.net with esmtpsa (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.69) (envelope-from ) id 1T68oV-00034y-9D for linux-mmc@vger.kernel.org; Tue, 28 Aug 2012 00:33:47 +0100 From: Chris Ball To: linux-mmc@vger.kernel.org Subject: [PATCH] mmc: core: Quieten "could not set regulator OCR" error. Date: Mon, 27 Aug 2012 19:33:45 -0400 Message-ID: <87a9xfyko6.fsf@octavius.laptop.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1 (gnu/linux) MIME-Version: 1.0 Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org Some distributions build with CONFIG_REGULATOR_DUMMY=y -- this makes regulator setup succeed harmlessly, but then trying to set the voltage on the dummy regulator will fail as below: [ 6.413866] sdhci-pci 0000:03:00.0: SDHCI controller found [1180:e822] (rev 0) [ 6.414081] _regulator_get: 0000:03:00.0 supply vmmc not found, using dummy regulator [ 6.415252] mmc0: SDHCI controller on PCI [0000:03:00.0] using DMA [ 6.415294] sdhci-pci 0000:03:00.0: could not set regulator OCR (-22) [ 6.444241] sdhci-pci 0000:03:00.0: could not set regulator OCR (-22) [ 6.473648] sdhci-pci 0000:03:00.0: could not set regulator OCR (-22) [..] Since this isn't an error in this case, move the error to pr_debug(). Reference: https://bugs.archlinux.org/task/29008 Signed-off-by: Chris Ball --- drivers/mmc/core/core.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index 835c9f0..30d9357 100644 --- a/drivers/mmc/core/core.c +++ b/drivers/mmc/core/core.c @@ -1017,8 +1017,9 @@ int mmc_regulator_set_ocr(struct mmc_host *mmc, } if (result) - dev_err(mmc_dev(mmc), - "could not set regulator OCR (%d)\n", result); + pr_debug("%s: could not set regulator OCR (%d)\n", + mmc_hostname(mmc), result); + return result; } EXPORT_SYMBOL_GPL(mmc_regulator_set_ocr);