Subversion Repositories HelenOS

Rev

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

Rev 2410 Rev 2412
Line 195... Line 195...
195
{
195
{
196
    return IRQ_ACCEPT;
196
    return IRQ_ACCEPT;
197
}
197
}
198
 
198
 
199
 
199
 
-
 
200
/** Acquire console back for kernel. */
200
void gxemul_grab_console(void)
201
void gxemul_grab_console(void)
201
{
202
{
202
    ipl_t ipl = interrupts_disable();
203
    ipl_t ipl = interrupts_disable();
203
    spinlock_lock(&gxemul_irq.lock);
204
    spinlock_lock(&gxemul_irq.lock);
204
    gxemul_irq.notif_cfg.notify = false;
205
    gxemul_irq.notif_cfg.notify = false;
205
    spinlock_unlock(&gxemul_irq.lock);
206
    spinlock_unlock(&gxemul_irq.lock);
206
    interrupts_restore(ipl);
207
    interrupts_restore(ipl);
207
}
208
}
208
 
209
 
209
 
210
 
-
 
211
/** Return console to userspace. */
210
void gxemul_release_console(void)
212
void gxemul_release_console(void)
211
{
213
{
212
    ipl_t ipl = interrupts_disable();
214
    ipl_t ipl = interrupts_disable();
213
    spinlock_lock(&gxemul_irq.lock);
215
    spinlock_lock(&gxemul_irq.lock);
214
    if (gxemul_irq.notif_cfg.answerbox) {
216
    if (gxemul_irq.notif_cfg.answerbox) {
Line 332... Line 334...
332
{
334
{
333
    return  *((int*)(GXEMUL_MP + GXEMUL_MP_MEMSIZE_OFFSET));
335
    return  *((int*)(GXEMUL_MP + GXEMUL_MP_MEMSIZE_OFFSET));
334
}
336
}
335
 
337
 
336
 
338
 
-
 
339
/** Prints a character.
-
 
340
 *
-
 
341
 *  @param ch Character to be printed.
-
 
342
 */
337
void gxemul_debug_putc(char ch)
343
void gxemul_debug_putc(char ch)
338
{
344
{
339
    char * addr = 0;
345
    char * addr = 0;
340
    if (!hw_map_init_called) {
346
    if (!hw_map_init_called) {
341
        addr = (char *) GXEMUL_KBD;
347
        addr = (char *) GXEMUL_KBD;
Line 386... Line 392...
386
            }
392
            }
387
        }
393
        }
388
    }
394
    }
389
}
395
}
390
 
396
 
-
 
397
/** Returns address of framebuffer device.
391
 
398
 *
-
 
399
 *  @return Address of framebuffer device.
-
 
400
 */
392
uintptr_t gxemul_get_fb_address(void)
401
uintptr_t gxemul_get_fb_address(void)
393
{
402
{
394
    return (uintptr_t) GXEMUL_FB;
403
    return (uintptr_t) GXEMUL_FB;
395
}
404
}
396
 
405