summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-12-11Reserve proper length in processes VMA when mapping USDPAA memoryRoy Pledge
USDPAA memory mapping were not properly reserving the entire length of the memory area when perfoming mapping of not power of 4 regions. This causes issues if the choosen address overlapped with an existing memory area. Signed-off-by: Roy Pledge <Roy.Pledge@freescale.com> Change-Id: I078d12279a43ddf3fc7c5de4b9e4a932d588832e Reviewed-on: http://git.am.freescale.net:8181/25329 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Geoff Thorpe <Geoff.Thorpe@freescale.com> Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
2014-12-11powerpc/fsl-soc: Add b4420- and b4-l3-cache-controller compatsScott Wood
These were missed by commit 745ecda7aa7e "powerpc/fsl-soc: Disable CPC sole-data mode if KVM enabled". Signed-off-by: Scott Wood <scottwood@freescale.com> Fixes: 745ecda7aa7e "powerpc/fsl-soc: Disable CPC sole-data mode if KVM enabled" Change-Id: I0b00cfbdf9846ba52fa8c58411b5df8002d7c67e Reviewed-on: http://git.am.freescale.net:8181/25338 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mihai Caraman <mihai.caraman@freescale.com> Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
2014-12-11gianfar: Disable Rx snooping for LS1Claudiu Manoil
It was observed that Rx snooping incurs a significant performance penalty. My suspicion is that it interferes with the DMA software coherency, currently performed by DMA-API. It is known that there are H/W coherency issues at least for the Tx side (see read data interleaving issue) which is why the software coherency is needed in the first place. This patch disables Rx snooping as well, as a workaround, until the root cause for the Rx side coherency related issue is found. Change-Id: I00c3a5723d52d2f9a9d18e11b5c64c9c208c466b Signed-off-by: Claudiu Manoil <claudiu.manoil@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/25325 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Zhengxiong Jin <Jason.Jin@freescale.com> Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
2014-12-11powerpc/fsl-soc: Disable CPC sole-data mode if KVM enabledScott Wood
Set undocumented bit to disable CPC sole data mode, making it safe to use the LRAT with KVM guests, which could otherwise hang the host (under certain usage patterns) by accessing memory with the M bit unset. The guest still needs to set the M bit to operate properly, but this removes a DoS vector. Only do so if CONFIG_KVM is enabled as supposedly disabling this affects performance, though I wasn't able to detect a difference in the workloads I ran. Signed-off-by: Scott Wood <scottwood@freescale.com> Change-Id: I5e69f03150f93556f3548ed4f8b3df65cfe6d802 Reviewed-on: http://git.am.freescale.net:8181/24843 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Stuart Yoder <stuart.yoder@freescale.com> Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
2014-12-11fmd: compat layer: remove redundant breaksMandy Lavi
Change-Id: Id7aeeb432a397008ac08c87418c68f0ec70413b2 Signed-off-by: Mandy Lavi <mandy.lavi@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/25100 Reviewed-by: Igal Liberman <Igal.Liberman@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
2014-12-11powerpc/fsl: Force coherent memory on e500mc derivativesScott Wood
In CoreNet systems it is not allowed to mix M and non-M mappings to the same memory, and coherent DMA accesses are considered to be M mappings for this purpose. Ignoring this has been observed to cause hard lockups in non-SMP kernels on e6500. Furthermore, e6500 implements the LRAT (logical to real address table) which allows KVM guests to control the WIMGE bits. This means that KVM cannot force the M bit on the way it usually does, so the guest had better set it itself. Signed-off-by: Scott Wood <scottwood@freescale.com> Change-Id: I083bdc9dd7990d475b8ae48680a8e63012998e93 Reviewed-on: http://git.am.freescale.net:8181/24841 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mihai Caraman <mihai.caraman@freescale.com> Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
2014-12-11drivers: dpaa: fix build errors after changes in crypto/caamCristian Stoica
Several patches in drivers/crypto/caam starting with fa9659cd4d3f40cead6263986cc235f3e67ab872 changed the API for error source reporting. Signed-off-by: Cristian Stoica <cristian.stoica@freescale.com> Change-Id: I9a2339272251b0e7a67ae8fe1fede5608e1aedc9 Reviewed-on: http://git.am.freescale.net:8181/25119 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11drivers:usb:pm: Fix sleep/deep-sleep issue for external ULPI phyRamneek Mehresh
External ULPI phy registers are not to be restored during normal sleep when phy power is not cut-off. In addition, phy saving/restoration needs to happen only during deep-sleep Signed-off-by: Ramneek Mehresh <ramneek.mehresh@freescale.com> Change-Id: I840724ff3cf4e85582e2e1c73b1ff9798dfd7304 Reviewed-on: http://git.am.freescale.net:8181/24849 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Nikhil Badola <nikhil.badola@freescale.com> Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
2014-12-11qbman: Add bman version check when reading idle registerJeffrey Ladouceur
The STATE_IDLE register was added to BMan hw version 2.1.0 Anything earlier than this will return undefined value. This is required in order to not abort suspend phase due to false information Change-Id: I055b37571fc7d500018e8a736cbfffc8e5920f3f Signed-off-by: Jeffrey Ladouceur <Jeffrey.Ladouceur@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/24834 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Haiying Wang <Haiying.Wang@freescale.com> Reviewed-by: Roy Pledge <roy.pledge@freescale.com> Reviewed-by: Geoff Thorpe <Geoff.Thorpe@freescale.com> Reviewed-by: Matthew Weigel <Matthew.Weigel@freescale.com>
2014-12-11dpa_offload: sync with CAAM changesAlex Porosanu
The CAAM driver function caam_jr_strstatus() has changed its usage, and now it performs the interpretation and printing of the error itself. This patch syncs dpa_offload's sources with the updated version. Change-Id: I5b7b04386dbc03c11e3277adb77af985cc6418ca Signed-off-by: Alex Porosanu <alexandru.porosanu@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/24679 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Cristian Stoica <cristian.stoica@freescale.com> Reviewed-by: Marian-Cornel Chereji <marian.chereji@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11ls1021a/dts: Add eTSEC1 as wake-up event sourceClaudiu Manoil
According to the H/W reference manual, eTSEC1 (EC1) is a valid wake-up event source. The supported wake-up events are magic packet and user defined packet (eTSEC filer). Change-Id: Ife1a0d1f0afcfa8641c6630cb12c9e40775b9e47 Signed-off-by: Claudiu Manoil <claudiu.manoil@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/24220 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Zhengxiong Jin <Jason.Jin@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11qspi: ls102xa: Adjust the size of QSPI AMBA Bus memory mapAlison Wang
This patch adjust the size of QSPI AMBA Bus memory map to 64M to avoid the issue that system default vmalloc size is not enough. Signed-off-by: Alison Wang <alison.wang@freescale.com> Change-Id: Ie917be03b0a0479f2c49dc02b9c36cb04ecc87c8 Reviewed-on: http://git.am.freescale.net:8181/24671 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Zhengxiong Jin <Jason.Jin@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11qspi: Fix system hang issue when reading QSPI flash on LS1021A TWR boardAlison Wang
For the QuadSPI SPI NOR flash driver, quad reading is used. This patch will add quad reading support for ST's flash n25q128a13 on LS1021A TWR board. Signed-off-by: Alison Wang <alison.wang@freescale.com> Change-Id: Icf3c1334825fb9a0fe957bc6b75fa4dfd54c6960 Reviewed-on: http://git.am.freescale.net:8181/24670 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Zhengxiong Jin <Jason.Jin@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11crypto: caam - add support for rfc4543(gcm(aes))Tudor Ambarus
Add AES-GMAC as an IPSec ESP mechanism to provide data origin authentication, but not confidentiality. This method is referred as ENCR_NULL_AUTH_AES_GMAC. Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 5d0429a30f06845af78a696de59e3e8d21252846) Specify the lowest (compatible) SEC Era on which the descriptors can run. Change-Id: If17a51a41c06dedf5b3589311d2677d522b4a209 Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/23481 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11crypto: caam - fix output sequence contiguity checkTudor Ambarus
This patch fixes the assumption that output sequence is not contiguous when input sequence is not contiguous and in-place encryption is done. Output sequence does not need to be contiguous with associated data. Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 19167bfd8ae72ceeb41930343227bf8f5fb19a66) Change-Id: I55797558a79c8113c7e299198f94caea6a0d10b5 Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/23480 Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11crypto: caam - add support for rfc4106(gcm(aes))Tudor Ambarus
Add Advanced Encryption Standard (AES) in Galois/Counter Mode (GCM) as an IPsec Encapsulating Security Payload (ESP) mechanism to provide confidentiality and data origin authentication. Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit bac68f2c9a43e60a70e27c0c75aaca7128b6271d) Specify the lowest (compatible) SEC Era on which the descriptors can run. Change-Id: I9054cb203f3f3acad5853ba973bb549ff1d2e10c Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/23479 Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11crypto: caam - add support for gcm(aes)Tudor Ambarus
Add support for AES working in Galois Counter Mode. There is a limitation related to IV size, similar to the one present in SW implementation (crypto/gcm.c): The only IV size allowed is 12 bytes. It will be padded by HW to the right with 0x0000_0001 (up to 16 bytes - AES block size), according to the GCM specification. Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Signed-off-by: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 3ef8d945d0dafd272e77c01099bc4975c5297a5a) Conflicts: drivers/crypto/caam/caamalg.c Specify the lowest (compatible) SEC Era on which the descriptors can run. Change-Id: Ic6e0695192a4b9cfcc388e0ce31ec50741f5e339 Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/23478 Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11Revert "crypto: caam - add support for gcm(aes)"Tudor Ambarus
This reverts commit 8901a6c015c66cecd70b301f58bab9fc68a11d69. The upstream version of gcm support contains some fixes that current version does not include. The removal of gcm support from caam driver will be followed by the cherry-pick of upstream's gcm patch. Change-Id: Ic8de49a977beae9cd15eb860e9f6e18695886d98 Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/23477 Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11Revert "crypto: caam - fix key typo in gcm descriptors"Tudor Ambarus
This reverts commit 47a0ea3dc8b50056f8dd39afb438d362d5f5ea45. The upstream version of gcm support contains some fixes that current version does not include. The removal of gcm support from caam driver will be followed by the cherry-pick of upstream's gcm patch. Change-Id: I1fcd770e7f15326a18a2fb18bc8efb40abbe5246 Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/23476 Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11spi/fsl-espi: Add the 4Byte address width device supportHou Zhiqiang
Get the address width information from the spi_message to correct the address to operate. when the one-time transfer length exceed the max limited length of eSPI controller 0xFFFF, for the subsequent transfer, the address to operate need to be corrected. Signed-off-by: Hou Zhiqiang <B48286@freescale.com> Change-Id: I54cf8e76c29c660603b864ff1ef2096a2f817dba Reviewed-on: http://git.am.freescale.net:8181/24586 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11mtd: m25p80: Initialize the addr_width field of spi_messageHou Zhiqiang
Add the addr_width information of spi_nor delivery to SPI controller. For the Freescale eSPI controller, the address width is needed to do the correct operations. Signed-off-by: Hou Zhiqiang <B48286@freescale.com> Change-Id: I6c3afe1ceab7d792ceaba0a2c94d2baac1ecbe56 Reviewed-on: http://git.am.freescale.net:8181/24585 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mingkai Hu <Mingkai.Hu@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11spi: Add addr_width field to struct spi_messageHou Zhiqiang
Make SPI controller can get address width of the SPI device. Signed-off-by: Hou Zhiqiang <B48286@freescale.com> Change-Id: I308e2cd5c91f067911fd5a6e89accfdf46473339 Reviewed-on: http://git.am.freescale.net:8181/24584 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mingkai Hu <Mingkai.Hu@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11drivers:usb:fsl: Fix deep-sleep resume issue caused by usbRamneek Mehresh
usb ip driver needs to save and restore all registers including phy registers across deep-sleep. This is required since latest changes in u-boot code doesn't re-init usb phy anymore during deep-sleep resume Signed-off-by: Ramneek Mehresh <ramneek.mehresh@freescale.com> Signed-off-by: Suresh Gupta <suresh.gupta@freescale.com> Signed-off-by: Nikhil Badola <nikhil.badola@freescale.com> Change-Id: Idc957b013a804bb4b12fa17836d0ae2371aeeed4 Reviewed-on: http://git.am.freescale.net:8181/24603 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11crypto: caampkc: remove inclusion of unused headerCristian Stoica
Signed-off-by: Cristian Stoica <cristian.stoica@freescale.com> Change-Id: I7983c1cdc0d19fd738b251de3c0374e9e67cf617 Reviewed-on: http://git.am.freescale.net:8181/19800 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11crypto: caam: remove dead codeCristian Stoica
- assoc_nents and src_nents are never zero when all_contig is false - iv_contig is zero on the else branch Signed-off-by: Cristian Stoica <cristian.stoica@freescale.com> Change-Id: Iccd420733cac736e92c1f9b0cb8fb83fd39b40e4 Reviewed-on: http://git.am.freescale.net:8181/19799 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11crypto: caam: remove unused local variablesCristian Stoica
Signed-off-by: Cristian Stoica <cristian.stoica@freescale.com> Change-Id: I7cd10343879e4b51c50b2c4058aad76374831e91 Reviewed-on: http://git.am.freescale.net:8181/19797 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11Merge remote-tracking branch 'b18196/fix_error_reporting'Rich Schmitt
2014-12-11crypto: caam - fix error reportingCristian Stoica
The error code returned by hardware is four bits wide with an expected zero MSB. A hardware error condition where the error code can get between 0x8 and 0xf will trigger an out of bound array access on the error message table. This patch fixes the invalid array access following such an error and reports the condition. Signed-off-by: Cristian Stoica <cristian.stoica@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 49783d0f54219e1c68eac738fdd3244b7a6cbda7)
2014-12-11crypto: caam - Fix the 'quoted string split across lines'Marek Vasut
Fix the checkpatch warnings that the strings were split across multiple lines. Checkpatch now complains about lines over 80, but this is better, since we can actually grep the source code for these strings now. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit da37503d37bb6ae72cca0b4d729c153f04b9f0cc)
2014-12-11crypto: caam - Sweep the remnantsMarek Vasut
Clean up the remnants from the rework. Constify function arguments. Note that checkpatch again complains about this space before newline, but this is the original code behavior, so I'm keeping it. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit e397ee0f2242a5f316906e1ff05f8669791b4e2c)
2014-12-11crypto: caam - Kill SPRINTFCAT() with fireMarek Vasut
This macro is just like an encyclopedia of string handling done wrong. This must die. This is so wrong on so many levels. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit e22cdcfa13d9799ea46245946ae09b4a328ff27d)
2014-12-11crypto: caam - Clean up report_deco_status()Marek Vasut
Clean this function up and rework it into sensible shape. This function now contains one single dev_err() instead of the previous insanity full of memory allocation, chaotic string handling and use of SPRINTFCAT(). Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 4f0fa52a5d89d763423cb9b428e988ea824fd95a)
2014-12-11crypto: caam - Clean up report_ccb_status()Marek Vasut
Clean this function up and rework it into sensible shape. This function now contains one single dev_err() instead of the previous insanity full of memory allocation, possible stack overwriting, chaotic string handling and use of SPRINTFCAT(). Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 1e16322da45b747c753162e421b7a1b25259377a)
2014-12-11crypto: caam - Dissolve report_jump_idx()Marek Vasut
Just dissolve this function so it's not in the way of applying further white magic cleanup down the line. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 526243cc872398ed8139a52ee0bf7715a3abcf31)
2014-12-11crypto: caam - Kill the easy targetsMarek Vasut
Fix the functions which can be obviously done right with a simple dev_err() now. While at it, further press the on-stack allocation of buffer for sprintf() voodoo down into the abominated functions. This patch cleans up most of the functions and leaves just two remaining functions, report_ccb_status() and report_deco_status() ugly and unhappy. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit e75880dd9afb60ff59efe079ac50ccc16daffe54)
2014-12-11crypto: caam - Pass error type into the functionsMarek Vasut
Pass the error type string into the functions, so they can handle the printing of the string. This is now still using the very unsafe sprintf(), but we will fix that. While at this, pass the device pointer too, so we can dev_err() functions readily when we start fixing this proper. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 8a4758268292eb036a63f49746fbfe3fcdc0c51d)
2014-12-11crypto: caam - Implement fast-path for error codes with no handlerMarek Vasut
Implement fast-path error code printout for errors with no associated handler function. This reduces calls to this kmalloc() nonsense in SPRINTFCAT() already. Note that the format of output is compatible with the old code, even if -- exposed like this -- it looks a bit weird. Checkpatch complains on this one as well. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 867e1ee395d845f49ae280c3d8f5271b214fa7e4)
2014-12-11crypto: caam - Pull all the error codes outMarek Vasut
Pull the error code <-> error string mapping tables out of the function so the code becomes readable. This lets me see the real flesh of the functions, without all that flab clouding the view. Note: There is a checkpatch issue with quoted strings across multiple lines. I will fix that in a subsequent patch to keep the changes small and separate. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit 9724d7adbb34b067b844b97599c1a5905229aa2b)
2014-12-11crypto: caam - Contain caam_jr_strstatus() uglinessMarek Vasut
The tentacles of this function were firmly attached to various places in the CAAM code. Just cut them, or this cthulhu function will sprout them anew. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: Horia Geanta <horia.geanta@freescale.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> (cherry picked from commit fa9659cd4d3f40cead6263986cc235f3e67ab872) Squash additional fixes to avoid broken builds in Freescale SDK crypto: caam: fix calls to caam_jr_strstatus This is a clean-up patch after changes made to caam_jr_strstatus API starting with fa9659cd4d3f40cead6263986cc235f3e67ab872. Signed-off-by: Cristian Stoica <cristian.stoica@freescale.com>
2014-12-11dpaa_eth: fix PTPd 1588 stack sync issueYangbo Lu
It existed a settime issue for 1588 timer module on some platforms' 32-bit kernels. It's caused by the difference of data type length between 32-bit and 64-bit platforms or kernels. Signed-off-by: Yangbo Lu <yangbo.lu@freescale.com> Change-Id: Ia223770de71fd30d08c6dab5d58bec62719e4a32 Reviewed-on: http://git.am.freescale.net:8181/24537 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Xiaobo Xie <X.Xie@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11ls1021a: Turn off DEBUG_SPINLOCK configClaudiu Manoil
This debug option should be off in the release defconfig. Enabling this debug option has significant impact on CPU utilization and overall system performance. i.e.: Networking Tx throughput tests with PKTGEN show a throughput loss of up to 10% when this debug config option is enabled. Change-Id: Ia160a8d99425fabb64051d7549f9d55ff5d420ce Signed-off-by: Claudiu Manoil <claudiu.manoil@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/23857 Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Sandeep Malik <Sandeep.Malik@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11fmd: adjust compat layer following capwap supportMandy Lavi
The addition of the capwap related structures required a few changes in the compat layer to better support 64b kernel space working with 32b user space Change-Id: I7d49c8cec351ada65259f928df2d6014f5d81342 Signed-off-by: Mandy Lavi <mandy.lavi@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/24499 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Jiafei Pan <Jiafei.Pan@freescale.com> Reviewed-by: Marian-Cornel Chereji <marian.chereji@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11mmc: esdhc: Follow T4240 eSDHC characteristic for T4160 and T4080Li Jingyu
The T4160 is a lower power version of the T4240, and The T4080 is a low power version of the T4160. So they have the same eSDHC controller. Signed-off-by: Li Jingyu <b41874@freescale.com> Change-Id: Iab5b0ae09bdd8b9c720c29168dfdafc23a5dde0d Reviewed-on: http://git.am.freescale.net:8181/24502 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Xiaobo Xie <X.Xie@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11powerpc/dts/c29xpcie: Update range field for IFC NANDJaiprakash Singh
C29xPCIe has NAND flash present on IFC CS1. So update "ranges" field for NAND flash on CS1. Signed-off-by: Jaiprakash Singh <b44839@freescale.com> Change-Id: Id3bcf527929b9caeda9a81a1712b030e364ed64c Reviewed-on: http://git.am.freescale.net:8181/24113 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mingkai Hu <Mingkai.Hu@freescale.com> Reviewed-by: Prabhakar Kushwaha <prabhakar@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11mtd: m25p80: Add Power Management supportHou Zhiqiang
Add the rescanning and initialization of SPI flash, to make the SPI flash in the correct state. Because if the Power Management system truns off power supply for SPI flash when system suspending, the SPI flash will return to the reset state after system resume. Signed-off-by: Hou Zhiqiang <B48286@freescale.com> Change-Id: Ifa38f33f894ab43ce99cb8848e40c2193c0c1aa6 Reviewed-on: http://git.am.freescale.net:8181/24154 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mingkai Hu <Mingkai.Hu@freescale.com> Reviewed-by: Yang Li <LeoLi@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11driver/memory:Fix ifc_out parameter in resume callbackPrabhakar Kushwaha
ifc_out32 requires data, address in sequence as input parameter. So fix ifc_out32 input parameter in fsl_ifc_resume. Signed-off-by: Prabhakar Kushwaha <prabhakar@freescale.com> Change-Id: I9ccd050d30b586cf6c6afde8131212b482abf78d Reviewed-on: http://git.am.freescale.net:8181/24158 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Poonam Aggrwal <poonam.aggrwal@freescale.com> Reviewed-by: Yusong Sun <yorksun@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11KVM: PPC: e500: Clear mas5 in inval_ea_on_host()Scott Wood
Commit 5957374238 "KVM: PPC: e500: Fix tlbilx_all emulation for HTW" removed the clearing of MAS5 from inval_ea_on_host() while moving it between files. As a result, KVM causes MAS5 to be set for guest mappings even when normal host Linux code is running, which renders host invalidations-by-page ineffective. This caused corruption in the host. Signed-off-by: Scott Wood <scottwood@freescale.com> Change-Id: I0401e85dcd6a50961ce4657110bfaf66d90c87d4 Reviewed-on: http://git.am.freescale.net:8181/24460 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Stuart Yoder <stuart.yoder@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11t2080qds/rtc: fix rtc interruptShengzhou Liu
RTC interrupt uses IRQ11 on T2080QDS. Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Change-Id: I5f4c3f89d007c48009ad3368a1f6ed5e31f4e464 Reviewed-on: http://git.am.freescale.net:8181/24195 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Dongsheng Wang <dongsheng.wang@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11devres: restore zeroing behavior of devres_alloc()Kevin Hilman
commit 64c862a8 (devres: add kernel standard devm_k.alloc functions) changed the default behavior of alloc_dr() to no longer zero the allocated memory. However, only the devm.k.alloc() function were modified to pass in __GFP_ZERO which leaves any users of devres_alloc() or __devres_alloc() with potentially wrong assumptions about memory being zero'd upon allocation. To fix, add __GFP_ZERO to devres_alloc() calls to preserve previous behavior of zero'ing memory upon allocation. Signed-off-by: Kevin Hilman <khilman@linaro.org> Cc: Tejun Heo <tj@kernel.org> Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> (cherry picked from commit 6fffcfa7c0fc438d3667b4eb2074d94f69c12c7b) Change-Id: Ib08e13e11b475aea6be4e5121cd926d580b3caa4 Reviewed-on: http://git.am.freescale.net:8181/24442 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>
2014-12-11Disable CPU migration during USDPAA CleanupRoy Pledge
CPU specific variables are used during USDPAA cleanup. Disabling CPU migration is needed to avoid the cleanup process from being moved to another CPU (especially when using the RT preemption models) Change-Id: If0133117fcec82f69e6123cb4da3167363b0dad3 Signed-off-by: Roy Pledge <Roy.Pledge@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/24105 Reviewed-by: Roy Pledge <roy.pledge@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com>