Subversion Repositories shark

Compare Revisions

Ignore whitespace Rev 33 → Rev 34

/shark/trunk/drivers/char/sermouse.c
20,11 → 20,11
 
/**
------------
CVS : $Id: sermouse.c,v 1.1.1.1 2002-03-29 14:12:49 pj Exp $
CVS : $Id: sermouse.c,v 1.2 2002-11-11 08:41:31 pj Exp $
 
File: $File$
Revision: $Revision: 1.1.1.1 $
Last update: $Date: 2002-03-29 14:12:49 $
Revision: $Revision: 1.2 $
Last update: $Date: 2002-11-11 08:41:31 $
------------
 
Author: Gerardo Lamastra
84,6 → 84,7
//#include <cons.h>
 
#include <kernel/kern.h>
#include <time.h>
//#include "sys/sys.h"
//#include "vm.h"
//#include "kern.h"
405,15 → 406,19
int port;
int ret;
int found;
struct timespec delay;
 
delay.tv_sec = 0;
delay.tv_nsec = 500000000;
 
found=0;
for (port=COM1;port<=COM4;port++) {
ret=com_open(port,1200,NONE,7,1);
if (ret==1) {
com_write(port,MCR,0x0e);
task_delay(500000l); /* necessary? */
nanosleep(&delay,NULL); /* necessary? */
com_write(port,MCR,0x0f);
task_delay(500000l); /* necessary? */
nanosleep(&delay,NULL); /* necessary? */
ret=sem_wait(&com_link[mouse_port].rx_sem);
if (ret==TRUE) {
if (*(com_link[mouse_port].rx_buf)=='M') found=1;
/shark/trunk/drivers/char/rtc.c
20,11 → 20,11
 
/**
------------
CVS : $Id: rtc.c,v 1.1.1.1 2002-03-29 14:12:49 pj Exp $
CVS : $Id: rtc.c,v 1.2 2002-11-11 08:41:31 pj Exp $
 
File: $File$
Revision: $Revision: 1.1.1.1 $
Last update: $Date: 2002-03-29 14:12:49 $
Revision: $Revision: 1.2 $
Last update: $Date: 2002-11-11 08:41:31 $
------------
 
Author: Massimiliano Giorgi
183,7 → 183,7
SYS_FLAGS flags;
unsigned char ctrl;
unsigned retries=0;
unsigned delay;
struct timespec delay;
 
/*
* read RTC once any update in progress is done. The update
201,8 → 201,9
barrier();
*/
 
delay=1000;
while (rtc_is_updating()&&++retries<=5) task_delay(delay);
delay.tv_nsec = 1000000;
delay.tv_sec = 0;
while (rtc_is_updating()&&++retries<=5) nanosleep(&delay, NULL);
if (retries>5) return -1;
 
/*
/shark/trunk/drivers/char/8042.c
20,11 → 20,11
 
/**
------------
CVS : $Id: 8042.c,v 1.1.1.1 2002-03-29 14:12:49 pj Exp $
CVS : $Id: 8042.c,v 1.2 2002-11-11 08:41:31 pj Exp $
 
File: $File$
Revision: $Revision: 1.1.1.1 $
Last update: $Date: 2002-03-29 14:12:49 $
Revision: $Revision: 1.2 $
Last update: $Date: 2002-11-11 08:41:31 $
------------
 
8042.h
348,7 → 348,7
static int C8042_reset(void)
{
int c;
int c=0;
int retries=16;
 
trace("8042 reset START");