From patchwork Wed Aug 13 04:46:16 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jaehoon Chung X-Patchwork-Id: 4715971 Return-Path: X-Original-To: patchwork-linux-mmc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id DE97CC0338 for ; Wed, 13 Aug 2014 04:46:23 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 2FEBD201BC for ; Wed, 13 Aug 2014 04:46:23 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DCF0C201B4 for ; Wed, 13 Aug 2014 04:46:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750749AbaHMEqV (ORCPT ); Wed, 13 Aug 2014 00:46:21 -0400 Received: from mailout1.samsung.com ([203.254.224.24]:21876 "EHLO mailout1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750707AbaHMEqU (ORCPT ); Wed, 13 Aug 2014 00:46:20 -0400 Received: from epcpsbgr4.samsung.com (u144.gpu120.samsung.co.kr [203.254.230.144]) by mailout1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NA8005KLAL6MT50@mailout1.samsung.com> for linux-mmc@vger.kernel.org; Wed, 13 Aug 2014 13:46:18 +0900 (KST) Received: from epcpsbgm1.samsung.com ( [172.20.52.113]) by epcpsbgr4.samsung.com (EPCPMTA) with SMTP id CE.0A.13863.A9DEAE35; Wed, 13 Aug 2014 13:46:18 +0900 (KST) X-AuditID: cbfee690-b7f526d000003627-39-53eaed9aecb7 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id 5C.A4.04943.A9DEAE35; Wed, 13 Aug 2014 13:46:18 +0900 (KST) Received: from localhost.localdomain ([10.252.81.186]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0NA800LMHAL5QHW1@mmp1.samsung.com>; Wed, 13 Aug 2014 13:46:17 +0900 (KST) From: Jaehoon Chung To: linux-mmc Cc: Chris Ball , Ulf Hansson , Jaehoon Chung Subject: [PATCH] mmc: host: don't access at boot partition when mode is HS200/HS400. Date: Wed, 13 Aug 2014 13:46:16 +0900 Message-id: <1407905176-6847-1-git-send-email-jh80.chung@samsung.com> X-Mailer: git-send-email 1.7.9.5 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrJLMWRmVeSWpSXmKPExsWyRsSkUHfW21fBBtMvi1tMuLyd0eLGrzZW iyP/+xktjq8Nd2DxuHNtD5vHjVcLmTz6tqxi9Pi8SS6AJYrLJiU1J7MstUjfLoEr43vPJsaC q6wVh9oPszcw3mDpYuTkkBAwkZj56BSULSZx4d56ti5GLg4hgaWMEncn3WSFKVry+QsjRGIR o0TL/o9MEE4bk8SF8/8YQarYBHQktn87zgRiiwhoSnRuX8kGYjMLFEr8n7ICbJKwQJjEnCvv wWwWAVWJq3vns4PYvAKuEr+mnwKyOYC2KUjMmWQDMl9C4D6bxN87TcwQ9QIS3yYfYoGokZXY dIAZ4jhJiYMrbrBMYBRcwMiwilE0tSC5oDgpvchErzgxt7g0L10vOT93EyMwGE//ezZhB+O9 A9aHGJOBxk1klhJNzgcGc15JvKGxmZGFqYmpsZG5pRlpwkrivGqPkoKEBNITS1KzU1MLUovi i0pzUosPMTJxcEo1MLJervIzuTIr67KX0c24t8t19DS+T+vYyfmlWyQpp2jqI50FDMZOebJG Xxr5b25Yce/+LPM2w1C+319bAnOPGSU8E9gz/+EN991Sl3t0V/U0KJ+UYvuasKOEX7b7hG5W lIn/8TyGryt68z9N2qJ9ReYiy7UqITPjDxVrQ/4znnozX8enpXmCsxJLcUaioRZzUXEiAGjr hw9cAgAA X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrBLMWRmVeSWpSXmKPExsVy+t9jAd1Zb18FG+zqE7SYcHk7o8WNX22s Fkf+9zNaHF8b7sDicefaHjaPG68WMnn0bVnF6PF5k1wAS1QDo01GamJKapFCal5yfkpmXrqt kndwvHO8qZmBoa6hpYW5kkJeYm6qrZKLT4CuW2YO0EolhbLEnFKgUEBicbGSvh2mCaEhbroW MI0Rur4hQXA9RgZoIGENY8b3nk2MBVdZKw61H2ZvYLzB0sXIySEhYCKx5PMXRghbTOLCvfVs XYxcHEICixglWvZ/ZIJw2pgkLpz/B1bFJqAjsf3bcSYQW0RAU6Jz+0o2EJtZoFDi/5QVrCC2 sECYxJwr78FsFgFViat757OD2LwCrhK/pp8CsjmAtilIzJlkM4GRewEjwypG0dSC5ILipPRc Q73ixNzi0rx0veT83E2M4FB/JrWDcWWDxSFGAQ5GJR7eCt5XwUKsiWXFlbmHGCU4mJVEeB22 AIV4UxIrq1KL8uOLSnNSiw8xmgItn8gsJZqcD4zDvJJ4Q2MTMyNLI3NDCyNjcyVx3gOt1oFC AumJJanZqakFqUUwfUwcnFINjFNv5P/L9p932zRljc7r3vzws3E3bLafezX7pSSLqLnYe5uw y4xq+qaKF27o2MuEWs+80HyjufVhdUt41ru02/dWznyv+10wU0Sk/9CkSl3TVWr+qReOuChK MOeuOzYr9dIfg7Si0s7LDkZLu/a0a319UcZY4Pdj8awLemm/r175Yly1hyX0sxJLcUaioRZz UXEiADfRKSuLAgAA DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP HS200/HS400 mode is not supported during boot operation. Signed-off-by: Jaehoon Chung --- include/linux/mmc/host.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/linux/mmc/host.h b/include/linux/mmc/host.h index 7960424..ce5db96 100644 --- a/include/linux/mmc/host.h +++ b/include/linux/mmc/host.h @@ -445,6 +445,10 @@ static inline int mmc_host_cmd23(struct mmc_host *host) static inline int mmc_boot_partition_access(struct mmc_host *host) { + /* HS200 & HS400 mode is not supported during boot operation */ + if (host->caps2 & (MMC_CAP2_HS200 | MMC_CAP2_HS400)) + return 0; + return !(host->caps2 & MMC_CAP2_BOOTPART_NOACC); }