svn commit: r248039 - stable/8/sys/dev/puc

Marius Strobl marius at FreeBSD.org
Fri Mar 8 11:41:53 UTC 2013


Author: marius
Date: Fri Mar  8 11:41:52 2013
New Revision: 248039
URL: http://svnweb.freebsd.org/changeset/base/248039

Log:
  MFC: r247571
  
  - Apparently, r186520 was just wrong and the clock of Oxford OX16PCI958 is
    neither DEFAULT_RCLK * 2 nor DEFAULT_RCLK * 10 but plain DEFAULT_RCLK
    and there's no (open) source indicating otherwise. This was tested with
    an EXSYS EX-41098-2, whose clock is not configurable and identifies as:
    puc0 at pci0:5:1:0:        class=0x070200 card=0x06711415 chip=0x95381415 rev=0x01 hdr=0x00
        vendor     = 'Oxford Semiconductor Ltd'
        class      = simple comms
        subclass   = multiport serial
  
    Note that this exactly matches the card mentioned in PR 129665 so no
    sub-device/sub-vendor based quirking of the latter is possible. So maybe
    we should grow some sort of tunable, in case non-default cards such as
    the latter aren't configurable either (this also wouldn't be the first
    time an allegedly tested commit turns out to be wrong though).
  - Make the TiMedia tables const.

Modified:
  stable/8/sys/dev/puc/pucdata.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/dev/   (props changed)
  stable/8/sys/dev/puc/   (props changed)

Modified: stable/8/sys/dev/puc/pucdata.c
==============================================================================
--- stable/8/sys/dev/puc/pucdata.c	Fri Mar  8 11:41:48 2013	(r248038)
+++ stable/8/sys/dev/puc/pucdata.c	Fri Mar  8 11:41:52 2013	(r248039)
@@ -769,7 +769,7 @@ const struct puc_cfg puc_pci_devices[] =
 
 	{   0x1415, 0x9538, 0xffff, 0,
 	    "Oxford Semiconductor OX16PCI958 UARTs",
-	    DEFAULT_RCLK * 10,
+	    DEFAULT_RCLK,
 	    PUC_PORT_8S, 0x18, 0, 8,
 	},
 
@@ -893,6 +893,7 @@ const struct puc_cfg puc_pci_devices[] =
 	    DEFAULT_RCLK * 8,
 	    PUC_PORT_4S, 0x10, 0, 8,
 	},
+
 	{   0x14d2, 0xa004, 0xffff, 0,
 	    "Titan PCI-800H",
 	    DEFAULT_RCLK * 8,
@@ -1029,7 +1030,7 @@ const struct puc_cfg puc_pci_devices[] =
 	{   0x9710, 0x9865, 0xa000, 0x3004,
 	    "NetMos NM9865 Quad UART",
 	    DEFAULT_RCLK,
-	    PUC_PORT_4S, 0x10, 4, 0,0
+	    PUC_PORT_4S, 0x10, 4, 0,
 	},
 
 	{   0x9710, 0x9865, 0xa000, 0x3011,
@@ -1389,26 +1390,26 @@ static int
 puc_config_timedia(struct puc_softc *sc, enum puc_cfg_cmd cmd, int port,
     intptr_t *res)
 {
-	static uint16_t dual[] = {
+	static const uint16_t dual[] = {
 	    0x0002, 0x4036, 0x4037, 0x4038, 0x4078, 0x4079, 0x4085,
 	    0x4088, 0x4089, 0x5037, 0x5078, 0x5079, 0x5085, 0x6079, 
 	    0x7079, 0x8079, 0x8137, 0x8138, 0x8237, 0x8238, 0x9079, 
 	    0x9137, 0x9138, 0x9237, 0x9238, 0xA079, 0xB079, 0xC079,
 	    0xD079, 0
 	};
-	static uint16_t quad[] = {
+	static const uint16_t quad[] = {
 	    0x4055, 0x4056, 0x4095, 0x4096, 0x5056, 0x8156, 0x8157, 
 	    0x8256, 0x8257, 0x9056, 0x9156, 0x9157, 0x9158, 0x9159, 
 	    0x9256, 0x9257, 0xA056, 0xA157, 0xA158, 0xA159, 0xB056,
 	    0xB157, 0
 	};
-	static uint16_t octa[] = {
+	static const uint16_t octa[] = {
 	    0x4065, 0x4066, 0x5065, 0x5066, 0x8166, 0x9066, 0x9166, 
 	    0x9167, 0x9168, 0xA066, 0xA167, 0xA168, 0
 	};
-	static struct {
+	static const struct {
 		int ports;
-		uint16_t *ids;
+		const uint16_t *ids;
 	} subdevs[] = {
 	    { 2, dual },
 	    { 4, quad },


More information about the svn-src-all mailing list