From: SF Markus Elfring <hidden> Date: 2016-09-10 07:16:12
From: Markus Elfring <redacted>
Date: Sat, 10 Sep 2016 09:10:01 +0200
A few update suggestions were taken into account
from static source code analysis.
Markus Elfring (5):
Use kmalloc_array() in get_scq()
Improve another size determination in get_scq()
Improve another size determination in ns_init_card()
Refactor a kmalloc() call in ns_init_card()
Refactor a dev_alloc_skb() call in dequeue_rx()
drivers/atm/nicstar.c | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
--
2.10.0
From: SF Markus Elfring <hidden> Date: 2016-09-10 07:18:23
From: Markus Elfring <redacted>
Date: Sat, 10 Sep 2016 08:02:06 +0200
* A multiplication for the size determination of a memory allocation
indicated that an array data structure should be processed.
Thus use the corresponding function "kmalloc_array".
This issue was detected by using the Coccinelle software.
* Replace the specification of a data type by a pointer dereference
to make the corresponding size determination a bit safer according to
the Linux coding style convention.
Signed-off-by: Markus Elfring <redacted>
---
drivers/atm/nicstar.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
From: SF Markus Elfring <hidden> Date: 2016-09-10 07:19:09
From: Markus Elfring <redacted>
Date: Sat, 10 Sep 2016 08:18:10 +0200
Replace the specification of a data structure by a pointer dereference
as the parameter for the operator "sizeof" to make the corresponding size
determination a bit safer according to the Linux coding style convention.
Signed-off-by: Markus Elfring <redacted>
---
drivers/atm/nicstar.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
From: SF Markus Elfring <hidden> Date: 2016-09-10 07:19:59
From: Markus Elfring <redacted>
Date: Sat, 10 Sep 2016 08:30:09 +0200
Replace the specification of a data structure by a reference for a field
in a local variable as the parameter for the operator "sizeof" to make
the corresponding size determination a bit safer according to
the Linux coding style convention.
Signed-off-by: Markus Elfring <redacted>
---
drivers/atm/nicstar.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
From: SF Markus Elfring <hidden> Date: 2016-09-10 07:20:40
From: Markus Elfring <redacted>
Date: Sat, 10 Sep 2016 08:48:17 +0200
* The script "checkpatch.pl" can point out that assignments should usually
not be performed within condition checks.
Thus move an assignment for a local variable to a separate statement
in this function.
* Replace the specification of a data structure by a pointer dereference
as the parameter for the operator "sizeof" to make the corresponding size
determination a bit safer according to the Linux coding style convention.
Signed-off-by: Markus Elfring <redacted>
---
drivers/atm/nicstar.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
From: SF Markus Elfring <hidden> Date: 2016-09-10 07:21:52
From: Markus Elfring <redacted>
Date: Sat, 10 Sep 2016 08:56:03 +0200
The script "checkpatch.pl" can point out that assignments should usually
not be performed within condition checks.
Thus move an assignment for a local variable to a separate statement
in this function.
Signed-off-by: Markus Elfring <redacted>
---
drivers/atm/nicstar.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
From: David Miller <davem@davemloft.net> Date: 2016-09-11 04:46:39
From: SF Markus Elfring <redacted>
Date: Sat, 10 Sep 2016 09:15:37 +0200
From: Markus Elfring <redacted>
Date: Sat, 10 Sep 2016 09:10:01 +0200
A few update suggestions were taken into account
from static source code analysis.