Re: [PATCH] edd: fix error paths in module_init

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Matt Domsch
Date: Friday, May 23, 2008 - 10:22 pm

On Sat, May 24, 2008 at 11:03:23AM +0900, Akinobu Mita wrote:

Thanks for these.  You caught me on holiday; I'll take a more thorough
look when I'm back next week.

 

Wouldn't WARN_ON() and return failure be sufficient?  I hate crashing
the system when loading a driver if I can avoid it.



I didn't really like my initial approach, but the question was: when
you hit a failure, do you try to back completely out (unregister
everything that had successfully registered until now), or do you
leave the things that have succeeded, and only fail the current and
future devices?  For my purposes, having even the first device be
reported, even if the others couldn't be, is useful.  Hence why I
didn't undo all the registrations on failure.


-- 
Matt Domsch
Linux Technology Strategist, Dell Office of the CTO
linux.dell.com & www.dell.com/linux
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] edd: fix error paths in module_init, Akinobu Mita, (Fri May 23, 7:03 pm)
Re: [PATCH] edd: fix error paths in module_init, Matt Domsch, (Fri May 23, 10:22 pm)
Re: [PATCH] edd: fix error paths in module_init, Akinobu Mita, (Sat May 24, 1:13 am)