[Midnightbsd-cvs] src: dev/cy: merge
laffer1 at midnightbsd.org
laffer1 at midnightbsd.org
Sun Nov 30 11:15:45 EST 2008
Log Message:
-----------
merge
Modified Files:
--------------
src/sys/dev/cy:
cy.c (r1.2 -> r1.3)
cy_isa.c (r1.1.1.1 -> r1.2)
cy_pci.c (r1.1.1.1 -> r1.2)
cyvar.h (r1.1.1.1 -> r1.2)
-------------- next part --------------
Index: cy_pci.c
===================================================================
RCS file: /home/cvs/src/sys/dev/cy/cy_pci.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -L sys/dev/cy/cy_pci.c -L sys/dev/cy/cy_pci.c -u -r1.1.1.1 -r1.2
--- sys/dev/cy/cy_pci.c
+++ sys/dev/cy/cy_pci.c
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/cy/cy_pci.c,v 1.37 2005/03/05 18:30:10 imp Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/cy/cy_pci.c,v 1.38 2007/02/23 12:18:37 piso Exp $");
#include "opt_cy_pci_fastintr.h"
@@ -145,14 +145,14 @@
goto fail;
}
#ifdef CY_PCI_FASTINTR
- irq_setup = bus_setup_intr(dev, irq_res, INTR_TYPE_TTY | INTR_FAST,
- cyintr, vsc, &irq_cookie);
+ irq_setup = bus_setup_intr(dev, irq_res, INTR_TYPE_TTY,
+ cyintr, NULL, vsc, &irq_cookie);
#else
irq_setup = ENXIO;
#endif
if (irq_setup != 0)
irq_setup = bus_setup_intr(dev, irq_res, INTR_TYPE_TTY,
- cyintr, vsc, &irq_cookie);
+ NULL, (driver_intr_t *)cyintr, vsc, &irq_cookie);
if (irq_setup != 0) {
device_printf(dev, "interrupt setup failed\n");
goto fail;
Index: cy.c
===================================================================
RCS file: /home/cvs/src/sys/dev/cy/cy.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -L sys/dev/cy/cy.c -L sys/dev/cy/cy.c -u -r1.2 -r1.3
--- sys/dev/cy/cy.c
+++ sys/dev/cy/cy.c
@@ -29,7 +29,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/cy/cy.c,v 1.160.2.1 2006/03/10 19:37:31 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/cy/cy.c,v 1.163 2007/02/23 12:18:36 piso Exp $");
#include "opt_compat.h"
@@ -433,7 +433,7 @@
swi_add(&clk_intr_event, "cy", cypoll, NULL, SWI_CLOCK, 0,
&cy_slow_ih);
}
- ttycreate(tp, NULL, 0, MINOR_CALLOUT, "c%r%r",
+ ttycreate(tp, TS_CALLOUT, "c%r%r",
adapter, unit % CY_MAX_PORTS);
}
}
@@ -644,7 +644,7 @@
com->mcr_image |= com->mcr_rts);
}
-void
+int
cyintr(void *vcom)
{
struct com_s *basecom;
@@ -671,7 +671,7 @@
/* poll to see if it has any work */
status = cd_inb(iobase, CD1400_SVRR, cy_align);
if (status == 0)
- continue;
+ continue; // XXX - FILTER_STRAY?
#ifdef CyDebug
++cy_svrr_probes;
#endif
@@ -1111,6 +1111,7 @@
swi_sched(cy_slow_ih, SWI_DELAY);
COM_UNLOCK();
+ return (FILTER_HANDLED);
}
static void
Index: cyvar.h
===================================================================
RCS file: /home/cvs/src/sys/dev/cy/cyvar.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -L sys/dev/cy/cyvar.h -L sys/dev/cy/cyvar.h -u -r1.1.1.1 -r1.2
--- sys/dev/cy/cyvar.h
+++ sys/dev/cy/cyvar.h
@@ -23,7 +23,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $FreeBSD: src/sys/dev/cy/cyvar.h,v 1.1 2004/05/01 17:44:03 bde Exp $
+ * $FreeBSD: src/sys/dev/cy/cyvar.h,v 1.2 2007/02/23 12:18:37 piso Exp $
*/
typedef u_char volatile *cy_addr;
@@ -32,5 +32,5 @@
extern char cy_driver_name[];
void *cyattach_common(cy_addr cy_iobase, int cy_align);
-driver_intr_t cyintr;
+driver_filter_t cyintr;
int cy_units(cy_addr cy_iobase, int cy_align);
Index: cy_isa.c
===================================================================
RCS file: /home/cvs/src/sys/dev/cy/cy_isa.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -L sys/dev/cy/cy_isa.c -L sys/dev/cy/cy_isa.c -u -r1.1.1.1 -r1.2
--- sys/dev/cy/cy_isa.c
+++ sys/dev/cy/cy_isa.c
@@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/cy/cy_isa.c,v 1.146 2004/05/30 20:08:29 phk Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/cy/cy_isa.c,v 1.148 2007/02/23 12:18:36 piso Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -74,7 +74,7 @@
{
struct resource *mem_res;
cy_addr iobase;
- int mem_rid;
+ int error, mem_rid;
if (isa_get_logicalid(dev) != 0) /* skip PnP probes */
return (ENXIO);
@@ -96,8 +96,9 @@
cy_outb(iobase, CY_CLEAR_INTR, 0, 0);
DELAY(500);
+ error = (cy_units(iobase, 0) == 0 ? ENXIO : 0);
bus_release_resource(dev, SYS_RES_MEMORY, mem_rid, mem_res);
- return (cy_units(iobase, 0) == 0 ? ENXIO : 0);
+ return (error);
}
static int
@@ -132,8 +133,8 @@
device_printf(dev, "interrupt resource allocation failed\n");
goto fail;
}
- if (bus_setup_intr(dev, irq_res, INTR_TYPE_TTY | INTR_FAST, cyintr,
- vsc, &irq_cookie) != 0) {
+ if (bus_setup_intr(dev, irq_res, INTR_TYPE_TTY,
+ cyintr, NULL, vsc, &irq_cookie) != 0) {
device_printf(dev, "interrupt setup failed\n");
goto fail;
}
More information about the Midnightbsd-cvs
mailing list