lkml.org 
[lkml]   [2002]   [Jan]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: SCSI host numbers?
Itai Nahshon writes:
> On Sunday 06 January 2002 03:44 am, Richard Gooch wrote:
> > Where exactly is the host_id for an unregistered host being
> > remembered?
>
> Sorry for the late reply. I was away from Email for the whole week.
>
> Scsi host numbers (for both regstered and unregistered hosts)
> are preserved in scsi_host_no_list.
>
> The list is used in the function scsi_register (in drivers/scsi/hosts.c).
> Same function also adds new hosts to the list.
>
> The list can be initialized (from boot parameters ?) by
> the function scsi_host_no_init (drivers/scsi/scsi.c).

Ah, yes. That was a patch someone sent to me years ago, and got
included in the jumbo devfs patch. There's a boot parameter which
allows you to control the allocation of host numbers.

So how about in scsi_host_no_init() we call alloc_unique_number() N
times until we've allocated the required number of host numbers for
manual control. These will never be freed. Then all other host
allocations can be done dynamically. We would just need a flag in the
host structure to disable deallocation of the number if it's one of
the reserved numbers.

Regards,

Richard....
Permanent: rgooch@atnf.csiro.au
Current: rgooch@ras.ucalgary.ca
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:15    [W:0.060 / U:1.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site