mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-20 14:16:02 +00:00
Staging: netlogic: Compress return logic into one line
Simplify function returns by merging assignment and return into one command line. Found with Coccinelle @@ expression e, ret; @@ -ret = +return e; -return ret; Signed-off-by: Mihaela Muraru <mihaela.muraru21@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
42178baf4a
commit
1cbe7adb9c
1 changed files with 2 additions and 4 deletions
|
@ -1007,10 +1007,8 @@ static int xlr_net_probe(struct platform_device *pdev)
|
||||||
*/
|
*/
|
||||||
adapter = (struct xlr_adapter *)
|
adapter = (struct xlr_adapter *)
|
||||||
devm_kzalloc(&pdev->dev, sizeof(*adapter), GFP_KERNEL);
|
devm_kzalloc(&pdev->dev, sizeof(*adapter), GFP_KERNEL);
|
||||||
if (!adapter) {
|
if (!adapter)
|
||||||
err = -ENOMEM;
|
return -ENOMEM;
|
||||||
return err;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* XLR and XLS have 1 and 2 NAE controller respectively
|
* XLR and XLS have 1 and 2 NAE controller respectively
|
||||||
|
|
Loading…
Reference in a new issue