* [PATCH 01/16] Clean up unnecessary void* pointer cast.
@ 2015-04-22 16:35 Firo Yang
2015-04-22 16:51 ` Dan Carpenter
0 siblings, 1 reply; 2+ messages in thread
From: Firo Yang @ 2015-04-22 16:35 UTC (permalink / raw)
To: kernel-janitors
Signed-off-by: Firo Yang <firogm@gmail.com>
---
sound/pci/emu10k1/emufx.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/sound/pci/emu10k1/emufx.c b/sound/pci/emu10k1/emufx.c
index 56fc47b..8a39a6f 100644
--- a/sound/pci/emu10k1/emufx.c
+++ b/sound/pci/emu10k1/emufx.c
@@ -1186,8 +1186,8 @@ static int _snd_emu10k1_audigy_init_efx(struct snd_emu10k1 *emu)
if (!icode)
return err;
- icode->gpr_map = (u_int32_t __user *) kcalloc(512 + 256 + 256 + 2 * 1024,
- sizeof(u_int32_t), GFP_KERNEL);
+ icode->gpr_map = kcalloc(512 + 256 + 256 + 2 * 1024,
+ sizeof(u_int32_t), GFP_KERNEL);
if (!icode->gpr_map)
goto __err_gpr;
controls = kcalloc(SND_EMU10K1_GPR_CONTROLS,
@@ -1824,8 +1824,8 @@ static int _snd_emu10k1_init_efx(struct snd_emu10k1 *emu)
if (!icode)
return err;
- icode->gpr_map = (u_int32_t __user *) kcalloc(256 + 160 + 160 + 2 * 512,
- sizeof(u_int32_t), GFP_KERNEL);
+ icode->gpr_map = kcalloc(256 + 160 + 160 + 2 * 512,
+ sizeof(u_int32_t), GFP_KERNEL);
if (!icode->gpr_map)
goto __err_gpr;
--
2.1.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 01/16] Clean up unnecessary void* pointer cast.
2015-04-22 16:35 [PATCH 01/16] Clean up unnecessary void* pointer cast Firo Yang
@ 2015-04-22 16:51 ` Dan Carpenter
0 siblings, 0 replies; 2+ messages in thread
From: Dan Carpenter @ 2015-04-22 16:51 UTC (permalink / raw)
To: kernel-janitors
The subject need to be written by hand and they need to be unique.
git log --oneline driver/file.c
Copy and paste the patch prefix for each email you send.
On Thu, Apr 23, 2015 at 12:35:15AM +0800, Firo Yang wrote:
> Signed-off-by: Firo Yang <firogm@gmail.com>
> ---
> sound/pci/emu10k1/emufx.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/sound/pci/emu10k1/emufx.c b/sound/pci/emu10k1/emufx.c
> index 56fc47b..8a39a6f 100644
> --- a/sound/pci/emu10k1/emufx.c
> +++ b/sound/pci/emu10k1/emufx.c
> @@ -1186,8 +1186,8 @@ static int _snd_emu10k1_audigy_init_efx(struct snd_emu10k1 *emu)
> if (!icode)
> return err;
>
> - icode->gpr_map = (u_int32_t __user *) kcalloc(512 + 256 + 256 + 2 * 1024,
> - sizeof(u_int32_t), GFP_KERNEL);
This cast is special. It's a Sparse thing. Since I know you have
Smatch installed you can do
~/path/to/smatch/smatch_scripts/kchecker --sparse sound/pci/emu10k1/emufx.c
I'm not positive if you need a __force in there?
Anyway, don't remove this.
regards,
dan carpenter
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-04-22 16:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-22 16:35 [PATCH 01/16] Clean up unnecessary void* pointer cast Firo Yang
2015-04-22 16:51 ` Dan Carpenter
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).