Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 Nov 2011 00:35:38 +0200
From:      Alexander Motin <mav@FreeBSD.org>
To:        Maksim Yevmenkin <emax@freebsd.org>
Cc:        current@freebsd.org
Subject:   Re: [RFC] ahci(4) patch
Message-ID:  <4EC43ABA.7060407@FreeBSD.org>
In-Reply-To: <CAFPOs6rU6AKeTNzKhaqxktDb9CN=g-EDMLf2%2Bcyvhq772SymjA@mail.gmail.com>
References:  <CAFPOs6rU6AKeTNzKhaqxktDb9CN=g-EDMLf2%2Bcyvhq772SymjA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi.

On 16.11.2011 23:59, Maksim Yevmenkin wrote:
> would anyone object to the following ahci(4) patch?
>
> ==
>
> --- ahci.c.orig	2011-11-16 21:35:26.000000000 +0000
> +++ ahci.c	2011-11-16 21:35:41.000000000 +0000
> @@ -500,7 +500,7 @@
>   	for (unit = 0; unit<  ctlr->channels; unit++) {
>   		if ((ctlr->ichannels&  (1<<  unit)) == 0)
>   			continue;
> -		child = device_add_child(dev, "ahcich", -1);
> +		child = device_add_child(dev, "ahcich", unit);
>   		if (child == NULL)
>   			device_printf(dev, "failed to add channel device\n");
>   		else
>
> ==
>
> the idea is to have "static" numbering for ada(4) disks.

I do. The only way I see this useful is if you have BIOS configured for 
non-hot-swappable disks, in which case you have some AHCI channels 
disabled, but want to keep numbers of the rest. While I don't like this 
mode in general, especially when it can't be disabled, that patch could 
be useful in these cases. But in other cases, when you have several AHCI 
controllers, it just wont not work. You will receive error on attempt to 
create second ahcich0.

-- 
Alexander Motin



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4EC43ABA.7060407>