lkml.org 
[lkml]   [2003]   [Jan]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[patch][trivial] fix drivers/base/cpu.c
Both drivers/base/node.c & memblk.c check the return values of the 
devclass_register & driver_register calls. cpu.c doesn't. This little
patch remedies that omission.

[mcd@arrakis push]$ diffstat sysfs_topo_cleanup-2.5.59.patch
cpu.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)

Cheers!

-Matt
diff -Nur --exclude-from=/usr/src/.dontdiff linux-2.5.58-vanilla/drivers/base/cpu.c linux-2.5.58-topo_cleanup/drivers/base/cpu.c
--- linux-2.5.58-vanilla/drivers/base/cpu.c Mon Jan 13 21:58:28 2003
+++ linux-2.5.58-topo_cleanup/drivers/base/cpu.c Thu Jan 16 16:48:23 2003
@@ -48,7 +48,7 @@

static int __init register_cpu_type(void)
{
- devclass_register(&cpu_devclass);
- return driver_register(&cpu_driver);
+ int error = devclass_register(&cpu_devclass);
+ return error ? error : driver_register(&cpu_driver);
}
postcore_initcall(register_cpu_type);
\
 
 \ /
  Last update: 2005-03-22 13:32    [W:0.034 / U:0.992 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site