ATM-iphase: Use kmalloc_array() in tx_init()
authorMarkus Elfring <elfring@users.sourceforge.net>
Fri, 9 Sep 2016 18:40:16 +0000 (20:40 +0200)
committerDavid S. Miller <davem@davemloft.net>
Sat, 10 Sep 2016 04:00:16 +0000 (21:00 -0700)
commite808bb6ed042020d3a15cb6e85ca646bc7c9eda8
tree490269b1a7a83e87a6722d8ca45a0183556cb421
parent171a6c523f6486236e3c12aa767d7f354eb543aa
ATM-iphase: Use kmalloc_array() in tx_init()

* Multiplications for the size determination of memory allocations
  indicated that array data structures should be processed.
  Thus use the corresponding function "kmalloc_array".

  This issue was detected by using the Coccinelle software.

* Replace the specification of data types by pointer dereferences
  to make the corresponding size determination a bit safer according to
  the Linux coding style convention.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/atm/iphase.c