Skip to content

Commit

Permalink
[IA64] Remove unnecessary cast of allocation return value in sn_hwper…
Browse files Browse the repository at this point in the history
…f_enum_objects()

vmalloc() returns a void pointer - no need to cast it.

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
  • Loading branch information
Jesper Juhl authored and Tony Luck committed Sep 1, 2007
1 parent f740e6c commit 1aac0b5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arch/ia64/sn/kernel/sn2/sn_hwperf.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 1aac0b5

Please sign in to comment.