[PATCH] ASoC: codecs/jz4770: Remove superfluous error message

2021-03-06 Thread Tang Bin
The function devm_platform_ioremap_resource has already contained error message if failed, so remove superfluous dev_err here. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/codecs/jz4770.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/sound/soc

[PATCH v2] ASoC: codec: Omit superfluous error message in jz4760_codec_probe()

2021-03-02 Thread Tang Bin
The function devm_platform_ioremap_resource has already contained error message, so remove the redundant dev_err here. Signed-off-by: Tang Bin --- Changes from v1 - to streamline the code. --- sound/soc/codecs/jz4760.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git

[PATCH] ASoC: fsl_xcvr: Use devm_platform_ioremap_resource_byname() to simplify code

2021-03-02 Thread Tang Bin
In this function, devm_platform_ioremap_resource_byname() should be suitable to simplify code. Signed-off-by: Tang Bin --- sound/soc/fsl/fsl_xcvr.c | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/sound/soc/fsl/fsl_xcvr.c b/sound/soc/fsl/fsl_xcvr.c index 6dd0a5fcd455

[PATCH] ASoC: codec: Omit superfluous error message in jz4760_codec_probe()

2021-03-02 Thread Tang Bin
The function devm_platform_ioremap_resource has already contained error message, so remove the redundant dev_err here. Signed-off-by: Tang Bin --- sound/soc/codecs/jz4760.c | 1 - 1 file changed, 1 deletion(-) diff --git a/sound/soc/codecs/jz4760.c b/sound/soc/codecs/jz4760.c index

[PATCH] net: tap: remove redundant assignments

2021-02-22 Thread Tang Bin
In the function tap_get_user, the assignment of 'err' at both places is redundant, so remove one. Signed-off-by: Tang Bin --- drivers/net/tap.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/net/tap.c b/drivers/net/tap.c index 1f4bdd944..3e9c72738 100644

[PATCH] thermal: amlogic: Omit superfluous error message in amlogic_thermal_probe()

2021-02-21 Thread Tang Bin
The function devm_platform_ioremap_resource has already contains error message, so remove the redundant dev_err here. Signed-off-by: Tang Bin --- drivers/thermal/amlogic_thermal.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/thermal/amlogic_thermal.c b/drivers

[PATCH v2] virtio-mmio: Use to_virtio_mmio_device() to simply code

2021-02-21 Thread Tang Bin
The file virtio_mmio.c has defined the function to_virtio_mmio_device, so use it instead of container_of() to simply code. Signed-off-by: Tang Bin --- Changes from v1 - Separate the patch with style changes. --- drivers/virtio/virtio_mmio.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions

Re: [PATCH] virtio-mmio: Use to_virtio_mmio_device() to simply code

2021-02-17 Thread Tang Bin
Dear Jason:   Sorry for the late reply this email. 在 2021/2/10 16:09, Jason Wang 写道: On 2021/2/10 上午11:04, Tang Bin wrote: The file virtio_mmio.c has defined the function to_virtio_mmio_device, so use it instead of container_of() to simply code. And remove superfluous blank lines

[PATCH] crypto: amlogic - Fix unnecessary check in meson_crypto_probe()

2021-02-09 Thread Tang Bin
The function meson_crypto_probe() is only called with an openfirmware platform device. Therefore there is no need to check that the passed in device is NULL. Signed-off-by: Tang Bin --- drivers/crypto/amlogic/amlogic-gxl-core.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers

[PATCH] virtio-mmio: Use to_virtio_mmio_device() to simply code

2021-02-09 Thread Tang Bin
The file virtio_mmio.c has defined the function to_virtio_mmio_device, so use it instead of container_of() to simply code. And remove superfluous blank lines in this file. Signed-off-by: Tang Bin --- drivers/virtio/virtio_mmio.c | 16 +--- 1 file changed, 1 insertion(+), 15

[PATCH] ASoC: fsl_spdif: Utilize the defined parameter to clear code

