Skip site navigation (1)Skip section navigation (2)
Date:      09 Jun 2002 18:57:41 +0100
From:      "S. Roberts" <sroberts@dsl.pipex.com>
To:        freebsd_mail@myrealbox.com
Cc:        FreeBSD-Questions <freebsd-questions@freebsd.org>
Subject:   Re: parallel port problems
Message-ID:  <1023645462.318.59.camel@Demon.Strobe.org>
In-Reply-To: <200206091016180204.00724C83@smtp.myrealbox.com>
References:  <1023634586.318.8.camel@Demon.Strobe.org>  <200206091016180204.00724C83@smtp.myrealbox.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--=-aJrByT6KO9UAY45njgp0
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

Thanks all the same Greg.

I'm due to cvsup to 4.6 as and when it is released, so I'll look into
what more options I could configure into the kernel at that point.

Thanks again for all the help, information and encouragement!

Stacey

On Sun, 2002-06-09 at 18:16, Greg Smith wrote:
> Stacey,
>=20
> I have to admit that I already gave you the extent of my knowledge
> about ppc and lpt.  I have spent a fair amount of time tinkering with
> the kernel config to get devices set up, but lpt just showed up for me.
>  I did once browse through the parallel port device driver code - when
> curious why it used different port addresses as defaults than I thought
> were "normal" from the PC world, or something like that - but have no
> special insights.
>=20
> Why don't you try adding
>=20
> options LPT_DEBUG
> options PPC_DEBUG
>=20
> to your kernel and recompile.  It might shed some light on this.  You
> could even try
>=20
> options PPC_PROBE_CHIPSET
>=20
> if you are curious what this might do.  I don't know.
>=20
>=20
> A favorite of mine is
>=20
> options INCLUDE_CONFIG_FILE
>=20
> which will but a text copy of your config file into your kernel.  Handy
> if you like to keep multiple kernels around, and don't remember exactly
> what the config was.
>=20
>=20
> [Another thing I would add to /boot/loader.conf is:
>=20
> boot_verbose=3D"YES"
>=20
> It's like doing boot -v every time, automatically.
>=20
> Unfortunately I verified by booting up my old firewall (new one just
> hit 300 days uptime, so don't want to mess with that) that lpt0 will
> show up in the dmesg without boot -v, so this is just general advice.]
>=20
> Sorry I have no definitive answer.  Happy hunting.
>=20
> Greg
>=20
> -----Original Message-----
>=20
> >Hi Greg,
> >   I followed the suggestions with respect to placing additions to
> >/boot/kernel.conf in your last e-mail and managed some progress:
> >~ $ dmesg | grep ppc0
> >config> ir ppc0 7
> >config> dr ppc0 3
> >config> po ppc0 0x3bc
> >ppc0     0x3bc      7     3     0       0        0     0          Yes
>=20
> >ppc0: <Parallel port> at port 0x3bc-0x3bf irq 7 drq 3 on isa0
> >ppc0: Generic chipset (ECP/PS2/NIBBLE) in COMPATIBLE mode
> >~ $ dmesg | grep lpt=20
> >~ $ cd /usr/src/sys/i386/conf
> ><snip> /usr/src/sys/i386/conf $ su
> >Password:
> ># grep lpt <kernel>
> >device		lpt		# Printer
> >device		ulpt		# Printer
> >#
> >
> >So I now can see ppc config in dmesg on boot-up.
> >
> >However, nothing is returned for lpt in dmesg as above
> ># grep lpt* dmesg.boot
> >grep: No match.
> >#
> >
> >What's could be the problem now? I do have lpt defined in my kernel:
> ># grep lpt <kernel>
> >device		lpt		# Printer
> >device		ulpt		# Printer
> >#
> >
> >Am I missing / neglecting something here?
> >
> >Thanks again for all your help (and patience), hope to hear from you
> >soon.
> >
> >Stacey
> >
> >From: "Greg Smith" <freebsd_mail@myrealbox.com>
> >Reply-To: freebsd_mail@myrealbox.com
> >To: sroberts84@hotmail.com
> >Subject: Re: parallel port
> >Date: Thu, 06 Jun 2002 08:29:18 -0700
> >Received: from [192.108.102.143] by hotmail.com (3.2) with ESMTP id
> >MHotMailBEC8CB1B005F40042A1AC06C668FB3890; Thu, 06 Jun 2002 08:30:35
> >-0700
> >Received: from gregs freebsd_mail@smtp-send.myrealbox.com
> >[63.195.114.87]by smtp-send.myrealbox.com with NetMail SMTP Agent
> >$Revision:   3.9  $ on Novell NetWare;Thu, 06 Jun 2002 09:29:18 -0600
> >From freebsd_mail@myrealbox.com Thu, 06 Jun 2002 08:31:27 -0700
> >Message-ID: <200206060829180182.0015607A@smtp.myrealbox.com>
> >In-Reply-To: <F46Yb17TWSEVU29AhsF000057ae@hotmail.com>
> >References: <F46Yb17TWSEVU29AhsF000057ae@hotmail.com>
> >X-Mailer: Calypso Version 3.30.00.00 (4)
> >
> >Stacey,
> >
> >Actually, you would use options PNPBIOS (one word) without enabling
> PnP
> >OS in the BIOS.  PnP OS usually does screw up FreeBSD, because FreeBSD
> >is not smart enough to work with a BIOS that sets all the device
> >resources.
> >
> >options PNPBIOS will make the kernel try to find all ISA and PCI
> >devices on your machine.  This option can be very useful for certain
> >devices, e.g. some sound cards, but can also screw up other devices
> >which are not PNPBIOS compatible, e.g. mwave modem port.
> >
> >I recommend not using options PNPBIOS unless you know you need it, or
> >just for fun.  It's a great idea in theory, but can screw up some
> >drivers in practice.
> >
> >If you would like to learn to make a change to a device without
> >recompiling the kernel, here is a method which works for most devices
> >which have unit numbers in the kernel, i.e. sio0 and sio1, but not
> sio.
> >
> >1) update /boot/loader.conf with
> >
> >userconfig_script_load=3D"YES"
> >
> >2) update /boot/kernel.conf with
> >
> >ir ppc0 7
> >dr ppc0 3
> >po ppc0 0x3bc
> >ls
> >q
> >
> >This method assumes your kernel has device ppc0 and not just device
> >ppc.  This is true in GENERIC kernels.
> >
> >[The userconfig solution is generalizable to the various devices (with
> >unit numbers) in the kernel, with at least the following commands:
> >
> >  di sio1            (disable)
> >  en pcic1           (enable)
> >  po pcm0 0x530      (set port)
> >  ir pcic0 9         (set IRQ)
> >  dr pcm0 1          (set DRQ)
> >  iom pcic0 0xd8000  (set iomem)
> >  ios ata2 16        (set iosize)
> >  f pcm0 0x10        (set flags)
> >  ls                 (list all configurable devices)
> >  q                  (last line)
> >
> >This is very handy on those older machines where it takes a long time
> >to rebuild the kernel.  Try boot -c to get the whole picture.]
> >
> >Greg
> >
> >-----Original Message-----
> >
> >>Hi greg,
> >>    Thanks for getting back to me.
> >>
> >>I haven't actually tried this, but I appreciate the info, and will
> try
> >>this
> >>asap!
> >>
> >>I've not got "OPTIONS PNP BIOS" set in the kernel, because I've
> >disabled
> >>Plug 'n Play OS settings in the MoBo bios (this was due to my
> >>understanding
> >>that its best to have this setting when running FreeBSD - am I wrong
> >in
> >>this?).
> >>
> >>But clarify for me, if I wanted to use this kernel option, is it a
> >case of
> >>my performing the follwoing:-
> >>
> >>1] Enable Plug 'n Play OS settings in MoBo bios
> >>2] Include OPTIONS PNP BIOS in the kernel
> >>3] Recompile kernel
> >>
> >>Thanks again for your suggestions. I'll anxiously await your reply
> and
> >
> >>thoughts on what I have asked here!
> >>
> >>Stacey
> >>
> >>
> >>>From: "Greg Smith" <freebsd_mail@myrealbox.com>
> >>>Reply-To: freebsd_mail@myrealbox.com
> >>>To: sroberts84@hotmail.com
> >>>Subject: parallel port
> >>>Date: Wed, 05 Jun 2002 21:31:38 -0700
> >>>Received: from [192.108.102.143] by hotmail.com (3.2) with ESMTP id
> >>>MHotMailBEC83A0800CC4004320EC06C668FB23D0; Wed, 05 Jun 2002 22:11:36
> >-0700
> >>>Received: from gregs freebsd_mail@smtp-send.myrealbox.com
> >>[63.195.114.87]by
> >>>smtp-send.myrealbox.com with NetMail SMTP Agent $Revision:   3.9  $
> >on
> >>>Novell NetWare;Wed, 05 Jun 2002 22:31:37 -0600
> >>>From freebsd_mail@myrealbox.com Wed, 05 Jun 2002 22:12:26 -0700
> >>>Message-ID: <200206052131380107.0308C9DB@smtp.myrealbox.com>
> >>>X-Mailer: Calypso Version 3.30.00.00 (4)
> >>>
> >>>Stacey,
> >>>
> >>>I saw your query on daemon news.  Did you try explicitly setting the
> >>>port and drq, e.g.
> >>>
> >>>device ppc0 at isa? port IO_LPT3 irq 7 drq 3
> >>>
> >>>where IO_LPT3 is a constant for 3bc I believe?  Or you could use
> >0x3bc
> >>>to be sure.
> >>>
> >>>I think you ought to do this since you don't have options PNPBIOS in
> >>>your kernel.
> >>>
> >>>Greg
> >>>
> >>>
> >>
> >>
> >>
> >
> >--=20
> >Stacey Roberts B.Sc. (HONS) Computer Science
> >Network Systems Engineer
>=20
>=20
>=20
--=20
Stacey Roberts B.Sc. (HONS) Computer Science
Network Systems Engineer

