[PATCH] powerpc/papr_scm: use dev_get_drvdata

2022-05-31 Thread Haowen Bai
Eliminate direct accesses to the driver_data field. Signed-off-by: Haowen Bai --- arch/powerpc/platforms/pseries/papr_scm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/platforms/pseries/papr_scm.c b/arch/powerpc/platforms/pseries/papr_scm.c index

[PATCH V2] powerpc/eeh: Drop redundant spinlock initialization

2022-05-10 Thread Haowen Bai
slot_errbuf_lock has declared and initialized by DEFINE_SPINLOCK, so we don't need to spin_lock_init again, drop it. Signed-off-by: Haowen Bai --- V1->V2: update comment arch/powerpc/platforms/pseries/eeh_pseries.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --gi

[PATCH] powerpc/eeh: Drop redundant spinlock initialization

2022-05-10 Thread Haowen Bai
slot_errbuf_lock has declared and initialized by DEFINE_SPINLOCK, so we don't need to spin_lock_init again, drop it. Signed-off-by: Haowen Bai --- arch/powerpc/platforms/pseries/eeh_pseries.c | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/powerpc/platforms/pseries/eeh_pseries.c b

[PATCH V2] selftests/powerpc/pmu: Fix unsigned function returning negative constant

2022-04-25 Thread Haowen Bai
The function __perf_reg_mask has an unsigned return type, but returns a negative constant to indicate an error condition. So we change unsigned to int. Fixes: 5f6c3061af7c ("selftests/powerpc/pmu: Add utility functions to post process the mmap buffer") Signed-off-by: Haowen Bai --- V

[PATCH] selftests/powerpc/pmu: Fix unsigned function returning negative constant

2022-04-24 Thread Haowen Bai
The function __perf_reg_mask has an unsigned return type, but returns a negative constant to indicate an error condition. So we change unsigned to int. Signed-off-by: Haowen Bai --- tools/testing/selftests/powerpc/pmu/sampling_tests/misc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCH] powerpc/pci: Remove useless null check before call of_node_put()

2022-04-20 Thread Haowen Bai
No need to add null check before call of_node_put(), since the implementation of of_node_put() has done it. Signed-off-by: Haowen Bai --- arch/powerpc/kernel/pci_dn.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/kernel/pci_dn.c b/arch/powerpc/kernel

[PATCH] ASoC: imx-hdmi: remove useless null check before call of_node_put()

2022-04-20 Thread Haowen Bai
No need to add null check before call of_node_put(), since the implementation of of_node_put() has done it. Signed-off-by: Haowen Bai --- sound/soc/fsl/imx-hdmi.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sound/soc/fsl/imx-hdmi.c b/sound/soc/fsl/imx-hdmi.c index

[PATCH] powerpc/xmon: Fix warning comparing pointer to 0

2022-03-23 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- arch/powerpc/xmon/spu-dis.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/arch/powerpc/xmon/spu-dis.c b/arch/powerpc/xmon/spu-dis.c index 4b0a4e6..6078aa5 100644

[PATCH] macintosh: macio-adb: Fix warning comparing pointer to 0

2022-03-17 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- drivers/macintosh/macio-adb.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/macintosh/macio-adb.c b/drivers/macintosh/macio-adb.c index dc634c2..b7d287a 100644 --- a

[PATCH] macintosh: windfarm_pm121: Fix warning comparing pointer to 0

2022-03-16 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- drivers/macintosh/windfarm_pm121.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/macintosh/windfarm_pm121.c b/drivers/macintosh/windfarm_pm121.c index ba1ec6f..f0aa263

[PATCH] macintosh: smu: Fix warning comparing pointer to 0

2022-03-16 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- drivers/macintosh/smu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/macintosh/smu.c b/drivers/macintosh/smu.c index a4fbc3f..d72d073 100644 --- a/drivers/macintosh

[PATCH] macintosh: windfarm_pm91: Fix warning comparing pointer to 0

2022-03-16 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- drivers/macintosh/windfarm_pm91.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/macintosh/windfarm_pm91.c b/drivers/macintosh/windfarm_pm91.c index 3f346af..568f8a2 100644

[PATCH] macintosh: via-cuda: Fix warning comparing pointer to 0

2022-03-16 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- drivers/macintosh/via-cuda.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/macintosh/via-cuda.c b/drivers/macintosh/via-cuda.c index cd267392..05a3cd9 100644 --- a

[PATCH] macintosh: adb: Fix warning comparing pointer to 0

2022-03-16 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- drivers/macintosh/adb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/macintosh/adb.c b/drivers/macintosh/adb.c index 73b3961..996f310 100644 --- a/drivers/macintosh

[PATCH] macintosh: windfarm_pm81: Fix warning comparing pointer to 0

2022-03-16 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- drivers/macintosh/windfarm_pm81.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/macintosh/windfarm_pm81.c b/drivers/macintosh/windfarm_pm81.c index 82c67a4..1dfced5

[PATCH] macintosh: macio-adb: Fix warning comparing pointer to 0

2022-03-16 Thread Haowen Bai
Avoid pointer type value compared with 0 to make code clear. Signed-off-by: Haowen Bai --- drivers/macintosh/macio-adb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/macintosh/macio-adb.c b/drivers/macintosh/macio-adb.c index dc634c2..51afa46 100644 --- a

[PATCH] ASoC: imx-pcm-rpmsg: Directly return 0 instead of using local ret variable

2022-03-01 Thread Haowen Bai
fixes coccinelle warning: sound/soc/fsl/imx-pcm-rpmsg.c:285:5-8: Unneeded variable: "ret". Return "0" on line 308 Signed-off-by: Haowen Bai --- sound/soc/fsl/imx-pcm-rpmsg.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sound/soc/fsl/imx-pcm-rpmsg.c