2021-01-28 Thread Tang Bin
Utilize the defined parameter 'dev' to make the code cleaner. Signed-off-by: Tang Bin --- sound/soc/fsl/fsl_spdif.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sound/soc/fsl/fsl_spdif.c b/sound/soc/fsl/fsl_spdif.c index 455f96908..b6d5563df 100644 --- a/sound

[PATCH] ARM: Fix the spelling mistake in vfpmodule.c

2020-11-19 Thread Tang Bin
In the word 'THREAD_NOFTIFY_SWTICH','SWTICH' is wrong, thus fix it. Signed-off-by: Tang Bin --- arch/arm/vfp/vfpmodule.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/vfp/vfpmodule.c b/arch/arm/vfp/vfpmodule.c index 8c9e7f9f0..dd0b875bc 100644 --- a/arch/arm/vfp

[PATCH] sh: boards: Fix the cacography in irq.c

2020-11-19 Thread Tang Bin
The world 'swtich' is wrong, so fix it. Signed-off-by: Tang Bin --- arch/sh/boards/mach-landisk/irq.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/sh/boards/mach-landisk/irq.c b/arch/sh/boards/mach-landisk/irq.c index 29b8b1f85..0b672b80c 100644 --- a/arch/sh

Re: [PATCH] usb: host: ehci-tegra: Fix error handling integra_ehci_probe()

