ALSA: pcxhr: Delete an error message for a failed memory allocation in pcxhr_create()

Omit an extra message for a memory allocation failure in this function.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Markus Elfring 2017-08-12 18:14:54 +02:00 committed by Takashi Iwai
parent dee49895b1
commit c38774d830
1 changed files with 1 additions and 3 deletions

View File

@ -1215,10 +1215,8 @@ static int pcxhr_create(struct pcxhr_mgr *mgr,
};
chip = kzalloc(sizeof(*chip), GFP_KERNEL);
if (! chip) {
dev_err(card->dev, "cannot allocate chip\n");
if (!chip)
return -ENOMEM;
}
chip->card = card;
chip->chip_idx = idx;