Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 16 Aug 2011 13:37:34 -0700
From:      Xin LI <delphij@delphij.net>
To:        Yuri <yuri@rawbw.com>
Cc:        d@delphij.net, freebsd-stable@freebsd.org, John Baldwin <jhb@freebsd.org>
Subject:   Re: How to use unrecognized COM port card?
Message-ID:  <4E4AD50E.6050906@delphij.net>
In-Reply-To: <4E4ACAAD.3030506@rawbw.com>
References:  <4E4A0C81.7020501@rawbw.com> <4E4A20BE.3060603@delphij.net> <4E4A3788.3030605@rawbw.com> <201108161157.20890.jhb@freebsd.org> <4E4ACAAD.3030506@rawbw.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format.
--------------060306060307040906060005
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 08/16/11 12:53, Yuri wrote:
> On 08/16/2011 08:57, John Baldwin wrote:
>> For multiport devices you will want to add an entry to 
>> sys/dev/puc/pucdata.c and use the puc driver instead of patching
>> uart directly.  Perhaps this:
> 
> John,
> 
> I did what you suggested: puc0: <WinChipHead Dual Port RS-232> port
> 0xe880-0xe887,0xe800-0xe807 irq 17 at device 1.0 on pci8
> 
> But it doesn't show up as a serial device and tty.

I found a datasheet:

	http://wch-ic.com/download/down.asp?id=116 (English)

	and

	http://winchiphead.com/download/CH352/CH352DS1.PDF (Chinese)

And I think John's patch is right, I've added a new PCI ID for it
though, found from the datasheet.  Did you have uart(4) in your kernel
(remove my old patch)?

Cheers,
- -- 
Xin LI <delphij@delphij.net>	https://www.delphij.net/
FreeBSD - The Power to Serve!		Live free or die
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.18 (FreeBSD)

iQEcBAEBCAAGBQJOStUOAAoJEATO+BI/yjfBSw0IANPaoND+0Xa2QtueAxI8Qa42
V86MiUnaZopRb0coiWf8dQNk+nIlayVuFstC9+77zC9NEEu1O7Mp8T4n2Bx2N7WP
jtsevUnLJq6lIyo0jYRTf4x84eYd1VDBduHqsWbI0B7aMArgfNtHvPV0qUD9Emrn
4yR6I3/tmO3sX3+cWcggYC4s3DIm7XidiyT/6lcWilsmy2QkQlw00HoAkoKl0V4m
DBkKHkmOB2oTUYadpBOKCt6HvdI29xWYF+1zN/sE0B3XwTy+Q1pp4Uq5KiBUyJi3
tNF533Z7COh/mog/Z9cpGpLSRJpWQgI2uCY7gAHZRAMT2+7k1AqkdNPWTJPXoCk=
=CcI6
-----END PGP SIGNATURE-----

--------------060306060307040906060005
Content-Type: text/plain;
 name="puc.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
 filename="puc.diff"

Index: sys/dev/puc/pucdata.c
===================================================================
--- sys/dev/puc/pucdata.c	(revision 224912)
+++ sys/dev/puc/pucdata.c	(working copy)
@@ -862,6 +862,20 @@ const struct puc_cfg puc_pci_devices[] = {
 	    .config_function = puc_config_syba
 	},
 
+	{
+	    0x4348, 0x3253, 0x4348, 0x3253,
+	    "WinChipHead Dual Port RS-232",
+	    DEFAULT_RCLK,
+	    PUC_PORT_2S, 0x10, 4, 0,
+	},
+
+	{
+	    0x4348, 0x5053, 0x4348, 0x5053,
+	    "WinChipHead RS-232 and Printer port",
+	    DEFAULT_RCLK,
+	    PUC_PORT_1S1P, 0x10, 4, 0,
+	},
+
 	{   0x6666, 0x0001, 0xffff, 0,
 	    "Decision Computer Inc, PCCOM 4-port serial",
 	    DEFAULT_RCLK,

--------------060306060307040906060005--



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