From patchwork Thu Nov 19 23:56:10 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cristian Ciocaltea X-Patchwork-Id: 11919251 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.7 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5FBAAC388F9 for ; Thu, 19 Nov 2020 23:59:38 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D79812222D for ; Thu, 19 Nov 2020 23:59:37 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="iwguNyU7"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Ok31bZxZ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D79812222D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=IVBXw8hTmYB3HtI0t7BCM6BURB7//CLC6f7FJ/NAmQ4=; b=iwguNyU7GTHfIyrIkvtDi5yi9 Df9RPI1Q5I+t/e/G1IuVB9XWNyotWOWdZ0b06uQklY5ri17oSQmdVYs/SU8gakt9RldwfY3+ds4I2 ODhKG0ica8DmG6Y3sY5AyFBUrhaQBA1C3wKr88H99SfmXeVZH9dRszcNxJq/FhBKil1AivqX4Mb+L 4EGrd9NqStlvLNAxUyjc44emX/IF79BTAVkRCgeDFau6Tw6xtrQvje9lmq9NO8nIEYSX1ceTZCpsJ HUhssTUujIzezrXtzMBrXxAqEQ8t5wASsWmJX8ejpCkXJiUwP8A0cVc9WscnUjD6Nxg2msMCHzv9c OnzAUWYmA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kftpO-0001KB-Ct; Thu, 19 Nov 2020 23:59:02 +0000 Received: from mail-ej1-x641.google.com ([2a00:1450:4864:20::641]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kftn4-0008Vn-Bb; Thu, 19 Nov 2020 23:56:39 +0000 Received: by mail-ej1-x641.google.com with SMTP id o9so10459811ejg.1; Thu, 19 Nov 2020 15:56:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=qO93vAGuITSebLhoJ1hpwjQmgCXudOAkh2U6z4dlaEM=; b=Ok31bZxZGVHmgQxPtvqLKDgAbESWqR6TkAcjj0CCABPgalzGMuYw1a9AS7ax+5kmak mwY4ri8PmJr7A6gqDrxBJpSdG3uR2YIUq0b4rlXC/6W1LRog803Wi4LlNAsZmxT4zrwd idJyS8jWov8wJat0Vd4rX0qd0Eq4ffm3I9SUvThFFdwMhSf6Cm84o5LU+qW2V7EDZn/+ FGJEBZHCJsU5X6Mcm4kJTUy1cXGaHHmiaQr2wgHToEjB8FTcQ+WD3ptGiddO7XbBXvj5 wYtpfyAmyfLVfjhvF44uKY4a6oaCPEQG74R6Dmmf1eRQMy7jjnQNHQNajc5u6Gz3n8PJ TvtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=qO93vAGuITSebLhoJ1hpwjQmgCXudOAkh2U6z4dlaEM=; b=rYfPiOwrQygiiX6J2AdDUYSA6h6XCViGTbUS4YPJGPfUi3nowWxh4NQn0N2so472FM sKjCDmCMTgdPuiiZ12S/2BTYDSqKuL3Hg32O/iwOI4LwFneGL5NbKX6lGR4VDZVvPT1/ iwcy8bjpwLCdmhFK8Z6BL/tAjnWmnshOq/3WN4m8r4b04aOIY10bnbg2DEmIXULzyayu Pkrcv2r0jhV+drWFy+5F1JFPde4HBQq+yfkcyiFhG7tyH9vxkJYMVdXd3dNGKVd2IUlP xNqFWHtcUCMMuU2pPgFS6GaL8nyh70yLUd5PHaJLb4PJzdomB4LCTwprbO8fAFmxd8D4 tpEQ== X-Gm-Message-State: AOAM530y46c0MR6/PyGAr/ap9PynZ9HyIHwp34NA52DT3W2Pn+KjsGsl Gjr4GXlwd9S7kcnI97K0RvA= X-Google-Smtp-Source: ABdhPJy3Z6o3YiBs+6Lolp+IvVcJ1y4/+1SQ2G+ojjITQePGqiiNV2kGlTsYNU5ih684IWcI36A14Q== X-Received: by 2002:a17:906:f1d8:: with SMTP id gx24mr29842741ejb.73.1605830197323; Thu, 19 Nov 2020 15:56:37 -0800 (PST) Received: from localhost.localdomain ([188.24.159.61]) by smtp.gmail.com with ESMTPSA id i3sm452987ejh.80.2020.11.19.15.56.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Nov 2020 15:56:36 -0800 (PST) From: Cristian Ciocaltea To: Rob Herring , =?utf-8?q?Andreas_F=C3=A4rber?= , Manivannan Sadhasivam Subject: [PATCH v2 16/18] arm: dts: owl-s500-roseapplepi: Add uSD support Date: Fri, 20 Nov 2020 01:56:10 +0200 Message-Id: X-Mailer: git-send-email 2.29.2 In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201119_185638_478876_C5449958 X-CRM114-Status: GOOD ( 13.75 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, linux-actions@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Add uSD support for RoseapplePi SBC using a fixed regulator as a temporary solution until PMIC support becomes available. Signed-off-by: Cristian Ciocaltea --- arch/arm/boot/dts/owl-s500-roseapplepi.dts | 50 ++++++++++++++++++++++ 1 file changed, 50 insertions(+) diff --git a/arch/arm/boot/dts/owl-s500-roseapplepi.dts b/arch/arm/boot/dts/owl-s500-roseapplepi.dts index 800edf5d2d12..fe9ae3619422 100644 --- a/arch/arm/boot/dts/owl-s500-roseapplepi.dts +++ b/arch/arm/boot/dts/owl-s500-roseapplepi.dts @@ -14,6 +14,7 @@ / { model = "Roseapple Pi"; aliases { + mmc0 = &mmc0; serial2 = &uart2; }; @@ -25,6 +26,55 @@ memory@0 { device_type = "memory"; reg = <0x0 0x80000000>; /* 2GB */ }; + + /* Fixed regulator used in the absence of PMIC */ + sd_vcc: sd-vcc { + compatible = "regulator-fixed"; + regulator-name = "fixed-3.1V"; + regulator-min-microvolt = <3100000>; + regulator-max-microvolt = <3100000>; + regulator-always-on; + }; +}; + +&pinctrl { + mmc0_pins: mmc0-pins { + pinmux { + groups = "sd0_d0_mfp", "sd0_d1_mfp", "sd0_d2_d3_mfp", + "sd0_cmd_mfp", "sd0_clk_mfp"; + function = "sd0"; + }; + + drv-pinconf { + groups = "sd0_d0_d3_drv", "sd0_cmd_drv", "sd0_clk_drv"; + drive-strength = <8>; + }; + + bias0-pinconf { + pins = "sd0_d0", "sd0_d1", "sd0_d2", + "sd0_d3", "sd0_cmd"; + bias-pull-up; + }; + + bias1-pinconf { + pins = "sd0_clk"; + bias-pull-down; + }; + }; +}; + +/* uSD */ +&mmc0 { + status = "okay"; + pinctrl-names = "default"; + pinctrl-0 = <&mmc0_pins>; + no-sdio; + no-mmc; + no-1-8-v; + cd-gpios = <&pinctrl 117 GPIO_ACTIVE_LOW>; + bus-width = <4>; + vmmc-supply = <&sd_vcc>; + vqmmc-supply = <&sd_vcc>; }; &twd_timer {