The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Vicentiu Ciorbaru <cvicentiu@gmail.com>
To: perex@perex.cz
Cc: tiwai@suse.de, wfp5p@virginia.edu, cvicentiu@gmail.com,
	alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org
Subject: [PATCH] emu10k1: Fix coccicheck warning
Date: Sun, 10 Mar 2013 14:37:47 +0200	[thread overview]
Message-ID: <1362919067-17250-1-git-send-email-cvicentiu@gmail.com> (raw)

Removed redundant cast of kmalloc return pointer.

Signed-off-by: Vicentiu Ciorbaru <cvicentiu@gmail.com>
---
 sound/pci/emu10k1/emufx.c |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/sound/pci/emu10k1/emufx.c b/sound/pci/emu10k1/emufx.c
index 0275209..a0f7502 100644
--- a/sound/pci/emu10k1/emufx.c
+++ b/sound/pci/emu10k1/emufx.c
@@ -1183,9 +1183,8 @@ static int _snd_emu10k1_audigy_init_efx(struct snd_emu10k1 *emu)
 	mm_segment_t seg;
 
 	if ((icode = kzalloc(sizeof(*icode), GFP_KERNEL)) == NULL ||
-	    (icode->gpr_map = (u_int32_t __user *)
-	     kcalloc(512 + 256 + 256 + 2 * 1024, sizeof(u_int32_t),
-		     GFP_KERNEL)) == NULL ||
+	    (icode->gpr_map = kcalloc(512 + 256 + 256 + 2 * 1024,
+				sizeof(u_int32_t), GFP_KERNEL)) == NULL ||
 	    (controls = kcalloc(SND_EMU10K1_GPR_CONTROLS,
 				sizeof(*controls), GFP_KERNEL)) == NULL) {
 		err = -ENOMEM;
-- 
1.7.10.4


             reply	other threads:[~2013-03-10 12:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-10 12:37 Vicentiu Ciorbaru [this message]
2013-03-10 16:32 ` [PATCH] emu10k1: Fix coccicheck warning Clemens Ladisch
     [not found]   ` <CACzaYTOE=tVst3=TvUCtxpMuUOtJiHQ3o2wbgWeMvxwZy41DMw@mail.gmail.com>
2013-03-10 19:49     ` Clemens Ladisch
2013-03-10 19:59       ` Vicentiu Ciorbaru

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1362919067-17250-1-git-send-email-cvicentiu@gmail.com \
    --to=cvicentiu@gmail.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.de \
    --cc=wfp5p@virginia.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox