scsi: hpsa: Use vmemdup_user to replace the open code
authorzhong jiang <zhongjiang@huawei.com>
Tue, 18 Sep 2018 15:54:41 +0000 (23:54 +0800)
committerMartin K. Petersen <martin.petersen@oracle.com>
Wed, 26 Sep 2018 00:44:21 +0000 (20:44 -0400)
commit048a864e533039cc950b716e774c2c09af8fa1dd
tree754b2bef513baf64d3c8baea76847b888c37d52a
parent874deb1c652df94917f5619d972d2435a762b8a0
scsi: hpsa: Use vmemdup_user to replace the open code

vmemdup_user is better than duplicating its implementation, So just replace
the open code.

The issue is detected with the help of Coccinelle.

Tested-by: Don Brace <don.brace@microsemi.com>
Acked-by: Don Brace <don.brace@microsemi.com>
Signed-off-by: zhong jiang <zhongjiang@huawei.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/hpsa.c