From patchwork Sat May 14 20:03:09 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 622283 X-Patchwork-Delegate: sjg@chromium.org Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 3r6d6J2W9dz9t5R for ; Sun, 15 May 2016 06:06:48 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=google.com header.i=@google.com header.b=ibEFhEa2; dkim-atps=neutral Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 6E39FA7748; Sat, 14 May 2016 22:05:21 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id kuWcQJT1E5Uo; Sat, 14 May 2016 22:05:21 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 5239EA7773; Sat, 14 May 2016 22:04:25 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 25240A76A1 for ; Sat, 14 May 2016 22:04:02 +0200 (CEST) Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id sKDYE9ASK5go for ; Sat, 14 May 2016 22:04:02 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-ig0-f178.google.com (mail-ig0-f178.google.com [209.85.213.178]) by theia.denx.de (Postfix) with ESMTPS id E7F66A7621 for ; Sat, 14 May 2016 22:03:40 +0200 (CEST) Received: by mail-ig0-f178.google.com with SMTP id qe5so27786720igc.1 for ; Sat, 14 May 2016 13:03:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=JUdhj/C78zFB3T/JeBBBhG83fYoDdjXEp8aXrLr1zKg=; b=ibEFhEa2xIAVFQ5GkGjcgd4jHXEYZ47uN4ZTbxWEQUaaWRRFOVRh9W4z/+SHYnRnPm iH1XsLVkDJ/JFkIhYf7imb934Avk/URrKdd35dWPbkaRNfVZcRf7U94DOvmBXwCV0eIy YwQjXkx4WS/DipYxg3xtxwsNxfclH7RcmjvFzMve1Qiouuj7s0wcUp3nAB459kVm1wKo SRMYHq4Dm+QiA4d0/0+TjuusJXd/ElwpcJHyMD9aT1JkyA7u39KuLC/IwQU/nOB77vuN LrPKwcgF4Lw3XPu00t5J5RG7/mUuxFPRqQq8tdXpBAjJleUlo826Z0GPfyhyDPU6BSdL o35w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=JUdhj/C78zFB3T/JeBBBhG83fYoDdjXEp8aXrLr1zKg=; b=jnWMgnOS8o8DrB/suTZpqX/Rkpcn1a+Re3hUy0E8L5geSKfAPs+DlHVM3MwX9q82ik S8QgL1SHqmZokoc/zOF7wn7fJQz72XVBOBtn35rE7AeTj/CV285LEqHplCSmAwl7be9T az796RxStcyAlGlzWfxl4Rjx8YLL/d+gBCIpkjYkYeu6v+kDtjCUaZeKoOpJwGW0lR/K vGDQlZ7vykVsuG7EFR5ya6d2NT0zYM2rjNPtbr5CFILe54Wf3X4WJZWerPUAv7RWrSW4 A+CYc9KvlAa/jqJ+nIsWpfO0UHFXv+McOvLAJIUh+dWO9ZesyHI+2QvSwennCc+5NjZl VLUA== X-Gm-Message-State: AOPr4FVMZ7JiKoKfsbf8thHoRzOo77d7I92JiQ2XdMeZm307HwjP7j0Fz6aAKB5mBTh348lp X-Received: by 10.50.72.237 with SMTP id g13mr6289139igv.4.1463256219119; Sat, 14 May 2016 13:03:39 -0700 (PDT) Received: from kaki.bld.corp.google.com ([2620:0:1005:12:f424:4d21:ea6d:565]) by smtp.gmail.com with ESMTPSA id 142sm2936719itk.12.2016.05.14.13.03.33 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 14 May 2016 13:03:35 -0700 (PDT) Received: by kaki.bld.corp.google.com (Postfix, from userid 121222) id 746FA220E3A; Sat, 14 May 2016 14:03:31 -0600 (MDT) From: Simon Glass To: U-Boot Mailing List Date: Sat, 14 May 2016 14:03:09 -0600 Message-Id: <1463256198-3829-19-git-send-email-sjg@chromium.org> X-Mailer: git-send-email 2.8.0.rc3.226.g39d4020 In-Reply-To: <1463256198-3829-1-git-send-email-sjg@chromium.org> References: <1463256198-3829-1-git-send-email-sjg@chromium.org> Cc: huang lin , Jeffy Chen , Pantelis Antoniou Subject: [U-Boot] [PATCH 18/20] dm: mmc: Fix up mmc_bread/bwrite() prototypes for SPL X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.15 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" When these functions are not compiled in, we still need to declare the correct function signature to avoid a build warnings in SPL. Fix this. Signed-off-by: Simon Glass --- drivers/mmc/mmc_private.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/drivers/mmc/mmc_private.h b/drivers/mmc/mmc_private.h index 27b9e5f..9f0d5c2 100644 --- a/drivers/mmc/mmc_private.h +++ b/drivers/mmc/mmc_private.h @@ -37,6 +37,19 @@ ulong mmc_bwrite(struct blk_desc *block_dev, lbaint_t start, lbaint_t blkcnt, /* SPL will never write or erase, declare dummies to reduce code size. */ +#ifdef CONFIG_BLK +static inline unsigned long mmc_berase(struct udevice *dev, + lbaint_t start, lbaint_t blkcnt) +{ + return 0; +} + +static inline ulong mmc_bwrite(struct udevice *dev, lbaint_t start, + lbaint_t blkcnt, const void *src) +{ + return 0; +} +#else static inline unsigned long mmc_berase(struct blk_desc *block_dev, lbaint_t start, lbaint_t blkcnt) { @@ -48,6 +61,7 @@ static inline ulong mmc_bwrite(struct blk_desc *block_dev, lbaint_t start, { return 0; } +#endif #endif /* CONFIG_SPL_BUILD */