[PATCH -next] staging: bcm2708_vchiq: remove .owner field for driver

2016-10-17 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Remove .owner field if calls are used which set it automatically. Generated by: scripts/coccinelle/api/platform_no_drv_owner.cocci Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/staging/vc04_services/interface/vchiq_arm

[PATCH -next] auxdisplay: img-ascii-lcd: use setup_timer instead of init_timer and data fields

2016-10-17 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Use setup_timer function instead of initializing timer with the function and data fields Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/auxdisplay/img-ascii-lcd.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)

[PATCH -next] mm: numa: remove duplicated include from mprotect.c

2016-10-17 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Remove duplicated include. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- mm/mprotect.c | 1 - 1 file changed, 1 deletion(-) diff --git a/mm/mprotect.c b/mm/mprotect.c index bcdbe62..1193652 100644 --- a/mm/mprotect.c +++ b/m

[PATCH -next] greybus: arche-platform: Add missing of_node_put() in arche_platform_change_state()

2016-10-17 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> This node pointer is returned by of_find_compatible_node() with refcount incremented in this function. of_node_put() on it before exitting this function. This is detected by Coccinelle semantic patch. Signed-off-by: Wei Yongjun <weiyongj...@h

[PATCH -next] libnvdimm: fix error return code in __blk_label_update()

2016-10-17 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Fix to return error code -ENXIO from the nd_label_alloc_slot() error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/nvdimm/label.c | 4 +++- 1 file changed,

[PATCH -next] soc: ti: wkup_m3_ipc: Fix error return code in wkup_m3_ipc_probe()

2017-01-12 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Fix to return a negative error code from the kthread_run() error handling case instead of 0, as done elsewhere in this function. Fixes: cdd5de500b2c ("soc: ti: Add wkup_m3_ipc driver") Signed-off-by: Wei Yongjun <weiyongj...@huawei.co

[PATCH -next] powerpc/pseries: Fix typo in parameter description

2017-01-12 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Fix typo in parameter description. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- arch/powerpc/platforms/pseries/cmm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/platforms/pseries/cmm.c b/

[PATCH -next] tracing: Fix return value check in trace_benchmark_reg()

2017-01-12 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> In case of error, the function kthread_run() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- kernel/trace/trace_ben

[PATCH -next] drm/atomic: make release_crtc_commit() static

2017-01-12 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Fixes the following sparse warning: drivers/gpu/drm/drm_atomic_helper.c:1360:6: warning: symbol 'release_crtc_commit' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/drm_ato

[PATCH -next] drm/hisilicon/hibmc: Fix wrong pointer passed to PTR_ERR()

2017-01-12 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> PTR_ERR should access the value just tested by IS_ERR, otherwise the wrong error code will be returned. Fixes: d1667b86795a ("drm/hisilicon/hibmc: Add support for frame buffer") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com>

[PATCH] drm/etnaviv: fix missing unlock on error in etnaviv_gpu_submit()

2017-04-11 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Add the missing unlock before return from function etnaviv_gpu_submit() in the error handling case. Fixes: f3cd1b064f11 ("drm/etnaviv: (re-)protect fence allocation with GPU mutex") Signed-off-by: Wei Yongjun <weiyongj...@huawei.co

[PATCH -next] firmware: Google VPD: Fix return value check in vpd_platform_init()

