From patchwork Thu Feb 12 07:37:25 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhangfei Gao X-Patchwork-Id: 5817951 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 5E909BF440 for ; Thu, 12 Feb 2015 07:40:51 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 8D42120160 for ; Thu, 12 Feb 2015 07:40:50 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id BA2B5200F0 for ; Thu, 12 Feb 2015 07:40:49 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1YLoMF-0006Vq-Ri; Thu, 12 Feb 2015 07:38:43 +0000 Received: from mail-pd0-f180.google.com ([209.85.192.180]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1YLoLm-0006FG-1d for linux-arm-kernel@lists.infradead.org; Thu, 12 Feb 2015 07:38:15 +0000 Received: by pdjy10 with SMTP id y10so10188442pdj.6 for ; Wed, 11 Feb 2015 23:37:53 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=X7obCbSeTAzjhHd7R/ISBDg9orlwJ7InrvBWiheFvdI=; b=hsU08cFGhmJkNgZ/dTGMc+q9GNKCQHZNr0w4rSqj+bNsexQY7ASIAK5tOK5bxC8wz9 aX3THD6+H1CeMIJpHTIPd1A7xr9CNu9kcSeJSW24d+pyqTbyBDQdOF41RtV/rouHNseR apDy4c5o1M6nIKRSkGvbMQJ3LKL88NKHfh5GaLe+/TL6IV6yiQyX69AP3zEagjoOYr6H k+jSKURKUG4McwOTIU76mKYKSuTayI7pQ8a8HpnHIamritAl91ru8lNy4SiBHjobL737 UeIsp37R8zgaYcvGiowcQnI0b3o9OMD8BKkYO3qxl82Hh10C/X/fgEoctAhpp0rQGt8D ktNg== X-Gm-Message-State: ALoCoQltXsUYn/eW/IGpKm+FBzqLD/Tqk+UJwMF0IyUHs2cyaBKHHPjztr/oZWUGAil2kTdo/ary X-Received: by 10.68.68.171 with SMTP id x11mr4388218pbt.60.1423726673050; Wed, 11 Feb 2015 23:37:53 -0800 (PST) Received: from linaro.solutionip.com ([210.177.145.245]) by mx.google.com with ESMTPSA id om9sm2844635pbb.34.2015.02.11.23.37.48 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 11 Feb 2015 23:37:51 -0800 (PST) From: Zhangfei Gao To: Kishon Vijay Abraham I , balbi@ti.com, mark.rutland@arm.com, Peter Chen , Sergei Shtylyov , "dan . zhao" , Wangbinghui Subject: [PATCH v4 3/4] usb: dwc2: platform: add hi6220 support Date: Thu, 12 Feb 2015 15:37:25 +0800 Message-Id: <1423726646-30336-4-git-send-email-zhangfei.gao@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1423726646-30336-1-git-send-email-zhangfei.gao@linaro.org> References: <1423726646-30336-1-git-send-email-zhangfei.gao@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150211_233814_192753_376D108F X-CRM114-Status: UNSURE ( 9.11 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.7 (/) Cc: devicetree@vger.kernel.org, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Zhangfei Gao X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_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 Signed-off-by: Zhangfei Gao --- drivers/usb/dwc2/platform.c | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/drivers/usb/dwc2/platform.c b/drivers/usb/dwc2/platform.c index ae095f0..f7c67db 100644 --- a/drivers/usb/dwc2/platform.c +++ b/drivers/usb/dwc2/platform.c @@ -50,6 +50,35 @@ static const char dwc2_driver_name[] = "dwc2"; +static const struct dwc2_core_params params_hi6220 = { + .otg_cap = 2, /* No HNP/SRP capable */ + .otg_ver = 0, /* 1.3 */ + .dma_enable = 1, + .dma_desc_enable = 0, + .speed = 0, /* High Speed */ + .enable_dynamic_fifo = 1, + .en_multiple_tx_fifo = 1, + .host_rx_fifo_size = 512, + .host_nperio_tx_fifo_size = 512, + .host_perio_tx_fifo_size = 512, + .max_transfer_size = 65535, + .max_packet_count = 511, + .host_channels = 16, + .phy_type = 1, /* UTMI */ + .phy_utmi_width = 8, + .phy_ulpi_ddr = 0, /* Single */ + .phy_ulpi_ext_vbus = 0, + .i2c_enable = 0, + .ulpi_fs_ls = 0, + .host_support_fs_ls_low_power = 0, + .host_ls_low_power_phy_clk = 0, /* 48 MHz */ + .ts_dline = 0, + .reload_ctl = 0, + .ahbcfg = GAHBCFG_HBSTLEN_INCR16 << + GAHBCFG_HBSTLEN_SHIFT, + .uframe_sched = 0, +}; + static const struct dwc2_core_params params_bcm2835 = { .otg_cap = 0, /* HNP/SRP capable */ .otg_ver = 0, /* 1.3 */ @@ -129,6 +158,7 @@ static int dwc2_driver_remove(struct platform_device *dev) static const struct of_device_id dwc2_of_match_table[] = { { .compatible = "brcm,bcm2835-usb", .data = ¶ms_bcm2835 }, + { .compatible = "hisilicon,hi6220-usb", .data = ¶ms_hi6220 }, { .compatible = "rockchip,rk3066-usb", .data = ¶ms_rk3066 }, { .compatible = "snps,dwc2", .data = NULL }, { .compatible = "samsung,s3c6400-hsotg", .data = NULL},