From owner-p4-projects@FreeBSD.ORG Sat Oct 30 03:40:33 2004 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id A0D0516A4D0; Sat, 30 Oct 2004 03:40:33 +0000 (GMT) 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 7C80216A4CE for ; Sat, 30 Oct 2004 03:40:33 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 507CE43D3F for ; Sat, 30 Oct 2004 03:40:33 +0000 (GMT) (envelope-from marcel@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.11/8.12.11) with ESMTP id i9U3eXk2018154 for ; Sat, 30 Oct 2004 03:40:33 GMT (envelope-from marcel@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.12.11/8.12.11/Submit) id i9U3eWLf018151 for perforce@freebsd.org; Sat, 30 Oct 2004 03:40:32 GMT (envelope-from marcel@freebsd.org) Date: Sat, 30 Oct 2004 03:40:32 GMT Message-Id: <200410300340.i9U3eWLf018151@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 Subject: PERFORCE change 63962 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Oct 2004 03:40:34 -0000 http://perforce.freebsd.org/chv.cgi?CH=63962 Change 63962 by marcel@marcel_nfs on 2004/10/30 03:39:58 Hook scc(4) up and make it compile (except for scc_core.c, which needs hasn't been written yet). Compile-tested on sparc64 only. Affected files ... .. //depot/projects/uart/conf/files#29 edit .. //depot/projects/uart/dev/scc/scc_bfe.h#2 edit .. //depot/projects/uart/dev/uart/uart_bus_scc.c#2 edit Differences ... ==== //depot/projects/uart/conf/files#29 (text+ko) ==== @@ -661,6 +661,9 @@ dev/sab/sab.c optional sab ebus dev/safe/safe.c optional safe dev/sbsh/if_sbsh.c optional sbsh +dev/scc/scc_bfe_ebus.c optional scc ebus +dev/scc/scc_bfe_sbus.c optional scc sbus +dev/scc/scc_core.c optional scc dev/scd/scd.c optional scd isa dev/scd/scd_isa.c optional scd isa dev/si/si.c optional si @@ -776,6 +779,7 @@ dev/uart/uart_bus_pci.c optional uart cardbus dev/uart/uart_bus_pci.c optional uart pci dev/uart/uart_bus_puc.c optional uart puc +dev/uart/uart_bus_scc.c optional uart scc dev/uart/uart_core.c optional uart dev/uart/uart_dbg.c optional uart gdb dev/uart/uart_dev_i8251.c optional uart ==== //depot/projects/uart/dev/scc/scc_bfe.h#2 (text+ko) ==== @@ -1,4 +1,4 @@ -/*- +/* * Copyright (c) 2004 Marcel Moolenaar * All rights reserved. * @@ -76,4 +76,13 @@ int scc_bfe_attach(device_t dev); int scc_bfe_detach(device_t dev); +struct resource *scc_bus_alloc_resource(device_t, device_t, int, int *, + u_long, u_long, u_long, u_int); +int scc_bus_get_resource(device_t, device_t, int, int, u_long *, u_long *); +int scc_bus_read_ivar(device_t, device_t, int, uintptr_t *); +int scc_bus_release_resource(device_t, device_t, int, int, struct resource *); +int scc_bus_setup_intr(device_t, device_t, struct resource *, int, + void (*)(void *), void *, void **); +int scc_bus_teardown_intr(device_t, device_t, struct resource *, void *); + #endif /* _DEV_SCC_BFE_H_ */ ==== //depot/projects/uart/dev/uart/uart_bus_scc.c#2 (text+ko) ==== @@ -1,9 +1,11 @@ -/*- +/* * Copyright (c) 2004 Marcel Moolenaar + * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: + * * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright @@ -38,6 +40,9 @@ #include +#include +#include + static int uart_scc_probe(device_t dev); static device_method_t uart_scc_methods[] = { @@ -69,7 +74,7 @@ switch (cl) { case SCC_CLASS_SAB82532: sc->sc_class = &uart_sab82532_class; - break + break; case SCC_CLASS_Z8530: sc->sc_class = &uart_z8530_class; break;