Bug 29104

Summary: [PATCH] md, disklabel and devfs do not play nice
Product: Base System Reporter: davidc <davidc>
Component: kernAssignee: Poul-Henning Kamp <phk>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: 5.0-CURRENT   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff none

Description davidc 2001-07-20 12:10:05 UTC
	When disklabel is run on a md without the full path name to the device a
	new device is created, even if the device name is silly.  If the device
	is the 'c' device then the error message:

	WARNING: Driver mistake: repeat make_dev("md10c")

	is reported.  If the md is detached the system crashes with the following
	error printed over and over:

	WARNING: Driver mistake: destroy_dev on 95/82

	Part of the problem is caused by disklabel auto appending a 'c' onto the
	device name so md10c becomes md10cc, and then disk_clone() doesn't bother
	to check for that.

Fix: Fix disk_clone() so that it does not try and [re]create devices that have bad names.
How-To-Repeat: 
	1) Create a md.
		mdconfig -a -t swap -s 32m -u 10

	2) run disklabel.
		disklabel md10c
		(note console output)

	3) detach the md. (XXX crashes my local machine).
		mdconfig -d -u 10
Comment 1 dd freebsd_committer freebsd_triage 2001-07-20 12:16:35 UTC
Responsible Changed
From-To: freebsd-bugs->phk

Over to author/maintainer/person with general know-how in this area.
Comment 2 Poul-Henning Kamp freebsd_committer freebsd_triage 2001-11-16 22:55:13 UTC
State Changed
From-To: open->closed

This has been fixed in the meantime.