 ------------------------------------------------------------------------
r3924 | blueswir1 | 2008-01-17 15:07:04 -0600 (Thu, 17 Jan 2008) | 2 lines
Changed paths:
   M /trunk/hw/slavio_serial.c

 Shuffle code to avoid NetBSD gcc 3.4.6 inlining bug (Rumko)

 ------------------------------------------------------------------------
Index: hw/slavio_serial.c
===================================================================
--- hw/slavio_serial.c	(revision 3923)
+++ hw/slavio_serial.c	(revision 3924)
@@ -215,7 +215,6 @@
 static void handle_kbd_command(ChannelState *s, int val);
 static int serial_can_receive(void *opaque);
 static void serial_receive_byte(ChannelState *s, int ch);
-static inline void set_txint(ChannelState *s);
 
 static void clear_queue(void *opaque)
 {
@@ -321,28 +320,6 @@
     slavio_serial_reset_chn(&s->chn[1]);
 }
 
-static inline void clr_rxint(ChannelState *s)
-{
-    s->rxint = 0;
-    s->rxint_under_svc = 0;
-    if (s->chn == chn_a) {
-        if (s->wregs[W_MINTR] & MINTR_STATUSHI)
-            s->otherchn->rregs[R_IVEC] = IVEC_HINOINT;
-        else
-            s->otherchn->rregs[R_IVEC] = IVEC_LONOINT;
-        s->rregs[R_INTR] &= ~INTR_RXINTA;
-    } else {
-        if (s->wregs[W_MINTR] & MINTR_STATUSHI)
-            s->rregs[R_IVEC] = IVEC_HINOINT;
-        else
-            s->rregs[R_IVEC] = IVEC_LONOINT;
-        s->otherchn->rregs[R_INTR] &= ~INTR_RXINTB;
-    }
-    if (s->txint)
-        set_txint(s);
-    slavio_serial_update_irq(s);
-}
-
 static inline void set_rxint(ChannelState *s)
 {
     s->rxint = 1;
@@ -367,6 +344,49 @@
     slavio_serial_update_irq(s);
 }
 
+static inline void set_txint(ChannelState *s)
+{
+    s->txint = 1;
+    if (!s->rxint_under_svc) {
+        s->txint_under_svc = 1;
+        if (s->chn == chn_a) {
+            if (s->wregs[W_MINTR] & MINTR_STATUSHI)
+                s->otherchn->rregs[R_IVEC] = IVEC_HITXINTA;
+            else
+                s->otherchn->rregs[R_IVEC] = IVEC_LOTXINTA;
+        } else {
+            s->rregs[R_IVEC] = IVEC_TXINTB;
+        }
+    }
+    if (s->chn == chn_a)
+        s->rregs[R_INTR] |= INTR_TXINTA;
+    else
+        s->otherchn->rregs[R_INTR] |= INTR_TXINTB;
+    slavio_serial_update_irq(s);
+}
+
+static inline void clr_rxint(ChannelState *s)
+{
+    s->rxint = 0;
+    s->rxint_under_svc = 0;
+    if (s->chn == chn_a) {
+        if (s->wregs[W_MINTR] & MINTR_STATUSHI)
+            s->otherchn->rregs[R_IVEC] = IVEC_HINOINT;
+        else
+            s->otherchn->rregs[R_IVEC] = IVEC_LONOINT;
+        s->rregs[R_INTR] &= ~INTR_RXINTA;
+    } else {
+        if (s->wregs[W_MINTR] & MINTR_STATUSHI)
+            s->rregs[R_IVEC] = IVEC_HINOINT;
+        else
+            s->rregs[R_IVEC] = IVEC_LONOINT;
+        s->otherchn->rregs[R_INTR] &= ~INTR_RXINTB;
+    }
+    if (s->txint)
+        set_txint(s);
+    slavio_serial_update_irq(s);
+}
+
 static inline void clr_txint(ChannelState *s)
 {
     s->txint = 0;
@@ -389,27 +409,6 @@
     slavio_serial_update_irq(s);
 }
 
-static inline void set_txint(ChannelState *s)
-{
-    s->txint = 1;
-    if (!s->rxint_under_svc) {
-        s->txint_under_svc = 1;
-        if (s->chn == chn_a) {
-            if (s->wregs[W_MINTR] & MINTR_STATUSHI)
-                s->otherchn->rregs[R_IVEC] = IVEC_HITXINTA;
-            else
-                s->otherchn->rregs[R_IVEC] = IVEC_LOTXINTA;
-        } else {
-            s->rregs[R_IVEC] = IVEC_TXINTB;
-        }
-    }
-    if (s->chn == chn_a)
-        s->rregs[R_INTR] |= INTR_TXINTA;
-    else
-        s->otherchn->rregs[R_INTR] |= INTR_TXINTB;
-    slavio_serial_update_irq(s);
-}
-
 static void slavio_serial_update_parameters(ChannelState *s)
 {
     int speed, parity, data_bits, stop_bits;

Property changes on: hw/slavio_serial.c
___________________________________________________________________
Name: cvs2svn:cvs-rev
   - 1.32
   + 1.33

