Subversion Repositories HelenOS-historic

Rev

Rev 1619 | Rev 1628 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1619 Rev 1625
Line 26... Line 26...
26
 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26
 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27
 */
27
 */
28
 
28
 
29
#include <arch/drivers/cuda.h>
29
#include <arch/drivers/cuda.h>
30
#include <arch/asm.h>
30
#include <arch/asm.h>
31
#include <console/chardev.h>
-
 
32
#include <console/console.h>
31
#include <console/console.h>
33
#include <arch/drivers/pic.h>
32
#include <arch/drivers/pic.h>
-
 
33
#include <sysinfo/sysinfo.h>
34
#include <interrupt.h>
34
#include <interrupt.h>
35
#include <stdarg.h>
35
#include <stdarg.h>
36
 
36
 
37
#define PACKET_ADB  0x00
37
#define PACKET_ADB  0x00
38
#define PACKET_CUDA 0x01
38
#define PACKET_CUDA 0x01
Line 127... Line 127...
127
    ch = 0;
127
    ch = 0;
128
    return ch;
128
    return ch;
129
}
129
}
130
 
130
 
131
 
131
 
132
static chardev_t kbrd;
132
chardev_t kbrd;
133
static chardev_operations_t ops = {
133
static chardev_operations_t ops = {
134
    .suspend = cuda_suspend,
134
    .suspend = cuda_suspend,
135
    .resume = cuda_resume,
135
    .resume = cuda_resume,
136
    .read = key_read
136
    .read = key_read
137
};
137
};
Line 160... Line 160...
160
    int_register(CUDA_IRQ, "cuda", cuda_irq);
160
    int_register(CUDA_IRQ, "cuda", cuda_irq);
161
    pic_enable_interrupt(CUDA_IRQ);
161
    pic_enable_interrupt(CUDA_IRQ);
162
   
162
   
163
    chardev_initialize("cuda_kbd", &kbrd, &ops);
163
    chardev_initialize("cuda_kbd", &kbrd, &ops);
164
    stdin = &kbrd;
164
    stdin = &kbrd;
-
 
165
   
-
 
166
    sysinfo_set_item_val("cuda", NULL, true);
-
 
167
    sysinfo_set_item_val("cuda.irq", NULL, CUDA_IRQ);
165
}
168
}
166
 
169
 
167
 
170
 
168
void cpu_halt(void) {
171
void cpu_halt(void) {
169
#ifdef CONFIG_POWEROFF
172
#ifdef CONFIG_POWEROFF