Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/microcode/siop Add hooks to drive the activity led v...



details:   https://anonhg.NetBSD.org/src/rev/4b7c7635bfb1
branches:  trunk
changeset: 525816:4b7c7635bfb1
user:      bouyer <bouyer%NetBSD.org@localhost>
date:      Thu Apr 18 11:56:11 2002 +0000

description:
Add hooks to drive the activity led via the GPIO pin 1, as required by some
tekram and symbios adapters.

diffstat:

 sys/dev/microcode/siop/siop.ss |  23 ++++++++++++++++++++++-
 1 files changed, 22 insertions(+), 1 deletions(-)

diffs (56 lines):

diff -r be5d827defb2 -r 4b7c7635bfb1 sys/dev/microcode/siop/siop.ss
--- a/sys/dev/microcode/siop/siop.ss    Thu Apr 18 11:14:33 2002 +0000
+++ b/sys/dev/microcode/siop/siop.ss    Thu Apr 18 11:56:11 2002 +0000
@@ -1,4 +1,4 @@
-;      $NetBSD: siop.ss,v 1.12 2000/10/23 14:53:53 bouyer Exp $
+;      $NetBSD: siop.ss,v 1.13 2002/04/18 11:56:11 bouyer Exp $
 
 ;
 ;  Copyright (c) 2000 Manuel Bouyer.
@@ -81,6 +81,9 @@
 ENTRY resel_targ0;
 ENTRY msgin_space;
 ENTRY lunsw_return;
+ENTRY led_on1;
+ENTRY led_on2;
+ENTRY led_off;
 EXTERN abs_script_sched_slot0;
 EXTERN abs_targ0;
 EXTERN abs_msgin;
@@ -134,6 +137,10 @@
        ; check that host asserted SIGP, this'll clear SIGP in ISTAT
        MOVE CTEST2 & 0x40 TO SFBR;
        INT int_resfail,  IF 0x00;
+; a NOP by default; patched with MOVE GPREG & 0xfe to GPREG on compile-time
+; option "SIOP_SYMLED"
+led_on1:
+       NOP;
 script_sched:
        ; Clear DSA and init status
        MOVE 0xff to DSA0;
@@ -197,7 +204,15 @@
        MOVE 0xff to DSA3;
        MOVE 0x00 to SCRATCHA2; no tag
        MOVE 0x20 to SCRATCHA3; simple tag msg, ignored by reselected:
+; a NOP by default; patched with MOVE GPREG | 0x01 to GPREG on compile-time
+; option "SIOP_SYMLED"
+led_off:
+       NOP;
        WAIT RESELECT REL(reselect_fail)
+; a NOP by default; patched with MOVE GPREG & 0xfe to GPREG on compile-time
+; option "SIOP_SYMLED"
+led_on2:
+       NOP;
        MOVE SSID & 0x8f to SFBR
        MOVE SFBR to SCRATCHA0 ; save reselect ID
 ; find the rigth param for this target
@@ -406,3 +421,9 @@
        JUMP ldsa_abs_selected;
 ldsa_data:
        NOP; contains data used by the MOVE MEMORY
+
+PROC siop_led_on:
+       MOVE GPREG & 0xfe TO GPREG;
+
+PROC siop_led_off:
+       MOVE GPREG | 0x01 TO GPREG;



Home | Main Index | Thread Index | Old Index