diff options
author | Mauro Carvalho Chehab <devnull@localhost> | 2006-01-11 19:28:02 +0000 |
---|---|---|
committer | Mauro Carvalho Chehab <devnull@localhost> | 2006-01-11 19:28:02 +0000 |
commit | 069637ed9609cb009c57d2bf1039e69812b2304b (patch) | |
tree | 043bf8adc38ec355490eff08f7bbdfe90a230456 /linux/drivers/media/video/cx88 | |
parent | 40aca7dd04e8f2d3e3a8cddd5d3d8c3d596c978f (diff) | |
download | mediapointer-dvb-s2-069637ed9609cb009c57d2bf1039e69812b2304b.tar.gz mediapointer-dvb-s2-069637ed9609cb009c57d2bf1039e69812b2304b.tar.bz2 |
From: Panagiotis Issaris <takis@issaris.org>
Conversions from kmalloc+memset to k(z|c)alloc
Conversions from kmalloc+memset to k(z|c)alloc.
kernel-sync
Signed-off-by: Panagiotis Issaris <takis@issaris.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'linux/drivers/media/video/cx88')
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-blackbird.c | 8 | ||||
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-core.c | 5 | ||||
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-dvb.c | 5 | ||||
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-video.c | 8 |
4 files changed, 10 insertions, 16 deletions
diff --git a/linux/drivers/media/video/cx88/cx88-blackbird.c b/linux/drivers/media/video/cx88/cx88-blackbird.c index 7a4c45279..fc4cadeaf 100644 --- a/linux/drivers/media/video/cx88/cx88-blackbird.c +++ b/linux/drivers/media/video/cx88/cx88-blackbird.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-blackbird.c,v 1.40 2006/01/01 17:17:39 mchehab Exp $ + * $Id: cx88-blackbird.c,v 1.41 2006/01/11 19:28:02 mchehab Exp $ * * Support for a cx23416 mpeg encoder via cx2388x host port. * "blackbird" reference design. @@ -1573,10 +1573,9 @@ static int mpeg_open(struct inode *inode, struct file *file) dprintk(1,"open minor=%d\n",minor); /* allocate + initialize per filehandle data */ - fh = kmalloc(sizeof(*fh),GFP_KERNEL); + fh = kzalloc(sizeof(*fh),GFP_KERNEL); if (NULL == fh) return -ENOMEM; - memset(fh,0,sizeof(*fh)); file->private_data = fh; fh->dev = dev; @@ -1712,10 +1711,9 @@ static int __devinit blackbird_probe(struct pci_dev *pci_dev, goto fail_core; err = -ENOMEM; - dev = kmalloc(sizeof(*dev),GFP_KERNEL); + dev = kzalloc(sizeof(*dev),GFP_KERNEL); if (NULL == dev) goto fail_core; - memset(dev,0,sizeof(*dev)); dev->pci = pci_dev; dev->core = core; dev->width = 720; diff --git a/linux/drivers/media/video/cx88/cx88-core.c b/linux/drivers/media/video/cx88/cx88-core.c index df19d7309..f2e18b89d 100644 --- a/linux/drivers/media/video/cx88/cx88-core.c +++ b/linux/drivers/media/video/cx88/cx88-core.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-core.c,v 1.52 2006/01/05 03:31:42 rmcc Exp $ + * $Id: cx88-core.c,v 1.53 2006/01/11 19:28:02 mchehab Exp $ * * device driver for Conexant 2388x based TV cards * driver core @@ -1095,11 +1095,10 @@ struct cx88_core* cx88_core_get(struct pci_dev *pci) up(&devlist); return core; } - core = kmalloc(sizeof(*core),GFP_KERNEL); + core = kzalloc(sizeof(*core),GFP_KERNEL); if (NULL == core) goto fail_unlock; - memset(core,0,sizeof(*core)); atomic_inc(&core->refcount); core->pci_bus = pci->bus->number; core->pci_slot = PCI_SLOT(pci->devfn); diff --git a/linux/drivers/media/video/cx88/cx88-dvb.c b/linux/drivers/media/video/cx88/cx88-dvb.c index a1cac4075..068b2e886 100644 --- a/linux/drivers/media/video/cx88/cx88-dvb.c +++ b/linux/drivers/media/video/cx88/cx88-dvb.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-dvb.c,v 1.82 2006/01/08 10:42:39 pascoe Exp $ + * $Id: cx88-dvb.c,v 1.83 2006/01/11 19:28:02 mchehab Exp $ * * device driver for Conexant 2388x based TV cards * MPEG Transport Stream (DVB) routines @@ -659,10 +659,9 @@ static int __devinit dvb_probe(struct pci_dev *pci_dev, goto fail_core; err = -ENOMEM; - dev = kmalloc(sizeof(*dev),GFP_KERNEL); + dev = kzalloc(sizeof(*dev),GFP_KERNEL); if (NULL == dev) goto fail_core; - memset(dev,0,sizeof(*dev)); dev->pci = pci_dev; dev->core = core; diff --git a/linux/drivers/media/video/cx88/cx88-video.c b/linux/drivers/media/video/cx88/cx88-video.c index dcc4c1f61..a31fee5df 100644 --- a/linux/drivers/media/video/cx88/cx88-video.c +++ b/linux/drivers/media/video/cx88/cx88-video.c @@ -1,5 +1,5 @@ /* - * $Id: cx88-video.c,v 1.104 2006/01/01 17:17:39 mchehab Exp $ + * $Id: cx88-video.c,v 1.105 2006/01/11 19:28:02 mchehab Exp $ * * device driver for Conexant 2388x based TV cards * video4linux video interface @@ -1001,10 +1001,9 @@ static int video_open(struct inode *inode, struct file *file) minor,radio,v4l2_type_names[type]); /* allocate + initialize per filehandle data */ - fh = kmalloc(sizeof(*fh),GFP_KERNEL); + fh = kzalloc(sizeof(*fh),GFP_KERNEL); if (NULL == fh) return -ENOMEM; - memset(fh,0,sizeof(*fh)); file->private_data = fh; fh->dev = dev; fh->radio = radio; @@ -2104,10 +2103,9 @@ static int __devinit cx8800_initdev(struct pci_dev *pci_dev, struct cx88_core *core; int err; - dev = kmalloc(sizeof(*dev),GFP_KERNEL); + dev = kzalloc(sizeof(*dev),GFP_KERNEL); if (NULL == dev) return -ENOMEM; - memset(dev,0,sizeof(*dev)); /* pci init */ dev->pci = pci_dev; |