Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3120532ybb; Mon, 6 Apr 2020 02:29:50 -0700 (PDT) X-Google-Smtp-Source: APiQypKX6phRrwngey08gjjMDb4WtLOFw0dk6/g7z34tsnR7qG0ikAC6j3RicXHE1lYWcoQgWAO4 X-Received: by 2002:a05:6830:1da6:: with SMTP id z6mr15047995oti.124.1586165390764; Mon, 06 Apr 2020 02:29:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586165390; cv=none; d=google.com; s=arc-20160816; b=yvqqmNX7i9GVTwUK2yTzaGCGdg+qfGyYzxktpryIFv9za2BgVluy+j7xul1PAj0Y7T EEcitr9UD/TGYEG+vCLxJsm4FHKDMxXU4Ld+ZJoM/sCwUq21syq1Y6wmd1iC/woAx1+I t3pRp2k+7aLDiA39lfEWhz1xDmTsVtvdRw6ryeY+NTt4lKltPQXSLGClyVgpUQg5YxZU 8CalSIUquEmpLy2wgMBZO3nG3r3cgwRomML/Z7kvdyXhqUjmFQE8F0QiDCUl3vhKIg0g GUEMjRb1I0H/XUB+MbfpJhiesVr5eQANh/3uCHMWy+p+VaOUdqqqPcKanBbea71pI6ah zn9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=muWMIkHaWKYbNBLLo8XrACMV/YRyMZLJ8+ep+aobtGo=; b=MS8xOpLVZnCMzf1YuQaa3JheX8ea5FGig0FfnvoHufHxrHphQJr0MmQFowEsoHYGr/ bRL70WO7heUe/U57bS2imvKbS6FVTxzXqe7JtPQsZN1gSGef7bZYqjZh4lbJEtHxvWO5 SAkQXvjB8/0n+pFIxKhDG8Z8E4VxSsYbvE8fTm0m9m+kHqOijX9bA8L3Hp2SZakD+KvT zhmMW6NKjcXQ1IRADiptnmpfrMPD57zne6gVQJDlPJeQt/lamf7ML3a9eRl42jgpL2kP nX3NRRBA0cKwZXTsEuEBIrg1a7Yoll7HpuOFCqSCLBWwwFvNDxr2BN5sz8lc832onaA4 rwRA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=Dn51w+Ct; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 6si7427776otv.76.2020.04.06.02.29.39; Mon, 06 Apr 2020 02:29:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=Dn51w+Ct; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726793AbgDFJ3A (ORCPT + 99 others); Mon, 6 Apr 2020 05:29:00 -0400 Received: from Mailgw01.mediatek.com ([1.203.163.78]:51800 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1726799AbgDFJ3A (ORCPT ); Mon, 6 Apr 2020 05:29:00 -0400 X-UUID: d772543e96b54573b2ed972ec2b4dd80-20200406 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=muWMIkHaWKYbNBLLo8XrACMV/YRyMZLJ8+ep+aobtGo=; b=Dn51w+Ctn/Y8eAldEDwwqJ069eZO5nsMpzhVCwjjCE2sMToIhL4vi9BBeujNsmtnIWQutmmX47JO7Dir1b/iZS6i24z0opg+CHwChYIKAQoJ790QvyjiGc77aNQPQj1nqOVi2QnS3mQMP78zLstny5T/eZlPNr6T/nVNEUvsOL0=; X-UUID: d772543e96b54573b2ed972ec2b4dd80-20200406 Received: from mtkcas34.mediatek.inc [(172.27.4.253)] by mailgw01.mediatek.com (envelope-from ) (mailgw01.mediatek.com ESMTP with TLS) with ESMTP id 1198615902; Mon, 06 Apr 2020 17:28:06 +0800 Received: from mtkcas08.mediatek.inc (172.21.101.126) by MTKMBS31DR.mediatek.inc (172.27.6.102) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Mon, 6 Apr 2020 17:28:03 +0800 Received: from mtkswgap22.mediatek.inc (172.21.77.33) by mtkcas08.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Mon, 6 Apr 2020 17:28:02 +0800 From: Chun-Hung Wu To: , Jonathan Hunter , Al Cooper , Adrian Hunter , Florian Fainelli , , Andy Gross , Bjorn Andersson , Michal Simek , Thierry Reding , Chaotian Jing , Ulf Hansson , Rob Herring , Mark Rutland , Matthias Brugger , Linus Walleij , Pavel Machek , Kate Stewart , Greg Kroah-Hartman , Martin Blumenstingl , Pan Bian , Thomas Gleixner , Allison Randal , Mathieu Malaterre , Stanley Chu , Kuohong Wang CC: , , , , , , , , , Chun-Hung Wu Subject: [PATCH 3/5] [3/5] mmc: mediatek: refine msdc timeout api Date: Mon, 6 Apr 2020 17:27:59 +0800 Message-ID: <1586165281-11888-4-git-send-email-chun-hung.wu@mediatek.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1586165281-11888-1-git-send-email-chun-hung.wu@mediatek.com> References: <1586165281-11888-1-git-send-email-chun-hung.wu@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain X-TM-SNTS-SMTP: 16F3C6724004E6AA8460B143588F4E3011ADAC7C8487500B14833265BC6D0BD32000:8 X-MTK: N Content-Transfer-Encoding: base64 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RXh0cmFjdCBtc2RjIHRpbWVvdXQgYXBpIGNvbW1vbiBwYXJ0IHRvIGhhdmUNCmJldHRlciBjb2Rl IGFyY2hpdGVjdHVyZSBhbmQgYXZvaWQgcmVkdW5kZW50DQpjb2RlLg0KDQpTaWduZWQtb2ZmLWJ5 OiBDaHVuLUh1bmcgV3UgPGNodW4taHVuZy53dUBtZWRpYXRlay5jb20+DQotLS0NCiBkcml2ZXJz L21tYy9ob3N0L210ay1zZC5jIHwgMzIgKysrKysrKysrKysrKysrKysrKysrKy0tLS0tLS0tLS0N CiAxIGZpbGUgY2hhbmdlZCwgMjIgaW5zZXJ0aW9ucygrKSwgMTAgZGVsZXRpb25zKC0pDQoNCmRp ZmYgLS1naXQgYS9kcml2ZXJzL21tYy9ob3N0L210ay1zZC5jIGIvZHJpdmVycy9tbWMvaG9zdC9t dGstc2QuYw0KaW5kZXggNzcyNmRjZi4uYTIzMjhmYiAxMDA2NDQNCi0tLSBhL2RyaXZlcnMvbW1j L2hvc3QvbXRrLXNkLmMNCisrKyBiL2RyaXZlcnMvbW1jL2hvc3QvbXRrLXNkLmMNCkBAIC02OTks MjEgKzY5OSwyMSBAQCBzdGF0aWMgdm9pZCBtc2RjX3VucHJlcGFyZV9kYXRhKHN0cnVjdCBtc2Rj X2hvc3QgKmhvc3QsIHN0cnVjdCBtbWNfcmVxdWVzdCAqbXJxKQ0KIAl9DQogfQ0KIA0KLS8qIGNs b2NrIGNvbnRyb2wgcHJpbWl0aXZlcyAqLw0KLXN0YXRpYyB2b2lkIG1zZGNfc2V0X3RpbWVvdXQo c3RydWN0IG1zZGNfaG9zdCAqaG9zdCwgdTMyIG5zLCB1MzIgY2xrcykNCitzdGF0aWMgdTY0IG1z ZGNfdGltZW91dF9jYWwoc3RydWN0IG1zZGNfaG9zdCAqaG9zdCwgdTY0I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