aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/fm
AgeCommit message (Collapse)AuthorFilesLines
2020-04-17net: fm: fix build error when not using nandFrancois Gervais1-0/+2
If CONFIG_CMD_NAND is disabled, get_nand_dev_by_index() is not accessible. This fix allows the build to succeed in this case. Signed-off-by: Francois Gervais <fgervais@distech-controls.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2020-03-30armv8/ls1046ardb: RGMII ports require internal delayMadalin Bucur1-2/+2
The correct setting for the RGMII ports on LS1046ARDB is to enable delay on both Rx and Tx so the interface mode used must be PHY_INTERFACE_MODE_RGMII_ID. There is a pull-up that turns on Rx internal delay by default and the u-boot does not override that (yet) so in u-boot the interface is functional. In Linux the PHY driver is clearing the Rx delay for the "rgmii-txid" mode and the reception does not work. Changing the RGMII mode to internal delay here ensures that device tree fix-ups for the PHY connection type turn on both Tx and Rx internal delay in Linux. Fixes: cc1aa218f510 ("armv8/ls1046a: RGMII PHY requires internal delay on Tx") Signed-off-by: Madalin Bucur <madalin.bucur@oss.nxp.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2020-03-30armv8/ls1043ardb: RGMII ports require internal delayMadalin Bucur1-2/+2
The correct setting for the RGMII ports on LS1043ARDB is to enable delay on both Rx and Tx so the interface mode used must be PHY_INTERFACE_MODE_RGMII_ID. There is a pull-up that turns on Rx internal delay by default and the u-boot does not override that (yet) so in u-boot the interface is functional. In Linux the PHY driver is clearing the Rx delay for the "rgmii-txid" mode and the reception does not work. Changing the RGMII mode to internal delay here ensures that device tree fix-ups for the PHY connection type turn on both Tx and Rx internal delay in Linux. Fixes: 5a78a472f666 ("armv8/ls1043a: RGMII PHY requires internal delay on Tx") Signed-off-by: Madalin Bucur <madalin.bucur@oss.nxp.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2020-03-30net: fman: add support for all RGMII delay modesMadalin Bucur1-0/+4
The RGMII modes that include internal delay were not all properly treated in the memac code. Add support for all RGMII delay modes. Fixes: 111fd19e3b9e ("fm/mEMAC: add mEMAC frame work") Signed-off-by: Madalin Bucur <madalin.bucur@oss.nxp.com> Reviewed-by: Priyanka Jain <priyanka.jain@nxp.com>
2019-12-02crc32: Use the crc.h header for crc functionsSimon Glass2-0/+2
Drop inclusion of crc.h in common.h and use the correct header directly instead. With this we can drop the conflicting definition in fw_env.h and rely on the crc.h header, which is already included. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
2019-08-11env: Drop environment.h header file where not neededSimon Glass1-1/+0
This header file is now only used by files that access internal environment features. Drop it from various places where it is not needed. Acked-by: Joe Hershberger <joe.hershberger@ni.com> Signed-off-by: Simon Glass <sjg@chromium.org>
2019-08-11env: Move env_get() to env.hSimon Glass1-0/+1
Move env_get() over to the new header file. Acked-by: Joe Hershberger <joe.hershberger@ni.com> Signed-off-by: Simon Glass <sjg@chromium.org>
2019-08-11env: Move env_set_hex() to env.hSimon Glass1-0/+1
Move env_set_hex() over to the new header file along with env_set_addr() which uses it. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2019-08-11env: Move env_get_f() to env.hSimon Glass1-0/+1
Move this function over to the new header file. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2019-05-26configs: Migrate CONFIG_FMAN_ENET and some related options to KconfigTom Rini1-1/+1
Move the main symbol for Freescale Fman Ethernet controller option to Kconfig. Also migrate the CONFIG_SYS_QE_FMAN_FW_IN_xxx macros and rename the SPIFLASH one to follow the same format as all of the others. To do this fully we need to migrate CONFIG_QC, do so. Signed-off-by: Tom Rini <trini@konsulko.com>
2018-12-06net: fm: add TFABOOT supportRajesh Bhagat1-3/+100
Adds TFABOOT support and allows to pick FMAN firmware on basis of boot source. Signed-off-by: Pankit Garg <pankit.garg@nxp.com> Signed-off-by: Rajesh Bhagat <rajesh.bhagat@nxp.com> [YS: fix checkpatch issues] Reviewed-by: York Sun <york.sun@nxp.com>
2018-10-29powerpc: t1040: Correct RCW EC2 settingsBin Meng1-3/+0
Per T1040RM (Rev. 1, 08/2015), there are 2 issues with the RCW EC2 settings. - The value of FSL_CORENET_RCWSR13_EC2_FM1_GPIO is wrong and should be 0x04000000 (value of 1 in RCW bit [420:421]) - Value of 2/3 are reserved in RCW bit [420:421], hence there is no macro FSL_CORENET_RCWSR13_EC2_FM1_DTSEC5_MII. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Acked-by: Poonam Aggrwal <poonam.aggrwal@nxp.com> Reviewed-by: York Sun <york.sun@nxp.com>
2018-09-27net: fman: Support both new and legacy FMan CompatiblesZhao Qiang1-1/+2
Recently the FMan Port and MAC compatibles were changed. This patch aligns the FMan Port and MAC compatibles to the new FMan device tree binding document. The FMan device tree binding document can be found in the Linux kernel version 3.18.0, commit 297d35fd2a7d3fbd4e5c0f0c1c18213117ba11ba ./Documentation/devicetree/bindings/powerpc/fsl/fman.txt This patch doesn't affect legacy compatibles support. Signed-off-by: Zhao Qiang <qiang.zhao@nxp.com> [York S: reformatted commit message] Reviewed-by: York Sun <york.sun@nxp.com>
2018-09-27ppa/fm/qe: use block layer in ppa/fm/qe driverYinbo Zhu1-1/+1
At present the MMC subsystem maintains its own list of MMC devices. This cannot work with driver model when CONFIG_BLK is enabled, use blk_dread to replace previous mmc read interface, use mmc_get_blk_desc to get the mmc device property. Signed-off-by: Yinbo Zhu <yinbo.zhu@nxp.com> [York S: reformatted commit message] Reviewed-by: York Sun <york.sun@nxp.com>
2018-05-07SPDX: Convert all of our single license tags to Linux Kernel styleTom Rini22-45/+22
When U-Boot started using SPDX tags we were among the early adopters and there weren't a lot of other examples to borrow from. So we picked the area of the file that usually had a full license text and replaced it with an appropriate SPDX-License-Identifier: entry. Since then, the Linux Kernel has adopted SPDX tags and they place it as the very first line in a file (except where shebangs are used, then it's second line) and with slightly different comment styles than us. In part due to community overlap, in part due to better tag visibility and in part for other minor reasons, switch over to that style. This commit changes all instances where we have a single declared license in the tag as both the before and after are identical in tag contents. There's also a few places where I found we did not have a tag and have introduced one. Signed-off-by: Tom Rini <trini@konsulko.com>
2017-09-15blk: Remove various places that do flush cache after readBin Meng1-2/+0
All these places seem to inherit the codes from the MMC driver where a FIXME was put in the comment. However the correct operation after read should be cache invalidate, not flush. The underlying drivers should be responsible for the cache operation. Remove these codes completely. Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Stefan Roese <sr@denx.de> Reviewed-by: York Sun <york.sun@nxp.com> Reviewed-by: Joe Hershberger <joe.hershberger@ni.com> Reviewed-by: Simon Glass <sjg@chromium.org> Tested-by: York Sun <york.sun@nxp.com>
2017-08-16env: Rename getenv/_f() to env_get()Simon Glass2-2/+2
We are now using an env_ prefix for environment functions. Rename these two functions for consistency. Also add function comments in common.h. Quite a few places use getenv() in a condition context, provoking a warning from checkpatch. These are fixed up in this patch also. Suggested-by: Wolfgang Denk <wd@denx.de> Signed-off-by: Simon Glass <sjg@chromium.org>
2017-08-16env: Rename common functions related to setenv()Simon Glass1-1/+1
We are now using an env_ prefix for environment functions. Rename these commonly used functions, for consistency. Also add function comments in common.h. Suggested-by: Wolfgang Denk <wd@denx.de> Signed-off-by: Simon Glass <sjg@chromium.org>
2017-08-14net: fman: add support RGMII_TXID to memacMadalin Bucur1-1/+3
Signed-off-by: Madalin Bucur <madalin.bucur@nxp.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2017-07-11net: fm: use get_nand_dev_by_index()Grygorii Strashko1-1/+2
As part of preparation for nand DM conversion the new API has been introduced to remove direct access to nand_info array. So, use it here instead of accessing to nand_info array directly. Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Reviewed-by: Joe Hershberger <joe.hershberger@ni.com>
2017-06-02armv8/ls1046a: RGMII PHY requires internal delay on TxMadalin Bucur1-2/+2
Signed-off-by: Madalin Bucur <madalin.bucur@nxp.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2017-06-02armv8/ls1043a: RGMII PHY requires internal delay on TxMadalin Bucur1-2/+2
Signed-off-by: Madalin Bucur <madalin.bucur@nxp.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2017-04-17armv8: ls1043a: Drop macro CONFIG_LS1043AYork Sun1-1/+1
Use CONFIG_ARCH_LS1043A instead. Signed-off-by: York Sun <york.sun@nxp.com>
2017-01-04powerpc: mpc85xx: Remove variant SoCs T1020/T1022/T1013/T1014York Sun1-2/+0
Remove these SoCs from Kconfig because they don't have individual configuration. Clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-12-08net: fman: fix 2.5G SGMII settingsshaohui xie2-10/+24
The settings for 2.5G SGMII are wrong, which the 2.5G case is missed in set_if_mode(), and the serdes PCS configuration are wrong, this patch uses the correct settings took from Linux. Signed-off-by: Shaohui Xie <Shaohui.Xie@nxp.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2016-11-23powerpc: T4080: Drop configuration for T4080York Sun1-1/+0
There is no T4080 target. Drop related macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: T4240: Remove macro CONFIG_PPC_T4240York Sun1-1/+1
Use CONFIG_ARCH_T4240 from Kconfig instead. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: T4160: Remove macro CONFIG_PPC_T4160York Sun1-1/+1
Use CONFIG_ARCH_T4160 instead. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: T2080, T2081: Remove macro CONFIG_PPC_T2080 and CONFIG_PPC_T2081York Sun1-2/+2
Use CONFIG_ARCH_T2080 and CONFIG_ARCH_T2081 instead. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: T1042: Remove macro CONFIG_PPC_T1042York Sun1-1/+1
Replace CONFIG_PPC_T1042 with ARCH_T1024 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: T1040: Remove macro CONFIG_PPC_T1040York Sun1-1/+1
Replace CONFIG_PPC_T1040 with ARCH_T1040 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: T1024: Remove macro CONFIG_PPC_T1024York Sun1-1/+1
Replace CONFIG_PPC_T1024 with ARCH_T1024 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: T1023: Remove macro CONFIG_PPC_T1023York Sun1-1/+1
Replace CONFIG_PPC_T1023 with ARCH_T1023 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: B4420: Remove macro CONFIG_PPC_B4420York Sun1-1/+1
Replace CONFIG_PPC_B4420 with ARCH_B4420 in Kconfig and clean up existing macros.
2016-11-23powerpc: B4860QDS: Remove macro CONFIG_B4860QDSYork Sun1-3/+4
Use CONFIG_TARGET_B4860QDS instead. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: B4860: Remove macro CONFIG_PPC_B4860York Sun1-1/+1
Replace CONFIG_PPC_B4860 with ARCH_B4860 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: P5040: Remove macro CONFIG_P5040York Sun1-1/+1
Replace CONFIG_P5040 with ARCH_P5040 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: P5020: Remove macro CONFIG_PPC_P5020York Sun1-1/+1
Replace CONFIG_PPC_P5020 with ARCH_P5020 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: P4080: Remove macro CONFIG_PPC_P4080York Sun1-1/+1
Replace CONFIG_PPC_P4080 with ARCH_P4080 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: P3041: Remove macro CONFIG_PPC_P3041York Sun1-1/+1
Replace CONFIG_PPC_P3041 with ARCH_P3041 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: P2041: Remove macro CONFIG_PPC_P2041York Sun1-1/+1
Replace CONFIG_PPC_P2041 with ARCH_P2041 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: P1017: Drop configuration for P1017York Sun2-2/+1
P1017 is a single-core version of P1023. There is no P1017 target configured. Drop related macros. P1017 SoC is still supported. Signed-off-by: York Sun <york.sun@nxp.com>
2016-11-23powerpc: P1023: Remove macro CONFIG_P1023York Sun2-2/+2
Replace CONFIG_P1023 with ARCH_P1023 in Kconfig and clean up existing macros. Signed-off-by: York Sun <york.sun@nxp.com>
2016-09-26Merge git://git.denx.de/u-boot-fsl-qoriqTom Rini2-1/+11
trini: Drop local memset() from examples/standalone/mem_to_mem_idma2intr.c Signed-off-by: Tom Rini <trini@konsulko.com>
2016-09-26armv8: ls1046a: Convert CONFIG_LS1046A to Kconfig option ARCH_LS1046AYork Sun1-1/+1
Move this option to Kconfig and clean up existing uses. Signed-off-by: York Sun <york.sun@nxp.com> CC: Mingkai Hu <mingkai.hu@nxp.com> CC: Gong Qianyu <Qianyu.Gong@nxp.com> Reviewed-by: Tom Rini <trini@konsulko.com>
2016-09-23treewide: replace #include <asm/errno.h> with <linux/errno.h>Masahiro Yamada1-1/+1
Now, arch/${ARCH}/include/asm/errno.h and include/linux/errno.h have the same content. (both just wrap <asm-generic/errno.h>) Replace all include directives for <asm/errno.h> with <linux/errno.h>. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> [trini: Fixup include/clk.] Signed-off-by: Tom Rini <trini@konsulko.com>
2016-09-14net: fm: fix spi flash probe for using driver modelQianyu Gong1-0/+10
The current code would always use the speed and mode set by CONFIG_ENV_SPI_MAX_HZ and CONFIG_ENV_SPI_MODE. But if using SPI driver model it should get the values from DT. Signed-off-by: Gong Qianyu <Qianyu.Gong@nxp.com> Reviewed-by: Jagan Teki <jteki@openedev.com> Reviewed-by: Joe Hershberger <joe.hershberger@ni.com> Reviewed-by: York Sun <york.sun@nxp.com>
2016-08-22net/fm: Remove unused code of FMan QMIHou Zhiqiang1-3/+0
The QMan is not used in FMan IM mode, so no QMI enqueue or QMI dequeue are performed. Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
2016-07-26drivers: net/fm: Add Fman support for LS1046AMingkai Hu2-0/+124
The Fman module on LS1046A is similiar with that on LS1043A but LS1046A has one more XFI (10GbE) interface. Signed-off-by: Shaohui Xie <Shaohui.Xie@nxp.com> Signed-off-by: Mingkai Hu <mingkai.hu@nxp.com> Signed-off-by: Gong Qianyu <Qianyu.Gong@nxp.com> Reviewed-by: York Sun <york.sun@nxp.com>
2016-06-03nand: Embed mtd_info in struct nand_chipScott Wood1-1/+1
nand_info[] is now an array of pointers, with the actual mtd_info instance embedded in struct nand_chip. This is in preparation for syncing the NAND code with Linux 4.6, which makes the same change to struct nand_chip. It's in a separate commit due to the large amount of changes required to accommodate the change to nand_info[]. Signed-off-by: Scott Wood <oss@buserror.net>