summaryrefslogtreecommitdiff
path: root/arch
AgeCommit message (Collapse)Author
2019-03-21imx6qdl-colibri.dtsi: UHS-I support for v1.1a hwtoradex_4.1-2.0.x-imx-nextIgor Opaniuk
Provide proper configuration for VGEN3, to make sure it's is always powered which allows that rail to be automatically switched to 1.8 volts for proper UHS-I operation. By default it's disabled. With UHS-I enabled: [ 104.153898] mmc1: new ultra high speed SDR104 SDHC card at address 59b4 [ 104.166202] mmcblk1: mmc1:59b4 USD00 15.0 GiB [ 104.173923] mmcblk1: p1 root@colibri-imx6:~# hdparm -t /dev/mmcblk1 /dev/mmcblk1: Timing buffered disk reads: 226 MB in 3.01 seconds = 75.01 MB/sec Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2018-08-16MLK-16266-01 ARM: imx: improve the soc revision calculation flowBai Ping
On our i.MX6 SOC, the DIGPROG register is used for represent the SOC ID and silicon revision. The revision has two part: MAJOR and MINOR. each is represented in 8 bits in the register. bits [15:8]: reflect the MAJOR part of the revision; bits [7:0]: reflect the MINOR part of the revision; In our linux kernel, the soc revision is represented in 8 bits. MAJOR part and MINOR each occupy 4 bits. previous method does NOT take care about the MAJOR part in DIGPROG register. So reformat the revision read from the HW to compatible the revision format used in kernel. Signed-off-by: Bai Ping <ping.bai@nxp.com> (cherry picked from commit cf6fa1477149d4bddd096c71b46fa6c4cf9cf750) Acked-by: Stefan Agner <stefan.agner@toradex.com>
2018-07-25imx6ull-colibri.dtsi: change touch i2c parametersMax Krummenacher
Switch on 22 kOhm pull ups and lower the I2C frequency to around 40kHz to get a more reliable communication. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> (cherry picked from commit ffb2a2a59869415921e816614749ad5e48f9c077)
2018-06-19Revert "ARM: dts: colibri-imx7: limit eMMC SDHC frequency to 100MHz"toradex_4.1-2.0.x-imxStefan Agner
Several modules have issues with HS400 at 100MHz at room temperature but they seem to work fine at HS400 at 200MHz. Do not restrict frequency for now. This reverts commit 166fb4842e780f63c31622af706335e7dcd48c24. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2018-06-19arm: Invalidate BTB on prefetch abort outside of user mapping on Cortex A8, ↵Marc Zyngier
A9, A12 and A17 In order to prevent aliasing attacks on the branch predictor, invalidate the BTB on CPUs that are known to be affected when taking a prefetch abort on a address that is outside of a user task limit. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> (cherry picked from commit a07373c8c365746583f25f49fee41b1bc0ff94b2) [jason: adapted to 4.1] Signed-off-by: Jason Liu <jason.hui.liu@nxp.com>
2018-06-19arm: Add BTB invalidation on switch_mm for Cortex-A9, A12 and A17Marc Zyngier
In order to avoid aliasing attacks against the branch predictor, some implementations require to invalidate the BTB when switching from one user context to another. For this, we reuse the existing implementation for Cortex-A8, and apply it to A9, A12 and A17. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com> (cherry picked commit from efcd0e857a656bbd1c1da15ff984ad6402332c61) [jason: adapted to 4.1] Signed-off-by: Jason Liu <jason.hui.liu@nxp.com>
2018-06-19ARM: dts: imx6qdl: Fix SPDIF regressionFabio Estevam
Commit 833f2cbf7091 ("ARM: dts: imx6: change the core clock of spdif") changed many more clocks than only the SPDIF core clock as stated in the commit message. The MLB clock has been added and this causes SPDIF regression as reported by Xavi Drudis Ferran and also in this forum post: https://forum.digikey.com/thread/34240 The MX6Q Reference Manual does not mention that MLB is a clock related to SPDIF, so change it back to a dummy clock to restore SPDIF functionality. Thanks to Ambika for providing the fix at: https://community.nxp.com/thread/387131 Fixes: 833f2cbf7091 ("ARM: dts: imx6: change the core clock of spdif") Cc: <stable@vger.kernel.org> # 4.4.x Reported-by: Xavi Drudis Ferran <xdrudis@tinet.cat> Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com> Tested-by: Xavi Drudis Ferran <xdrudis@tinet.cat> Signed-off-by: Shawn Guo <shawnguo@kernel.org> (cherry picked from commit f065e9e4addd75c21bb976bb2558648bf4f61de6) Tested playback and record on pulseaudio with 44.1kHz samples. Signed-off-by: Gerard Salvatella <gerard.salvatella@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-11-27arm: dts: imx6ull-colibri: enable pwmColibri-iMX6ULL_LXDE-Image_2.7b5-20171201Max Krummenacher
Now that the PWM work enable them. While at it move the backlight pwm settings into the carrier board file were it belongs. Periode and polarity are carrier board / display dependent. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-11-27arm: dts: imx6ull: add support for PWM polarity controlMax Krummenacher
Update #pwm-cells to 3 in order to support PWM signal polarity control. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-11-27arm: dts: imx6ull: fix pwm clockMax Krummenacher
All PWM clock instances have their clock gate. Add these consistently. Fixes freezing the kernel when one of these instances is used with IMX6UL_CLK_DUMMY as its clock source. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-11-27colibri_imx6ull: add dtb for wifi variantMax Krummenacher
Add a device tree for the Colibri iMX6ULL 512MB Wi-Fi / BT. This is done by splitting out common nodes / properties into common *dtsi files and keep only the differences in a separate files. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-11-27ARM: dts: colibri-imx7: limit eMMC SDHC frequency to 100MHzStefan Agner
During temperature testing modules print the following error every now and then: [ 12.231006] mmc0: Timeout waiting for hardware interrupt. retries left=0 opcode=12 Often the SDHC controller/driver does not recover from the issue which leads to a Kernel panic (e.g. during boot the kernel can not mount the root fs). Lowering the frequency to 100MHz proves to be stable and affects effective bandwith by less than 5%. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-11-27mx6ull-colibri.dtsi: remove wrong bmode pin muxingMax Krummenacher
There are macros specifying the bmode pins for i.MX 6UL and ULL. Don't use the UL macros. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-11-27MLK-14409-02 ARM: dts: imx: Add 900MHz setpoint on i.mx6ullBai Ping
Add 900MHz/1.25V setpoint according the latest datasheet(Rev.1,2/2017), we add a 25mV voltage margin to cover the IR frop and board tolerance. Signed-off-by: Bai Ping <ping.bai@nxp.com> (cherry picked from commit 9c31f7bf938adb9a808ea7bf637ccecf53f6e7be) (cherry picked from commit c27010d99a3d91703ea2d1a3f9630a9dedc3f86f)
2017-11-27MLK-14409-01 ARM: imx: Add speed grading fuse check for 900MHz on i.mx6ullBai Ping
According to the latest datasheet(Rev.1,02/2017), when the internal LDO is enabled, the ARM core can run at 900MHz. We need to check the speed grading fuse to determine the max ARM core frequency. Signed-off-by: Bai Ping <ping.bai@nxp.com> (cherry picked from commit cc0edd14c5fc3b5590302572687b08f80563c683) (cherry picked from commit c0821bb630b5a993a7cb8405f228f8bbd9e0bef7)
2017-11-27MLK-16134 ARM: dts: imx6ull: update imx6ull header file with the latest ↵Fugang Duan
imx6ull RDP Update imx6ull header file with the latest imx6ull RDP. - add new pin function definitions. - update pin function changes. Signed-off-by: Fugang Duan <fugang.duan@nxp.com> Reviewed-by: Richard Zhu <hongxing.zhu@nxp.com> (cherry picked from commit 2c32aec9f6b910e03c7d422ad524352663547f52)
2017-11-27imx6ull-colibri.dtsi: remove wrong cpu operating-pointsMax Krummenacher
imx6ull.dtsi contains the values for 800/900MHz i.MX 6ULL. Don't override the values here with wrong cpu voltages. This fixes the i.MX6ULL 512MB boot freeze and it fixes the SoC temperature sensor. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-31imx6ull-colibri.dtsi: alias ethernet macsMax Krummenacher
We use the second ethernet MAC for the on module ethernet. Use an alias so that U-Boot fixes up the device tree to assign the MAC address corresponding to the serial number to the second MAC and uses the (serial# + 0x100000) one for the first MAC. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-31imx6ull-colibri.dtsi: make adc1 providing 10 channelsMax Krummenacher
By default one can only use channels 0 and 1. The AD channels on the SODIMM are connected as follows: AD0 channel 0 AD1 channel 1 AD2 channel 8 AD3 channel 9 Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-31imx6ull-colibri.dtsi: cleanupMax Krummenacher
Move all entries for node cpu0 together. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02colibri-imx6ull_defconfig: synchronize with colibri_imx7Colibri-iMX7_LXDE-Image_2.7b4-20171005Colibri-iMX6_LXDE-Image_2.7b4-20171005Apalis-iMX6_LXDE-Image_2.7b4-20171005Max Krummenacher
This brings in the configuration changes needed for backports. Also remove drivers not used in a Colibri iMX6ULL. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02toradex defconfigs: synchronize with defconfigs in oeMax Krummenacher
Synchronize the defconfigs with changes done in meta-toradex-nxp. Normalize the defconfigs by make ..._defconfig make savedevconig cp defconfig arch/arm/configs/..._defconfig Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02colibri-imx6ull_defconfig: add atmel-mxt-ts as a moduleMax Krummenacher
Enable atmel mxt multi-touch controller driver to be built as a module. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02ARM: dts: imx6ull-colibri: add atmel mxt multitouch controllerMax Krummenacher
Add atmel mxt multitouch controller driver which is interfaced over I2C bus. This controller is used by the Logic Technologies, Capacitive Touch Display 7" Parallel (LT161010-2NHC). Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02colibri_imx7_defconfig: add atmel-mxt-ts as a moduleBhuvanchandra DV
Enable atmel mxt multi-touch controller driver to be built as a module. Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02ARM: dts: imx7-colibri: add atmel mxt multitouch controllerBhuvanchandra DV
Add atmel mxt multitouch controller driver which is interfaced over I2C bus. This controller is used by the Logic Technologies, Capacitive Touch Display 7" Parallel (LT161010-2NHC). Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02ARM: dts: colibri-imx7: add new gpio hog grpBhuvanchandra DV
Add new gpio hog group for atmel mxt ts GPIOs. Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02colibri_imx6_defconfig: add atmel-mxt-ts as a moduleBhuvanchandra DV
Enable atmel mxt multi-touch controller driver to be built as a module. Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02ARM: dts: imx6dl-colibri: add atmel mxt multitouch controllerBhuvanchandra DV
Add atmel mxt multitouch controller driver which is interfaced over I2C bus. This controller is used by the Logic Technologies, Capacitive Touch Display 7" Parallel (LT161010-2NHC). Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02apalis_imx6_defconfig: add atmel-mxt-ts as a moduleBhuvanchandra DV
Enable atmel mxt multi-touch controller driver to be built as a module. Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02ARM: dts: imx6qdl-apalis: add atmel mxt multitouch controllerBhuvanchandra DV
Add atmel mxt multitouch controller driver which is interfaced over I2C bus. This controller is used by the Logic Technologies, Capacitive Touch Display 7" Parallel (LT161010-2NHC). Signed-off-by: Bhuvanchandra DV <bhuvanchandra.dv@toradex.com> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02imx6ull-colibri dtb: disable all pwmMax Krummenacher
They currently don't work. Activating them from the sysfs does freeze the kernel. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02ARM: imx: clk: enable OCOTP clock by defaultStefan Agner
For some reason USDHC and USB access crashes the kernel if the OCOTP clock is not enabled. It seems not to be software related since there is no direct access from the USDHC/Chipidea USB driver to the OCOTP IP. It might be that the hardware checks the fuses to determine if the particular SoC is supposed to let user access a certain peripheral... Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02colibri imx6ull: add initial device treeMax Krummenacher
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02colibri-imx6ull_defconfig: add a defconfigMax Krummenacher
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02imx6ull.dtsi: include all needed definitionsMax Krummenacher
The file uses linux,keycode = <KEY_POWER>;, so include the header which defines KEY_POWER. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02imx: Fix 'Expose SoC unique ID' for newer i.MX6Max Krummenacher
i.MX6 SL/UL/ULL use a different node in the device tree for with ocotp. So change to the relevant compatible string for these SoCs. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02imx6dl-colibri-eval-v3: fix weim nodeMax Krummenacher
With the move from the 3.14.52 to the 4.1 kernel the way the weim node defines chipselects changed. A phandle to the gpr node is needed. Only the following 4 configuration can be specified in the ranges property: CS0(128M), CS1 (0M), CS2(0M), CS3(0M) CS0(64M), CS1(64M), CS2(0M), CS3(0M) CS0(64M), CS1(32M), CS2(32M), CS3(0M) CS0(32M), CS1(32M), CS2(32M), CS3(32M) Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Acked-by: Stefan Agner <stefan.agner@toradex.com>
2017-10-02ARM: dts: imx7-colibri: add Colibri iMX7 Dual 1GB (eMMC)Stefan Agner
Add support for the latest addition to the Colibri iMX7 familiy, Colibri iMX7 Dual 1GB with eMMC storage. Signed-off-by: Stefan Agner <stefan.agner@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-10-02apalis_imx6: update defconfig for wifiDominik Sliwa
Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Max Krummenacher <max.krummenacher@toradex.com>
2017-09-27Merge remote-tracking branch 'fslc/4.1-2.0.x-imx' into toradex_4.1-2.0.x-imxMax Krummenacher
2017-09-22Merge tag 'v4.1.44' into 4.1-2.0.x-imxOtavio Salvador
Linux 4.1.44 * tag 'v4.1.44': (180 commits) Linux 4.1.44 mtd: fsl-quadspi: fix macro collision problems with READ/WRITE pinctrl: samsung: Remove bogus irq_[un]mask from resource management pinctrl: sunxi: add a missing function of A10/A20 pinctrl driver pnfs/blocklayout: require 64-bit sector_t iio: adc: vf610_adc: Fix VALT selection value for REFSEL bits usb:xhci:Add quirk for Certain failing HP keyboard on reset after resume usb: quirks: Add no-lpm quirk for Moshi USB to Ethernet Adapter USB: Check for dropped connection before switching to full speed uas: Add US_FL_IGNORE_RESIDUE for Initio Corporation INIC-3069 iio: light: tsl2563: use correct event code staging:iio:resolver:ad2s1210 fix negative IIO_ANGL_VEL read USB: hcd: Mark secondary HCD as dead if the primary one died USB: serial: pl2303: add new ATEN device id USB: serial: cp210x: add support for Qivicon USB ZigBee dongle USB: serial: option: add D-Link DWM-222 device ID nfs/flexfiles: fix leak of nfs4_ff_ds_version arrays fuse: initialize the flock flag in fuse_file on allocation iscsi-target: Fix iscsi_np reset hung task during parallel delete iscsi-target: fix memory leak in iscsit_setup_text_cmd() ... Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
2017-09-10KVM: arm/arm64: Handle hva aging while destroying the vmSuzuki K Poulose
[ Upstream commit 7e5a672289c9754d07e1c3b33649786d3d70f5e4 ] The mmu_notifier_release() callback of KVM triggers cleaning up the stage2 page table on kvm-arm. However there could be other notifier callbacks in parallel with the mmu_notifier_release(), which could cause the call backs ending up in an empty stage2 page table. Make sure we check it for all the notifier callbacks. Cc: stable@vger.kernel.org Fixes: commit 293f29363 ("kvm-arm: Unmap shadow pagetables properly") Reported-by: Alex Graf <agraf@suse.de> Reviewed-by: Christoffer Dall <cdall@linaro.org> Signed-off-by: Suzuki K Poulose <suzuki.poulose@arm.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
2017-09-10sparc64: Prevent perf from running during super critical sectionsRob Gardner
[ Upstream commit fc290a114fc6034b0f6a5a46e2fb7d54976cf87a ] This fixes another cause of random segfaults and bus errors that may occur while running perf with the callgraph option. Critical sections beginning with spin_lock_irqsave() raise the interrupt level to PIL_NORMAL_MAX (14) and intentionally do not block performance counter interrupts, which arrive at PIL_NMI (15). But some sections of code are "super critical" with respect to perf because the perf_callchain_user() path accesses user space and may cause TLB activity as well as faults as it unwinds the user stack. One particular critical section occurs in switch_mm: spin_lock_irqsave(&mm->context.lock, flags); ... load_secondary_context(mm); tsb_context_switch(mm); ... spin_unlock_irqrestore(&mm->context.lock, flags); If a perf interrupt arrives in between load_secondary_context() and tsb_context_switch(), then perf_callchain_user() could execute with the context ID of one process, but with an active TSB for a different process. When the user stack is accessed, it is very likely to incur a TLB miss, since the h/w context ID has been changed. The TLB will then be reloaded with a translation from the TSB for one process, but using a context ID for another process. This exposes memory from one process to another, and since it is a mapping for stack memory, this usually causes the new process to crash quickly. This super critical section needs more protection than is provided by spin_lock_irqsave() since perf interrupts must not be allowed in. Since __tsb_context_switch already goes through the trouble of disabling interrupts completely, we fix this by moving the secondary context load down into this better protected region. Orabug: 25577560 Signed-off-by: Dave Aldridge <david.j.aldridge@oracle.com> Signed-off-by: Rob Gardner <rob.gardner@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
2017-09-10bpf, s390: fix jit branch offset related to ldimm64Daniel Borkmann
[ Upstream commit b0a0c2566f28e71e5e32121992ac8060cec75510 ] While testing some other work that required JIT modifications, I run into test_bpf causing a hang when JIT enabled on s390. The problematic test case was the one from ddc665a4bb4b (bpf, arm64: fix jit branch offset related to ldimm64), and turns out that we do have a similar issue on s390 as well. In bpf_jit_prog() we update next instruction address after returning from bpf_jit_insn() with an insn_count. bpf_jit_insn() returns either -1 in case of error (e.g. unsupported insn), 1 or 2. The latter is only the case for ldimm64 due to spanning 2 insns, however, next address is only set to i + 1 not taking actual insn_count into account, thus fix is to use insn_count instead of 1. bpf_jit_enable in mode 2 provides also disasm on s390: Before fix: 000003ff800349b6: a7f40003 brc 15,3ff800349bc ; target 000003ff800349ba: 0000 unknown 000003ff800349bc: e3b0f0700024 stg %r11,112(%r15) 000003ff800349c2: e3e0f0880024 stg %r14,136(%r15) 000003ff800349c8: 0db0 basr %r11,%r0 000003ff800349ca: c0ef00000000 llilf %r14,0 000003ff800349d0: e320b0360004 lg %r2,54(%r11) 000003ff800349d6: e330b03e0004 lg %r3,62(%r11) 000003ff800349dc: ec23ffeda065 clgrj %r2,%r3,10,3ff800349b6 ; jmp 000003ff800349e2: e3e0b0460004 lg %r14,70(%r11) 000003ff800349e8: e3e0b04e0004 lg %r14,78(%r11) 000003ff800349ee: b904002e lgr %r2,%r14 000003ff800349f2: e3b0f0700004 lg %r11,112(%r15) 000003ff800349f8: e3e0f0880004 lg %r14,136(%r15) 000003ff800349fe: 07fe bcr 15,%r14 After fix: 000003ff80ef3db4: a7f40003 brc 15,3ff80ef3dba 000003ff80ef3db8: 0000 unknown 000003ff80ef3dba: e3b0f0700024 stg %r11,112(%r15) 000003ff80ef3dc0: e3e0f0880024 stg %r14,136(%r15) 000003ff80ef3dc6: 0db0 basr %r11,%r0 000003ff80ef3dc8: c0ef00000000 llilf %r14,0 000003ff80ef3dce: e320b0360004 lg %r2,54(%r11) 000003ff80ef3dd4: e330b03e0004 lg %r3,62(%r11) 000003ff80ef3dda: ec230006a065 clgrj %r2,%r3,10,3ff80ef3de6 ; jmp 000003ff80ef3de0: e3e0b0460004 lg %r14,70(%r11) 000003ff80ef3de6: e3e0b04e0004 lg %r14,78(%r11) ; target 000003ff80ef3dec: b904002e lgr %r2,%r14 000003ff80ef3df0: e3b0f0700004 lg %r11,112(%r15) 000003ff80ef3df6: e3e0f0880004 lg %r14,136(%r15) 000003ff80ef3dfc: 07fe bcr 15,%r14 test_bpf.ko suite runs fine after the fix. Fixes: 054623105728 ("s390/bpf: Add s390x eBPF JIT compiler backend") Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Tested-by: Michael Holzheu <holzheu@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
2017-09-10ARM: 8632/1: ftrace: fix syscall name matchingRabin Vincent
[ Upstream commit 270c8cf1cacc69cb8d99dea812f06067a45e4609 ] ARM has a few system calls (most notably mmap) for which the names of the functions which are referenced in the syscall table do not match the names of the syscall tracepoints. As a consequence of this, these tracepoints are not made available. Implement arch_syscall_match_sym_name to fix this and allow tracing even these system calls. Signed-off-by: Rabin Vincent <rabinv@axis.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
2017-09-10x86/boot: Add missing declaration of string functionsNicholas Mc Guire
[ Upstream commit fac69d0efad08fc15e4dbfc116830782acc0dc9a ] Add the missing declarations of basic string functions to string.h to allow a clean build. Fixes: 5be865661516 ("String-handling functions for the new x86 setup code.") Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org> Link: http://lkml.kernel.org/r/1483781911-21399-1-git-send-email-hofrat@osadl.org Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
2017-09-10sparc64: Measure receiver forward progress to avoid send mondo timeoutJane Chu
[ Upstream commit 9d53caec84c7c5700e7c1ed744ea584fff55f9ac ] A large sun4v SPARC system may have moments of intensive xcall activities, usually caused by unmapping many pages on many CPUs concurrently. This can flood receivers with CPU mondo interrupts for an extended period, causing some unlucky senders to hit send-mondo timeout. This problem gets worse as cpu count increases because sometimes mappings must be invalidated on all CPUs, and sometimes all CPUs may gang up on a single CPU. But a busy system is not a broken system. In the above scenario, as long as the receiver is making forward progress processing mondo interrupts, the sender should continue to retry. This patch implements the receiver's forward progress meter by introducing a per cpu counter 'cpu_mondo_counter[cpu]' where 'cpu' is in the range of 0..NR_CPUS. The receiver increments its counter as soon as it receives a mondo and the sender tracks the receiver's counter. If the receiver has stopped making forward progress when the retry limit is reached, the sender declares send-mondo-timeout and panic; otherwise, the receiver is allowed to keep making forward progress. In addition, it's been observed that PCIe hotplug events generate Correctable Errors that are handled by hypervisor and then OS. Hypervisor 'borrows' a guest cpu strand briefly to provide the service. If the cpu strand is simultaneously the only cpu targeted by a mondo, it may not be available for the mondo in 20msec, causing SUN4V mondo timeout. It appears that 1 second is the agreed wait time between hypervisor and guest OS, this patch makes the adjustment. Orabug: 25476541 Orabug: 26417466 Signed-off-by: Jane Chu <jane.chu@oracle.com> Reviewed-by: Steve Sistare <steven.sistare@oracle.com> Reviewed-by: Anthony Yznaga <anthony.yznaga@oracle.com> Reviewed-by: Rob Gardner <rob.gardner@oracle.com> Reviewed-by: Thomas Tai <thomas.tai@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
2017-09-10ARM: dts: armada-38x: Fix irq type for pca955Gregory CLEMENT
[ Upstream commit 8d4514173211586c6238629b1ef1e071927735f5 ] As written in the datasheet the PCA955 can only handle low level irq and not edge irq. Without this fix the interrupt is not usable for pca955: the gpio-pca953x driver already set the irq type as low level which is incompatible with edge type, then the kernel prevents using the interrupt: "irq: type mismatch, failed to map hwirq-18 for /soc/internal-regs/gpio@18100!" Fixes: 928413bd859c ("ARM: mvebu: Add Armada 388 General Purpose Development Board support") Cc: stable@vger.kernel.org Signed-off-by: Gregory CLEMENT <gregory.clement@free-electrons.com> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
2017-09-10KVM: async_pf: make rcu irq exit if not triggered from idle taskWanpeng Li
[ Upstream commit 337c017ccdf2653d0040099433fc1a2b1beb5926 ] WARNING: CPU: 5 PID: 1242 at kernel/rcu/tree_plugin.h:323 rcu_note_context_switch+0x207/0x6b0 CPU: 5 PID: 1242 Comm: unity-settings- Not tainted 4.13.0-rc2+ #1 RIP: 0010:rcu_note_context_switch+0x207/0x6b0 Call Trace: __schedule+0xda/0xba0 ? kvm_async_pf_task_wait+0x1b2/0x270 schedule+0x40/0x90 kvm_async_pf_task_wait+0x1cc/0x270 ? prepare_to_swait+0x22/0x70 do_async_page_fault+0x77/0xb0 ? do_async_page_fault+0x77/0xb0 async_page_fault+0x28/0x30 RIP: 0010:__d_lookup_rcu+0x90/0x1e0 I encounter this when trying to stress the async page fault in L1 guest w/ L2 guests running. Commit 9b132fbe5419 (Add rcu user eqs exception hooks for async page fault) adds rcu_irq_enter/exit() to kvm_async_pf_task_wait() to exit cpu idle eqs when needed, to protect the code that needs use rcu. However, we need to call the pair even if the function calls schedule(), as seen from the above backtrace. This patch fixes it by informing the RCU subsystem exit/enter the irq towards/away from idle for both n.halted and !n.halted. Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: Radim Krčmář <rkrcmar@redhat.com> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: stable@vger.kernel.org Signed-off-by: Wanpeng Li <wanpeng.li@hotmail.com> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Radim Krčmář <rkrcmar@redhat.com> Signed-off-by: Sasha Levin <alexander.levin@verizon.com>