Bug 199013 - Add ID for StarTech.com PCIe RS232 Serial Adapter Card
Summary: Add ID for StarTech.com PCIe RS232 Serial Adapter Card
Status: Closed Overcome By Events
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: 10.1-RELEASE
Hardware: amd64 Any
: --- Affects Some People
Assignee: Eitan Adler
URL:
Keywords: easy, patch
Depends on:
Blocks:
 
Reported: 2015-03-30 01:23 UTC by mlsemon35
Modified: 2015-03-30 13:56 UTC (History)
0 users

See Also:


Attachments
Add ID for Moschip chipset on StarTech.com serial adaper card PEX2S553 (527 bytes, patch)
2015-03-30 01:23 UTC, mlsemon35
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description mlsemon35 2015-03-30 01:23:52 UTC
Created attachment 154983 [details]
Add ID for Moschip chipset on StarTech.com serial adaper card PEX2S553

Hi!  I bought a StarTech.com PCIe 2-port serial adapter card, Part # PEX2S553.  I couldn't get it to work with the scc(4) driver.  Thinking it was a matter of not knowing what serial driver to use--scc? puc? uart?--I grepped around the latest svn pull of 10.1-RELEASE until I found sys/dev/uart/uart_bus_pci.c.  I adapted one of the MosChip entries and provide it as a patch.  This card indeed uses the scc(4) driver.

Serial sessions work fine, and the PPS is supported by this card.  I can have one port at 4800 baud and the other port at 115200 baud.  Looks good and my Garmin GPS18-LVC performs over it continuously, performing much like it did on x86 with standard motherboard serial ports.  IOW, it works for every way I would normally use the serial port, no traps or other issues noted by the kernel.  I did have issue trying to interrupt a process of doing a `cat /dev/ttyu3` while piping /dev/urandom from the other end of the serial cable, but that's been the only trouble spot (solved by clean reboot).

The instructions claim that this card is a Moschip MCS9922CV-AA chipset.

No other alterations have been required, and I wouldn't know how to make such modifications.

dmesg shows this on boot:

uart2: <MosChip MCS9922 PCIe to Peripheral Controller> port 0xdcf0-0xdcf7 mem 0xdfdfc000-0xdfdfcfff,0xdfdfd000-0xdfdfdfff irq 17 at device 0.0 on pci2
uart3: <MosChip MCS9922 PCIe to Peripheral Controller> port 0xdcf8-0xdcff mem 0xdfdfe000-0xdfdfefff,0xdfdff000-0xdfdfffff irq 18 at device 0.1 on pci2

Thanks!

Michael
Comment 1 commit-hook freebsd_committer freebsd_triage 2015-03-30 08:49:29 UTC
A commit references this bug:

Author: eadler
Date: Mon Mar 30 08:48:36 UTC 2015
New revision: 280843
URL: https://svnweb.freebsd.org/changeset/base/280843

Log:
  Add support for "MosChip MCS9922 PCIe to Peripheral Controller" to uart

  Submitted by:	<mlsemon35@gmail.com>
  PR:		199013
  MFC After:	1 month

Changes:
  head/sys/dev/uart/uart_bus_pci.c
Comment 2 commit-hook freebsd_committer freebsd_triage 2015-03-30 08:55:31 UTC
A commit references this bug:

Author: eadler
Date: Mon Mar 30 08:55:00 UTC 2015
New revision: 280844
URL: https://svnweb.freebsd.org/changeset/base/280844

Log:
  And it turns out someone beat me to it....

  PR:		199013

Changes:
  head/sys/dev/uart/uart_bus_pci.c
Comment 3 Eitan Adler freebsd_committer freebsd_triage 2015-03-30 08:56:17 UTC
It turns out this was fixed previously by another committer
Comment 4 mlsemon35 2015-03-30 13:56:46 UTC
OK, thanks!  As long as a patch from somebody gets in there, that's good news!  Though a patch currently appears to be in there twice, according to the svnweb link given in this thread (https://svnweb.freebsd.org/changeset/base/280843)...