Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/401391/?format=api
{ "id": 401391, "url": "http://patchwork.ozlabs.org/api/patches/401391/?format=api", "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/1413880493-3490-2-git-send-email-yao.yuan@freescale.com/", "project": { "id": 18, "url": "http://patchwork.ozlabs.org/api/projects/18/?format=api", "name": "U-Boot", "link_name": "uboot", "list_id": "u-boot.lists.denx.de", "list_email": "u-boot@lists.denx.de", "web_url": null, "scm_url": null, "webscm_url": null, "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<1413880493-3490-2-git-send-email-yao.yuan@freescale.com>", "list_archive_url": null, "date": "2014-10-21T08:34:53", "name": "[U-Boot] ls1021aqds: add hwconfig setting to do pin mux", "commit_ref": null, "pull_url": null, "state": "changes-requested", "archived": false, "hash": "4a1c68b9d8225ca627a65ecaaddb64f9899bc850", "submitter": { "id": 53507, "url": "http://patchwork.ozlabs.org/api/people/53507/?format=api", "name": "Yao Yuan", "email": "yao.yuan@freescale.com" }, "delegate": { "id": 2666, "url": "http://patchwork.ozlabs.org/api/users/2666/?format=api", "username": "yorksun", "first_name": "York", "last_name": "Sun", "email": "yorksun@freescale.com" }, "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/1413880493-3490-2-git-send-email-yao.yuan@freescale.com/mbox/", "series": [], "comments": "http://patchwork.ozlabs.org/api/patches/401391/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/401391/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<u-boot-bounces@lists.denx.de>", "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])\n\tby ozlabs.org (Postfix) with ESMTP id D9FF2140077\n\tfor <incoming@patchwork.ozlabs.org>;\n\tTue, 21 Oct 2014 20:24:04 +1100 (AEDT)", "from localhost (localhost [127.0.0.1])\n\tby theia.denx.de (Postfix) with ESMTP id 4CC4A4B606;\n\tTue, 21 Oct 2014 11:24:01 +0200 (CEST)", "from theia.denx.de ([127.0.0.1])\n\tby localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id UGzLDj7aO6K6; Tue, 21 Oct 2014 11:24:01 +0200 (CEST)", "from theia.denx.de (localhost [127.0.0.1])\n\tby theia.denx.de (Postfix) with ESMTP id BA0D14B5FB;\n\tTue, 21 Oct 2014 11:24:00 +0200 (CEST)", "from localhost (localhost [127.0.0.1])\n\tby theia.denx.de (Postfix) with ESMTP id B3BE84B5FB\n\tfor <u-boot@lists.denx.de>; Tue, 21 Oct 2014 11:07:20 +0200 (CEST)", "from theia.denx.de ([127.0.0.1])\n\tby localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id 0IwIptfBBQ5s for <u-boot@lists.denx.de>;\n\tTue, 21 Oct 2014 11:07:20 +0200 (CEST)", "from na01-bl2-obe.outbound.protection.outlook.com\n\t(mail-bl2on0110.outbound.protection.outlook.com [65.55.169.110])\n\tby theia.denx.de (Postfix) with ESMTPS id 4E8084B5FA\n\tfor <u-boot@lists.denx.de>; Tue, 21 Oct 2014 11:07:16 +0200 (CEST)", "from BY2PR03CA003.namprd03.prod.outlook.com (10.255.93.20) by\n\tBLUPR03MB152.namprd03.prod.outlook.com (10.255.212.28) with Microsoft\n\tSMTP Server (TLS) id 15.0.1054.13; Tue, 21 Oct 2014 08:35:37 +0000", "from BN1BFFO11FD051.protection.gbl (10.255.93.4) by\n\tBY2PR03CA003.outlook.office365.com (10.255.93.20) with Microsoft SMTP\n\tServer (TLS) id 15.0.1054.13 via Frontend Transport;\n\tTue, 21 Oct 2014 08:35:36 +0000", "from tx30smr01.am.freescale.net (192.88.168.50) by\n\tBN1BFFO11FD051.mail.protection.outlook.com (10.58.145.6) with\n\tMicrosoft SMTP\n\tServer (TLS) id 15.0.1049.20 via Frontend Transport; Tue, 21 Oct 2014\n\t08:35:36 +0000", "from titan.ap.freescale.net ([10.192.208.233])\n\tby tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id\n\ts9L8ZV9R008784; Tue, 21 Oct 2014 01:35:34 -0700" ], "X-Greylist": "delayed 1895 seconds by postgrey-1.32 at theia;\n\tTue, 21 Oct 2014 11:07:16 CEST", "X-policyd-weight": "NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5\n\tNOT_IN_BL_NJABL=-1.5 (only DNSBL check requested)", "From": "Yuan Yao <yao.yuan@freescale.com>", "To": "<yorksun@freescale.com>", "Date": "Tue, 21 Oct 2014 16:34:53 +0800", "Message-ID": "<1413880493-3490-2-git-send-email-yao.yuan@freescale.com>", "X-Mailer": "git-send-email 2.1.0.27.g96db324", "In-Reply-To": "<1413880493-3490-1-git-send-email-yao.yuan@freescale.com>", "References": "<1413880493-3490-1-git-send-email-yao.yuan@freescale.com>", "X-EOPAttributedMessage": "0", "X-Forefront-Antispam-Report": "CIP:192.88.168.50; CTRY:US; IPV:CAL; IPV:NLI;\n\tEFV:NLI; SFV:NSPM;\n\tSFS:(10019020)(6009001)(199003)(189002)(87936001)(76176999)(50986999)(85306004)(26826002)(92726001)(89996001)(68736004)(575784001)(19580405001)(93916002)(86362001)(19580395003)(88136002)(21056001)(47776003)(44976005)(6806004)(20776003)(64706001)(46102003)(80022003)(102836001)(4396001)(2371004)(50226001)(85852003)(87286001)(104166001)(62966002)(31966008)(84676001)(50466002)(105606002)(106466001)(110136001)(99396003)(92566001)(76482002)(48376002)(104016003)(95666004)(36756003)(229853001)(97736003)(77156001)(33646002)(2351001)(120916001)(107046002);\n\tDIR:OUT; SFP:1102; SCL:1; SRVR:BLUPR03MB152;\n\tH:tx30smr01.am.freescale.net; FPR:; MLV:ovrnspm;\n\tPTR:InfoDomainNonexistent; A:1; MX:1; LANG:en; ", "MIME-Version": "1.0", "X-Microsoft-Antispam": [ "UriScan:;", "BCL:0;PCL:0;RULEID:;SRVR:BLUPR03MB152;" ], "X-Exchange-Antispam-Report-Test": "UriScan:;", "X-Forefront-PRVS": "0371762FE7", "Received-SPF": "Fail (protection.outlook.com: domain of freescale.com does not\n\tdesignate 192.88.168.50 as permitted sender)\n\treceiver=protection.outlook.com; \n\tclient-ip=192.88.168.50; helo=tx30smr01.am.freescale.net;", "Authentication-Results": "spf=fail (sender IP is 192.88.168.50)\n\tsmtp.mailfrom=yao.yuan@freescale.com; ", "X-OriginatorOrg": "freescale.com", "X-Mailman-Approved-At": "Tue, 21 Oct 2014 11:23:59 +0200", "Cc": "u-boot@lists.denx.de", "Subject": "[U-Boot] [PATCH] ls1021aqds: add hwconfig setting to do pin mux", "X-BeenThere": "u-boot@lists.denx.de", "X-Mailman-Version": "2.1.13", "Precedence": "list", "List-Id": "U-Boot discussion <u-boot.lists.denx.de>", "List-Unsubscribe": "<http://lists.denx.de/mailman/options/u-boot>,\n\t<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": "<http://lists.denx.de/mailman/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>", "Content-Type": "text/plain; charset=\"us-ascii\"", "Content-Transfer-Encoding": "7bit", "Sender": "u-boot-bounces@lists.denx.de", "Errors-To": "u-boot-bounces@lists.denx.de" }, "content": "The Freescale LS1021AQDS share some pins, so Add the hwconfig option\nthat allows the user to choose which the function he wants.\n\nThe main pin mux IP is:\neSDHC, SAI, IIC2, RGMII, CAN, SAI.\n\nSigned-off-by: Yuan Yao <yao.yuan@freescale.com>\n---\n board/freescale/ls1021aqds/ls1021aqds.c | 67 ++++++++++++++++++++++++++++++++-\n include/configs/ls1021aqds.h | 1 +\n 2 files changed, 67 insertions(+), 1 deletion(-)", "diff": "diff --git a/board/freescale/ls1021aqds/ls1021aqds.c b/board/freescale/ls1021aqds/ls1021aqds.c\nindex 12e83f7..9229151 100644\n--- a/board/freescale/ls1021aqds/ls1021aqds.c\n+++ b/board/freescale/ls1021aqds/ls1021aqds.c\n@@ -10,6 +10,7 @@\n #include <asm/arch/immap_ls102xa.h>\n #include <asm/arch/clock.h>\n #include <asm/arch/fsl_serdes.h>\n+#include <hwconfig.h>\n #include <mmc.h>\n #include <fsl_esdhc.h>\n #include <fsl_ifc.h>\n@@ -20,6 +21,11 @@\n DECLARE_GLOBAL_DATA_PTR;\n \n enum {\n+\tMUX_TYPE_CAN,\n+\tMUX_TYPE_IIC2,\n+\tMUX_TYPE_RGMII,\n+\tMUX_TYPE_SAI,\n+\tMUX_TYPE_SDHC,\n \tMUX_TYPE_SD_PCI4,\n \tMUX_TYPE_SD_PC_SA_SG_SG,\n \tMUX_TYPE_SD_PC_SA_PC_SG,\n@@ -157,11 +163,27 @@ int board_early_init_f(void)\n \n int config_board_mux(int ctrl_type)\n {\n-\tu8 reg12;\n+\tu8 reg12, reg14;\n \n \treg12 = QIXIS_READ(brdcfg[12]);\n+\treg14 = QIXIS_READ(brdcfg[14]);\n \n \tswitch (ctrl_type) {\n+\tcase MUX_TYPE_CAN:\n+\t\treg14 = (reg14 & 0xf0) | 0x03;\n+\t\tbreak;\n+\tcase MUX_TYPE_IIC2:\n+\t\treg14 = (reg14 & 0x0f) | 0xa0;\n+\t\tbreak;\n+\tcase MUX_TYPE_RGMII:\n+\t\treg14 = (reg14 & 0xf0) | 0x0;\n+\t\tbreak;\n+\tcase MUX_TYPE_SAI:\n+\t\treg14 = (reg14 & 0xf0) | 0x0c;\n+\t\tbreak;\n+\tcase MUX_TYPE_SDHC:\n+\t\treg14 = (reg14 & 0x0f) | 0x0;\n+\t\tbreak;\n \tcase MUX_TYPE_SD_PCI4:\n \t\treg12 = 0x38;\n \t\tbreak;\n@@ -180,6 +202,7 @@ int config_board_mux(int ctrl_type)\n \t}\n \n \tQIXIS_WRITE(brdcfg[12], reg12);\n+\tQIXIS_WRITE(brdcfg[14], reg14);\n \n \treturn 0;\n }\n@@ -213,6 +236,48 @@ int config_serdes_mux(void)\n \treturn 0;\n }\n \n+int misc_init_r(void)\n+{\n+\tint conflict_flag;\n+\n+\t/* some signals can not enable simultaneous*/\n+\tconflict_flag = 0;\n+\tif (hwconfig(\"sdhc\"))\n+\t\tconflict_flag++;\n+\tif (hwconfig(\"iic2\"))\n+\t\tconflict_flag++;\n+\tif (conflict_flag > 1) {\n+\t\tprintf(\"WARNING: pin conflict !\\n\");\n+\t\treturn 0;\n+\t}\n+\n+\tconflict_flag = 0;\n+\tif (hwconfig(\"rgmii\"))\n+\t\tconflict_flag++;\n+\tif (hwconfig(\"can\"))\n+\t\tconflict_flag++;\n+\tif (hwconfig(\"sai\"))\n+\t\tconflict_flag++;\n+\tif (conflict_flag > 1) {\n+\t\tprintf(\"WARNING: pin conflict !\\n\");\n+\t\treturn 0;\n+\t}\n+\n+\tif (hwconfig(\"can\"))\n+\t\tconfig_board_mux(MUX_TYPE_CAN);\n+\telse if (hwconfig(\"rgmii\"))\n+\t\tconfig_board_mux(MUX_TYPE_RGMII);\n+\telse if (hwconfig(\"sai\"))\n+\t\tconfig_board_mux(MUX_TYPE_SAI);\n+\n+\tif (hwconfig(\"iic2\"))\n+\t\tconfig_board_mux(MUX_TYPE_IIC2);\n+\telse if (hwconfig(\"sdhc\"))\n+\t\tconfig_board_mux(MUX_TYPE_SDHC);\n+\n+\treturn 0;\n+}\n+\n int board_init(void)\n {\n \tstruct ccsr_cci400 *cci = (struct ccsr_cci400 *)CONFIG_SYS_CCI400_ADDR;\ndiff --git a/include/configs/ls1021aqds.h b/include/configs/ls1021aqds.h\nindex bb47813..acb2aed 100644\n--- a/include/configs/ls1021aqds.h\n+++ b/include/configs/ls1021aqds.h\n@@ -326,6 +326,7 @@ unsigned long get_board_ddr_clk(void);\n #define CONFIG_CMDLINE_EDITING\n #define CONFIG_CMD_IMLS\n \n+#define CONFIG_MISC_INIT_R\n #define CONFIG_HWCONFIG\n #define HWCONFIG_BUFFER_SIZE\t\t128\n \n", "prefixes": [ "U-Boot" ] }