Date: Tue, 22 Sep 2009 08:37:26 -0700 (PDT) From: Barney Cordoba <barney_cordoba@yahoo.com> To: pluknet <pluknet@gmail.com>, gary.jennejohn@freenet.de Cc: current@freebsd.org Subject: Re: where is device_get_parent function defined Message-ID: <917077.59537.qm@web63902.mail.re1.yahoo.com> In-Reply-To: <20090922171629.418a089b@ernst.jennejohn.org>
index | next in thread | previous in thread | raw e-mail
--- On Tue, 9/22/09, Gary Jennejohn <gary.jennejohn@freenet.de> wrote: > From: Gary Jennejohn <gary.jennejohn@freenet.de> > Subject: Re: where is device_get_parent function defined > To: "pluknet" <pluknet@gmail.com> > Cc: "Barney Cordoba" <barney_cordoba@yahoo.com>, current@freebsd..org > Date: Tuesday, September 22, 2009, 11:16 AM > On Tue, 22 Sep 2009 17:37:00 +0400 > pluknet <pluknet@gmail.com> > wrote: > > > 2009/9/22 Barney Cordoba <barney_cordoba@yahoo.com>: > > > > > > > > > --- On Tue, 9/22/09, Gary Jennejohn <gary.jennejohn@freenet.de> > wrote: > > > > > >> From: Gary Jennejohn <gary.jennejohn@freenet.de> > > >> Subject: Re: where is device_get_parent > function defined > > >> To: "Barney Cordoba" <barney_cordoba@yahoo.com> > > >> Cc: current@freebsd.org > > >> Date: Tuesday, September 22, 2009, 5:32 AM > > >> On Mon, 21 Sep 2009 15:27:42 -0700 > > >> (PDT) > > >> Barney Cordoba <barney_cordoba@yahoo.com> > > >> wrote: > > >> > > >> > I can't seem to find where > device_get_parent() is > > >> defined. > > >> > > > >> > > >> /sys/kern/subr_bus,c > > >> > > >> grep -r ^device_get_parent /sys/ > > > > > > Thanks, I found it shortly after posting. The > "problem" with grep is > > > that you get about a billion lines, particularly > on systems with 4 or > > > 5 different kernel sources installed. > > > > > > > Following style(9): > > ### > > The function type should be on a > line by itself preceding the function. > > > > static char * > > function(int a1, int a2, float fl, > int a4) > > ### > > > > So you can safely use the caret sign in regex: grep > ^keyword path > > > > Which, of course, is exactly why I used it. This > style(9) rule is one > big advantage which FreeBSD has over Linux. It's > practically impossible to > find a function in Linux because the type is always on the > same line as the > function declaration. Drives my crazy. > > --- > Gary Jennejohn So all they need now is an open to turn off the recursive directory warnings.... Of course a section in the man page telling you the source module would make way too much sense to be adopted by any of the free software groups... BChome | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?917077.59537.qm>
