Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/arm/s3c2xx0 add an arg to s3c2800_intr_establish() ...



details:   https://anonhg.NetBSD.org/src/rev/8dac8ed02cb1
branches:  trunk
changeset: 547059:8dac8ed02cb1
user:      bsh <bsh%NetBSD.org@localhost>
date:      Mon May 12 07:49:10 2003 +0000

description:
add an arg to s3c2800_intr_establish() for interrupt type.

diffstat:

 sys/arch/arm/s3c2xx0/s3c2800_clk.c   |   8 +++++---
 sys/arch/arm/s3c2xx0/s3c2800_pci.c   |   4 ++--
 sys/arch/arm/s3c2xx0/s3c2800var.h    |   5 ++---
 sys/arch/arm/s3c2xx0/sscom_s3c2800.c |  21 +++++++--------------
 4 files changed, 16 insertions(+), 22 deletions(-)

diffs (116 lines):

diff -r 52ea2cc776ee -r 8dac8ed02cb1 sys/arch/arm/s3c2xx0/s3c2800_clk.c
--- a/sys/arch/arm/s3c2xx0/s3c2800_clk.c        Mon May 12 07:48:37 2003 +0000
+++ b/sys/arch/arm/s3c2xx0/s3c2800_clk.c        Mon May 12 07:49:10 2003 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: s3c2800_clk.c,v 1.2 2003/01/02 22:30:04 thorpej Exp $ */
+/* $NetBSD: s3c2800_clk.c,v 1.3 2003/05/12 07:49:11 bsh Exp $ */
 
 /*
  * Copyright (c) 2002 Fujitsu Component Limited
@@ -303,8 +303,10 @@
            ((prescaler - 1) << 16) | (tc - 1));
 
 
-       s3c2800_intr_establish(S3C2800_INT_TIMER0, IPL_CLOCK, hardintr, 0);
-       s3c2800_intr_establish(S3C2800_INT_TIMER1, IPL_STATCLOCK, statintr, 0);
+       s3c2800_intr_establish(S3C2800_INT_TIMER0, IPL_CLOCK, IST_EDGE, 
+           hardintr, 0);
+       s3c2800_intr_establish(S3C2800_INT_TIMER1, IPL_STATCLOCK, IST_EDGE,
+           statintr, 0);
 
        /* start timers */
        bus_space_write_4(sc->sc_sx.sc_iot, sc->sc_tmr0_ioh, TIMER_TMCON,
diff -r 52ea2cc776ee -r 8dac8ed02cb1 sys/arch/arm/s3c2xx0/s3c2800_pci.c
--- a/sys/arch/arm/s3c2xx0/s3c2800_pci.c        Mon May 12 07:48:37 2003 +0000
+++ b/sys/arch/arm/s3c2xx0/s3c2800_pci.c        Mon May 12 07:49:10 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: s3c2800_pci.c,v 1.3 2003/04/01 23:19:11 thorpej Exp $  */
+/*     $NetBSD: s3c2800_pci.c,v 1.4 2003/05/12 07:49:10 bsh Exp $      */
 
 /*
  * Copyright (c) 2002 Fujitsu Component Limited
@@ -264,7 +264,7 @@
        printf("\n");
 
        SLIST_INIT(&sc->sc_irq_handlers);
-       if (!s3c2800_intr_establish(S3C2800_INT_PCI, IPL_AUDIO,
+       if (!s3c2800_intr_establish(S3C2800_INT_PCI, IPL_AUDIO, IST_LEVEL,
                sspci_intr, sc))
                FAIL("intr_establish");
 
diff -r 52ea2cc776ee -r 8dac8ed02cb1 sys/arch/arm/s3c2xx0/s3c2800var.h
--- a/sys/arch/arm/s3c2xx0/s3c2800var.h Mon May 12 07:48:37 2003 +0000
+++ b/sys/arch/arm/s3c2xx0/s3c2800var.h Mon May 12 07:49:10 2003 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: s3c2800var.h,v 1.2 2003/05/03 05:17:54 bsh Exp $ */
+/* $NetBSD: s3c2800var.h,v 1.3 2003/05/12 07:49:10 bsh Exp $ */
 
 /*
  * Copyright (c) 2002 Fujitsu Component Limited
@@ -47,13 +47,12 @@
 };
 
 void   s3c2800_softreset(void);
-void   *s3c2800_intr_establish(int, int,  s3c2xx0_irq_handler_t, void *);
+void   *s3c2800_intr_establish(int, int, int, s3c2xx0_irq_handler_t, void *);
 void   s3c2800_intr_init(struct s3c2800_softc *);
 int    s3c2800_sscom_cnattach(bus_space_tag_t, int, int, int, tcflag_t);
 int    s3c2800_sscom_kgdb_attach(bus_space_tag_t, int, int, int, tcflag_t);
 void   s3c2800_pci_init(pci_chipset_tag_t, void *);
 
-
 /* Platform provides this */
 bus_dma_tag_t s3c2800_pci_dma_init(void);
 
diff -r 52ea2cc776ee -r 8dac8ed02cb1 sys/arch/arm/s3c2xx0/sscom_s3c2800.c
--- a/sys/arch/arm/s3c2xx0/sscom_s3c2800.c      Mon May 12 07:48:37 2003 +0000
+++ b/sys/arch/arm/s3c2xx0/sscom_s3c2800.c      Mon May 12 07:49:10 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sscom_s3c2800.c,v 1.1 2002/11/20 17:52:52 bsh Exp $ */
+/*     $NetBSD: sscom_s3c2800.c,v 1.2 2003/05/12 07:49:10 bsh Exp $ */
 
 /*
  * Copyright (c) 2002 Fujitsu Component Limited
@@ -101,6 +101,7 @@
        return unit == 0 || unit == 1;
 }
 
+#if 0
 int tx_int(void *);
 int rx_int(void *);
 int err_int(void *);
@@ -122,7 +123,7 @@
 {
        return sscomintr(arg);
 }
-
+#endif
 
 static void
 sscom_attach(struct device * parent, struct device * self, void *aux)
@@ -148,21 +149,13 @@
        }
        printf("\n");
 
-#if 0
        s3c2800_intr_establish(s3c2800_uart_config[unit].tx_int,
-           IPL_SERIAL, sscomintr, sc);
+           IPL_SERIAL, IST_LEVEL, sscomintr, sc);
        s3c2800_intr_establish(s3c2800_uart_config[unit].rx_int,
-           IPL_SERIAL, sscomintr, sc);
+           IPL_SERIAL, IST_LEVEL, sscomintr, sc);
        s3c2800_intr_establish(s3c2800_uart_config[unit].err_int,
-           IPL_SERIAL, sscomintr, sc);
-#else
-       s3c2800_intr_establish(s3c2800_uart_config[unit].tx_int,
-           IPL_SERIAL, tx_int, sc);
-       s3c2800_intr_establish(s3c2800_uart_config[unit].rx_int,
-           IPL_SERIAL, rx_int, sc);
-       s3c2800_intr_establish(s3c2800_uart_config[unit].err_int,
-           IPL_SERIAL, err_int, sc);
-#endif
+           IPL_SERIAL, IST_LEVEL, sscomintr, sc);
+
        sscom_disable_txrxint(sc);
 
        sscom_attach_subr(sc);



Home | Main Index | Thread Index | Old Index