2017-04-26 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> In case of error, the function platform_device_register_simple() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: 049a59db34eb ("firmware: Google VPD sysfs driver&q

[PATCH -next] irqchip/mbigen: Fix return value check in mbigen_device_probe()

2017-04-27 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> In case of error, the function devm_ioremap() returns NULL pointer not ERR_PTR(). Use devm_ioremap_resource() instead of devm_ioremap() to fix the IS_ERR() test issue. Fixes: 76e1f77f9c26 ("irqchip/mbigen: Introduce mbigen_of_create_domain

[PATCH -next] irqchip/qcom: Use builtin_platform_driver to simplify the code

2017-04-25 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Use the builtin_platform_driver() macro to make the code simpler. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/irqchip/qcom-irq-combiner.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/drivers/

[PATCH -next] auxdisplay: Convert list_for_each to entry variant

2017-04-25 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> convert list_for_each() to list_for_each_entry() where applicable. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/auxdisplay/panel.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/auxdispl

[PATCH -next] firmware: google memconsole: Fix return value check in platform_memconsole_init()

2017-04-24 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> In case of error, the function platform_device_register_simple() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: d384d6f43d1e ("firmware: google memconsole: Add coreb

[PATCH -next] drm/rockchip: cdn-dp: fix return value check in cdn_dp_probe()

2017-04-24 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Fix the retrn value check which testing the wrong variable in cdn_dp_probe(). Fixes: 1a0f7ed3abe2 ("drm/rockchip: cdn-dp: add cdn DP support for rk3399") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/rock

[PATCH -next] phy: qcom-qmp: fix return value check in qcom_qmp_phy_create()

2017-04-24 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> In case of error, the function of_iomap() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: e78f3d15e115 ("phy: qcom-qmp: new qmp phy driver for qcom-chipsets") Si

[PATCH -next] phy: qcom-qmp: fix invalid use of sizeof in qcom_qmp_phy_vreg_init()

2017-04-25 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> sizeof() when applied to a pointer typed expression gives the size of the pointer, not that of the pointed data. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/phy/phy-qcom-qmp.c | 2 +- 1 file changed, 1 insertion(+)

[PATCH -next] drm/nouveau/secboot/gm20b: fix the error return code in gm20b_secboot_tegra_read_wpr()

2017-04-25 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> The error return code PTR_ERR(mc) is always 0 since mc is equal to 0 in this error handling case. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/nouveau/nvkm/subdev/secboot/gm20b.c | 2 +- 1 file changed, 1 ins

[PATCH -next] ASoC: Intel: Skylake: Fix to use list_for_each_safe() when delete items

2017-04-24 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Since we will remove items off the list using list_del() we need to use a safe version of the list_for_each() macro aptly named list_for_each_safe(). This is detected by Coccinelle semantic patch. Fixes: b8c722ddd548 ("ASoC: Intel: Skylake:

[PATCH -next] ASoC: rt5665: make local symbol rt5665_i2c_driver static

2017-05-16 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Fixes the following sparse warnings: sound/soc/codecs/rt5665.c:4928:19: warning: symbol 'rt5665_i2c_driver' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- sound/soc/codecs/rt5665.c | 2 +- 1

[PATCH -next] RAS: Make local function parse_ras_param() static

2017-05-16 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Fixes the following sparse warning: drivers/ras/ras.c:32:12: warning: symbol 'parse_ras_param' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/ras/ras.c | 2 +- 1 file changed, 1 ins

[PATCH] goldfish_pipe: use GFP_ATOMIC under spin lock

2017-05-20 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> The function get_free_pipe_id_locked() is called from goldfish_pipe_open() with a lock is held, so we should use GFP_ATOMIC instead of GFP_KERNEL. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/platform/goldfish/goldfis

[PATCH -next] drm/pl111: Fix return value check in pl111_amba_probe()

2017-05-20 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> In case of error, the function devm_ioremap_resource() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: bed41005e617 ("drm/pl111: Initial drm/kms driver for pl111&q

[PATCH -next] drm/vgem: Fix return value check in vgem_init()

2017-05-20 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> In case of error, the function platform_device_register_simple() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: 315f0242aa2b ("drm/vgem: Convert to a struct drm_devi

[PATCH -next] drm/i915: Fix return value check in kfence selftests

2017-05-18 Thread Wei Yongjun
From: Wei Yongjun <weiyongj...@huawei.com> Fix the return value check which testing the wrong variable. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/i915/selftests/i915_sw_fence.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dri

[PATCH -next] MIPS: bpf: Fix a typo in build_one_insn()

2017-10-13 Thread Wei Yongjun
Fix a typo in build_one_insn(). Fixes: b6bd53f9c4e8 ("MIPS: Add missing file for eBPF JIT.") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- arch/mips/net/ebpf_jit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/mips/net/ebpf_jit.c b/arch/mip

[PATCH -next] nullb: fix error return code in null_init()

2017-10-17 Thread Wei Yongjun
Fix to return error code -ENOMEM from the null_alloc_dev() error handling case instead of 0, as done elsewhere in this function. Fixes: 2984c8684f96 ("nullb: factor disk parameters") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/block/null_blk.c | 4 +++- 1

[PATCH -next] iommu/ipmmu-vmsa: Fix return value check in ipmmu_find_group_dma()

2017-10-17 Thread Wei Yongjun
In case of error, the function iommu_group_get() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: 3ae47292024f ("iommu/ipmmu-vmsa: Add new IOMMU_DOMAIN_DMA ops") Signed-off-by: Wei Yongjun <weiyongj.

[PATCH] drm: Fix return value check in kirin_drm_platform_probe()

2017-10-11 Thread Wei Yongjun
In case of error, the function of_graph_get_remote_node() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test.. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/hisilicon/kirin/kirin_drm_drv.c | 4 ++--

[PATCH -next] mtd: sharpslpart: make local function sharpsl_nand_cleanup_ftl() static

2017-12-19 Thread Wei Yongjun
Fixes the following sparse warnings: drivers/mtd/parsers/sharpslpart.c:222:6: warning: symbol 'sharpsl_nand_cleanup_ftl' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/mtd/parsers/sharpslpart.c | 2 +- 1 file changed, 1 insertion

[PATCH -next] irqchip/exiu: Fix return value check in exiu_init()

2017-11-13 Thread Wei Yongjun
In case of error, the function of_iomap() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: 706cffc1b912 ("irqchip/exiu: Add support for Socionext Synquacer EXIU controller") Signed-off-by: Wei Yongjun

[PATCH -next] ipmi watchdog: fix typo in parameter description

2017-11-03 Thread Wei Yongjun
Fix typo in parameter description. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/char/ipmi/ipmi_watchdog.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/char/ipmi/ipmi_watchdog.c b/drivers/char/ipmi/ipmi_watchdog.c index 76b2706..09e8463

[PATCH -next] ipmi_si_platform: Fix typo in parameter description

2017-11-03 Thread Wei Yongjun
Fix typo in parameter description. Fixes: 95e300c052fd ("ipmi: Make the DMI probe into a generic platform probe") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/char/ipmi/ipmi_si_platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/d

[PATCH -next] ASoC: fix return value check in mt6351_codec_driver_probe()

2018-05-06 Thread Wei Yongjun
In case of error, the function dev_get_regmap() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- sound/soc/codecs/mt6351.c | 4 ++-- 1 file changed, 2 insertions

[PATCH -next] slimbus: qcom: fix potential NULL dereference in qcom_slim_prg_slew()

2018-05-22 Thread Wei Yongjun
); + if (!res) + return -EINVAL; ... when != res == NULL e = devm_ioremap(e1, res->start, e2); Fixes: ad7fcbc308b0 ("slimbus: qcom: Add Qualcomm Slimbus controller driver") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/slimbus/qcom-ctrl.c | 2 ++ 1 file ch

[PATCH -next] misc: ibmvmc: Use GFP_ATOMIC under spin lock

2018-05-26 Thread Wei Yongjun
The function alloc_dma_buffer() is called from ibmvmc_add_buffer(), in which a spin lock be held here, so we should use GFP_ATOMIC when a lock is held. Fixes: 0eca353e7ae7 ("misc: IBM Virtual Management Channel Driver (VMC)") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> -

[PATCH -next] nvmet: fix a typo in nvmet_file_ns_enable()

2018-05-30 Thread Wei Yongjun
Fix a typo in nvmet_file_ns_enable(). Fixes: d5eff33ee6f8 ("nvmet: add simple file backed ns support") Signed-off-by: Wei Yongjun --- drivers/nvme/target/io-cmd-file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/nvme/target/io-cmd-file.c b/drivers/nvme

[PATCH -next] nvmet: fix error return code in nvmet_file_ns_enable()

2018-05-31 Thread Wei Yongjun
Fix to return error code -ENOMEM from the memory alloc fail error handling case instead of 0, as done elsewhere in this function. Fixes: d5eff33ee6f8 ("nvmet: add simple file backed ns support") Signed-off-by: Wei Yongjun --- drivers/nvme/target/io-cmd-file.c | 8 ++-- 1 file

[PATCH -next] mqueue: fix a typo in mq_init_ns()

2018-06-20 Thread Wei Yongjun
Fix a typo, use 'm' instead of 'ns->mq_mnt'. Fixes: 5cd6a50ace05 ("ipc: Convert mqueue fs to fs_context") Signed-off-by: Wei Yongjun --- ipc/mqueue.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ipc/mqueue.c b/ipc/mqueue.c index 833b8d7..0f10221 100644 --- a

[PATCH -next] ASoC: mediatek: mt2701: fix return value check in mt2701_afe_pcm_dev_probe()

2018-01-07 Thread Wei Yongjun
In case of error, the function syscon_node_to_regmap() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: dfa3cbb83e09 ("ASoC: mediatek: modify MT2701 AFE driver to adapt mfd device") Signed-off-by: Wei Yongjun

[PATCH -next] clocksource/drivers/stm32: fix error return code in stm32_timer_init()

2018-01-10 Thread Wei Yongjun
Fix to return error code -ENOMEM from the kzalloc error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/clocksource/timer-stm32.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/d

[PATCH -next] test_firmware: make local symbol test_fw_config static

2018-01-11 Thread Wei Yongjun
Fixes the following sparse warnings: lib/test_firmware.c:99:20: warning: symbol 'test_fw_config' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- lib/test_firmware.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH -next] ASoC: stm32: fix a typo in stm32_adfsdm_probe()

2018-01-11 Thread Wei Yongjun
Fix a typo, we should return PTR_ERR(priv->iio_cb) instead of PTR_ERR(priv->iio_ch). Fixes: 55da094824c4 ("ASoC: stm32: add DFSDM DAI support") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- sound/soc/stm/stm32_adfsdm.c | 2 +- 1 file changed, 1 insertion(+), 1 d

[PATCH -next] test_firmware: fix missing unlock on error in config_num_requests_store()

2018-01-11 Thread Wei Yongjun
Add the missing unlock before return from function config_num_requests_store() in the error handling case. Fixes: c92316bf8e94 ("test_firmware: add batched firmware tests") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- lib/test_firmware.c | 1 + 1 file changed, 1 in

[PATCH -next] drm/etnaviv: make local symbols static

2018-01-11 Thread Wei Yongjun
? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/etnaviv/etnaviv_iommu.c | 2 +- drivers/gpu/drm/etnaviv/etnaviv_iommu_v2.c | 2 +- 2 file changed, 2 insertion(+), 2 deletion(-) diff --git a/drivers/gpu/drm/etnaviv/etnaviv_iommu.c b/drivers/gpu/drm/etnaviv/etnaviv_iommu.c

[PATCH -next] um: vector: fix missing unlock on error in vector_net_open()

2018-01-04 Thread Wei Yongjun
Add the missing unlock before return from function vector_net_open() in the error handling case. Fixes: ad1f62ab2bd4 ("High Performance UML Vector Network Driver") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- arch/um/drivers/vector_kern.c | 4 +++- 1 file changed, 3

[PATCH -next] f2fs: make local functions static

2018-01-05 Thread Wei Yongjun
'f2fs_get_projid' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- fs/f2fs/segment.c | 4 ++-- fs/f2fs/super.c | 2 +- 2 file changed, 3 insertions(+), 3 deletions(-) diff --git a/fs/f2fs/segment.c b/fs/f2fs/segment.c index b03f65e..36bfd53 100644 --- a/f

[PATCH -next] meson-gx-socinfo: make local function meson_gx_socinfo_init static

2018-01-10 Thread Wei Yongjun
Fixes the following sparse warnings: drivers/soc/amlogic/meson-gx-socinfo.c:100:12: warning: symbol 'meson_gx_socinfo_init' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/soc/amlogic/meson-gx-socinfo.c | 2 +- 1 file changed, 1 ins

[PATCH -next] meson-mx-socinfo: Make local function meson_mx_socinfo_init() static

2018-01-10 Thread Wei Yongjun
Fixes the following sparse warnings: drivers/soc/amlogic/meson-mx-socinfo.c:107:12: warning: symbol 'meson_mx_socinfo_init' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/soc/amlogic/meson-mx-socinfo.c | 2 +- 1 file changed, 1 ins

[PATCH -next] mtd: ubi: wl: Fix error return code in ubi_wl_init()

2018-01-18 Thread Wei Yongjun
Fix to return error code -ENOMEM from the kmem_cache_alloc() error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/mtd/ubi/wl.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drive

[PATCH -next v2] ipmi/powernv: Fix error return code in ipmi_powernv_probe()

2018-01-17 Thread Wei Yongjun
Fix to return a negative error code from the request_irq() error handling case instead of 0, as done elsewhere in this function. Fixes: dce143c3381c ("ipmi/powernv: Convert to irq event interface") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- v1 -> v2: add fixes. ---

[PATCH -next] firmware: arm_sdei: Fix return value check in sdei_present_dt()

2018-01-15 Thread Wei Yongjun
In case of error, the function of_platform_device_create() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: 677a60bd2003 ("firmware: arm_sdei: Discover SDEI support via ACPI") Signed-off-by: Wei Yongjun

[PATCH -next] soundwire: Fix typo in return value check of sdw_read()

2018-01-01 Thread Wei Yongjun
Fix the typo, 'status' should be instead of 'status2'. Fixes: b0a9c37b0178 ("soundwire: Add slave status handling") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/soundwire/bus.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/d

[PATCH -next] tee: shm: make local function __tee_shm_alloc() static

2018-01-01 Thread Wei Yongjun
Fixes the following sparse warnings: drivers/tee/tee_shm.c:115:16: warning: symbol '__tee_shm_alloc' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/tee/tee_shm.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff

[PATCH -next] drm/panel: ili9322:Make local symbols static

2018-01-02 Thread Wei Yongjun
? Also change ili9322_inputs to 'const char * const' to avoid chackpatch warning. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/panel/panel-ilitek-ili9322.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-ilitek-ili

[PATCH -next] dm raid: make local symbol raid_sets static

2018-01-01 Thread Wei Yongjun
Fixes the following sparse warning: drivers/md/dm-raid.c:33:1: warning: symbol 'raid_sets' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/md/dm-raid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers

[PATCH -next] irqchip/ompic: fix return value check in ompic_of_init()

2018-01-02 Thread Wei Yongjun
In case of error, the function ioremap() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: 9b54470afd83 ("irqchip: add initial support for ompic") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- dri

[PATCH -next] xen/pvcalls: use GFP_ATOMIC under spin lock

2017-12-27 Thread Wei Yongjun
A spin lock is taken here so we should use GFP_ATOMIC. Fixes: 9774c6cca266 ("xen/pvcalls: implement accept command") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/xen/pvcalls-front.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/xen

[PATCH -next] slimbus: qcom: Make some local functions static

2018-01-01 Thread Wei Yongjun
Fixes the following sparse warnings: drivers/slimbus/qcom-ctrl.c:151:6: warning: symbol 'slim_ack_txn' was not declared. Should it be static? drivers/slimbus/qcom-ctrl.c:304:6: warning: symbol 'slim_alloc_txbuf' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyo

[PATCH -next] slimbus: qcom: Fix return value check in qcom_slim_probe()

2018-01-01 Thread Wei Yongjun
In case of error, the function devm_ioremap_resource() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: ad7fcbc308b0 ("slimbus: qcom: Add Qualcomm Slimbus controller driver") Signed-off-by: Wei Yongjun

[PATCH -next] slimbus: Fix missing unlock on error in slim_msg_response()

2018-01-01 Thread Wei Yongjun
Add the missing unlock before return from function slim_msg_response() in the error handling case. Fixes: afbdcc7c384b ("slimbus: Add messaging APIs to slimbus framework") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/slimbus/messaging.c | 1 + 1 file chan

[PATCH -next] slimbus: Use GFP_ATOMIC under spin lock

2018-01-01 Thread Wei Yongjun
A spin lock is taken here so we should use GFP_ATOMIC. Fixes: afbdcc7c384b ("slimbus: Add messaging APIs to slimbus framework") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/slimbus/messaging.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a

[PATCH -next] ASoC: rt5682: use devm_snd_soc_register_component()

2018-06-21 Thread Wei Yongjun
Using devm_snd_soc_register_component() and drop all of the code related to .remove hook. Signed-off-by: Wei Yongjun --- sound/soc/codecs/rt5682.c | 11 ++- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/sound/soc/codecs/rt5682.c b/sound/soc/codecs/rt5682.c index 61a9730

[PATCH -next] ASoC: rt1305: use devm_snd_soc_register_component()

2018-06-21 Thread Wei Yongjun
Using devm_snd_soc_register_component() and drop all of the code related to .remove hook. Signed-off-by: Wei Yongjun --- sound/soc/codecs/rt1305.c | 11 ++- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/sound/soc/codecs/rt1305.c b/sound/soc/codecs/rt1305.c index 421b8fb

[PATCH -next] staging: axis-fifo: fix return value check in axis_fifo_probe()

2018-07-27 Thread Wei Yongjun
In case of error, the function device_create() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: 4a965c5f89de ("staging: add driver for Xilinx AXI-Stream FIFO v4.1 IP core") Signed-off-by: Wei Yongjun --- drive

[PATCH -next] ALSA: usb-audio: Fix invalid use of sizeof in parse_uac_endpoint_attributes()

2018-08-01 Thread Wei Yongjun
sizeof() when applied to a pointer typed expression gives the size of the pointer, not that of the pointed data. Fixes: 7edf3b5e6a45 ("ALSA: usb-audio: AudioStreaming Power Domain parsing") Signed-off-by: Wei Yongjun --- sound/usb/stream.c | 2 +- 1 file changed, 1 insertion(+),

[PATCH -next] drm/vkms: Fix the error handling in vkms_init()

2018-08-02 Thread Wei Yongjun
In the drm_vblank_init() error handling case, platform device unregister is missing. This patch fix it. Fixes: 3a0709928b17 ("drm/vkms: Add vblank events simulated by hrtimers") Signed-off-by: Wei Yongjun --- drivers/gpu/drm/vkms/vkms_drv.c | 2 +- 1 file changed, 1 insertion(+),

[PATCH -next v3] mtd: spinand: fix missing unlock on error

2018-07-04 Thread Wei Yongjun
Add the missing unlock before return from function spinand_mtd_(read|write) in the error handling case. Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs") Signed-off-by: Wei Yongjun --- v2 -> v3: remove blank line v1 -> v2: using break instead of ret

[PATCH -next v2] mtd: spinand: fix missing unlock on error

2018-07-04 Thread Wei Yongjun
Add the missing unlock before return from function spinand_mtd_(read|write) in the error handling case. Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs") Signed-off-by: Wei Yongjun --- v1 -> v2: using break instead of return --- drivers/mtd/nand/s

[PATCH -next] mtd: spinand: Fix missing unlock on error path

2018-07-04 Thread Wei Yongjun
Add the missing unlock before return from function spinand_mtd_(read|write) in the error handling case. Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs") Signed-off-by: Wei Yongjun --- drivers/mtd/nand/spi/core.c | 12 1 file changed, 8

[PATCH -next] mtd: spinand: Fix error return code in spinand_init()

2018-07-04 Thread Wei Yongjun
Fix to return error code -ENOMEM from the kzalloc() error handling case instead of 0, as done elsewhere in this function. Fixes: c898e0526fb6 ("mtd: nand: Add core infrastructure to support SPI NANDs") Signed-off-by: Wei Yongjun --- drivers/mtd/nand/spi/core.c | 4 +++- 1 file

[PATCH -next] misc: vexpress: Fix potential NULL dereference in vexpress_syscfg_probe()

2018-07-11 Thread Wei Yongjun
); + if (!res) + return -EINVAL; ... when != res == NULL e = devm_ioremap(e1, res->start, e2); Signed-off-by: Wei Yongjun --- drivers/misc/vexpress-syscfg.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/misc/vexpress-syscfg.c b/drivers/misc/vexpress-syscfg.c index 9eea30f..2d72c93 100

[PATCH -next] staging: pi433: fix error return code in pi433_probe()

2018-07-11 Thread Wei Yongjun
Fix to return a negative error code from the kthread_run() error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun --- drivers/staging/pi433/pi433_if.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/staging/pi433/pi433_if.c b/drivers/staging

[PATCH -next] fsi: sbefifo: Fix missing unlock on error in sbefifo_dump_ffdc()

2018-07-12 Thread Wei Yongjun
Add the missing unlock before return from function sbefifo_dump_ffdc() in the error handling case. Fixes: 9f4a8a2d7f9d ("fsi/sbefifo: Add driver for the SBE FIFO") Signed-off-by: Wei Yongjun --- drivers/fsi/fsi-sbefifo.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drive

[PATCH -next] mtd: onenand: omap2: Remove redundant dev_err call in omap2_onenand_probe()

2018-01-17 Thread Wei Yongjun
There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/mtd/onenand/omap2.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drive

[PATCH -next] ipmi/powernv: Fix error return code in ipmi_powernv_probe()

2018-01-17 Thread Wei Yongjun
Fix to return a negative error code from the request_irq() error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/char/ipmi/ipmi_powernv.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff

[PATCH -next] perf: hisi: Remove redundant dev_err call

2018-01-17 Thread Wei Yongjun
There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/perf/hisilicon/hisi_uncore_ddrc_pmu.c | 4 +--- drivers/perf/hisilicon/hisi_uncore_hha_pmu

[PATCH -next] slimbus: qcom: remove redundant dev_err call in qcom_slim_probe()

2018-01-17 Thread Wei Yongjun
There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/slimbus/qcom-ctrl.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/s

[PATCH -next] dm crypt: fix error return code in crypt_ctr()

2018-01-17 Thread Wei Yongjun
Fix to return error code -ENOMEM from the mempool_create_kmalloc_pool() error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/md/dm-crypt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-cry

[PATCH -next] memory: ti-emif-sram: remove redundant dev_err call in ti_emif_probe()

2018-01-17 Thread Wei Yongjun
There is a error message within devm_ioremap_resource already, so remove the dev_err call to avoid redundant error message. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/memory/ti-emif-pm.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/memory/ti-emif-pm.c b/d

[PATCH -next] phy: usb: phy-brcm-usb: Remove redundant return value check of platform_get_resource()

2018-01-17 Thread Wei Yongjun
Remove unneeded error handling on the result of a call to platform_get_resource() when the value is passed to devm_ioremap_resource(). Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/phy/broadcom/phy-brcm-usb.c | 4 1 file changed, 4 deletions(-) diff --git a/drive

[PATCH -next] ASoC: da7210: Use devm_snd_soc_register_component()

2018-03-16 Thread Wei Yongjun
Since the remove callback is removed, the snd_soc_unregister_component() is missing when remove device. Using devm_snd_soc_register_component() instead of snd_soc_register_component(). Fixes: d06f33aed85c ("ASoC: da7210: replace codec to component") Signed-off-by: Wei Yongjun

[PATCH -next] ASoC: wm8400: Use devm_snd_soc_register_component()

2018-03-16 Thread Wei Yongjun
Since the remove callback is removed, the snd_soc_unregister_component() is missing when remove device. Using devm_snd_soc_register_component() instead of snd_soc_register_component(). Fixes: 10dc44c6462d ("ASoC: wm8400: replace codec to component") Signed-off-by: Wei Yongjun

[PATCH -next] ASoC: mediatek: mt2701: drop unnessary snd_soc_unregister_component()

2018-03-16 Thread Wei Yongjun
It's not necessary to unregister a component registered with devm_snd_soc_register_component(). Fixes: f1b5bf07365d ("ASoC: mt2701/mt8173: replace platform to componen") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- sound/soc/mediatek/mt2701/mt2701-afe-pcm.c | 2 -- 1

[PATCH -next] m68k: fix return value check in mcf_pci_init()

2018-04-18 Thread Wei Yongjun
In case of error, the function ioremap() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: bf114d773167 ("m68k: force use of __raw_read/__raw_write address to be iomem") Signed-off-by: Wei Yongjun <weiyongj.

[PATCH -next] dm verity: make some functions static

2018-03-28 Thread Wei Yongjun
Fixes the following sparse warnings: drivers/md/dm-verity-target.c:375:6: warning: symbol 'verity_for_io_block' was not declared. Should it be static? drivers/md/dm-verity-target.c:403:14: warning: symbol 'verity_calc_buffs_for_bv' was not declared. Should it be static? Signed-off-by: Wei

[PATCH -next] bus: fsl-mc: Remove duplicated includes

2018-03-28 Thread Wei Yongjun
Remove duplicated include. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/bus/fsl-mc/dpbp.c | 1 - drivers/bus/fsl-mc/dpcon.c | 1 - 2 file changed, 2 deletion(-) diff --git a/drivers/bus/fsl-mc/dpbp.c b/drivers/bus/fsl-mc/dpbp.c index 0aeacc5..9a7faab 100644 --- a/drive

[PATCH -next] drm/amdgpu: fix error return code in amdgpu_amdkfd_gpuvm_create_process_vm()

2018-03-28 Thread Wei Yongjun
Fix to return error code -ENOMEM from the eviction fence create fail error handling case instead of 0, as done elsewhere in this function. Fixes: a46a2cd103a8 ("drm/amdgpu: Add GPUVM memory management functions for KFD") Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> ---

[PATCH -next] afs: Make symbol 'afs_cell_gc_delay' static

2018-03-26 Thread Wei Yongjun
Fixes the following sparse warnings: fs/afs/cell.c:21:24: warning: symbol 'afs_cell_gc_delay' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- fs/afs/cell.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/afs/cell.c b/

[PATCH -next] ASoC: amd: acp-da7219-max98357: Make symbol da7219_dai_clk static

2018-03-28 Thread Wei Yongjun
Fixes the following sparse warning: sound/soc/amd/acp-da7219-max98357a.c:46:12: warning: symbol 'da7219_dai_clk' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- sound/soc/amd/acp-da7219-max98357a.c | 2 +- 1 file changed, 1 insertion

[PATCH -next] powerpc: Fix error return code in ppc4xx_msi_probe()

2018-03-26 Thread Wei Yongjun
Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- arch/powerpc/platforms/4xx/msi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/powerpc/pla

[PATCH -next] drm/amdkfd: Make function kfd_dev_is_large_bar() static

2018-03-29 Thread Wei Yongjun
Fixes the following sparse warning: drivers/gpu/drm/amd/amdkfd/kfd_chardev.c:1150:6: warning: symbol 'kfd_dev_is_large_bar' was not declared. Should it be static? Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 2 +- 1 file chan

[PATCH -next] drm/amdkfd: Fix the error return code in kfd_ioctl_unmap_memory_from_gpu()

2018-03-29 Thread Wei Yongjun
Passing NULL pointer to PTR_ERR will result in return value of 0 indicating success which is clearly not what it is intended here. This patch returns -EINVAL instead. Fixes: 5ec7e02854b3 ("drm/amdkfd: Add ioctls for GPUVM memory management") Signed-off-by: Wei Yongjun <weiyongj.

[PATCH -next] phy: stm32: fix using 0 as NULL pointer warnings

2018-03-20 Thread Wei Yongjun
Fixes the following sparse warnings: drivers/phy/st/phy-stm32-usbphyc.c:331:42: warning: Using plain integer as NULL pointer drivers/phy/st/phy-stm32-usbphyc.c:344:52: warning: Using plain integer as NULL pointer Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/phy/st/phy

[PATCH -next] phy: phy-mtk-tphy: fix missing clk_disable_unprepare() on error in mtk_phy_init()

2018-03-20 Thread Wei Yongjun
Fix the missing clk_disable_unprepare() before return from mtk_phy_init() in the error handling case. Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/phy/mediatek/phy-mtk-tphy.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/drivers/phy/me

[PATCH -next] drm/meson: Fix potential NULL dereference in meson_drv_bind_master()

2018-03-20 Thread Wei Yongjun
, t, n); + if (!res) + return -EINVAL; ... when != res == NULL e = devm_ioremap(e1, res->start, e2); Signed-off-by: Wei Yongjun <weiyongj...@huawei.com> --- drivers/gpu/drm/meson/meson_drv.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/gpu/drm/meson/meson_drv.c b/dr

[PATCH -next] staging: mt7621-eth: fix return value check in mtk_probe()

2018-03-21 Thread Wei Yongjun
In case of error, the function devm_ioremap_resource() returns ERR_PTR() and never returns NULL. The NULL test in the return value check should be replaced with IS_ERR(). Fixes: e3cbf478f846 ("staging: mt7621-eth: add the drivers core files") Signed-off-by: Wei Yongjun <weiyongj.

[PATCH -next] staging: mt7621-eth: fix return value check in mtk_connect_phy_node()

2018-03-21 Thread Wei Yongjun
In case of error, the function of_phy_connect() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: e3cbf478f846 ("staging: mt7621-eth: add the drivers core files") Signed-off-by: Wei Yongjun <weiyongj.

<    1   2   3   4   5   6   7   8   9   10   >