From owner-p4-projects@FreeBSD.ORG Thu Apr 27 17:31:54 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 2A12416A409; Thu, 27 Apr 2006 17:31:54 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E0F2416A40D for ; Thu, 27 Apr 2006 17:31:53 +0000 (UTC) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6808643D49 for ; Thu, 27 Apr 2006 17:31:53 +0000 (GMT) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id k3RHVr5m071986 for ; Thu, 27 Apr 2006 17:31:53 GMT (envelope-from marcel@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id k3RHVrWc071978 for perforce@freebsd.org; Thu, 27 Apr 2006 17:31:53 GMT (envelope-from marcel@freebsd.org) Date: Thu, 27 Apr 2006 17:31:53 GMT Message-Id: <200604271731.k3RHVrWc071978@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to marcel@freebsd.org using -f From: Marcel Moolenaar To: Perforce Change Reviews Cc: Subject: PERFORCE change 96222 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Apr 2006 17:31:54 -0000 http://perforce.freebsd.org/chv.cgi?CH=96222 Change 96222 by marcel@marcel_nfs on 2006/04/27 17:30:52 Sync with NetBSD: Add Siig PS8000 8S Affected files ... .. //depot/projects/uart/dev/puc/pucdata.c#40 edit Differences ... ==== //depot/projects/uart/dev/puc/pucdata.c#40 (text+ko) ==== @@ -405,6 +405,13 @@ PUC_PORT_2S1P, 0x10, 4, 0, }, + { 0x131f, 0x2081, 0xffff, 0, + "SIIG PS8000 8S PCI 16C650 (20x family)", + DEFAULT_RCLK, + PUC_PORT_8S, 0x10, -1, -1, + .config_function = puc_config_siig + }, + { 0x135c, 0x0010, 0xffff, 0, "Quatech QSC-100", -3, /* max 8x clock rate */ @@ -962,12 +969,30 @@ puc_config_siig(struct puc_softc *sc, enum puc_cfg_cmd cmd, int port, intptr_t *res) { - if (cmd == PUC_CFG_GET_RID) { - switch (port) { - case 0: *res = 0x10; return (0); - case 1: *res = 0x14; return (0); - case 2: *res = 0x1c; return (0); + const struct puc_cfg *cfg = sc->sc_cfg; + + switch (cmd) { + case PUC_CFG_GET_OFS: + if (cfg->ports == PUC_PORT_8S) { + *res = (port > 4) ? 8 * (port - 4) : 0; + return (0); + } + break; + case PUC_CFG_GET_RID: + if (cfg->ports == PUC_PORT_8S) { + *res = 0x10 + ((port > 4) ? 0x10 : 4 * port); + return (0); + } + if (cfg->ports = PUC_PORT_2S1P) { + switch (port) { + case 0: *res = 0x10; return (0); + case 1: *res = 0x14; return (0); + case 2: *res = 0x1c; return (0); + } } + break; + default: + break; } return (ENXIO); }