vmalloc() returns a void pointer - no need to cast it. Signed-off-by: Jesper Juhl <[email protected]> --- arch/ia64/sn/kernel/sn2/sn_hwperf.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/arch/ia64/sn/kernel/sn2/sn_hwperf.c b/arch/ia64/sn/kernel/sn2/sn_hwperf.c index df8d5be..1a8e496 100644 --- a/arch/ia64/sn/kernel/sn2/sn_hwperf.c +++ b/arch/ia64/sn/kernel/sn2/sn_hwperf.c @@ -66,7 +66,8 @@ static int sn_hwperf_enum_objects(int *nobj, struct sn_hwperf_object_info **ret) } sz = sn_hwperf_obj_cnt * sizeof(struct sn_hwperf_object_info); - if ((objbuf = (struct sn_hwperf_object_info *) vmalloc(sz)) == NULL) { + objbuf = vmalloc(sz); + if (objbuf == NULL) { printk("sn_hwperf_enum_objects: vmalloc(%d) failed\n", (int)sz); e = -ENOMEM; goto out; -- 1.5.2.2 - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
- Follow-Ups:
- [PATCH 30/30] emu10k1: There's no need to cast vmalloc() return value in snd_emu10k1_create()
- From: Jesper Juhl <[email protected]>
- [PATCH 29/30] mm: No need to cast vmalloc() return value in zone_wait_table_init()
- From: Jesper Juhl <[email protected]>
- [PATCH 28/30] jfs: avoid pointless casts of kmalloc() return val
- From: Jesper Juhl <[email protected]>
- [PATCH 27/30] usb: avoid redundant cast of kmalloc() return value in OTi-6858 driver
- From: Jesper Juhl <[email protected]>
- [PATCH 26/30] md: vmalloc() returns void pointer so we don't need to cast it in dm-ioctl
- From: Jesper Juhl <[email protected]>
- [PATCH 25/30] tty: dont needlessly cast kmalloc() return value
- From: Jesper Juhl <[email protected]>
- [PATCH 24/30] dvb: remove some unneeded vmalloc() return value casts from av7110
- From: Jesper Juhl <[email protected]>
- [PATCH 23/30] video: Remove pointless kmalloc() return value cast in Zoran PCI controller driver
- From: Jesper Juhl <[email protected]>
- [PATCH 22/30] ivtv: kzalloc() returns void pointer, no need to cast
- From: Jesper Juhl <[email protected]>
- [PATCH 21/30] oss: Remove unneeded vmalloc() return value casts in OSS
- From: Jesper Juhl <[email protected]>
- [PATCH 20/30] scsi: In the Advansys driver, do not cast allocation function return values
- From: Jesper Juhl <[email protected]>
- [PATCH 19/30] scsi: Remove explicit casts of [kv]alloc return values in osst driver
- From: Jesper Juhl <[email protected]>
- [PATCH 18/30] isdn: eicon - get rid of a pointless vmalloc() return value cast
- From: Jesper Juhl <[email protected]>
- [PATCH 17/30] isdn: Get rid of some pointless allocation casts in common and bsd comp.
- From: Jesper Juhl <[email protected]>
- [PATCH 16/30] net: Avoid pointless allocation casts in BSD compression module
- From: Jesper Juhl <[email protected]>
- [PATCH 14/30] net: Kill some unneeded allocation return value casts in libertas
- From: Jesper Juhl <[email protected]>
- [PATCH 10/30] irda: Do not do pointless kmalloc return value cast in KingSun driver
- From: Jesper Juhl <[email protected]>
- [PATCH 09/30] mtd: Don't cast kmalloc() return value in drivers/mtd/maps/pmcmsp-flash.c
- From: Jesper Juhl <[email protected]>
- [PATCH 08/30] mtd: Avoid a pointless kmalloc() return value cast in TQM8xxL mapping handling code
- From: Jesper Juhl <[email protected]>
- [PATCH 07/30] mtd: Get rid of pointless cast of kzalloc() return value in AT26xxx driver
- From: Jesper Juhl <[email protected]>
- [PATCH 06/30] i2o: No need to cast kmalloc() return value in cfg_open()
- From: Jesper Juhl <[email protected]>
- [PATCH 05/30] atm: No need to cast vmalloc() return value
- From: Jesper Juhl <[email protected]>
- [PATCH 04/30] powerpc: Don't cast kmalloc return value in ibmebus.c
- From: Jesper Juhl <[email protected]>
- [PATCH 03/30] um: Don't unnecessarily cast allocation return value in ubd_kern.c
- From: Jesper Juhl <[email protected]>
- [PATCH 02/30] cris: Remove unnecessary cast of allocation return value in intmem.c
- From: Jesper Juhl <[email protected]>
- [PATCH 30/30] emu10k1: There's no need to cast vmalloc() return value in snd_emu10k1_create()
- References:
- Prev by Date: Re: [BUG] 2.6.23-rc3-mm1 Oops: Machine check, sig: 7 [#1]
- Next by Date: division and cpu usage
- Previous by thread: [PATCH 0/30] Remove unneeded casts of [kv][mzc]alloc() return values
- Next by thread: [PATCH 02/30] cris: Remove unnecessary cast of allocation return value in intmem.c
- Index(es):