2020-10-26 Thread Tang Bin
在 2020/10/26 23:05, Alan Stern 写道: On Mon, Oct 26, 2020 at 05:06:57PM +0800, Tang Bin wrote: If the function platform_get_irq() failed, the negative value returned will not be detected here. So fix error handling in tegra_ehci_probe(). Fixes: 79ad3b5add4a ("usb: host: Add EHCI d

[PATCH] usb: host: ehci-tegra: Fix error handling in tegra_ehci_probe()

2020-10-26 Thread Tang Bin
If the function platform_get_irq() failed, the negative value returned will not be detected here. So fix error handling in tegra_ehci_probe(). Fixes: 79ad3b5add4a ("usb: host: Add EHCI driver for NVIDIA Tegra SoCs") Signed-off-by: Tang Bin --- drivers/usb/host/ehci-tegra.c | 6 +++-

[PATCH v2] usb: bdc: Fix the return value and remove duplicate error message

2020-09-28 Thread Tang Bin
When call function devm_platform_ioremap_resource(), we should use IS_ERR() to check the return value and return PTR_ERR() if failed, and it can print an error message itself if failed. So remove the redundant dev_err() in this place. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin

Re: [PATCH] usb: bdc: Remove duplicate error message in bdc_probe()

2020-09-28 Thread Tang Bin
Hi 在 2020/9/28 19:23, Greg KH 写道: On Mon, Sep 28, 2020 at 06:55:26PM +0800, Tang Bin wrote: Hi Balbi: 在 2020/9/28 17:40, Felipe Balbi 写道: Hi, Tang Bin writes: Hi Greg KH: 在 2020/9/27 21:45, Greg KH 写道: On Sun, Sep 27, 2020 at 09:42:18PM +0800, Tang Bin wrote: In this function, we don't

Re: [PATCH] usb: bdc: Remove duplicate error message in bdc_probe()

2020-09-28 Thread Tang Bin
Hi Balbi: 在 2020/9/28 17:40, Felipe Balbi 写道: Hi, Tang Bin writes: Hi Greg KH: 在 2020/9/27 21:45, Greg KH 写道: On Sun, Sep 27, 2020 at 09:42:18PM +0800, Tang Bin wrote: In this function, we don't need dev_err() message because when something goes wrong, devm_platform_ioremap_resource() can

Re: [PATCH] usb: phy: tegra: Use IS_ERR() to check and simplify code

2020-09-28 Thread Tang Bin
Hi all: 在 2020/9/24 18:37, Felipe Balbi 写道: Thierry Reding writes: On Thu, Sep 24, 2020 at 10:26:15AM +0300, Felipe Balbi wrote: Tang Bin writes: Use IS_ERR() and PTR_ERR() instead of PTR_ERR_OR_ZERO() to simplify code, avoid redundant judgements. Signed-off-by: Zhang Shengju Signed

Re: [PATCH] usb: bdc: Remove duplicate error message in bdc_probe()

2020-09-28 Thread Tang Bin
Hi Greg KH: 在 2020/9/27 21:45, Greg KH 写道: On Sun, Sep 27, 2020 at 09:42:18PM +0800, Tang Bin wrote: In this function, we don't need dev_err() message because when something goes wrong, devm_platform_ioremap_resource() can print an error message itself, so remove the redundant one. Signed-off

Re: [PATCH] usb: bdc: Remove duplicate error message in bdc_probe()

2020-09-28 Thread Tang Bin
在 2020/9/28 14:49, Chunfeng Yun 写道: On Sun, 2020-09-27 at 21:42 +0800, Tang Bin wrote: In this function, we don't need dev_err() message because when something goes wrong, devm_platform_ioremap_resource() can print an error message itself, so remove the redundant one. Signed-off-by: Zhang

[PATCH] usb: bdc: Fix unused assignment in bdc_probe()

2020-09-27 Thread Tang Bin
Delete unused initialized value of 'ret', because it will be assigned by the function clk_prepare_enable(). Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/gadget/udc/bdc/bdc_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/udc

[PATCH] usb: bdc: Remove duplicate error message in bdc_probe()

2020-09-27 Thread Tang Bin
In this function, we don't need dev_err() message because when something goes wrong, devm_platform_ioremap_resource() can print an error message itself, so remove the redundant one. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/gadget/udc/bdc/bdc_core.c | 4 +--- 1 file

[PATCH] net: mdio: Remove redundant parameter and check

2020-09-23 Thread Tang Bin
In the function ipq8064_mdio_probe(), of_mdiobus_register() might returned zero, so the direct return can simplify code. Thus remove redundant parameter and check. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/mdio/mdio-ipq8064.c | 8 ++-- 1 file changed, 2

[PATCH] usb: phy: tegra: Use IS_ERR() to check and simplify code

2020-09-10 Thread Tang Bin
Use IS_ERR() and PTR_ERR() instead of PTR_ERR_OR_ZERO() to simplify code, avoid redundant judgements. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/phy/phy-tegra-usb.c | 25 ++--- 1 file changed, 10 insertions(+), 15 deletions(-) diff --git a/drivers

[PATCH] ARM: OMAP1: clock: Use IS_ERR_OR_NULL() to clean code

2020-09-10 Thread Tang Bin
Use IS_ERR_OR_NULL() to make the code cleaner. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- arch/arm/mach-omap1/clock.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/arch/arm/mach-omap1/clock.c b/arch/arm/mach-omap1/clock.c index bd5be8210

Re: [PATCH] ASoC: fsl_spdif: Fix unnecessary check infsl_spdif_probe()

2020-08-26 Thread Tang Bin
Hi Mark 在 2020/8/27 0:53, Mark Brown 写道: On Wed, Aug 26, 2020 at 11:09:18PM +0800, Tang Bin wrote: The function fsl_spdif_probe() is only called with an openfirmware platform device. Therefore there is no need to check that the passed in device is NULL. Why is this an issue - the check

[PATCH] ASoC: fsl_spdif: Fix unnecessary check in fsl_spdif_probe()

2020-08-26 Thread Tang Bin
The function fsl_spdif_probe() is only called with an openfirmware platform device. Therefore there is no need to check that the passed in device is NULL. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/fsl/fsl_spdif.c | 3 --- 1 file changed, 3 deletions(-) diff --git

[PATCH] usb: host: ohci-exynos: Fix error handling in exynos_ohci_probe()

2020-08-26 Thread Tang Bin
msung Exynos OHCI diver") Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/host/ohci-exynos.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/usb/host/ohci-exynos.c b/drivers/usb/host/ohci-exynos.c index bd40e597f..5f5e8a64c 100644 --- a/d

[PATCH] usb: hcd: fix the error check

2020-08-20 Thread Tang Bin
In the function usb_add_hcd(), usb_phy_roothub_alloc() can return NULL in some cases, so IS_ERR() doesn't meet the requirements. Thus fix it. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/core/hcd.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git

Re: [PATCH] ath10k: fix the status check and wrong return

2020-08-17 Thread Tang Bin
? Thanks for you reply, the benefit of this patch is simplify the code, because in this function, I don't think the situation of 'devm_clk_get() return NULL' exists. So please think about it, thanks. Tang Bin Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net

[PATCH] ath10k: fix the status check and wrong return

2020-08-14 Thread Tang Bin
In the function ath10k_ahb_clock_init(), devm_clk_get() doesn't return NULL. Thus use IS_ERR() and PTR_ERR() to validate the returned value instead of IS_ERR_OR_NULL(). Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/wireless/ath/ath10k/ahb.c | 12 ++-- 1 file

[PATCH] ASoC: qcom: qdsp6: Use the defined variable to clean code

2020-07-14 Thread Tang Bin
Use the defined variable "dev" to make the code cleaner. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/qcom/qdsp6/q6adm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/soc/qcom/qdsp6/q6adm.c b/sound/soc/qcom/qdsp6/q6adm.c index

[PATCH] ASoC: qcom: qdsp6: Use IS_ERR() instead of IS_ERR_OR_NULL()

2020-07-14 Thread Tang Bin
In the function q6adm_open(), q6adm_alloc_copp() doesn't return NULL. Thus use IS_ERR() to validate the returned value instead of IS_ERR_OR_NULL(). And delete the extra line. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/qcom/qdsp6/q6adm.c | 3 +-- 1 file changed, 1

[PATCH] net/amd: Remove needless assignment and the extra brank lines

2020-07-06 Thread Tang Bin
The variable 'err = -ENODEV;' in au1000_probe() is duplicate, so remove redundant one. And remove the extra blank lines in the file au1000_eth.c Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/amd/au1000_eth.c | 5 - 1 file changed, 5 deletions(-) diff --git

[PATCH] usb: host: ehci-exynos: Fix error check in exynos_ehci_probe()

2020-06-02 Thread Tang Bin
itial S5P EHCI driver") Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/host/ehci-exynos.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/usb/host/ehci-exynos.c b/drivers/usb/host/ehci-exynos.c index a4e9abcbd..1a9b7572e 100644 --- a/d

[PATCH] usb: phy: tegra: Fix unnecessary check in tegra_usb_phy_probe()

2020-05-28 Thread Tang Bin
In the function tegra_usb_phy_probe(), if usb_add_phy_dev() failed, the return value will be given to err, and if usb_add_phy_dev() succeed, the return value will be zero. Thus it is unnecessary to repeated check here. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/phy

[PATCH] usb: phy: tegra: Remove unnecessary spaces and tables

2020-05-28 Thread Tang Bin
The macros in phy-tegra-usb.c have inconsistent sapces between the macro name and the value. Thus sets all the macros to have a signal space between the name and value. Signed-off-by: Tang Bin --- drivers/usb/phy/phy-tegra-usb.c | 214 1 file changed, 107

[PATCH] driver core: platform: Fix spelling errors in platform.c

2020-05-20 Thread Tang Bin
There is a word spelling mistake of 'Unegisters', thus it should be fixed. Signed-off-by: Tang Bin --- drivers/base/platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/base/platform.c b/drivers/base/platform.c index 7fa654f12..15ae9428a 100644 --- a/drivers

[PATCH] net: sgi: ioc3-eth: Fix return value check in ioc3eth_probe()

2020-05-20 Thread Tang Bin
t;) Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/sgi/ioc3-eth.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/sgi/ioc3-eth.c b/drivers/net/ethernet/sgi/ioc3-eth.c index db6b2988e..8021a3d34 100644 --- a/d