--=-aJrByT6KO9UAY45njgp0
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

Thanks all the same Greg.

I'm due to cvsup to 4.6 as and when it is released, so I'll look into
what more options I could configure into the kernel at that point.

Thanks again for all the help, information and encouragement!

Stacey

On Sun, 2002-06-09 at 18:16, Greg Smith wrote:
> Stacey,
>=20
> I have to admit that I already gave you the extent of my knowledge
> about ppc and lpt.  I have spent a fair amount of time tinkering with
> the kernel config to get devices set up, but lpt just showed up for me.
>  I did once browse through the parallel port device driver code - when
> curious why it used different port addresses as defaults than I thought
> were "normal" from the PC world, or something like that - but have no
> special insights.
>=20
> Why don't you try adding
>=20
> options LPT_DEBUG
> options PPC_DEBUG
>=20
> to your kernel and recompile.  It might shed some light on this.  You
> could even try
>=20
> options PPC_PROBE_CHIPSET
>=20
> if you are curious what this might do.  I don't know.
>=20
>=20
> A favorite of mine is
>=20
> options INCLUDE_CONFIG_FILE
>=20
> which will but a text copy of your config file into your kernel.  Handy
> if you like to keep multiple kernels around, and don't remember exactly
> what the config was.
>=20
>=20
> [Another thing I would add to /boot/loader.conf is:
>=20
> boot_verbose=3D"YES"
>=20
> It's like doing boot -v every time, automatically.
>=20
> Unfortunately I verified by booting up my old firewall (new one just
> hit 300 days uptime, so don't want to mess with that) that lpt0 will
> show up in the dmesg without boot -v, so this is just general advice.]
>=20
> Sorry I have no definitive answer.  Happy hunting.
>=20
> Greg
>=20
> -----Original Message-----
>=20
> >Hi Greg,
> >   I followed the suggestions with respect to placing additions to
> >/boot/kernel.conf in your last e-mail and managed some progress:
> >~ $ dmesg | grep ppc0
> >config> ir ppc0 7
> >config> dr ppc0 3
> >config> po ppc0 0x3bc
> >ppc0     0x3bc      7     3     0       0        0     0          Yes
>=20
> >ppc0: <Parallel port> at port 0x3bc-0x3bf irq 7 drq 3 on isa0
> >ppc0: Generic chipset (ECP/PS2/NIBBLE) in COMPATIBLE mode
> >~ $ dmesg | grep lpt=20
> >~ $ cd /usr/src/sys/i386/conf
> ><snip> /usr/src/sys/i386/conf $ su
> >Password:
> ># grep lpt <kernel>
> >device		lpt		# Printer
> >device		ulpt		# Printer
> >#
> >
> >So I now can see ppc config in dmesg on boot-up.
> >
> >However, nothing is returned for lpt in dmesg as above
> ># grep lpt* dmesg.boot
> >grep: No match.
> >#
> >
> >What's could be the problem now? I do have lpt defined in my kernel:
> ># grep lpt <kernel>
> >device		lpt		# Printer
> >device		ulpt		# Printer
> >#
> >
> >Am I missing / neglecting something here?
> >
> >Thanks again for all your help (and patience), hope to hear from you
> >soon.
> >
> >Stacey
> >
> >From: "Greg Smith" <freebsd_mail@myrealbox.com>
> >Reply-To: freebsd_mail@myrealbox.com
> >To: sroberts84@hotmail.com
> >Subject: Re: parallel port
> >Date: Thu, 06 Jun 2002 08:29:18 -0700
> >Received: from [192.108.102.143] by hotmail.com (3.2) with ESMTP id
> >MHotMailBEC8CB1B005F40042A1AC06C668FB3890; Thu, 06 Jun 2002 08:30:35
> >-0700
> >Received: from gregs freebsd_mail@smtp-send.myrealbox.com
> >[63.195.114.87]by smtp-send.myrealbox.com with NetMail SMTP Agent
> >$Revision:   3.9  $ on Novell NetWare;Thu, 06 Jun 2002 09:29:18 -0600
> >From freebsd_mail@myrealbox.com Thu, 06 Jun 2002 08:31:27 -0700
> >Message-ID: <200206060829180182.0015607A@smtp.myrealbox.com>
> >In-Reply-To: <F46Yb17TWSEVU29AhsF000057ae@hotmail.com>
> >References: <F46Yb17TWSEVU29AhsF000057ae@hotmail.com>
> >X-Mailer: Calypso Version 3.30.00.00 (4)
> >
> >Stacey,
> >
> >Actually, you would use options PNPBIOS (one word) without enabling
> PnP
> >OS in the BIOS.  PnP OS usually does screw up FreeBSD, because FreeBSD
> >is not smart enough to work with a BIOS that sets all the device
> >resources.
> >
> >options PNPBIOS will make the kernel try to find all ISA and PCI
> >devices on your machine.  This option can be very useful for certain
> >devices, e.g. some sound cards, but can also screw up other devices
> >which are not PNPBIOS compatible, e.g. mwave modem port.
> >
> >I recommend not using options PNPBIOS unless you know you need it, or
> >just for fun.  It's a great idea in theory, but can screw up some
> >drivers in practice.
> >
> >If you would like to learn to make a change to a device without
> >recompiling the kernel, here is a method which works for most devices
> >which have unit numbers in the kernel, i.e. sio0 and sio1, but not
> sio.
> >
> >1) update /boot/loader.conf with
> >
> >userconfig_script_load=3D"YES"
> >
> >2) update /boot/kernel.conf with
> >
> >ir ppc0 7
> >dr ppc0 3
> >po ppc0 0x3bc
> >ls
> >q
> >
> >This method assumes your kernel has device ppc0 and not just device
> >ppc.  This is true in GENERIC kernels.
> >
> >[The userconfig solution is generalizable to the various devices (with
> >unit numbers) in the kernel, with at least the following commands:
> >
> >  di sio1            (disable)
> >  en pcic1           (enable)
> >  po pcm0 0x530      (set port)
> >  ir pcic0 9         (set IRQ)
> >  dr pcm0 1          (set DRQ)
> >  iom pcic0 0xd8000  (set iomem)
> >  ios ata2 16        (set iosize)
> >  f pcm0 0x10        (set flags)
> >  ls                 (list all configurable devices)
> >  q                  (last line)
> >
> >This is very handy on those older machines where it takes a long time
> >to rebuild the kernel.  Try boot -c to get the whole picture.]
> >
> >Greg
> >
> >-----Original Message-----
> >
> >>Hi greg,
> >>    Thanks for getting back to me.
> >>
> >>I haven't actually tried this, but I appreciate the info, and will
> try
> >>this
> >>asap!
> >>
> >>I've not got "OPTIONS PNP BIOS" set in the kernel, because I've
> >disabled
> >>Plug 'n Play OS settings in the MoBo bios (this was due to my
> >>understanding
> >>that its best to have this setting when running FreeBSD - am I wrong
> >in
> >>this?).
> >>
> >>But clarify for me, if I wanted to use this kernel option, is it a
> >case of
> >>my performing the follwoing:-
> >>
> >>1] Enable Plug 'n Play OS settings in MoBo bios
> >>2] Include OPTIONS PNP BIOS in the kernel
> >>3] Recompile kernel
> >>
> >>Thanks again for your suggestions. I'll anxiously await your reply
> and
> >
> >>thoughts on what I have asked here!
> >>
> >>Stacey
> >>
> >>
> >>>From: "Greg Smith" <freebsd_mail@myrealbox.com>
> >>>Reply-To: freebsd_mail@myrealbox.com
> >>>To: sroberts84@hotmail.com
> >>>Subject: parallel port
> >>>Date: Wed, 05 Jun 2002 21:31:38 -0700
> >>>Received: from [192.108.102.143] by hotmail.com (3.2) with ESMTP id
> >>>MHotMailBEC83A0800CC4004320EC06C668FB23D0; Wed, 05 Jun 2002 22:11:36
> >-0700
> >>>Received: from gregs freebsd_mail@smtp-send.myrealbox.com
> >>[63.195.114.87]by
> >>>smtp-send.myrealbox.com with NetMail SMTP Agent $Revision:   3.9  $
> >on
> >>>Novell NetWare;Wed, 05 Jun 2002 22:31:37 -0600
> >>>From freebsd_mail@myrealbox.com Wed, 05 Jun 2002 22:12:26 -0700
> >>>Message-ID: <200206052131380107.0308C9DB@smtp.myrealbox.com>
> >>>X-Mailer: Calypso Version 3.30.00.00 (4)
> >>>
> >>>Stacey,
> >>>
> >>>I saw your query on daemon news.  Did you try explicitly setting the
> >>>port and drq, e.g.
> >>>
> >>>device ppc0 at isa? port IO_LPT3 irq 7 drq 3
> >>>
> >>>where IO_LPT3 is a constant for 3bc I believe?  Or you could use
> >0x3bc
> >>>to be sure.
> >>>
> >>>I think you ought to do this since you don't have options PNPBIOS in
> >>>your kernel.
> >>>
> >>>Greg
> >>>
> >>>
> >>
> >>
> >>
> >
> >--=20
> >Stacey Roberts B.Sc. (HONS) Computer Science
> >Network Systems Engineer
>=20
>=20
>=20
- --=20
Stacey Roberts B.Sc. (HONS) Computer Science
Network Systems Engineer

-----BEGIN PGP SIGNATURE-----
Version: PGP 6.5.8

iQA/AwUBPQOXFfdn4A8qiCO5EQIEjACcDwvq3iCxQjiKz1mqOd1OjaoNsC0AoOO/
KZZh2ELifXjlwt/K96r6GBRW
=lpTU
-----END PGP SIGNATURE-----

--=-aJrByT6KO9UAY45njgp0--


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1023645462.318.59.camel>