From patchwork Thu Jul 14 02:42:50 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: shaohui xie X-Patchwork-Id: 104626 X-Patchwork-Delegate: galak@kernel.crashing.org Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 95F79B6F65 for ; Thu, 14 Jul 2011 13:54:18 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id C4BC12807D; Thu, 14 Jul 2011 05:54:15 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 97rTZe4dhBYi; Thu, 14 Jul 2011 05:54:15 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E333D2807E; Thu, 14 Jul 2011 05:54:12 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 40C512807E for ; Thu, 14 Jul 2011 05:54:11 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gbGTcWOhZJj4 for ; Thu, 14 Jul 2011 05:54:10 +0200 (CEST) X-Greylist: delayed 907 seconds by postgrey-1.27 at theia; Thu, 14 Jul 2011 05:54:08 CEST X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from DB3EHSOBE004.bigfish.com (db3ehsobe004.messaging.microsoft.com [213.199.154.142]) by theia.denx.de (Postfix) with ESMTPS id 193BA2807D for ; Thu, 14 Jul 2011 05:54:08 +0200 (CEST) Received: from mail40-db3-R.bigfish.com (10.3.81.242) by DB3EHSOBE004.bigfish.com (10.3.84.24) with Microsoft SMTP Server id 14.1.225.22; Thu, 14 Jul 2011 03:39:00 +0000 Received: from mail40-db3 (localhost.localdomain [127.0.0.1]) by mail40-db3-R.bigfish.com (Postfix) with ESMTP id 5BC9B6102E3; Thu, 14 Jul 2011 03:39:00 +0000 (UTC) X-SpamScore: 0 X-BigFish: VS0(zzzz1202hzz8275bhz2dh2a8h668h839h61h) X-Spam-TCS-SCL: 0:0 X-Forefront-Antispam-Report: CIP:70.37.183.190; KIP:(null); UIP:(null); IPVD:NLI; H:mail.freescale.net; RD:none; EFVD:NLI Received: from mail40-db3 (localhost.localdomain [127.0.0.1]) by mail40-db3 (MessageSwitch) id 1310614740245453_25358; Thu, 14 Jul 2011 03:39:00 +0000 (UTC) Received: from DB3EHSMHS018.bigfish.com (unknown [10.3.81.244]) by mail40-db3.bigfish.com (Postfix) with ESMTP id 30495E7805B; Thu, 14 Jul 2011 03:39:00 +0000 (UTC) Received: from mail.freescale.net (70.37.183.190) by DB3EHSMHS018.bigfish.com (10.3.87.118) with Microsoft SMTP Server (TLS) id 14.1.225.22; Thu, 14 Jul 2011 03:38:57 +0000 Received: from az33smr02.freescale.net (10.64.34.200) by 039-SN1MMR1-002.039d.mgd.msft.net (10.84.1.15) with Microsoft SMTP Server id 14.1.289.8; Wed, 13 Jul 2011 22:38:55 -0500 Received: from localhost.localdomain (rock.ap.freescale.net [10.193.20.106]) by az33smr02.freescale.net (8.13.1/8.13.0) with ESMTP id p6E3cr2P028606; Wed, 13 Jul 2011 22:38:54 -0500 (CDT) From: Shaohui Xie To: Date: Thu, 14 Jul 2011 10:42:50 +0800 Message-ID: <1310611370-20652-1-git-send-email-Shaohui.Xie@freescale.com> X-Mailer: git-send-email 1.6.4 MIME-Version: 1.0 X-OriginatorOrg: freescale.com Cc: kumar.gala@freescale.com, Shaohui Xie Subject: [U-Boot] [PATCH] powerpc/85xx: enanle USB2 gadget mode for corenet ds board X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.9 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Signed-off-by: Shaohui Xie --- arch/powerpc/cpu/mpc8xxx/fdt.c | 3 ++- board/freescale/corenet_ds/corenet_ds.c | 1 + include/configs/corenet_ds.h | 2 ++ 3 files changed, 5 insertions(+), 1 deletions(-) diff --git a/arch/powerpc/cpu/mpc8xxx/fdt.c b/arch/powerpc/cpu/mpc8xxx/fdt.c index d9e3e7e..60cb210 100644 --- a/arch/powerpc/cpu/mpc8xxx/fdt.c +++ b/arch/powerpc/cpu/mpc8xxx/fdt.c @@ -164,7 +164,8 @@ void fdt_fixup_dr_usb(void *blob, bd_t *bd) if (mode_idx < 0 && phy_idx < 0) printf("WARNING: invalid phy or mode\n"); } else { - break; + if (i > CONFIG_SYS_USB_DEVICE) + break; } } if (!usb1_defined) { diff --git a/board/freescale/corenet_ds/corenet_ds.c b/board/freescale/corenet_ds/corenet_ds.c index cf9b7b8..b1e7823 100644 --- a/board/freescale/corenet_ds/corenet_ds.c +++ b/board/freescale/corenet_ds/corenet_ds.c @@ -236,6 +236,7 @@ void ft_board_setup(void *blob, bd_t *bd) #endif fdt_fixup_liodn(blob); + fdt_fixup_dr_usb(blob, bd); } int board_eth_init(bd_t *bis) diff --git a/include/configs/corenet_ds.h b/include/configs/corenet_ds.h index c9cc22a..2c86ba3 100644 --- a/include/configs/corenet_ds.h +++ b/include/configs/corenet_ds.h @@ -580,6 +580,8 @@ #define CONFIG_USB_EHCI_FSL #define CONFIG_EHCI_HCD_INIT_AFTER_RESET #define CONFIG_CMD_EXT2 +#define CONFIG_HAS_FSL_DR_USB +#define CONFIG_SYS_USB_DEVICE 2 #define CONFIG_MMC