summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2015-04-23dpaa_eth: supplement MEMAC sysfs statisticsMadalin Bucur
Add Rx/Tx detailed statistics. Signed-off-by: Madalin Bucur <madalin.bucur@freescale.com> Change-Id: Ibcb5e2a6b564c85d434a563ab52c45143281315f Reviewed-on: http://git.am.freescale.net:8181/35265 Reviewed-by: Mandy Lavi <Mandy.Lavi@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-22t1042d4rdb/dts: Added usdpaa device tree and sharedSandeep Singh
interface device tree source Signed-off-by: Sandeep Singh <sandeep@freescale.com> Change-Id: If7e2e984aa0883f2ceacc30b67cf493b42f3f67d Reviewed-on: http://git.am.freescale.net:8181/35357 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Vakul Garg <vakul@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-22t1040d4rdb/dts: Add usdpaa device tree and usdpaa sharedSandeep Singh
interface device tree. Signed-off-by: Sandeep Singh <sandeep@freescale.com> Change-Id: I27db2e3e2b55c66e8b75ae560f2899c0455bf893 Reviewed-on: http://git.am.freescale.net:8181/34646 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Vakul Garg <vakul@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-21dpa_offload: Resync B4860QDS device tree files with NFAPI applicationsMarian Chereji
Example device tree files for the B4860QDS platform needed to be synchronized and aligned due to differences in the Virtual Storage Profile utilization between traditional DPAA offloading applications and the DPAA NF offloading applications. Signed-off-by: Marian Chereji <marian.chereji@freescale.com> Change-Id: Ia6f7443b19876c1e9882419ef1e7b6b9729242e1 Reviewed-on: http://git.am.freescale.net:8181/35181 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Nicolae-Sebastian Grigore <sebastian.grigore@freescale.com> Reviewed-by: Radu-Andrei Bulie <Radu.Bulie@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-21FMD: DSAR: add dsar support to device tree filesEyal Harari
Signed-off-by: Eyal Harari <eyal.harari@freescale.com> Change-Id: I900fd4e19738897af4be22df651b106e7384f30c Reviewed-on: http://git.am.freescale.net:8181/35281 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mandy Lavi <Mandy.Lavi@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-21fmd: rtc: consider RCW[FM_MAC_RAT] when calcuating rtc ref clockMandy Lavi
Change-Id: I1b8a2966ad45f995e7e6b3cdca7f8ed5e0dd397a Signed-off-by: Mandy Lavi <mandy.lavi@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/35026 Reviewed-by: Igal Liberman <Igal.Liberman@freescale.com> Reviewed-by: Yangbo Lu <yangbo.lu@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-21Expose RCW in the ccsr_guts structureMandy Lavi
This will enable the reading of essential h/w configuration setup from within the kernel space Change-Id: I8d5ffbf48b02b5ef6ad6bf546f3440485ccd9778 Reviewed-on: http://git.am.freescale.net:8181/35025 Reviewed-by: Igal Liberman <Igal.Liberman@freescale.com> Reviewed-by: Yangbo Lu <yangbo.lu@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-21qbman: Agressively clean QMan portals before useRoy Pledge
Make sure both the message ring and dequeue ring of a QMan portal are clean before attempting to use them Signed-off-by: Roy Pledge <Roy.Pledge@freescale.com> Change-Id: I8b4736625acfb25954cd3fa60e0761f86c2d9620 Reviewed-on: http://git.am.freescale.net:8181/31755 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Haiying Wang <Haiying.Wang@freescale.com> Reviewed-by: Jeffrey Ladouceur <Jeffrey.Ladouceur@freescale.com> Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/35331 Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-21perf hists browser: Change print format from %lu to %PRIu64Tom Huynh
The nr_events variable in tools/perf/ui/browsers/hists.c is of type u64, so the print format (%lu) causes 'perf report' to show 0 event count when running with 32-bit userspace without redirection. This patch fixes that problem by printing nr_events as PRIu64. Signed-off-by: Tom Huynh <tom.huynh@freescale.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Kim Phillips <kim.phillips@freescale.com> Cc: Matt Mullins <mmullins@mmlx.us> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/1417541842-9747-1-git-send-email-tom.huynh@freescale.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Change-Id: I74e6ad212a7e0dd26b52f738f54f1b6d60edd60d Reviewed-on: http://git.am.freescale.net:8181/29120 Reviewed-by: Yang Li <LeoLi@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-17dpaa_eth: avoid race between init and probing codeMadalin Bucur
The generic driver debugfs root is now added in the initialization code, at the end. Under certain conditions the probing code gets to run before the debugfs root is created resulting in errors. Signed-off-by: Madalin Bucur <madalin.bucur@freescale.com>
2015-04-16t1024rdb/qe-tdm: remove incorrect qoriq-tdm1.0.dtsi for t1024Shengzhou Liu
qoriq-tdm1.0.dtsi is used for TDM instead of QE-TDM. qoriq-tdm1.0.dtsi was included incorrectly in t1024si-post.dtsi, so remove the unused node. Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Change-Id: I04db42316df853ad596a466cccc0ac88621a5384 Reviewed-on: http://git.am.freescale.net:8181/34968 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-16caam: remove dependencies on QI when it is disabledCristian Stoica
The dependency on CAAM-QI was incorrectly set on FSL_QMAN and resulted in an always-enabled CAAM-QI on DPAA platforms. This patch fixes the dependency and allows CAAM-QI interface to be freely disabled on DPAA platforms. Signed-off-by: Cristian Stoica <cristian.stoica@freescale.com> Change-Id: Iaf752ae8774a7b03383244a6c9fbbadd9959f3d4 Reviewed-on: http://git.am.freescale.net:8181/34732 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-16powerpc/perf: fix fsl_emb_pmu_start to write correct pmc valueTom Huynh
PMCs on PowerPC increases towards 0x80000000 and triggers an overflow interrupt when the msb is set to collect a sample. Therefore, to setup for the next sample collection, pmu_start should set the pmc value to 0x80000000 - left instead of left which incorrectly delays the next overflow interrupt. Same as commit 9a45a9407c69 ("powerpc/perf: power_pmu_start restores incorrect values, breaking frequency events") for book3s. Signed-off-by: Tom Huynh <tom.huynh@freescale.com> Signed-off-by: Scott Wood <scottwood@freescale.com> (cherry picked from commit d2caa3cebda8b626336e100b80a0ed6f909dccab) Change-Id: I2179f49218e1e0cd836c67714430a86be8535a27 Reviewed-on: http://git.am.freescale.net:8181/35052 Reviewed-by: Richard Schmitt <richard.schmitt@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-15Do not miss inactive (deferred) timersJia Hongtao
The inactive timer could not be raised casued by this patch: https://lkml.org/lkml/2014/2/28/230 This makes the system using deferred timer like CPUfreq not working. Signed-off-by: Jia Hongtao <hongtao.jia@freescale.com> Change-Id: I8e1b6dbcb2845c6e502d9ff50617e8c30d2da7c0 Reviewed-on: http://git.am.freescale.net:8181/34890 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Yang Li <LeoLi@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-14Revert "of: fix of_property_read_string"Scott Wood
This reverts commit 9c3d11c6a2f1e86927cd762dfaa696c82def8e95. That commit was merged too hastily with improper review, and is not only the wrong fix, but it appears to allow malformed device trees to propagate non-NULL-terminated strings into the kernel which can result in kernel code accessing beyond the end of the string. Upstream discussion at https://www.mail-archive.com/devicetree@vger.kernel.org/msg68463.html Change-Id: I418b29bea7e8e088e1c54c49896264616eed1b83 Reviewed-on: http://git.am.freescale.net:8181/34776 Reviewed-by: Stuart Yoder <stuart.yoder@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-13Kconfig: Patch to remove warning in non-DPA case when asf is enabled.Alok Makhariya
When ASF is enabled FSL_DPAA_HOOKS flag is selected for non-DPA case as well. So an if check is added to select FSL_DPAA_HOOKS flag in DPA case only. Signed-off-by: Alok Makhariya <B46187@freescale.com> Change-Id: I3e7a439135339262581c2526fd1c22f464412e2e Reviewed-on: http://git.am.freescale.net:8181/34313 Reviewed-by: Sandeep Malik <Sandeep.Malik@freescale.com> Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-13t1023rdb/dts: add usdpaa device tree and usdpaaVakul Garg
shared interface device tree Signed-off-by: Sandeep Singh <sandeep@freescale.com> Change-Id: Id22399683933675957f945f61621f87856d53b2c Reviewed-on: http://git.am.freescale.net:8181/34778 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Vakul Garg <vakul@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-08ENGR353929: Merge remote-tracking branch 'dpaa/dpaa-next'Olivia Yin-R63875
2015-04-08of: fix of_property_read_stringShengzhou Liu
in of_property_read_string function, strnlen(prop->value, prop->length) is always less or equal to prop->length and we should allow the '==' condition, so let's remove the original unreasonable condition, otherwise it was causing kernel crash. Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Change-Id: I4adf0d8ed7c3185b942d8da0f671faf7b5272720 Reviewed-on: http://git.am.freescale.net:8181/34543 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Xiaobo Xie <X.Xie@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-06fmd: Fix incorrect disabling of macsec cfg ptp registerCamelia Groza
Signed-off-by: Camelia Groza <camelia.groza@freescale.com> Change-Id: I7ae237524eea4a1a7587850152ca88eb74a9807d Reviewed-on: http://git.am.freescale.net:8181/34261 Reviewed-by: Madalin-Cristian Bucur <madalin.bucur@freescale.com> Tested-by: Cristian-Constantin Sovaiala <Cristian.Sovaiala@freescale.com>
2015-04-03net/phy: fixup for RTL8211F linkShengzhou Liu
Fix the checking link of RTL8211F. Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Change-Id: I4c88f7a19f467f680957b47e0a630c950aabe46d Reviewed-on: http://git.am.freescale.net:8181/34202 Reviewed-by: Shaohui Xie <Shaohui.Xie@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-03fsl/mdio: fixup for rtl8211f on t1023rdbShengzhou Liu
As the 50us delay was not enough and lead to RTL8211F PHY not working on some T1023RDB boards. so increase the delay to make it work stably. Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com> Change-Id: Iff011d0b762e087ae401a510c71e06b8181061c5 Reviewed-on: http://git.am.freescale.net:8181/34201 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Shaohui Xie <Shaohui.Xie@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-02kconfig: Select FSL_DPAA_HOOKS when asf is enabledAlok Makhariya
Since ASF hooks in dpa driver is replaced by FSL_DPAA_HOOKS so selecting FSL_DPAA_HOOKS when AS_FASTPATH is enabled. Signed-off-by: Alok Makhariya <B46187@freescale.com> Change-Id: Iebcaf825042e0d0c8e2e4f324325cb8c2c3be1bb Reviewed-on: http://git.am.freescale.net:8181/33922 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Sandeep Malik <Sandeep.Malik@freescale.com> Reviewed-by: Cristian-Constantin Sovaiala <Cristian.Sovaiala@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-02ENGR336776: Merge remote-tracking branch 'dpaa/dpaa-next'Olivia Yin-R63875
2015-04-02dpa_offload: Add DTS file for NF DPAA offloadingMarian Chereji
Added the B4860QDS platform DTS file example for NF DPAA offloading demo application. Signed-off-by: Marian Chereji <marian.chereji@freescale.com> Change-Id: Ib546a6b2984735f933df90cce1be376bd60245d5 Reviewed-on: http://git.am.freescale.net:8181/33632 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-01crypto: caam - change QI memory allocation on hotpathAlex Porosanu
This patch changes the allocation of memory on the hotpath, by replacing the malloc allocation with a kmem_cache backed allocation. Change-Id: I55a21bb7cbd022f6b86bd784988491b551a0f81e Signed-off-by: Alex Porosanu <alexandru.porosanu@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/31371 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mircea Pop <mircea.pop@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-01crypto: caam - cleanup caamalg_qiAlex Porosanu
This patch synchronizez the QI shared descriptors creation with the corresponding JR ones, as well as cleaning up the unused parameters of the *edesc_alloc() functions. While here, also fix a formatting error in cra_init(). Change-Id: Ic5bae734e4a6e6dcb329f7e9530422b9f8cc0377 Signed-off-by: Alex Porosanu <alexandru.porosanu@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/31370 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Mircea Pop <mircea.pop@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-04-01capwap: clear memory for variablePan Jiafei
Signed-off-by: Pan Jiafei <Jiafei.Pan@freescale.com> Change-Id: I4c37af569b6011945860d2d7379e728ee69e133d Reviewed-on: http://git.am.freescale.net:8181/34071 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Jianhua Xie <jianhua.xie@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-31dpaa_eth: Add support for MACsecCristian Sovaiala
This patch adds support for MACsec in DPAA. The feature is implemented as a separate driver and hooks into the DPAA Ethernet driver using the hooks exported by the latter. The MACsec driver exposes a set of APIs allowing the user to configure the hardware in MACsec mode and to change configuration at runtime (add/ remove secure channels, secure associations, change secure association keys, etc.). The following capabilities are supported by the current implementation: - MACsec enabled on multiple interfaces - one SecY per interface (MAC) - one TX Secure Channel per SecY - up to 16 RX Secure Channels per SecY - debugfs statistics (TX counters only) per CPU per interface Signed-off-by: Camelia Groza <camelia.groza@freescale.com> Signed-off-by: Andrei Vasiliu <andrei.vasiliu@freescale.com> Signed-off-by: Iulia Manda <manda.iulia@freescale.com> Signed-off-by: Cristian Sovaiala <cristian.sovaiala@freescale.com> Change-Id: I8fe2883a716bf82dc14aae467f3e0eab140d236d Reviewed-on: http://git.am.freescale.net:8181/33832 Reviewed-by: Madalin-Cristian Bucur <madalin.bucur@freescale.com> Tested-by: Madalin-Cristian Bucur <madalin.bucur@freescale.com>
2015-03-31dpaa_eth: Export several APIs for external usageCristian Sovaiala
Some APIs can be used by other DPAA drivers (such as MACsec driver) which hook into the processing path of the DPAA Ethernet driver therefore we export those APIs for external usage. Signed-off-by: Camelia Groza <camelia.groza@freescale.com> Signed-off-by: Andrei Vasiliu <andrei.vasiliu@freescale.com> Signed-off-by: Iulia Manda <manda.iulia@freescale.com> Signed-off-by: Cristian Sovaiala <cristian.sovaiala@freescale.com> Change-Id: I312d281002a047d05b9471ecf4ea12c36b28c6b0 Reviewed-on: http://git.am.freescale.net:8181/33831 Reviewed-by: Madalin-Cristian Bucur <madalin.bucur@freescale.com> Tested-by: Cristian-Constantin Sovaiala <Cristian.Sovaiala@freescale.com>
2015-03-31powerpc/fsl: add power_off support for fsl platformWang Dongsheng
QIXIS System Logic FPGA support to manage system power. So we through QIXIS to power off freescale SOC. Signed-off-by: Wang Dongsheng <dongsheng.wang@freescale.com> Change-Id: I7478cca11dcd23c8d9580c3f52c46946375573c4 Reviewed-on: http://git.am.freescale.net:8181/33082 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-31mmc: esdhc: add eMMC DDR mode support for t2080qdsYangbo Lu
Signed-off-by: Yangbo Lu <yangbo.lu@freescale.com> Change-Id: I8ff8ea59c97e562cd0786b81165ccc944670e1f2 Reviewed-on: http://git.am.freescale.net:8181/30874 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Xiaobo Xie <X.Xie@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-31crypto: caam - add useful prints for debuggingAlex Porosanu
This patch adds some output from the CAAM QI driver so the engineer can gain some insight on some of the internals of the driver. Normally, this information should reside in debug fs, but for now it's guarded by the DEBUG define. Change-Id: Ic6b7e570bc8fcedd758fb4163e15c94544e47130 Signed-off-by: Alex Porosanu <alexandru.porosanu@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/31369 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-31crypto: caam - remove list lookup of requestsAlex Porosanu
This patch removes the per-packet lookup of a completed request by adding an opaque after the SG entries in the FD. While here, also the software congestion control is removed and replaced with a proper CGR with a sensible threshold. While here, some very likely branches are decorated. Change-Id: I48f2c71b6ac0d537843a44f8c0627c9b70c77592 Signed-off-by: Alex Porosanu <alexandru.porosanu@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/31368 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Alexandru Marginean <Alexandru.Marginean@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-31Revert "dpa_offload: Add DTS file for NF DPAA offloading"Honghua Yin
This reverts commit fa008b7d96cc30a7d711641d1513e226badd3de9. Change-Id: If2569f9e57d697ef1cceb865326c52eeaa5b03ad Reviewed-on: http://git.am.freescale.net:8181/33914 Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-31dpa_offload: Add DTS file for NF DPAA offloadingMarian Chereji
Added the B4860QDS platform DTS file example for NF DPAA offloading demo application. Signed-off-by: Marian Chereji <marian.chereji@freescale.com> Change-Id: Ib546a6b2984735f933df90cce1be376bd60245d5 Reviewed-on: http://git.am.freescale.net:8181/33632 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30fmd: Fix build issue in case FSL_FMAN_TEST is selectedCristian Sovaiala
Signed-off-by: Cristian Sovaiala <cristian.sovaiala@freescale.com> Change-Id: Ic80a3f28c92aba18af32416d9216759f819c3e8c Reviewed-on: http://git.am.freescale.net:8181/33687 Reviewed-by: Madalin-Cristian Bucur <madalin.bucur@freescale.com> Tested-by: Cristian-Constantin Sovaiala <Cristian.Sovaiala@freescale.com>
2015-03-30fmd: Automatically select FSL_DPAA_HOOKS optionCristian Sovaiala
The hooks in the DPAA Ethernet driver are guarded by a new config option FSL_DPAA_HOOKS therefore select this option when enabling FSL_FMAN_TEST. Signed-off-by: Cristian Sovaiala <cristian.sovaiala@freescale.com> Change-Id: I52a22ae0357f9169741b8ccb17fc669a087cde36 Reviewed-on: http://git.am.freescale.net:8181/33686 Reviewed-by: Madalin-Cristian Bucur <madalin.bucur@freescale.com> Tested-by: Cristian-Constantin Sovaiala <Cristian.Sovaiala@freescale.com>
2015-03-30dpaa_eth: Add generic hook option FSL_DPAA_HOOKSCristian Sovaiala
Replace existing CONFIG_AS_FASTPATH and CONFIG_FSL_FMAN_TEST options guarding the hooks with a new option CONFIG_FSL_DPAA_HOOKS. Signed-off-by: Cristian Sovaiala <cristian.sovaiala@freescale.com> Change-Id: Ie571a761c7971bd558ec711e4c1a811f9eee1c89 Reviewed-on: http://git.am.freescale.net:8181/33685 Reviewed-by: Madalin-Cristian Bucur <madalin.bucur@freescale.com> Tested-by: Cristian-Constantin Sovaiala <Cristian.Sovaiala@freescale.com>
2015-03-30dpaa_eth: Remove Jumbo frame verificationCristian Sovaiala
The check must be added in the RX hook instead of conditioning the call of the hook based on the frame size. The hooks might be utilized by multiple drivers therefore each must add its specific checks inside the hooks. Signed-off-by: Cristian Sovaiala <cristian.sovaiala@freescale.com> Change-Id: I9f1ee9321bad4b6c9c38fdc332a0a8785153f81b Reviewed-on: http://git.am.freescale.net:8181/33684 Reviewed-by: Madalin-Cristian Bucur <madalin.bucur@freescale.com> Tested-by: Cristian-Constantin Sovaiala <Cristian.Sovaiala@freescale.com>
2015-03-30powerpc: add little endian flag to syscall_get_arch()Richard Guy Briggs
Since both ppc and ppc64 have LE variants which are now reported by uname, add that flag (__AUDIT_ARCH_LE) to syscall_get_arch() and add AUDIT_ARCH_PPC64LE variant. Without this, perf trace and auditctl fail. Mainline kernel reports ppc64le (per a058801) but there is no matching AUDIT_ARCH_PPC64LE. Since 32-bit PPC LE is not supported by audit, don't advertise it in AUDIT_ARCH_PPC* variants. See: https://www.redhat.com/archives/linux-audit/2014-August/msg00082.html https://www.redhat.com/archives/linux-audit/2014-December/msg00004.html Signed-off-by: Richard Guy Briggs <rgb@redhat.com> Acked-by: Paul Moore <paul@paul-moore.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> (cherry picked from commit 63f13448d81c910a284b096149411a719cbed501) Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: I8bee5c00b6d4e0f3a6a3d322b21c2f103bd9ce00 Reviewed-on: http://git.am.freescale.net:8181/33027 Reviewed-by: Scott Wood <scottwood@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30sparc: simplify syscall_get_arch()Eric Paris
Include linux/thread_info.h so we can use is_32_bit_task() cleanly. Then just simplify syscall_get_arch() since is_32_bit_task() works for all configuration options. Suggested-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Eric Paris <eparis@redhat.com> (cherry picked from commit 75dddcbd9651eec29708f91149e405cd42cf68d7) Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: Ie3eb2b996101ff3fbd8e3d44c708cd0d94bfb9f3 Reviewed-on: http://git.am.freescale.net:8181/33025 Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30powerpc: Relax secure computing on syscall entry traceBogdan Purcareata
The secure_computing_strict will just force the kernel to panic on secure_computing failure. Once SECCOMP_FILTER support is enabled in the kernel, syscalls can be denied without system failure. v4: - rebase on top of 3.19 v3,v2: no changes Upstream-Status: Pending [https://lkml.org/lkml/2015/2/18/53] Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: Icd077291db86657edce29b8079696fc8e48e554e Reviewed-on: http://git.am.freescale.net:8181/33031 Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30drivers:usb:pm: Fix usb pm support for deep-sleepRamneek Mehresh
Make sure that saving and restoration of usb phy registers only happen in case of deep-sleep, and not for any other feature like sleep, etc. Also export pm_suspend_state() and set_pm_suspend_state() Signed-off-by: Ramneek Mehresh <ramneek.mehresh@freescale.com> Change-Id: I2e08208c975ec7aee7ed42e7d424aaa8d14899e3 Reviewed-on: http://git.am.freescale.net:8181/33384 Reviewed-by: Nikhil Badola <nikhil.badola@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30ARCH: AUDIT: implement syscall_get_arch for all archesEric Paris
For all arches which support audit implement syscall_get_arch() They are all pretty easy and straight forward, stolen from how the call to audit_syscall_entry() determines the arch. Based-on-patch-by: Richard Briggs <rgb@redhat.com> Signed-off-by: Eric Paris <eparis@redhat.com> Cc: linux-ia64@vger.kernel.org Cc: microblaze-uclinux@itee.uq.edu.au Cc: linux-mips@linux-mips.org Cc: linux@lists.openrisc.net Cc: linux-parisc@vger.kernel.org Cc: linuxppc-dev@lists.ozlabs.org Cc: sparclinux@vger.kernel.org (cherry picked from commit ce5d112827e5c2e9864323d0efd7ec2a62c6dce0) Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: I772d52f630cca58c583a8f9b42f396ffecacdd1e Conflicts: arch/mips/include/asm/syscall.h Change-Id: I261719173454c5157a96eaf06c1deb9b2e3835d6 Reviewed-on: http://git.am.freescale.net:8181/33086 Reviewed-by: Scott Wood <scottwood@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30powerpc: Don't force ENOSYS as error on syscall failBogdan Purcareata
In certain scenarios - e.g. seccomp filtering with ERRNO as default action - the system call fails for other reasons than the syscall not being available. The seccomp filter can be configured to store a user-defined error code on return from a blacklisted syscall. Don't always set ENOSYS on do_syscall_trace_enter failure. Delegate setting ENOSYS in case of failure, where appropriate, to do_syscall_trace_enter. v4: - update syscall_exit to be local label on 64bit, after rebasing on top of 3.19 v3: - keep setting ENOSYS in the syscall entry assembly for scenarios without syscall tracing v2: - move setting ENOSYS as errno from the syscall entry assembly to do_syscall_trace_enter, only in the specific case Upstream-Status: Pending [https://lkml.org/lkml/2015/2/18/50] Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: I938a8754407a60c79fe9485cc76a6ec891e08e82 Reviewed-on: http://git.am.freescale.net:8181/33030 Reviewed-by: Scott Wood <scottwood@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30powerpc: Enable HAVE_ARCH_SECCOMP_FILTERBogdan Purcareata
Upstream-Status: Pending [https://lkml.org/lkml/2015/2/18/51] Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: I8960b958a7115139caeedda53da76d96da0260fc Reviewed-on: http://git.am.freescale.net:8181/33032 Reviewed-by: Scott Wood <scottwood@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30seccomp,x86,arm,mips,s390: Remove nr parameter from secure_computingBogdan Purcareata
The secure_computing function took a syscall number parameter, but it only paid any attention to that parameter if seccomp mode 1 was enabled. Rather than coming up with a kludge to get the parameter to work in mode 2, just remove the parameter. To avoid churn in arches that don't have seccomp filters (and may not even support syscall_get_nr right now), this leaves the parameter in secure_computing_strict, which is now a real function. For ARM, this is a bit ugly due to the fact that ARM conditionally supports seccomp filters. Fixing that would probably only be a couple of lines of code, but it should be coordinated with the audit maintainers. This will be a slight slowdown on some arches. The right fix is to pass in all of seccomp_data instead of trying to make just the syscall nr part be fast. This is a prerequisite for making two-phase seccomp work cleanly. Cc: Russell King <linux@arm.linux.org.uk> Cc: linux-arm-kernel@lists.infradead.org Cc: Ralf Baechle <ralf@linux-mips.org> Cc: linux-mips@linux-mips.org Cc: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Cc: linux-s390@vger.kernel.org Cc: x86@kernel.org Cc: Kees Cook <keescook@chromium.org> Signed-off-by: Andy Lutomirski <luto@amacapital.net> Signed-off-by: Kees Cook <keescook@chromium.org> (backported from commit a4412fc9486ec85686c6c7929e7e829f62ae377e) Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: I4109ed2560d19349927c3e3f7648022ae23db318 Reviewed-on: http://git.am.freescale.net:8181/33029 Reviewed-by: Scott Wood <scottwood@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30powerpc/kernel: Make syscall_exit a local labelBogdan Purcareata
Currently when we back trace something that is in a syscall we see something like this: [c000000000000000] [c000000000000000] SyS_read+0x6c/0x110 [c000000000000000] [c000000000000000] syscall_exit+0x0/0x98 Although it's entirely correct, seeing syscall_exit at the bottom can be confusing - we were exiting from a syscall and then called SyS_read() ? If we instead change syscall_exit to be a local label we get something more intuitive: [c0000001fa46fde0] [c00000000026719c] SyS_read+0x6c/0x110 [c0000001fa46fe30] [c000000000009264] system_call+0x38/0xd0 ie. we were handling a system call, and it was SyS_read(). Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> (backported from commit 4c3b21686111e0ac6018469dacbc5549f9915cf8) Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: I2f04a5c9db260ffc36b95ce6ee48c50535053f7e Reviewed-on: http://git.am.freescale.net:8181/33028 Reviewed-by: Scott Wood <scottwood@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>
2015-03-30powerpc: Fix sys_call_table declaration to enable syscall tracingRomeo Cane
Declaring sys_call_table as a pointer causes the compiler to generate the wrong lookup code in arch_syscall_addr(). <arch_syscall_addr>: lis r9,-16384 rlwinm r3,r3,2,0,29 - lwz r11,30640(r9) - lwzx r3,r11,r3 + addi r9,r9,30640 + lwzx r3,r9,r3 blr The actual sys_call_table symbol, declared in assembler, is an array. If we lie about that to the compiler we get the wrong code generated, as above. This definition seems only to be used by the syscall tracing code in kernel/trace/trace_syscalls.c. With this patch I can successfully use the syscall tracepoints: bash-3815 [002] .... 333.239082: sys_write -> 0x2 bash-3815 [002] .... 333.239087: sys_dup2(oldfd: a, newfd: 1) bash-3815 [002] .... 333.239088: sys_dup2 -> 0x1 bash-3815 [002] .... 333.239092: sys_fcntl(fd: a, cmd: 1, arg: 0) bash-3815 [002] .... 333.239093: sys_fcntl -> 0x1 bash-3815 [002] .... 333.239094: sys_close(fd: a) bash-3815 [002] .... 333.239094: sys_close -> 0x0 Signed-off-by: Romeo Cane <romeo.cane.ext@coriant.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> (cherry picked from commit 1028ccf560b97adbf272381a61a67e17d44d1054) Signed-off-by: Bogdan Purcareata <bogdan.purcareata@freescale.com> Change-Id: I1754c0e1ca6c77cc56566bf50019c153ea405cbf Reviewed-on: http://git.am.freescale.net:8181/33026 Reviewed-by: Scott Wood <scottwood@freescale.com> Tested-by: Honghua Yin <Hong-Hua.Yin@freescale.com> Reviewed-by: Honghua Yin <Hong-Hua.Yin@freescale.com>