Re: [PATCH] net/amd: Remove the extra blank lines

2020-05-19 Thread Tang Bin
is where these changes should be targetted. Please respin. Can you tell me which one is useless, I will drop and not put it in the patches set. Thanks, Tang Bin

[PATCH] net/amd: Simplify assertions

2020-05-19 Thread Tang Bin
Simplifies assertions for errors. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/amd/au1000_eth.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/amd/au1000_eth.c b/drivers/net/ethernet/amd/au1000_eth.c index

[PATCH] net/amd: Fix indentation to put on one line affected code

2020-05-19 Thread Tang Bin
It looks better and has improved readability without additional line breaks. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/amd/au1000_eth.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/ethernet/amd/au1000_eth.c b/drivers/net

[PATCH] net/amd: Fix unused assignment in au1000_probe()

2020-05-19 Thread Tang Bin
Delete unused initialized value of 'err', because it will be assigned by the function mdiobus_register(). And the variable 'err = -ENODEV' is duplicate, so remove redundant one. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/amd/au1000_eth.c | 3 +-- 1 file

[PATCH] net/amd: Remove unnecessary spaces and tables in au1000_eth.c

2020-05-19 Thread Tang Bin
The macros in au1000_eth.c have inconsistent spaces between the macro name and the value. Thus sets all the macros to have a signal space between the name and value. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/amd/au1000_eth.c | 172

