Skip to content

Commit

Permalink
x86, cpuid: Use PTR_ERR_OR_ZERO
Browse files Browse the repository at this point in the history
Replace IS_ERR/PTR_ERR

Signed-off-by: Fabian Frederick <fabf@skynet.be>
Link: http://lkml.kernel.org/r/1413576077-26969-1-git-send-email-fabf@skynet.be
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
  • Loading branch information
Fabian Frederick authored and H. Peter Anvin committed Oct 17, 2014
1 parent 196cf35 commit cbda45a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/x86/kernel/cpuid.c
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ static int cpuid_device_create(int cpu)

dev = device_create(cpuid_class, NULL, MKDEV(CPUID_MAJOR, cpu), NULL,
"cpu%d", cpu);
return IS_ERR(dev) ? PTR_ERR(dev) : 0;
return PTR_ERR_OR_ZERO(dev);
}

static void cpuid_device_destroy(int cpu)
Expand Down

0 comments on commit cbda45a

Please sign in to comment.