Message ID | 20190723073445.23864-3-peng.fan@nxp.com |
---|---|
State | Superseded |
Delegated to: | Stefano Babic |
Headers | show
Return-Path: <u-boot-bounces@lists.denx.de> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=<UNKNOWN>) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=nxp.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=nxp.com header.i=@nxp.com header.b="ExDi8rL9"; dkim-atps=neutral Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 45t8z04bdbz9sBt for <incoming@patchwork.ozlabs.org>; Tue, 23 Jul 2019 17:21:00 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id 42689C21E02; Tue, 23 Jul 2019 07:20:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=SPF_HELO_PASS, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 2D3C4C21CB1; Tue, 23 Jul 2019 07:19:47 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 39D81C21E2C; Tue, 23 Jul 2019 07:19:44 +0000 (UTC) Received: from EUR01-HE1-obe.outbound.protection.outlook.com (mail-eopbgr130057.outbound.protection.outlook.com [40.107.13.57]) by lists.denx.de (Postfix) with ESMTPS id E81A6C21D8E for <u-boot@lists.denx.de>; Tue, 23 Jul 2019 07:19:35 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XYGWdj8lheL12qQXhsWGck+FoBeEl8ZjqBcudTUobkvc3xLjEQRAY9tS5OCWofvFm2ROzoFuwV5eulYL3drxYtOKkUvpIIZLBiq+k9gm7g4kLq/TcuOQmIAYc4UPRZ4g7x1iERcW9XkVrjFFrV1wzsGpgj4Ob3tTVvhX/IkFKG/OaQH4jLUQUyREiPOIikx+VxtQ+d3nVEnnWuhcynifw/fo9wOzQOHElfW3fUuyH7wOQErsN5R0I5Yb0wzYfthyFvsI+V6pUnkEx+c1zgWiWC6fbjM8ChH7tSAGM4KAYozKwQLJYV0XSQAfj0LH4HDmDcozw0qeHzHhcKPhYnhGXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=aw17cLf/jOjFCpioZWbb+dyQEtDHcJy8UvPc82Y9+S8=; b=FU1doyB1XyUsTkm+EXqAm1VcbbunLVPkFgGNgj+R6nq8QeOuHi3F+M4IWSlavpLvXabVEgC8ET+GD6jaXyf2t58Yw9f6kO/K3V/6yOOOTuwE4zJCL0cmuqichsE/QP6ErEj84ne4oI4LOeOjjfS9OAf/vPRs3cFPzCkn9SOCipNDG+fNytpb2ZRX5LMOoYyvR/RuMggzCY1Wg7MxVsVRcilOEKlMo3J1u319ASnCi+UeQOH8SEl9jTl7ugjLAic29xf1wFHYp69pUCm4/OnwTvhlAQLzzwA4iy5RbUjnUBv/VSaUmdMaIccWfV2akob1qGTut3ylL2EDcVrAcDObVQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1;spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com;arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=aw17cLf/jOjFCpioZWbb+dyQEtDHcJy8UvPc82Y9+S8=; b=ExDi8rL9PbFDRUPnWjhl23NjtMgI7ZqJKjT7cE06dA6Bx+Bdha6Wp+pFCbcwE2hiRYutin5Y8zWjaxwRdeV96bMFhlUerWFrUQNUJP0PQKM2czMfedSbg2NfntxuxIUcfPhuvwo82P5OJ7VeG8VTkvtROBfr+ieEJWPoOdmos9I= Received: from AM0PR04MB4481.eurprd04.prod.outlook.com (52.135.147.15) by AM0PR04MB5475.eurprd04.prod.outlook.com (20.178.113.146) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2094.16; Tue, 23 Jul 2019 07:19:34 +0000 Received: from AM0PR04MB4481.eurprd04.prod.outlook.com ([fe80::2023:c0e5:8a63:2e47]) by AM0PR04MB4481.eurprd04.prod.outlook.com ([fe80::2023:c0e5:8a63:2e47%5]) with mapi id 15.20.2094.011; Tue, 23 Jul 2019 07:19:34 +0000 From: Peng Fan <peng.fan@nxp.com> To: "sbabic@denx.de" <sbabic@denx.de>, "festevam@gmail.com" <festevam@gmail.com>, "hs@denx.de" <hs@denx.de>, "joe.hershberger@ni.com" <joe.hershberger@ni.com>, "marex@denx.de" <marex@denx.de> Thread-Topic: [PATCH V2 3/4] usb: mx6: add fuse check Thread-Index: AQHVQSb6M6mErFRwoU2+pljO+QNStA== Date: Tue, 23 Jul 2019 07:19:34 +0000 Message-ID: <20190723073445.23864-3-peng.fan@nxp.com> References: <20190723073445.23864-1-peng.fan@nxp.com> In-Reply-To: <20190723073445.23864-1-peng.fan@nxp.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-mailer: git-send-email 2.16.4 x-clientproxiedby: HK2PR02CA0134.apcprd02.prod.outlook.com (2603:1096:202:16::18) To AM0PR04MB4481.eurprd04.prod.outlook.com (2603:10a6:208:70::15) authentication-results: spf=none (sender IP is ) smtp.mailfrom=peng.fan@nxp.com; x-ms-exchange-messagesentrepresentingtype: 1 x-originating-ip: [119.31.174.71] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 1e94a41c-badf-41c8-77cf-08d70f3e1cf1 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(4618075)(2017052603328)(7193020); SRVR:AM0PR04MB5475; x-ms-traffictypediagnostic: AM0PR04MB5475: x-microsoft-antispam-prvs: <AM0PR04MB54750549DE23F93F6F0D59BF88C70@AM0PR04MB5475.eurprd04.prod.outlook.com> x-ms-oob-tlc-oobclassifiers: OLM:131; x-forefront-prvs: 0107098B6C x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(366004)(396003)(136003)(39860400002)(346002)(376002)(189003)(199004)(6506007)(102836004)(2201001)(186003)(386003)(36756003)(305945005)(1076003)(71190400001)(7736002)(53936002)(99286004)(71200400001)(25786009)(8676002)(2501003)(52116002)(478600001)(76176011)(4326008)(6512007)(446003)(6116002)(68736007)(66066001)(6486002)(8936002)(14454004)(66476007)(66556008)(64756008)(66446008)(44832011)(50226002)(2616005)(476003)(86362001)(6436002)(11346002)(2906002)(81166006)(26005)(316002)(5660300002)(81156014)(66946007)(110136005)(14444005)(54906003)(3846002)(486006)(256004); DIR:OUT; SFP:1101; SCL:1; SRVR:AM0PR04MB5475; H:AM0PR04MB4481.eurprd04.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: tICP9PB3tK+6fXNk+c7vjUTdGJ+Jj1bb1QeRWhrC48o63D8/AflgRlQ4CG3ki/Lpxw5dmxB0+z/P+mXyG+eodO0ZSx+dyRgNgCX0jpylDOR8JYHif30E/xOJgFQgzkOqaIfk/DX6yfxQCeiuAtZfKml8B15IZmjEh2Gx8p/DqIKhbqsYJqtNrZNzKIKISaGXgpnb9W1HlZu/QDHXGjR3mY0C1SpeJtj5B3j/xo//scivq2M97CNfRfQVtB1oC0KQm0pfgdpF7xxJfBLa88pesxvX/YmUZ3vZunvg2ARMMh1V5LWTzVE54iV/tDzmKloj3tfWJRAQyFAyJ8bwzsbCt6V8fHwIZ3FkI66OHKnfcKqI9lDVNPsICCPAjyun3/5asmluBs0dMpPA4+BHZTGTZlhN5fZ7guWWs8cgbZIw7Vw= MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1e94a41c-badf-41c8-77cf-08d70f3e1cf1 X-MS-Exchange-CrossTenant-originalarrivaltime: 23 Jul 2019 07:19:34.8248 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: peng.fan@nxp.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR04MB5475 Cc: "u-boot@lists.denx.de" <u-boot@lists.denx.de>, dl-uboot-imx <uboot-imx@nxp.com> Subject: [U-Boot] [PATCH V2 3/4] usb: mx6: add fuse check X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion <u-boot.lists.denx.de> List-Unsubscribe: <https://lists.denx.de/options/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=unsubscribe> List-Archive: <http://lists.denx.de/pipermail/u-boot/> List-Post: <mailto:u-boot@lists.denx.de> List-Help: <mailto:u-boot-request@lists.denx.de?subject=help> List-Subscribe: <https://lists.denx.de/listinfo/u-boot>, <mailto:u-boot-request@lists.denx.de?subject=subscribe> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" <u-boot-bounces@lists.denx.de> |
Series |
[U-Boot,V2,1/4] imx: add module fuse support
|
expand
|
diff --git a/drivers/usb/host/ehci-mx6.c b/drivers/usb/host/ehci-mx6.c index e9e6ed596d..60b4d1ceb3 100644 --- a/drivers/usb/host/ehci-mx6.c +++ b/drivers/usb/host/ehci-mx6.c @@ -353,6 +353,14 @@ int ehci_hcd_init(int index, enum usb_init_type init, if (index > 3) return -EINVAL; + if (IS_ENABLED(CONFIG_IMX_MODULE_FUSE)) { + if (usb_fused((u32)ehci)) { + printf("SoC fuse indicates USB@0x%x is unavailable.\n", + (u32)ehci); + return -ENODEV; + } + } + ret = ehci_mx6_common_init(ehci, index); if (ret) return ret; @@ -549,6 +557,14 @@ static int ehci_usb_probe(struct udevice *dev) struct ehci_hcor *hcor; int ret; + if (IS_ENABLED(CONFIG_IMX_MODULE_FUSE)) { + if (usb_fused((u32)ehci)) { + printf("SoC fuse indicates USB@0x%x is unavailable.\n", + (u32)ehci); + return -ENODEV; + } + } + priv->ehci = ehci; priv->portnr = dev->seq; priv->init_type = type;
Add fuse check for USB. If the fuse indicates the module will not work in the SoC, let's fail the initialization. Signed-off-by: Peng Fan <peng.fan@nxp.com> --- V2: Update commit and debug info drivers/usb/host/ehci-mx6.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+)