mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-13 08:07:32 -04:00
staging: kpc2000: use sizeof(var) in kzalloc call
Fixes checkpatch.pl warning "Prefer kzalloc(sizeof(*pcard)...) over kzalloc(sizeof(struct kp2000_device)...)". Signed-off-by: Simon Sandström <simon@nikanor.nu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
a12cae870a
commit
a1ceab8b92
1 changed files with 1 additions and 1 deletions
|
|
@ -317,7 +317,7 @@ static int kp2000_pcie_probe(struct pci_dev *pdev,
|
|||
/*
|
||||
* Step 1: Allocate a struct for the pcard
|
||||
*/
|
||||
pcard = kzalloc(sizeof(struct kp2000_device), GFP_KERNEL);
|
||||
pcard = kzalloc(sizeof(*pcard), GFP_KERNEL);
|
||||
if (!pcard)
|
||||
return -ENOMEM;
|
||||
dev_dbg(&pdev->dev, "probe: allocated struct kp2000_device @ %p\n",
|
||||
|
|
|
|||
Loading…
Reference in a new issue