From patchwork Thu Feb 5 14:46:59 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zhangfei Gao X-Patchwork-Id: 44463 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-we0-f197.google.com (mail-we0-f197.google.com [74.125.82.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id D390821173 for ; Thu, 5 Feb 2015 14:47:40 +0000 (UTC) Received: by mail-we0-f197.google.com with SMTP id l61sf5722000wev.0 for ; Thu, 05 Feb 2015 06:47:40 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=AoKNBEXXpqCC+p01RO1vNHBojFYm2oopoGrYqNPhMPA=; b=hA68lQZXoWcUuRMH44V/uXNPenHsRJgNcjhZUEFG4Vr/u4oOOgpd7ysdDStdufn7h/ 41p4TV8tnfCTjc1vdUzIkCmYzmBZL9c+vr1jyx2NX7LAYItZ/qtuxZi1HVO7Tsk5z5Ai d+3rNkq/JTQrXNvryQPvWp70JbETrDvui4qze13k2xxpytMpCWnR++yAB7+WiEf+xKbG icp2/zTElS0ekfLmqm3HyHGA5ipInSxyIQ6EPnMKfFafuG7kF9QcGShLZI+n4WrIoSfg 5gGivaP+wKNNRKo5ritEMjlFSGU8SRRQ8kyE+gbvckfa0arM9FS9SxYeeQ+rpbwgeTYb W50g== X-Gm-Message-State: ALoCoQmqOMRV8YZ9dejojqwJmuXphBXdLB/7A44ZU06Aqr9EXoxpxmM7Q9mVhiEhULGDqUaLI1Ie X-Received: by 10.152.10.65 with SMTP id g1mr546363lab.5.1423147660093; Thu, 05 Feb 2015 06:47:40 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.234.5 with SMTP id ua5ls137871lac.68.gmail; Thu, 05 Feb 2015 06:47:39 -0800 (PST) X-Received: by 10.152.88.44 with SMTP id bd12mr3900281lab.86.1423147659957; Thu, 05 Feb 2015 06:47:39 -0800 (PST) Received: from mail-lb0-f176.google.com (mail-lb0-f176.google.com. [209.85.217.176]) by mx.google.com with ESMTPS id v4si4139892lav.14.2015.02.05.06.47.39 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 05 Feb 2015 06:47:39 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.176 as permitted sender) client-ip=209.85.217.176; Received: by mail-lb0-f176.google.com with SMTP id w7so3551393lbi.7 for ; Thu, 05 Feb 2015 06:47:39 -0800 (PST) X-Received: by 10.112.114.230 with SMTP id jj6mr352897lbb.112.1423147659529; Thu, 05 Feb 2015 06:47:39 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.35.133 with SMTP id h5csp1186340lbj; Thu, 5 Feb 2015 06:47:38 -0800 (PST) X-Received: by 10.66.146.39 with SMTP id sz7mr5256217pab.59.1423147656953; Thu, 05 Feb 2015 06:47:36 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id rn9si6284062pbc.203.2015.02.05.06.47.35; Thu, 05 Feb 2015 06:47:36 -0800 (PST) Received-SPF: none (google.com: linux-usb-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757862AbbBEOrd (ORCPT + 4 others); Thu, 5 Feb 2015 09:47:33 -0500 Received: from mail-pd0-f172.google.com ([209.85.192.172]:45267 "EHLO mail-pd0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757718AbbBEOrc (ORCPT ); Thu, 5 Feb 2015 09:47:32 -0500 Received: by pdbnh10 with SMTP id nh10so5562728pdb.12 for ; Thu, 05 Feb 2015 06:47:32 -0800 (PST) X-Received: by 10.68.135.37 with SMTP id pp5mr6034971pbb.105.1423147652332; Thu, 05 Feb 2015 06:47:32 -0800 (PST) Received: from localhost.localdomain (119.81.172.112-static.reverse.softlayer.com. [119.81.172.112]) by mx.google.com with ESMTPSA id rb3sm5353511pab.29.2015.02.05.06.47.26 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 05 Feb 2015 06:47:31 -0800 (PST) From: Zhangfei Gao To: balbi@ti.com, john.youn@synopsys.com, Mian Yousaf Kaukab , "dan . zhao" Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-usb@vger.kernel.org, Zhangfei Gao Subject: [PATCH 3/4] usb: dwc2: platform: add hi6220 support Date: Thu, 5 Feb 2015 22:46:59 +0800 Message-Id: <1423147620-5760-4-git-send-email-zhangfei.gao@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1423147620-5760-1-git-send-email-zhangfei.gao@linaro.org> References: <1423147620-5760-1-git-send-email-zhangfei.gao@linaro.org> Sender: linux-usb-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-usb@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: zhangfei.gao@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.176 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Signed-off-by: Zhangfei Gao --- drivers/usb/dwc2/platform.c | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/drivers/usb/dwc2/platform.c b/drivers/usb/dwc2/platform.c index ae095f0..ceee385 100644 --- a/drivers/usb/dwc2/platform.c +++ b/drivers/usb/dwc2/platform.c @@ -50,6 +50,34 @@ 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 = 0x7 << GAHBCFG_HBSTLEN_SHIFT, /* INCR16 */ + .uframe_sched = 0, +}; + static const struct dwc2_core_params params_bcm2835 = { .otg_cap = 0, /* HNP/SRP capable */ .otg_ver = 0, /* 1.3 */ @@ -129,6 +157,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},