Re: Writing device drivers (was: help me please)
hi, Thanx Julian for pointing me to the tunnel pseudo-driver. But my major concern was regarding linking the driver to the kernel( i am trying to use static linking stuff). I am presently doing a major grep on tun 8-) It would be great if i could get some docs regding which files have to be modified so that the kernel realises my driver. So far i could figure out that the below files have to be modified( did i leave anything ) /usr/src/sys/i386/conf/* /usr/src/sys/conf/majors /usr/src/sys/conf/files Do i really have to modify the /usr/src/sys/modules/* files??? jayesh From: Julian Elischer [EMAIL PROTECTED] To: Brian Somers [EMAIL PROTECTED] CC: Greg Lehey [EMAIL PROTECTED], Jayesh Krishna [EMAIL PROTECTED],[EMAIL PROTECTED] Subject: Re: Writing device drivers (was: help me please) Date: Thu, 10 May 2001 12:51:42 -0700 Brian Somers wrote: On Wednesday, 9 May 2001 at 10:40:50 +0530, Jayesh Krishna wrote: Hi guys... I am comfortable with Linux Device Drivers. Presently I am trying to write some pseudo-drivers in FreeBSD(4.2-Release). I tried out make_pseudo_driver.sh in the /usr/share/examples/drivers but it does not work :-( I also went through the FreeBSD Device Driver Writer's Guide by Eric L. Hernes but it seems to be outdated :-( Please someone point me out to some docs regarding writing device drivers in FreeBSD UTSL. Take a look at a similar driver and get to understand it. I'm afraid that this is an area which is woefully undocumented. You'll also get more replies if you put a useful text on the Subject: line. You should probably tell julian@ about the problems you have with make_pseudo_driver.sh. The pseudo one is known to be WAYYY out of date... the other one there (make_device_driver.sh) is more or less up to date. Greg -- Finger [EMAIL PROTECTED] for PGP public key See complete headers for address and phone numbers -- Brian [EMAIL PROTECTED] brian@[uk.]FreeBSD.org http://www.Awfulhak.org brian@[uk.]OpenBSD.org Don't _EVER_ lose your sense of humour ! To Unsubscribe: send mail to [EMAIL PROTECTED] with unsubscribe freebsd-hackers in the body of the message -- __--_|\ Julian Elischer / \ [EMAIL PROTECTED] ( OZ) World tour 2000-2001 --- X_.---._/ v _ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. To Unsubscribe: send mail to [EMAIL PROTECTED] with unsubscribe freebsd-hackers in the body of the message
Re: Writing device drivers (was: help me please)
hi, Thanx Julian for pointing me to the tunnel pseudo-driver. But my major concern was regarding linking the driver to the kernel( i am trying to use static linking stuff). I am presently doing a major grep on tun 8-) It would be great if i could get some docs regding which files have to be modified so that the kernel realises my driver. So far i could figure out that the below files have to be modified( did i leave anything ) /usr/src/sys/i386/conf/* /usr/src/sys/conf/majors /usr/src/sys/conf/files That's about it. Do i really have to modify the /usr/src/sys/modules/* files??? Only if you want a module (and have a MODULE_DECLARE in your source). I would suggest that it's worthwhile spending the time making your code modular - it makes development easier and leads to better practices of ensuring that your detach cleans up all resources etc. jayesh -- Brian [EMAIL PROTECTED]brian@[uk.]FreeBSD.org http://www.Awfulhak.org brian@[uk.]OpenBSD.org Don't _EVER_ lose your sense of humour ! To Unsubscribe: send mail to [EMAIL PROTECTED] with unsubscribe freebsd-hackers in the body of the message
Re: Writing device drivers (was: help me please)
On Wednesday, 9 May 2001 at 10:40:50 +0530, Jayesh Krishna wrote: Hi guys... I am comfortable with Linux Device Drivers. Presently I am trying to write some pseudo-drivers in FreeBSD(4.2-Release). I tried out make_pseudo_driver.sh in the /usr/share/examples/drivers but it does not work :-( I also went through the FreeBSD Device Driver Writer's Guide by Eric L. Hernes but it seems to be outdated :-( Please someone point me out to some docs regarding writing device drivers in FreeBSD UTSL. Take a look at a similar driver and get to understand it. I'm afraid that this is an area which is woefully undocumented. You'll also get more replies if you put a useful text on the Subject: line. You should probably tell julian@ about the problems you have with make_pseudo_driver.sh. Greg -- Finger [EMAIL PROTECTED] for PGP public key See complete headers for address and phone numbers -- Brian [EMAIL PROTECTED]brian@[uk.]FreeBSD.org http://www.Awfulhak.org brian@[uk.]OpenBSD.org Don't _EVER_ lose your sense of humour ! To Unsubscribe: send mail to [EMAIL PROTECTED] with unsubscribe freebsd-hackers in the body of the message
Re: Writing device drivers (was: help me please)
Brian Somers wrote: On Wednesday, 9 May 2001 at 10:40:50 +0530, Jayesh Krishna wrote: Hi guys... I am comfortable with Linux Device Drivers. Presently I am trying to write some pseudo-drivers in FreeBSD(4.2-Release). I tried out make_pseudo_driver.sh in the /usr/share/examples/drivers but it does not work :-( I also went through the "FreeBSD Device Driver Writer's Guide" by Eric L. Hernes but it seems to be outdated :-( Please someone point me out to some docs regarding writing device drivers in FreeBSD "UTSL". Take a look at a similar driver and get to understand it. I'm afraid that this is an area which is woefully undocumented. You'll also get more replies if you put a useful text on the Subject: line. You should probably tell julian@ about the problems you have with make_pseudo_driver.sh. The pseudo one is known to be WAYYY out of date... the other one there (make_device_driver.sh) is more or less up to date. Greg -- Finger [EMAIL PROTECTED] for PGP public key See complete headers for address and phone numbers -- Brian [EMAIL PROTECTED]brian@[uk.]FreeBSD.org http://www.Awfulhak.org brian@[uk.]OpenBSD.org Don't _EVER_ lose your sense of humour ! To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message -- __--_|\ Julian Elischer / \ [EMAIL PROTECTED] ( OZ) World tour 2000-2001 --- X_.---._/ v To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message
Writing device drivers (was: help me please)
On Wednesday, 9 May 2001 at 10:40:50 +0530, Jayesh Krishna wrote: Hi guys... I am comfortable with Linux Device Drivers. Presently I am trying to write some pseudo-drivers in FreeBSD(4.2-Release). I tried out make_pseudo_driver.sh in the /usr/share/examples/drivers but it does not work :-( I also went through the FreeBSD Device Driver Writer's Guide by Eric L. Hernes but it seems to be outdated :-( Please someone point me out to some docs regarding writing device drivers in FreeBSD UTSL. Take a look at a similar driver and get to understand it. I'm afraid that this is an area which is woefully undocumented. You'll also get more replies if you put a useful text on the Subject: line. Greg -- Finger [EMAIL PROTECTED] for PGP public key See complete headers for address and phone numbers To Unsubscribe: send mail to [EMAIL PROTECTED] with unsubscribe freebsd-hackers in the body of the message