Message ID | 1493059318-767-2-git-send-email-steven.hill@cavium.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-mmc-owner@kernel.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B73F360224 for <patchwork-linux-mmc@patchwork.kernel.org>; Mon, 24 Apr 2017 18:44:40 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AC2C62841D for <patchwork-linux-mmc@patchwork.kernel.org>; Mon, 24 Apr 2017 18:44:40 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A0D1F2842A; Mon, 24 Apr 2017 18:44:40 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 05D902841D for <patchwork-linux-mmc@patchwork.kernel.org>; Mon, 24 Apr 2017 18:44:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S973121AbdDXSoh (ORCPT <rfc822;patchwork-linux-mmc@patchwork.kernel.org>); Mon, 24 Apr 2017 14:44:37 -0400 Received: from mail-by2nam03on0042.outbound.protection.outlook.com ([104.47.42.42]:48489 "EHLO NAM03-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S973056AbdDXSo3 (ORCPT <rfc822;linux-mmc@vger.kernel.org>); Mon, 24 Apr 2017 14:44:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=Mfua8lLlEZucrhx7JmpXg2HO1ZM8DAM8Wb/H0liMCN8=; b=nE3qHYwWw4CRUirzg8I3qQeMiMliQawc1dNmASRff6znmF0Yb0xiJYQ2s39IRuflazQg5pqHj6m5QzvmEO7hAErmFyphRLpDp6TWmLxvlvdmZ68OghbOX+iMCG/d9AVj0SEemLcc+2CFCceyghSnsZSU+gpqm/FPbUwgC4dBJYM= Authentication-Results: linaro.org; dkim=none (message not signed) header.d=none; linaro.org; dmarc=none action=none header.from=cavium.com; Received: from black.inter.net (50.82.184.123) by CY4PR07MB3206.namprd07.prod.outlook.com (10.172.115.148) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1047.13; Mon, 24 Apr 2017 18:44:15 +0000 From: "Steven J. Hill" <steven.hill@cavium.com> To: Ulf Hansson <ulf.hansson@linaro.org> Cc: David Daney <david.daney@cavium.com>, Jan Glauber <jglauber@cavium.com>, linux-mmc@vger.kernel.org, linux-mips@linux-mips.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/4] mmc: core: Export API to allow hosts to get the card address Date: Mon, 24 Apr 2017 13:41:55 -0500 Message-Id: <1493059318-767-2-git-send-email-steven.hill@cavium.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1493059318-767-1-git-send-email-steven.hill@cavium.com> References: <1493059318-767-1-git-send-email-steven.hill@cavium.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [50.82.184.123] X-ClientProxiedBy: BY2PR07CA044.namprd07.prod.outlook.com (10.141.251.19) To CY4PR07MB3206.namprd07.prod.outlook.com (10.172.115.148) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 72acd3e7-104c-4dfe-6591-08d48b41e927 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(201703131423075)(201703031133081); SRVR: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Qg/UNyHROrsxWfEYEeHJjLcoZ3IYa4WPuwomxnwkJVck230F5i68D8ZscolhcQvNM5Sb4aqEyze3pEROo++wFcHiD8Bm5KC9J; 20:fb26m+e0123daQFlV1BQzvbkbAiP3lwzZar4Cc5S4zHV80Y7k0Bf5TtZAq+y8MmHScuA9EFQcBU0XYwhC6Ti9NPiN0CIjauK/EKHiC90Abb9piaF54MYzgyGcF0qSbtZ4MjLH/tFsa+G05aCD2kSfXVX/mYRHMpYU7+eKN2nQp91x4nbKzL5g4KWKj+hs5F6r+NCSO61SqXklrctk6SSI6Qa79ItSL/THi8lJccD9UfAnVnRwbHOuh+0E2tFnNZuWAPW7cgfHHCh73YbKxqJ7AnJaEhz2nXWopCbaM7ZppHPy2zfl41Ha/Qjpx4xAFLVEZPNUI+6bnucEfK5gx66bBY7Tn+7Ewb8GG76YkeD5TelgCR6Bfheh5wYjPjH7Q5LBQVVnk6ZaPXlG7cX2eA9ylQMBJhD2FeHuCrEzdUhKqzcCm7XdF+00EWZ/bIw14S/zjfZNaBNhaH23bL6bNGTNJGjdZUL45pMZG5uacFNv/osxMfKgkn6UbzuPLKoOq2y X-Microsoft-Antispam-PRVS: <CY4PR07MB3206650B381609DD19CB40F4801F0@CY4PR07MB3206.namprd07.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040450)(601004)(2401047)(8121501046)(5005006)(10201501046)(93006095)(93001095)(3002001)(6041248)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(20161123560025)(20161123555025)(20161123564025)(6072148); SRVR:CY4PR07MB3206; BCL:0; PCL:0; RULEID:; SRVR:CY4PR07MB3206; X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3206; 4:R+UkimknPb0xWpndt+aWnuTouYL9dGV1pyZA84xCNm5g7JFTj8wHBodMniBeNobxEUzs/y3UbWzvdkCeOy0lUADj3SsSKck2XAfI2M6C6zoC4MdLdaNl+eh/Td1gMqLNYncMOnqUZPu/bMt9m1gd00KKTiNzgp1uxNbcJAqChULLy+h651sXuGx2KC5lp7hWl5x3r7c/W92PpTnGly2irbNUFNNEpqrWpFUf2Cp/an5jJgtPWZCiabrVn9V/6O6YGkTrPMezFV6Azn+NTVfNPO4Z4DjTRKawKlDk0ZfizbOKoO4Q0cjDxmrnhC+IbLSVGTLh2MWbXo/Hn74VNmHwt69rjtDoZlMSgIyOQ4blC3CKy3DOpiYaq19PAPfm5ZXSH/s8B6rc+KkgVfctnGPaf4CbGx7JH05PW8lUI+YQe749Ttcsh9AmXSk1mLpdkT8X6FsUAY4c5QU8HCHr83Z9+7f17K8nm9O7INGU2GHVS9Bg0v1QJUcBe2RZTdW8oSnRdsxbVGbBoJcbbP1OavCcpCC+sZjIhfwSp9IzaCHsgWPLCm0s4wWATCNOsGwicOVfSt+bw/81kExU2U/hV8ddamopTfhWcpb/Cg7qmIotyZdG+5aDy0SP7vWvaKLuas1bY/yxxyPVdk3PE5C6UuNZt6mLpNBeBaLiUH6nTtLJzEYZgAo0kJLRUIUx+12F3Of+ps8w4vGDkRmuuU9kh6lxFRMnJ66NshftYoRlVSwUpBU= X-Forefront-PRVS: 0287BBA78D X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(39850400002)(39410400002)(39450400003)(39840400002)(39400400002)(4326008)(110136004)(6116002)(54906002)(2906002)(50986999)(3846002)(6486002)(6506006)(76176999)(189998001)(53416004)(50466002)(66066001)(47776003)(38730400002)(48376002)(42186005)(25786009)(305945005)(575784001)(5003940100001)(50226002)(7736002)(81166006)(8676002)(5660300001)(6916009)(86362001)(36756003)(53936002)(6512007)(6666003)(33646002)(2950100002)(15583001); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR07MB3206; H:black.inter.net; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CY4PR07MB3206; 23:C5GXkpnctA2dr4+drsd3rI+cbB29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VH1XEL1eI6kNsqn9tQT7e5CIy02HMN3NH+RH6puFdjvYONce47iLi/9GmfQqnPq4Vv/o= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3206; 7:octj7cppIwX6R1EJJC10yuFjtH1Bv36AhHG8s3O3RJslJYybykXvFqNfyjMM+XYAYM8Q4zj3Lhw2toyiGZo8cTnFqymjHvXHMC7tf8bQPeEOzks+EzCUbIVHx5GBoX9WJ6zqqqfvSpqPu5E2DvfF0tKJkr8ilZ6niFNsY6MYNHRKGxWi6InK9caEFzGgtDfzQ81jEWb36AwJ5wKIES8X/gdKhqVK3YuiaqQhwNiBsaqFNPEF1qlrVwuTGyheDoUvjvgrGDxXJZtxaSJPxqbvPfA4QjJWclKbGok782zKRM8qlp/B92hx6cy134hMUG+krwCP3gtSy8Jey81Qe57a8g== X-OriginatorOrg: cavium.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Apr 2017 18:44:15.8593 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR07MB3206 Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: <linux-mmc.vger.kernel.org> X-Mailing-List: linux-mmc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index 926e0fd..f9fae34 100644 --- a/drivers/mmc/core/core.c +++ b/drivers/mmc/core/core.c @@ -2555,6 +2555,12 @@ unsigned int mmc_calc_max_discard(struct mmc_card *card) } EXPORT_SYMBOL(mmc_calc_max_discard); +bool mmc_card_is_blockaddr(struct mmc_card *card) +{ + return card ? mmc_card_blockaddr(card) : false; +} +EXPORT_SYMBOL(mmc_card_is_blockaddr); + int mmc_set_blocklen(struct mmc_card *card, unsigned int blocklen) { struct mmc_command cmd = {}; diff --git a/include/linux/mmc/card.h b/include/linux/mmc/card.h index 77e61e0..4cd9450 100644 --- a/include/linux/mmc/card.h +++ b/include/linux/mmc/card.h @@ -307,6 +307,8 @@ static inline bool mmc_large_sector(struct mmc_card *card) return card->ext_csd.data_sector_size == 4096; } +bool mmc_card_is_blockaddr(struct mmc_card *card); + #define mmc_card_mmc(c) ((c)->type == MMC_TYPE_MMC) #define mmc_card_sd(c) ((c)->type == MMC_TYPE_SD) #define mmc_card_sdio(c) ((c)->type == MMC_TYPE_SDIO)