Re: XXX driver didn't initialize queue mtx
On Sat, Jan 27, 2001 at 03:19:04PM -0600, Jonathan Lemon wrote: > Actually, the new check appears to be incorrect, as seen by the code > fragments below: Whoops. I obviously looked at the wrong #define when making the change. Thanks for pointing out the mistake. Jason To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
On 27-Jan-01 Matthew Jacob wrote: > > Oh, yeah- can someone say *which* queue mtx it's referring to? The if queues. Ones with the IFQ_ENQUEUE() etc. macros. > On 27 Jan 2001, Dag-Erling Smorgrav wrote: > >> Blaz Zupan <[EMAIL PROTECTED]> writes: >> > xl0 XXX: driver didn't initialize queue mtx >> > [...] >> >> Nothing to worry about, it's just a reminder for us kernel jocks. >> >> DES >> -- >> Dag-Erling Smorgrav - [EMAIL PROTECTED] >> >> >> To Unsubscribe: send mail to [EMAIL PROTECTED] >> with "unsubscribe freebsd-current" in the body of the message >> > > > > To Unsubscribe: send mail to [EMAIL PROTECTED] > with "unsubscribe freebsd-current" in the body of the message -- John Baldwin <[EMAIL PROTECTED]> -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
On Sat, Jan 27, 2001 at 01:05:58PM -0800, Jason Evans wrote: > On Sat, Jan 27, 2001 at 12:48:36PM -0800, Matthew Jacob wrote: > > Somewhere in between, Jason Evans wrote: > > > On Sat, Jan 27, 2001 at 12:36:41PM -0800, Matthew Jacob wrote: > > > > > > > > Oh, I suppose, I did find that... well, mainly I wanted the person who made > > > > the change to actually broadcast to NIC maintainers what the expectations > > > > were... > > > > > > The code that prints these warnings out has existed for a while. However, > > > whoever added it made a bad assumption about the internals of the mutex > > > implementation, so the code never got executed. I "fixed" it last week, so > > > the warnings get printed now. > > > > Shouldn't ether_ifattach initialize the mutex? Or do expect all drivers to > > initialize these prior to calling ether_ifattach? > > > > Look- I just want to know what the people who put the check in *want*. > > cvs annotate is your friend. The code was added in revision 1.95 of > src/sys/net/if.c by Jonathan Lemon. Please talk to him about what should > be done to fix the drivers. Actually, the new check appears to be incorrect, as seen by the code fragments below: #define MTX_DEF 0x0 /* Default (spin/sleep) */ mtx_init(&ifp->if_snd.ifq_mtx, ifp->if_name, MTX_DEF); mtx_init(... , flag) { ... m->mtx_flags = flag; ... } if (ifp->if_snd.ifq_mtx.mtx_flags == 0) { So the warning will always be printed out even though the mutex is correctly initialized. -- Jonathan To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
In article [EMAIL PROTECTED]> you write: >On Sat, Jan 27, 2001 at 12:36:41PM -0800, Matthew Jacob wrote: >> >> Oh, I suppose, I did find that... well, mainly I wanted the person who made >> the change to actually broadcast to NIC maintainers what the expectations >> were... > >The code that prints these warnings out has existed for a while. However, >whoever added it made a bad assumption about the internals of the mutex >implementation, so the code never got executed. I "fixed" it last week, so >the warnings get printed now. Actually, I think it was correct at the time I added it. Anything that calls if_attach (or ether_ifattach) will automatically have the mutex correctly initialized, so the driver doesn't have to do anything extra. e.g.: ifp->if_name = "lo"; ifp->if_unit = i++; ifp->if_snd.ifq_maxlen = ifqmaxlen; if_attach(ifp); if_attach(ifp) { mtx_init(&ifp->if_snd.ifq_mtx, ifp->if_name, MTX_DEF); ... } I'm not up-to-date with -current at the moment, so I'm not sure why things aren't working any more. -- Jonathan To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
> > cvs annotate is your friend. The code was added in revision 1.95 of > src/sys/net/if.c by Jonathan Lemon. Please talk to him about what should > be done to fix the drivers. Yes, and I shall... but this came up in a public forum. I'm making a point here (that apparently you and others don't get). To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
On Sat, Jan 27, 2001 at 12:48:36PM -0800, Matthew Jacob wrote: > Somewhere in between, Jason Evans wrote: > > On Sat, Jan 27, 2001 at 12:36:41PM -0800, Matthew Jacob wrote: > > > > > > Oh, I suppose, I did find that... well, mainly I wanted the person who made > > > the change to actually broadcast to NIC maintainers what the expectations > > > were... > > > > The code that prints these warnings out has existed for a while. However, > > whoever added it made a bad assumption about the internals of the mutex > > implementation, so the code never got executed. I "fixed" it last week, so > > the warnings get printed now. > > Shouldn't ether_ifattach initialize the mutex? Or do expect all drivers to > initialize these prior to calling ether_ifattach? > > Look- I just want to know what the people who put the check in *want*. cvs annotate is your friend. The code was added in revision 1.95 of src/sys/net/if.c by Jonathan Lemon. Please talk to him about what should be done to fix the drivers. Jason To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
Shouldn't ether_ifattach initialize the mutex? Or do expect all drivers to initialize these prior to calling ether_ifattach? Look- I just want to know what the people who put the check in *want*. > On Sat, Jan 27, 2001 at 12:36:41PM -0800, Matthew Jacob wrote: > > > > Oh, I suppose, I did find that... well, mainly I wanted the person who made > > the change to actually broadcast to NIC maintainers what the expectations > > were... > > The code that prints these warnings out has existed for a while. However, > whoever added it made a bad assumption about the internals of the mutex > implementation, so the code never got executed. I "fixed" it last week, so > the warnings get printed now. > > Jason > > > To Unsubscribe: send mail to [EMAIL PROTECTED] > with "unsubscribe freebsd-current" in the body of the message > To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
On Sat, Jan 27, 2001 at 12:36:41PM -0800, Matthew Jacob wrote: > > Oh, I suppose, I did find that... well, mainly I wanted the person who made > the change to actually broadcast to NIC maintainers what the expectations > were... The code that prints these warnings out has existed for a while. However, whoever added it made a bad assumption about the internals of the mutex implementation, so the code never got executed. I "fixed" it last week, so the warnings get printed now. Jason To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
Oh, I suppose, I did find that... well, mainly I wanted the person who made the change to actually broadcast to NIC maintainers what the expectations were... > Matthew Jacob <[EMAIL PROTECTED]> writes: > > Oh, yeah- can someone say *which* queue mtx it's referring to? > > des@des ~% current "driver didn.t initialize" > src/sys/net/if.c: printf("%s%d XXX: driver didn't initialize >queue mtx\n", > des@des ~% grep -C "driver didn.t initialize" /sys/net/if.c > /* XXX This is an access violation of the mutex internals. */ > if (ifp->if_snd.ifq_mtx.mtx_flags == 0) { > printf("%s%d XXX: driver didn't initialize queue mtx\n", > ifp->if_name, ifp->if_unit); > mtx_init(&ifp->if_snd.ifq_mtx, "unknown", MTX_DEF); > > That wasn't so hard, was it? > > DES > To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
Matthew Jacob <[EMAIL PROTECTED]> writes: > Oh, yeah- can someone say *which* queue mtx it's referring to? des@des ~% current "driver didn.t initialize" src/sys/net/if.c: printf("%s%d XXX: driver didn't initialize queue mtx\n", des@des ~% grep -C "driver didn.t initialize" /sys/net/if.c /* XXX This is an access violation of the mutex internals. */ if (ifp->if_snd.ifq_mtx.mtx_flags == 0) { printf("%s%d XXX: driver didn't initialize queue mtx\n", ifp->if_name, ifp->if_unit); mtx_init(&ifp->if_snd.ifq_mtx, "unknown", MTX_DEF); That wasn't so hard, was it? DES -- Dag-Erling Smorgrav - [EMAIL PROTECTED] To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
Oh, yeah- can someone say *which* queue mtx it's referring to? On 27 Jan 2001, Dag-Erling Smorgrav wrote: > Blaz Zupan <[EMAIL PROTECTED]> writes: > > xl0 XXX: driver didn't initialize queue mtx > > [...] > > Nothing to worry about, it's just a reminder for us kernel jocks. > > DES > -- > Dag-Erling Smorgrav - [EMAIL PROTECTED] > > > To Unsubscribe: send mail to [EMAIL PROTECTED] > with "unsubscribe freebsd-current" in the body of the message > To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
Re: XXX driver didn't initialize queue mtx
Blaz Zupan <[EMAIL PROTECTED]> writes: > xl0 XXX: driver didn't initialize queue mtx > [...] Nothing to worry about, it's just a reminder for us kernel jocks. DES -- Dag-Erling Smorgrav - [EMAIL PROTECTED] To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message
XXX driver didn't initialize queue mtx
# dmesg ... xl0 XXX: driver didn't initialize queue mtx lo0 XXX: driver didn't initialize queue mtx isp0 XXX: driver didn't initialize queue mtx isp1 XXX: driver didn't initialize queue mtx isp2 XXX: driver didn't initialize queue mtx isp3 XXX: driver didn't initialize queue mtx ... Anything to worry about? 5.0-CURRENT as of today. Blaz Zupan, Medinet d.o.o, Linhartova 21, 2000 Maribor, Slovenia E-mail: [EMAIL PROTECTED], Tel: +386-2-320-6320, Fax: +386-2-320-6325 To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message