[PATCH] net/amd: Remove the extra blank lines

2020-05-19 Thread Tang Bin
Remove the extra blank lines in the file au1000_eth.c Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/amd/au1000_eth.c | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/net/ethernet/amd/au1000_eth.c b/drivers/net/ethernet/amd/au1000_eth.c index

[PATCH] ASoC: fsl_micfil: Fix unused assignment in fsl_set_clock_params()

2020-05-18 Thread Tang Bin
Delete unused initialized value of 'ret', because it will be assigned by the function fsl_micfil_set_mclk_rate(). Signed-off-by: Tang Bin --- sound/soc/fsl/fsl_micfil.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/fsl/fsl_micfil.c b/sound/soc/fsl/fsl_micfil.c

[PATCH] ASoC: fsl_micfil: Fix indentation to put on one line affected code

2020-05-18 Thread Tang Bin
In the function fsl_micfil_startup(), the two lines of dev_err() can be shortened to one line. Signed-off-by: Tang Bin --- sound/soc/fsl/fsl_micfil.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sound/soc/fsl/fsl_micfil.c b/sound/soc/fsl/fsl_micfil.c index f7f2d29f1

Re: [PATCH] ASoC: fsl_micfil: Fix format and unused assignment

2020-05-18 Thread Tang Bin
On 2020/5/18 18:25, Mark Brown wrote: On Mon, May 18, 2020 at 03:44:05PM +0800, Tang Bin wrote: In the function fsl_micfil_startup(), the two lines of dev_err() can be shortened to one line. And delete unused initialized value of 'ret', because it will be assigned by the function

[PATCH] ASoC: fsl_micfil: Fix format and unused assignment

2020-05-18 Thread Tang Bin
In the function fsl_micfil_startup(), the two lines of dev_err() can be shortened to one line. And delete unused initialized value of 'ret', because it will be assigned by the function fsl_micfil_set_mclk_rate(). Signed-off-by: Tang Bin --- sound/soc/fsl/fsl_micfil.c | 5 ++--- 1 file changed

Re: [PATCH][next] USB: EHCI: ehci-mv: fix less than zero comparisonof an unsigned int

2020-05-15 Thread Tang Bin
negative, why not just modify the variables in the 'struct usb_hcd',  'unsigned int  irq'--> 'int irq'? After all, it's a public one. Thanks, Tang Bin

[PATCH v2] net/mlx5e: Use IS_ERR() to check and simplify code

2020-05-15 Thread Tang Bin
Use IS_ERR() and PTR_ERR() instead of PTR_ERR_OR_ZERO() to simplify code, avoid redundant judgements. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin Reviewed-by: Leon Romanovsky --- Changes from v1 - fix the commit message for typo. --- drivers/net/ethernet/mellanox/mlx5/core/en

Re: [PATCH] net/mlx5e: Use IS_ERR() to check and simplify code

