* [PATCH] dvb-core: remove unnecessary casting of kmalloc.
@ 2010-01-16 13:25 Thiago Farina
0 siblings, 0 replies; only message in thread
From: Thiago Farina @ 2010-01-16 13:25 UTC (permalink / raw)
To: linux-kernel
Cc: Mauro Carvalho Chehab, Devin Heitmueller, Janne Grunau,
Patrick Boettcher, tstrelar, linux-media
Signed-off-by: Thiago Farina <tfransosi@gmail.com>
---
drivers/media/dvb/dvb-core/dvb_frontend.c | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/media/dvb/dvb-core/dvb_frontend.c b/drivers/media/dvb/dvb-core/dvb_frontend.c
index 0746122..8eb4a3b 100644
--- a/drivers/media/dvb/dvb-core/dvb_frontend.c
+++ b/drivers/media/dvb/dvb-core/dvb_frontend.c
@@ -1536,8 +1536,7 @@ static int dvb_frontend_ioctl_properties(struct inode *inode, struct file *file,
if ((tvps->num == 0) || (tvps->num > DTV_IOCTL_MAX_MSGS))
return -EINVAL;
- tvp = (struct dtv_property *) kmalloc(tvps->num *
- sizeof(struct dtv_property), GFP_KERNEL);
+ tvp = kmalloc(tvps->num * sizeof(struct dtv_property), GFP_KERNEL);
if (!tvp) {
err = -ENOMEM;
goto out;
@@ -1569,8 +1568,7 @@ static int dvb_frontend_ioctl_properties(struct inode *inode, struct file *file,
if ((tvps->num == 0) || (tvps->num > DTV_IOCTL_MAX_MSGS))
return -EINVAL;
- tvp = (struct dtv_property *) kmalloc(tvps->num *
- sizeof(struct dtv_property), GFP_KERNEL);
+ tvp = kmalloc(tvps->num * sizeof(struct dtv_property), GFP_KERNEL);
if (!tvp) {
err = -ENOMEM;
goto out;
--
1.6.6.103.g699d2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2010-01-16 13:26 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-16 13:25 [PATCH] dvb-core: remove unnecessary casting of kmalloc Thiago Farina
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.