Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp846194pxb; Fri, 22 Apr 2022 12:27:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxEwI+NMkshqYbr9UTSxvrzBwVGCGAbB6vlge7dlv6Be4XPli7BsisHAPL1tP/MXnHxmcrV X-Received: by 2002:a17:90b:1bd2:b0:1d2:9340:d02b with SMTP id oa18-20020a17090b1bd200b001d29340d02bmr17861886pjb.1.1650655642344; Fri, 22 Apr 2022 12:27:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650655642; cv=none; d=google.com; s=arc-20160816; b=0+hlxvjlEzTgebxiqpfCceSi+uWGnJ43MB/CMCCkQ+gJ5ufkJc990wlscy5rUIyvag RcyPC7xeMUVsWh7XVxnNqyxOA/ZKjTD/rUkj9yQ2prrii9LrQewC/4kMJ7zYlrO/ZyWw 24o1YcVYGqejITvq37oWuFKiAwQkZeDwvCfhzS0tODJtIBXq1V0H0MCsUXoZpjIxL59e ClJNBmipTEEX+A6erYK3W5jxTRm/w9XziieC/Zq0uqgVgiKBFOVFf/A0K+vLRTm4v8Dz pEA+dMF1KQJixEAli7O2ULSgqjMpt/sOVUCwpX6iCmR2zvdD+cZp3jjQc35sc6fB2Hbu 9f3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=EuaL7JEQDpvToC0Cm51ew7pmUpFEcOvUA3jwfhr9EhE=; b=l9eiIyKc0Rjz+3jl33U8tAHKw5aUW0PyBOKWl54akNdJBRaJBAeOtWsIs9sxaDNUQ5 /sWMzPAe92qtEa49/qjt9jtJQOxcCsQZ0adAzBk2RW3G3Is6vhoMzxf9TKQwKWTtk6Ur wOnDTAbEv1F4hmuJLjffRw69206II47QQ8uzqF5m6s9CJZL+bEats8ZyzTXkYzQcwqJm y1KF8eVfW7yzJZwBbEWrziVPXmcBAOFwwi9Q61FKE2Qg6DRUe61IEKjLVpYVFnlCWQxJ PHEw6mTszzbsTQEkkAur7x87MlR5h156RUqdLzoYayHob5KPu4l1Kr9VFqZN1ylk3cx4 RKPA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=D4oyNGqb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id l20-20020a17090ac59400b001d286a9cc6dsi11581578pjt.54.2022.04.22.12.27.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Apr 2022 12:27:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=D4oyNGqb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id EBA291D388F; Fri, 22 Apr 2022 11:38:29 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1385815AbiDUHhw (ORCPT + 99 others); Thu, 21 Apr 2022 03:37:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58794 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1385791AbiDUHhl (ORCPT ); Thu, 21 Apr 2022 03:37:41 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6483F1EA; Thu, 21 Apr 2022 00:34:52 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 2B74CB82297; Thu, 21 Apr 2022 07:34:51 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 36852C385A1; Thu, 21 Apr 2022 07:34:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1650526489; bh=Kin58/D9rBGPYeU7vdp0KoxJSMLdV86dYDxrjs2mWTs=; h=From:To:Cc:Subject:Date:From; b=D4oyNGqbn3hpT5aW7wal6OkmWXo2Cwua9G/+HCjZlCcBvelUwHHhq/FqsO6ts5+tY 2qml5Q61vnK2VSCi2Ol3bRvbAMjUVN9nhg/7H++b+RL1TsYdLna7CirQ4hagpf8bq1 OsVwAZQvMS9PQU00CNpZh5AK2RZ2VJvBbFVfTNtlP5fnoDES6pNx1oO/ENTALvafiz uP+pfoeNQuR0Evg5KZjc6rnb3KNGPaljiiETTSDe+OZTbT+B2d08J0XB/3K/9YgJBP 1CB9WP9n92AvMrTr/z7tcmfPe97J/J93JnbmC2QSurKaG9Xfm6DEcALjW0tVeUFu1p IO5HCYFuUcQxw== From: Vinod Koul To: Bjorn Andersson Cc: linux-arm-msm@vger.kernel.org, Vinod Koul , Rob Herring , Krzysztof Kozlowski , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Manivannan Sadhasivam Subject: [PATCH v3] arm64: dts: qcom: db845c: Add support for MCP2517FD Date: Thu, 21 Apr 2022 13:04:38 +0530 Message-Id: <20220421073438.1824061-1-vkoul@kernel.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RDNS_NONE,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add support for onboard MCP2517FD SPI CAN transceiver attached to SPI0 of RB3. Signed-off-by: Vinod Koul --- Change in v3: - change underscore(_) to dash (-) in can-clock node name - remove superfluous status = okay in can node Changes in v2: - add cs and pinctrl config - remove misleading comment arch/arm64/boot/dts/qcom/sdm845-db845c.dts | 32 ++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/arch/arm64/boot/dts/qcom/sdm845-db845c.dts b/arch/arm64/boot/dts/qcom/sdm845-db845c.dts index 28fe45c5d516..d2ade684703d 100644 --- a/arch/arm64/boot/dts/qcom/sdm845-db845c.dts +++ b/arch/arm64/boot/dts/qcom/sdm845-db845c.dts @@ -28,6 +28,13 @@ chosen { stdout-path = "serial0:115200n8"; }; + /* Fixed crystal oscillator dedicated to MCP2517FD */ + clk40M: can-clock { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-frequency = <40000000>; + }; + dc12v: dc12v-regulator { compatible = "regulator-fixed"; regulator-name = "DC12V"; @@ -746,6 +753,23 @@ codec { }; }; +&spi0 { + status = "okay"; + pinctrl-names = "default"; + pinctrl-0 = <&qup_spi0_default>; + cs-gpios = <&tlmm 3 GPIO_ACTIVE_LOW>; + + can@0 { + compatible = "microchip,mcp2517fd"; + reg = <0>; + clocks = <&clk40M>; + interrupts-extended = <&tlmm 104 IRQ_TYPE_LEVEL_LOW>; + spi-max-frequency = <10000000>; + vdd-supply = <&vdc_5v>; + xceiver-supply = <&vdc_5v>; + }; +}; + &spi2 { /* On Low speed expansion */ label = "LS-SPI0"; @@ -1219,3 +1243,11 @@ ov7251_ep: endpoint { }; }; }; + +/* PINCTRL - additions to nodes defined in sdm845.dtsi */ +&qup_spi0_default { + config { + drive-strength = <6>; + bias-disable; + }; +}; -- 2.34.1