2020-05-15 Thread Tang Bin
Hi Saeed: On 2020/5/16 6:28, Saeed Mahameed wrote: On Wed, 2020-05-13 at 17:48 +0800, Tang Bin wrote: Hi David: On 2020/5/8 4:18, David Miller wrote: From: Tang Bin Date: Thu, 7 May 2020 19:50:10 +0800 Use IS_ERR() and PTR_ERR() instead of PTR_ZRR_OR_ZERO

Re: [PATCH v3] ipmi:bt-bmc: Fix error handling and status check

2020-05-14 Thread Tang Bin
Hi Corey: On 2020/5/5 19:49, Corey Minyard wrote: On Tue, May 05, 2020 at 06:29:06PM +0800, Tang Bin wrote: Ok, this is included in my tree. I just checked that this patch has been merged into the linux-next branch, and I saw the modification of you by this patch.  I have learned a lot

[PATCH v2] USB: host: ehci-mxc: Add error handling in ehci_mxc_drv_probe()

2020-05-13 Thread Tang Bin
The function ehci_mxc_drv_probe() does not perform sufficient error checking after executing platform_get_irq(), thus fix it. Fixes: 7e8d5cd93fa ("USB: Add EHCI support for MX27 and MX31 based boards") Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- Changes from v1 - fix t

Re: [PATCH] USB: host: ehci: Add error handling in ehci_mxc_drv_probe()

2020-05-13 Thread Tang Bin
Hi gregkh: On 2020/5/8 21:51, Alan Stern wrote: On Fri, 8 May 2020, Tang Bin wrote: The function ehci_mxc_drv_probe() does not perform sufficient error checking after executing platform_get_irq(), thus fix it. Aside from the "irq <= 0" issue, the Subject: line should

[PATCH] ASoC: fsl: imx-audmix: Fix unused assignment to variable 'ret'

2020-05-13 Thread Tang Bin
Omit unused initialized value, because 'ret' will be assigined by the function snd_soc_component_read(). Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/fsl/fsl_audmix.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/soc/fsl/fsl_audmix.c b

Re: [PATCH] net/mlx5e: Use IS_ERR() to check and simplify code

2020-05-13 Thread Tang Bin
Hi David: On 2020/5/8 4:18, David Miller wrote: From: Tang Bin Date: Thu, 7 May 2020 19:50:10 +0800 Use IS_ERR() and PTR_ERR() instead of PTR_ZRR_OR_ZERO() to simplify code, avoid redundant judgements. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin Saeed, please pick this up

Re: [PATCH] USB: host: ehci: Add error handlinginehci_mxc_drv_probe()

2020-05-08 Thread Tang Bin
Hi Sergei: On 2020/5/9 4:27, Sergei Shtylyov wrote: On 05/08/2020 06:03 PM, Tang Bin wrote: On Fri, May 08, 2020 at 07:44:53PM +0800, Tang Bin wrote: The function ehci_mxc_drv_probe() does not perform sufficient error checking after executing platform_get_irq(), thus fix it. Fixes

Re: [PATCH] USB: host: ehci: Add error handlinginehci_mxc_drv_probe()

2020-05-08 Thread Tang Bin
On 2020/5/8 22:31, Greg KH wrote: On Fri, May 08, 2020 at 09:55:53PM +0800, Tang Bin wrote: Hi, Greg: On 2020/5/8 19:48, Greg KH wrote: On Fri, May 08, 2020 at 07:44:53PM +0800, Tang Bin wrote: The function ehci_mxc_drv_probe() does not perform sufficient error checking after executing

[PATCH v2] USB: host: ehci-mxc: Use the defined variable to simplify code

2020-05-08 Thread Tang Bin
Use the defined variable "dev" to make the code cleaner. And delete an extra blank line. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- Changes from v1: - fix the subject and the code. --- drivers/usb/host/ehci-mxc.c | 13 ++--- 1 file changed, 6 insertions(+), 7

Re: [PATCH] USB: host: ehci: Use the defined variable to simplifycode

2020-05-08 Thread Tang Bin
On 2020/5/8 21:56, Alan Stern wrote: On Fri, 8 May 2020, Tang Bin wrote: Use the defined variable "dev" to make the code cleaner. And delete an extra blank line. Again, the Subject: line should say "ehci-mxc". Got it. Signed-off-by: Zhang Shengju Signed-off-by: Tan

