Commit 2e8c54db authored by Arnd Bergmann's avatar Arnd Bergmann

Merge tag 'imx-fixes-5.1' of...

Merge tag 'imx-fixes-5.1' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into arm/fixes

i.MX fixes for 5.1:
 - Correct phy mode setting of imx6dl-yapp4 board to fix a problem
   caused by commit 5ecdd77c ("net: dsa: qca8k: disable delay
   for RGMII mode").
 - Add a missing of_node_put call to fix leaked reference detected by
   coccinelle in imx51 machine code.
 - Fix imx6q cpuidle driver bug which causes that CPU might not wake up
   at expected time.
 - Increase reset duration of Ethernet phy Micrel KSZ9031RNX to fix
   transmission timeouts error seen on imx6qdl-phytec-pfla02 board.
 - Correct SPDX License Identifier style for imx6ull-pinfunc-snvs.h.
 - Fix 'bus-witdh' typos in imx6qdl-icore-rqs.dtsi.
 - Correct pseudo PHY address of switch device for imx6dl-yapp4 board.
 - Update PWM driver options in imx defconfig files due to the change
   on driver part.

* tag 'imx-fixes-5.1' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux:
  ARM: imx_v4_v5_defconfig: enable PWM driver
  ARM: imx_v6_v7_defconfig: continue compiling the pwm driver
  ARM: dts: imx6dl-yapp4: Use correct pseudo PHY address for the switch
  ARM: dts: imx6qdl: Fix typo in imx6qdl-icore-rqs.dtsi
  ARM: dts: imx6ull: Use the correct style for SPDX License Identifier
  ARM: dts: pfla02: increase phy reset duration
  ARM: imx6q: cpuidle: fix bug that CPU might not wake up at expected time
  ARM: imx51: fix a leaked reference by adding missing of_node_put
  ARM: dts: imx6dl-yapp4: Use rgmii-id phy mode on the cpu port
parents 0cee41d4 507aaeee
...@@ -114,9 +114,9 @@ phy_port3: phy@2 { ...@@ -114,9 +114,9 @@ phy_port3: phy@2 {
reg = <2>; reg = <2>;
}; };
switch@0 { switch@10 {
compatible = "qca,qca8334"; compatible = "qca,qca8334";
reg = <0>; reg = <10>;
switch_ports: ports { switch_ports: ports {
#address-cells = <1>; #address-cells = <1>;
...@@ -125,7 +125,7 @@ switch_ports: ports { ...@@ -125,7 +125,7 @@ switch_ports: ports {
ethphy0: port@0 { ethphy0: port@0 {
reg = <0>; reg = <0>;
label = "cpu"; label = "cpu";
phy-mode = "rgmii"; phy-mode = "rgmii-id";
ethernet = <&fec>; ethernet = <&fec>;
fixed-link { fixed-link {
......
...@@ -264,7 +264,7 @@ &usdhc3 { ...@@ -264,7 +264,7 @@ &usdhc3 {
pinctrl-2 = <&pinctrl_usdhc3_200mhz>; pinctrl-2 = <&pinctrl_usdhc3_200mhz>;
vmcc-supply = <&reg_sd3_vmmc>; vmcc-supply = <&reg_sd3_vmmc>;
cd-gpios = <&gpio1 1 GPIO_ACTIVE_LOW>; cd-gpios = <&gpio1 1 GPIO_ACTIVE_LOW>;
bus-witdh = <4>; bus-width = <4>;
no-1-8-v; no-1-8-v;
status = "okay"; status = "okay";
}; };
...@@ -275,7 +275,7 @@ &usdhc4 { ...@@ -275,7 +275,7 @@ &usdhc4 {
pinctrl-1 = <&pinctrl_usdhc4_100mhz>; pinctrl-1 = <&pinctrl_usdhc4_100mhz>;
pinctrl-2 = <&pinctrl_usdhc4_200mhz>; pinctrl-2 = <&pinctrl_usdhc4_200mhz>;
vmcc-supply = <&reg_sd4_vmmc>; vmcc-supply = <&reg_sd4_vmmc>;
bus-witdh = <8>; bus-width = <8>;
no-1-8-v; no-1-8-v;
non-removable; non-removable;
status = "okay"; status = "okay";
......
...@@ -91,6 +91,7 @@ &fec { ...@@ -91,6 +91,7 @@ &fec {
pinctrl-0 = <&pinctrl_enet>; pinctrl-0 = <&pinctrl_enet>;
phy-handle = <&ethphy>; phy-handle = <&ethphy>;
phy-mode = "rgmii"; phy-mode = "rgmii";
phy-reset-duration = <10>; /* in msecs */
phy-reset-gpios = <&gpio3 23 GPIO_ACTIVE_LOW>; phy-reset-gpios = <&gpio3 23 GPIO_ACTIVE_LOW>;
phy-supply = <&vdd_eth_io_reg>; phy-supply = <&vdd_eth_io_reg>;
status = "disabled"; status = "disabled";
......
// SPDX-License-Identifier: GPL-2.0 /* SPDX-License-Identifier: GPL-2.0 */
/* /*
* Copyright (C) 2016 Freescale Semiconductor, Inc. * Copyright (C) 2016 Freescale Semiconductor, Inc.
* Copyright (C) 2017 NXP * Copyright (C) 2017 NXP
......
...@@ -170,6 +170,9 @@ CONFIG_IMX_SDMA=y ...@@ -170,6 +170,9 @@ CONFIG_IMX_SDMA=y
# CONFIG_IOMMU_SUPPORT is not set # CONFIG_IOMMU_SUPPORT is not set
CONFIG_IIO=y CONFIG_IIO=y
CONFIG_FSL_MX25_ADC=y CONFIG_FSL_MX25_ADC=y
CONFIG_PWM=y
CONFIG_PWM_IMX1=y
CONFIG_PWM_IMX27=y
CONFIG_EXT4_FS=y CONFIG_EXT4_FS=y
# CONFIG_DNOTIFY is not set # CONFIG_DNOTIFY is not set
CONFIG_VFAT_FS=y CONFIG_VFAT_FS=y
......
...@@ -398,7 +398,7 @@ CONFIG_MAG3110=y ...@@ -398,7 +398,7 @@ CONFIG_MAG3110=y
CONFIG_MPL3115=y CONFIG_MPL3115=y
CONFIG_PWM=y CONFIG_PWM=y
CONFIG_PWM_FSL_FTM=y CONFIG_PWM_FSL_FTM=y
CONFIG_PWM_IMX=y CONFIG_PWM_IMX27=y
CONFIG_NVMEM_IMX_OCOTP=y CONFIG_NVMEM_IMX_OCOTP=y
CONFIG_NVMEM_VF610_OCOTP=y CONFIG_NVMEM_VF610_OCOTP=y
CONFIG_TEE=y CONFIG_TEE=y
......
...@@ -16,30 +16,23 @@ ...@@ -16,30 +16,23 @@
#include "cpuidle.h" #include "cpuidle.h"
#include "hardware.h" #include "hardware.h"
static atomic_t master = ATOMIC_INIT(0); static int num_idle_cpus = 0;
static DEFINE_SPINLOCK(master_lock); static DEFINE_SPINLOCK(cpuidle_lock);
static int imx6q_enter_wait(struct cpuidle_device *dev, static int imx6q_enter_wait(struct cpuidle_device *dev,
struct cpuidle_driver *drv, int index) struct cpuidle_driver *drv, int index)
{ {
if (atomic_inc_return(&master) == num_online_cpus()) { spin_lock(&cpuidle_lock);
/* if (++num_idle_cpus == num_online_cpus())
* With this lock, we prevent other cpu to exit and enter
* this function again and become the master.
*/
if (!spin_trylock(&master_lock))
goto idle;
imx6_set_lpm(WAIT_UNCLOCKED); imx6_set_lpm(WAIT_UNCLOCKED);
cpu_do_idle(); spin_unlock(&cpuidle_lock);
imx6_set_lpm(WAIT_CLOCKED);
spin_unlock(&master_lock);
goto done;
}
idle:
cpu_do_idle(); cpu_do_idle();
done:
atomic_dec(&master); spin_lock(&cpuidle_lock);
if (num_idle_cpus-- == num_online_cpus())
imx6_set_lpm(WAIT_CLOCKED);
spin_unlock(&cpuidle_lock);
return index; return index;
} }
......
...@@ -59,6 +59,7 @@ static void __init imx51_m4if_setup(void) ...@@ -59,6 +59,7 @@ static void __init imx51_m4if_setup(void)
return; return;
m4if_base = of_iomap(np, 0); m4if_base = of_iomap(np, 0);
of_node_put(np);
if (!m4if_base) { if (!m4if_base) {
pr_err("Unable to map M4IF registers\n"); pr_err("Unable to map M4IF registers\n");
return; return;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment