Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3692430ybb; Tue, 31 Mar 2020 10:05:21 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuzLdbQ7QnM8iZaSD8pAbuFsPGbz7j393wBA19UESmlIQRtZAv7ipfRJBEFeCPvtoWObTg9 X-Received: by 2002:aca:130f:: with SMTP id e15mr2670893oii.160.1585674321615; Tue, 31 Mar 2020 10:05:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585674321; cv=none; d=google.com; s=arc-20160816; b=AYv7RnyEJ33WZISe36vNcUmctE0DqbaNWXCjhctZumF3jQBoiK6xew+jCZApo6ou++ tnHaU0+6Q0cSi5K6uAipHdtjGEi9a1Q4MiuLm5VmsI8OcUrrV4wWI0ih/UU8/YjQqU5S jhWHz+7vY0tm6ZFXksQ8jxmVNoX5RkuZ6lo1xoASb0A43Tf951EggHE1rGKQiCDyXXEY MkTI8t9hAnuBExn9QuqwERcWKx4fP6mm7hGvzQtGBeN9KOd/L43A5djwdEqRrEv7Ok0q BTpxMYLNcY3jC6aiYkvJ4hiWvffuJXUMRn1kTyvbUSCRZyKlpV3+vML6zC3mfKeAArCQ Q2eg== 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=j9UnDZyQ2YKPggbhoniPAeDPe2uWjAaBSRBm1Rfex5E=; b=epu14FuE1mPRW/wyrk5B88h0jKR6G5WWO5/B21ZSVadlXpfCoQYtQUeWGeoQGk0rje mHWG9FtsemkkVONHNWB/qM8aciX4jAes5iXc0EUJBSDRje+rUXXTL3kent4i5u9B1vGJ qz6b6Uqi5QqiyD0gCuwl1obmrnvKoEtIrwmohDct6XNaFDhIJAKoKsL4X0F1Z/TW6jXl pb0WPn1YKnDOKXhVBVUJQLAdqc1DZ4E1HGFIlkDqL0wphBQDa6QPWmM68iow0SyZOGOh Fkjh+Y+54mxTkmFX7wA815d/OrKTTaPoikvML9zZetrbnJOp7uFr1NvL5yYHV/OJsRW3 rj2A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="iOq/MgcB"; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k21si2791698oik.231.2020.03.31.10.05.05; Tue, 31 Mar 2020 10:05:21 -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=@gmail.com header.s=20161025 header.b="iOq/MgcB"; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731291AbgCaRCc (ORCPT + 99 others); Tue, 31 Mar 2020 13:02:32 -0400 Received: from mail-ot1-f68.google.com ([209.85.210.68]:43202 "EHLO mail-ot1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731224AbgCaRCa (ORCPT ); Tue, 31 Mar 2020 13:02:30 -0400 Received: by mail-ot1-f68.google.com with SMTP id a6so22752276otb.10; Tue, 31 Mar 2020 10:02:30 -0700 (PDT) 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=j9UnDZyQ2YKPggbhoniPAeDPe2uWjAaBSRBm1Rfex5E=; b=iOq/MgcBbSipwpL2n98Yk5g1vneSS5GA3tyBB69AbUUL5cNdEcOnw2MeATbdsbXuPa q51MWnepSfz4AUMlY558zD6fcHf/6wVH/QlYdH/68WRgQCEc9lS1is6B2QZD5Mh6vr3i hes/yYhQ8QzoKYlEsOa6tG7ZLh18RpmgwgYS5UUwM4erDxteM1dktc1Bx8ynD030JWVX vKePHvx7M7ZOhOBmHOA74xux6fdXR+5/xAI/6wVckRj4fEVNihE3dwP1nR4Xo6pjr3x1 N6zbgzjaKWMXiZL/ovbynVMSYl0Zu8Vz39FNjPEXCvLsOKNA9s4YB671aHX9QfC7obaD O0Sw== 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=j9UnDZyQ2YKPggbhoniPAeDPe2uWjAaBSRBm1Rfex5E=; b=gfjdg/8Kz+pZnlHv7g4rQ3FHdaP2fjYE4CD69kwSZhQLyoPeyQX6GIGwExK6AXzKDp lu29BDlm7gRC8KF8eRIxw6LvsdE6V+Ubylp0zeLAkSpw09i8UEkZvkydx/+AyEySefHv ZgiXpBwflhODZc6YM6Thdwas+9utLQutch/BKHAJbeXZ8QkjXB5JKNsvTuSPzfzAMSWQ h1OSYe1f5/+RCqe+oiR3Iq/bvSlCwoAYQ00Ex0YL5VEAT8SYGxuxfRDD4d5fekA1R1ZE JkYJBAdK8uM4vUED/KVm2UubigKaDRhY8mcgNlcPYdNs2GhV39u7RAtC4YHBEQhvX4N5 OCkA== X-Gm-Message-State: ANhLgQ15/7+8iFqp9xrr/0OmyWPjF/dafRmvOZL/Kz0mkEmlU7amDeq5 KY6NCmDaceV8pCQIQJV6wJE= X-Received: by 2002:a05:6830:1d90:: with SMTP id y16mr14257426oti.157.1585674149603; Tue, 31 Mar 2020 10:02:29 -0700 (PDT) Received: from desertvoice.lan ([2601:3c7:8303:2a10::21c]) by smtp.gmail.com with ESMTPSA id h7sm2952605otk.3.2020.03.31.10.02.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 31 Mar 2020 10:02:29 -0700 (PDT) From: George Hilliard To: Chen-Yu Tsai , Rob Herring , Mark Rutland Cc: Icenowy Zheng , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, George Hilliard Subject: [PATCH v2 2/5] phy: sun4i-usb: add support for the USB PHY on suniv SoC Date: Tue, 31 Mar 2020 12:02:16 -0500 Message-Id: <20200331170219.267732-3-thirtythreeforty@gmail.com> X-Mailer: git-send-email 2.26.0 In-Reply-To: <20200331170219.267732-1-thirtythreeforty@gmail.com> References: <20200331170219.267732-1-thirtythreeforty@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Icenowy Zheng The suniv SoC has one USB OTG port connected to a MUSB controller. Add support for its USB PHY. Signed-off-by: Icenowy Zheng George Hilliard: changed style to match existing code. Signed-off-by: George Hilliard --- v1..v2: reordered sun{50,iv} to match `sort` order. drivers/phy/allwinner/phy-sun4i-usb.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/drivers/phy/allwinner/phy-sun4i-usb.c b/drivers/phy/allwinner/phy-sun4i-usb.c index 856927382248..5c10b55f2aad 100644 --- a/drivers/phy/allwinner/phy-sun4i-usb.c +++ b/drivers/phy/allwinner/phy-sun4i-usb.c @@ -107,6 +107,7 @@ enum sun4i_usb_phy_type { sun8i_v3s_phy, sun50i_a64_phy, sun50i_h6_phy, + suniv_f1c100s_phy, }; struct sun4i_usb_phy_cfg { @@ -972,6 +973,14 @@ static const struct sun4i_usb_phy_cfg sun50i_h6_cfg = { .missing_phys = BIT(1) | BIT(2), }; +static const struct sun4i_usb_phy_cfg suniv_f1c100s_cfg = { + .num_phys = 1, + .type = suniv_f1c100s_phy, + .disc_thresh = 3, + .phyctl_offset = REG_PHYCTL_A10, + .dedicated_clocks = true, +}; + static const struct of_device_id sun4i_usb_phy_of_match[] = { { .compatible = "allwinner,sun4i-a10-usb-phy", .data = &sun4i_a10_cfg }, { .compatible = "allwinner,sun5i-a13-usb-phy", .data = &sun5i_a13_cfg }, @@ -986,6 +995,7 @@ static const struct of_device_id sun4i_usb_phy_of_match[] = { { .compatible = "allwinner,sun50i-a64-usb-phy", .data = &sun50i_a64_cfg}, { .compatible = "allwinner,sun50i-h6-usb-phy", .data = &sun50i_h6_cfg }, + { .compatible = "allwinner,suniv-f1c100s-usb-phy", .data = &suniv_f1c100s_cfg }, { }, }; MODULE_DEVICE_TABLE(of, sun4i_usb_phy_of_match); -- 2.26.0