[PATCH v2] USB: EHCI: ehci-mv: Fix unused assignment in mv_ehci_probe()

2020-05-08 Thread Tang Bin
Delete unused initialized value, because 'retval' will be assigined by the function mv_ehci_enable(). And delete the extra blank lines. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- Changes from v1 - fix the commit message. --- drivers/usb/host/ehci-mv.c | 4 +--- 1 file changed, 1

Re: [PATCH] USB: EHCI: ehci-mv: Fix unused assignment in mv_ehci_probe()

2020-05-08 Thread Tang Bin
On 2020/5/8 21:49, Alan Stern wrote: On Fri, 8 May 2020, Tang Bin wrote: Delete unused initialized value, because 'retval' will be assigined by the function mv_ehci_enable(). This should also mention the extra blank line that the patch removes. Sorry, my mistake, I'll send v2 for you

Re: [PATCH] USB: host: ehci: Add error handling inehci_mxc_drv_probe()

2020-05-08 Thread Tang Bin
Hi, Greg: On 2020/5/8 19:48, Greg KH wrote: On Fri, May 08, 2020 at 07:44:53PM +0800, Tang Bin wrote: The function ehci_mxc_drv_probe() does not perform sufficient error checking after executing platform_get_irq(), thus fix it. Fixes: 7e8d5cd93fa ("USB: Add EHCI support for MX27 and

[PATCH] USB: host: ehci: Use the defined variable to simplify code

2020-05-08 Thread Tang Bin
Use the defined variable "dev" to make the code cleaner. And delete an extra blank line. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/host/ehci-mxc.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/drivers/usb/host/ehci-mxc.c b/d

[PATCH] USB: host: ehci: Add error handling in ehci_mxc_drv_probe()

2020-05-08 Thread Tang Bin
The function ehci_mxc_drv_probe() does not perform sufficient error checking after executing platform_get_irq(), thus fix it. Fixes: 7e8d5cd93fa ("USB: Add EHCI support for MX27 and MX31 based boards") Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/host/ehci

[PATCH] USB: EHCI: ehci-mv: Fix unused assignment in mv_ehci_probe()

2020-05-08 Thread Tang Bin
Delete unused initialized value, because 'retval' will be assigined by the function mv_ehci_enable(). Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/usb/host/ehci-mv.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/usb/host/ehci-mv.c b/drivers

[PATCH] USB: EHCI: ehci-mv: fix error handling in mv_ehci_probe()

2020-05-08 Thread Tang Bin
-by: Tang Bin --- drivers/usb/host/ehci-mv.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/usb/host/ehci-mv.c b/drivers/usb/host/ehci-mv.c index 1c079953e..b2da62bfd 100644 --- a/drivers/usb/host/ehci-mv.c +++ b/drivers/usb/host/ehci-mv.c @@ -166,9 +166,8 @@ static

[PATCH] net/mlx5e: Use IS_ERR() to check and simplify code

2020-05-07 Thread Tang Bin
Use IS_ERR() and PTR_ERR() instead of PTR_ZRR_OR_ZERO() to simplify code, avoid redundant judgements. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/mellanox/mlx5/core/en/tc_tun.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers

[PATCH] dca: Use PTR_ERR_OR_ZERO() to simplify code

2020-05-07 Thread Tang Bin
The function PTR_ERR_OR_ZERO() contains the check of IS_ERR() and the return of PTR_ERR() or zero. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/dca/dca-sysfs.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/dca/dca-sysfs.c b/drivers/dca/dca

[PATCH] ASoC: mediatek: Fix error handling

2020-05-06 Thread Tang Bin
Signed-off-by: Tang Bin --- sound/soc/mediatek/mt6797/mt6797-afe-pcm.c | 7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/sound/soc/mediatek/mt6797/mt6797-afe-pcm.c b/sound/soc/mediatek/mt6797/mt6797-afe-pcm.c index 378bfc16e..a621dcf91 100644 --- a/sound/soc/mediatek/mt6797

Re: [PATCH] ASoC: qcom: Use devm_platform_ioremap_resource_byname()to simplify code

2020-05-06 Thread Tang Bin
. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Tang-Bin/ASoC-qcom-Use-devm_platform_ioremap_resource_byname-to-simplify-code/20200505-051041 base: https

Re: [PATCH v3] ipmi:bt-bmc: Fix error handling and status check

2020-05-05 Thread Tang Bin
Hi, Corey: On 2020/5/5 19:49, Corey Minyard wrote: On Tue, May 05, 2020 at 06:29:06PM +0800, Tang Bin wrote: If the function platform_get_irq() failed, the negative value returned will not be detected here. So fix error handling in bt_bmc_config_irq(). And in the function bt_bmc_probe(), when

Re: [PATCH v2] ipmi:bt-bmc: Fix error handling and status check

2020-05-04 Thread Tang Bin
Hi, Corey: On 2020/4/19 14:29, Tang Bin wrote: Hi, Corey: On 2020/4/18 21:49, Corey Minyard wrote: On Sat, Apr 18, 2020 at 04:02:29PM +0800, Tang Bin wrote: If the function platform_get_irq() failed, the negative value returned will not be detected here. So fix error handling

[PATCH] ASoC: qcom: Remove the unnecessary cast

2020-05-04 Thread Tang Bin
It's not necessary to specify 'void const __force *' casting for 'drvdata->lpaif'. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/qcom/lpass-cpu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sound/soc/qcom/lpass-cpu.c b/sound/soc/qcom/lp

[PATCH] ASoC: qcom: Use devm_platform_ioremap_resource_byname() to simplify code

2020-05-04 Thread Tang Bin
Use devm_platform_ioremap_resource_byname() instead of platform_get_resource_byname() + devm_ioremap_resource(). Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/qcom/lpass-cpu.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/sound/soc/qcom/lpass

[PATCH] ASoC: qcom: Use the defined variable to simplify code

2020-05-04 Thread Tang Bin
Use the defined variable "dev" to make the code cleaner. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/qcom/lpass-apq8016.c | 9 sound/soc/qcom/lpass-cpu.c | 39 -- 2 files changed, 22 insertions(+), 26 deletions(-)

Re: [PATCH v2]iommu/qcom:fix local_base status check

2020-05-01 Thread Tang Bin
On 2020/5/1 19:37, Joerg Roedel wrote: On Sat, Apr 18, 2020 at 09:47:03PM +0800, Tang Bin wrote: The function qcom_iommu_device_probe() does not perform sufficient error checking after executing devm_ioremap_resource(), which can result in crashes if a critical error path is encountered

[PATCH] net/faraday: Fix unnecessary check in ftmac100_probe()

2020-04-30 Thread Tang Bin
The function ftmac100_probe() is only called with an openfirmware platform device. Therefore there is no need to check that the passed in device is NULL. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/faraday/ftmac100.c | 3 --- 1 file changed, 3 deletions

[PATCH] net: ftgmac100: Fix unused assignment

2020-04-30 Thread Tang Bin
Delete unused initialized value in ftgmac100.c file. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- drivers/net/ethernet/faraday/ftgmac100.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/faraday/ftgmac100.c b/drivers/net/ethernet

[PATCH] ASoC: mxs-saif: Add variable dev to simplify code

2020-04-29 Thread Tang Bin
Add variable 'dev' to make the code cleaner in the function mxs_saif_probe(). And now that the function mxs_saif_mclk_init() have defined the variables 'ret' as the error returned value, then it should be used instead in this place. Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin

[PATCH] ASoC: mxs-saif: Fix unused assignment

2020-04-29 Thread Tang Bin
Delete unused initialized value, because 'ret' will be assigined by the function of_alias_get_id(). Signed-off-by: Zhang Shengju Signed-off-by: Tang Bin --- sound/soc/mxs/mxs-saif.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/mxs/mxs-saif.c b/sound/soc/mxs/mxs