Date: Fri, 3 Sep 2010 10:01:58 -0400 From: John Baldwin <jhb@freebsd.org> To: Andriy Gapon <avg@freebsd.org> Cc: freebsd-arch@freebsd.org Subject: Re: newbus: type (max value) for device order Message-ID: <201009031001.58036.jhb@freebsd.org> In-Reply-To: <4C80A728.6090002@freebsd.org> References: <4C80A728.6090002@freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Friday, September 03, 2010 3:43:36 am Andriy Gapon wrote: > > device_add_child_ordered() takes order as a parameter of int type. > struct device stores it as u_char. > > This can be confusing, can't it? > In fact, up to r203776 we used to use order value of 100000 in acpi.c (which > effectively was 160 according to my calculations). > > Not sure what I want to suggest, perhaps defining DEVICE_MAX_ORDER or something. > Or changing the type in struct device to int. Just fix device_t to store an int I think. Also, it should probably be a u_int as negative values don't really make sense. -- John Baldwin -- John Baldwin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201009031001.58036.jhb>