From owner-freebsd-stable@FreeBSD.ORG Sat Dec 28 14:11:19 2013 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 9299371F for ; Sat, 28 Dec 2013 14:11:19 +0000 (UTC) Received: from mail-wg0-x229.google.com (mail-wg0-x229.google.com [IPv6:2a00:1450:400c:c00::229]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 2A7B21FF5 for ; Sat, 28 Dec 2013 14:11:19 +0000 (UTC) Received: by mail-wg0-f41.google.com with SMTP id y10so12922978wgg.2 for ; Sat, 28 Dec 2013 06:11:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=Hu4Zc64p8H/Jd5tcU/qChrvJES1Z1jpmX1Adrg/ofFE=; b=U66bw5MAxfTBLVvMKSN4f+hx2xXVY5kocV2yqk0t4YPJn42PWvyBJiYSD843AtzSwK x3fSnwPPBVJOq7L68gBu4wgNjMPSOkTCaI2Z2wXb+VY3ab2peeh3hurWDZ+BDuDo4cXs TxdvfYh83OCld0eF/N3dJqkqJNKZ8chngolKAmj5aW0nTIaQkp2BSS3cB8QTbp8IRpai 2Kq1QJ6fyhxMqKuheuJ0RpWVpTHPq5xDlGxmcNoxya9VlqoQ7jX/ZtMTfZMWF7UVBgC8 2Wlqw2Jy/dZGEfwUINNk9uodAFj6NXGgCxxEL0xD4bYZoJz5zZychhS3rED3nhUczVej g6iA== MIME-Version: 1.0 X-Received: by 10.180.97.164 with SMTP id eb4mr4289153wib.11.1388239877480; Sat, 28 Dec 2013 06:11:17 -0800 (PST) Sender: conall@gmail.com Received: by 10.194.46.10 with HTTP; Sat, 28 Dec 2013 06:11:17 -0800 (PST) In-Reply-To: <20131227201342.08842077@zeta.dino.sk> References: <20131227181326.GA88638@in-addr.com> <20131227201342.08842077@zeta.dino.sk> Date: Sat, 28 Dec 2013 14:11:17 +0000 X-Google-Sender-Auth: 2RCsb8yKhBZH5svtisStkzpBHHM Message-ID: Subject: Re: serial card on RC2 , RC3 From: "Conall O'Brien" To: Milan Obuch Content-Type: text/plain; charset=UTF-8 Cc: Darrel , freebsd-stable@freebsd.org X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 28 Dec 2013 14:11:19 -0000 On 27 December 2013 19:13, Milan Obuch wrote: > On Fri, 27 Dec 2013 13:41:50 -0500 (EST) > Darrel wrote: > >> >> >> Anyone know how to get serial cable working with StarTech "2 Port >> >> Native Express RS232 Serial Adapter Card with 16550 UART"? It is >> >> part number PEX2S553. I've been trying to get the low profile version (part PEX2S553LP) of this card to work in my system on and off for a while now. Having added the following diff (which I keep meaning to submit in a PR), I have the uart driver recognising the card. --- sys/dev/uart/uart_bus_pci.c (revision 259948) +++ sys/dev/uart/uart_bus_pci.c (working copy) @@ -130,6 +130,8 @@ "MosChip MCS9901 PCIe to Peripheral Controller", 0x10 }, { 0x9710, 0x9904, 0xa000, 0x1000, "MosChip MCS9904 PCIe to Peripheral Controller", 0x10 }, +{ 0x9710, 0x9922, 0xa000, 0x1000, + "MosChip MCS9900 PCIe to Peripheral Controller", 0x10 }, { 0xdeaf, 0x9051, 0xffff, 0, "Middle Digital PC Weasel Serial Port", 0x10 }, { 0xffff, 0, 0xffff, 0, NULL, 0, 0} }; grep uart /var/run/dmesg.boot: uart2: port 0xd010-0xd017 mem 0xfe203000-0xfe203fff,0xfe202000-0xfe202fff irq 18 at device 0.0 on pci4 uart3: port 0xd000-0xd007 mem 0xfe201000-0xfe201fff,0xfe200000-0xfe200fff irq 19 at device 0.1 on pci4 and with pciconf -lv uart2@pci0:4:0:0: class=0x070002 card=0x1000a000 chip=0x99229710 rev=0x00 hdr=0x00 vendor = 'NetMos Technology' device = 'PCIe 9922 Multi-I/O Controller' class = simple comms subclass = UART uart3@pci0:4:0:1: class=0x070002 card=0x1000a000 chip=0x99229710 rev=0x00 hdr=0x00 vendor = 'NetMos Technology' device = 'PCIe 9922 Multi-I/O Controller' class = simple comms subclass = UART However, I can't get a working tty on either serial port. When I connect over the serial port, I have a blank tty, which clearly states "Not a controlling terminal" when sent SIGINFO. >> >> In my kernel I tried this: >> >> >> >> device puc >> >> device sio >> >> options COM_MULTIPORT >> >> >> >> in different variations. >> >> >> >> Also I tried in /boot/device.hints: >> >> >> >> hint.sio.2.flags="0x201" >> >> hint.sio.3.flags="0x201" >> >> >> >> It is obviously a cheap card, but I do have one working in a msft >> >> 7 machine. >> >> >> > >> > Please post some more information about your system. pciconf -lv >> > and dmesg would both help developers see why the card isn't >> > detected. If your system has been up for a while you may be better >> > off sending /var/run/dmesg.boot than the output of the dmesg >> > program. >> > >> > > Hi, > > could you apply following patch to /usr/src/sys/dev/puc/pucdata.c and > rebuild your kernel and/or modules? This is the first thing I would > test, and it could even work, but no guarantee yet, naturally :) > --- pucdata.c 2013-10-23 22:51:08.000000000 +0200 > +++ pucdata.c.mod 2013-12-27 20:09:36.000000000 +0100 > @@ -1094,6 +1094,12 @@ > PUC_PORT_2P, 0x10, 4, 0, > }, > > + { 0x9710, 0x9922, 0xffff, 0, > + "NetMos NM9922 Dual UART", > + DEFAULT_RCLK, > + PUC_PORT_2S, 0x10, 4, 0, > + }, > + > { 0xb00c, 0x021c, 0xffff, 0, > "IC Book Labs Gunboat x4 Lite", > DEFAULT_RCLK, I'm currently trying to enable sio, but run into kernel compile time problems already reported in http://www.freebsd.org/cgi/query-pr.cgi?pr=166626 . Perhaps I need to give up on sio and try using the puc driver with your patch > [ dmesg and pciconf output snipped ] > > Regards, > Milan > _______________________________________________ > freebsd-stable@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-stable > To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org" -- Conall O'Brien