Panic with ugen
    Jay Cornwall 
    jay at evilrealms.net
       
    Wed Nov 26 16:08:56 PST 2003
    
    
  
Martin wrote:
> It looks like this:
> panic()
> destroy_dev()
> ugen_destroy_devnodes()
> ugen_set_config()
Yes, that's the one, and I think I can see why. The existing code fixed devfs 
problems for normal ugen_set_config calls, but doesn't account for what 
happens when an error occurs (which is presumably happening in your example 
program, as you said it gives an error the first time round) - the devfs stuff 
only half completes.
(actually, looking at that error handling code, it doesn't look like it's been 
thought through well anyway - /* XXX should only do this after setting new 
altno has succeeded */ - maybe time to clean this code up?)
After the device endpoints are destroyed (sys/dev/ugen.c:1038), the returns on 
lines 1055 and 1058 need to be covered by a devnode recovery procedure - 
particularly tricky given we just wiped the endpoint descriptors clean.
I'll look at restructuring this code tomorrow, if Bernd doesn't beat me to it.
-- 
Cheers,
Jay
http://www.evilrealms.net/ - Systems Administrator & Developer
http://www.imperial.ac.uk/ - 3rd year CS student
    
    
More information about the freebsd-current
mailing list