clock.c/mem.c: real time clock detection fix/config change

pmap.c: zap mmap
This commit is contained in:
phil 1994-05-03 07:30:30 +00:00
parent cbe2aab3b2
commit 4e523f8ddb
3 changed files with 17 additions and 7 deletions

View File

@ -35,7 +35,7 @@
*
* @(#)clock.c 7.2 (Berkeley) 5/12/91
*
* $Id: clock.c,v 1.3 1994/02/22 22:55:24 phil Exp $
* $Id: clock.c,v 1.4 1994/05/03 07:30:30 phil Exp $
*/
/*
@ -126,16 +126,22 @@ inittodr(base)
unsigned int sec;
int leap;
if (!have_rtc) return;
if (!have_rtc)
{
time.tv_sec = 0;
return;
}
/* Read rtc and convert to seconds since Jan 1, 1970. */
rw_rtc ( buffer, 0); /* Read the rtc. */
/* Check to see if it was really the rtc! */
if (buffer[0] == 0x6d) /* The first byte of the rom. */
/* Check to see if it was really the rtc by checking for bad date info. */
if (buffer[1] > 59 || buffer[2] > 59 || buffer[3] > 23 || buffer[5] > 31
|| buffer[6] > 12)
{
have_rtc = 0;
time.tv_sec = 0;
return;
}

View File

@ -62,7 +62,11 @@
extern char *vmmap; /* poor name! */
#ifndef NO_RTC
int have_rtc = 1; /* For access to rtc. */
#else
int have_rtc = 0; /* For no rtc. */
#endif
#define ROM_ORIGIN 0xFFF00000 /* Mapped origin! */
/* Do the actual reading and writing of the rtc. We have to read

View File

@ -36,7 +36,7 @@
*
* @(#)pmap.c 7.7 (Berkeley) 5/12/91
*
* $Id: pmap.c,v 1.4 1994/04/19 17:14:21 phil Exp $
* $Id: pmap.c,v 1.5 1994/05/03 07:30:33 phil Exp $
*/
/*
@ -202,7 +202,7 @@ void pmap_clear_modify();
/*
* All those kernel PT submaps that BSD is so fond of
*/
struct pte *CMAP1, *CMAP2, *mmap;
struct pte *CMAP1, *CMAP2, *xxx_mmap;
caddr_t CADDR1, CADDR2, vmmap;
struct pte *msgbufmap;
struct msgbuf *msgbufp;
@ -406,7 +406,7 @@ pmap_bootstrap(firstaddr, loadaddr)
SYSMAP(caddr_t ,CMAP1 ,CADDR1 ,1 )
SYSMAP(caddr_t ,CMAP2 ,CADDR2 ,1 )
SYSMAP(caddr_t ,mmap ,vmmap ,1 )
SYSMAP(caddr_t ,xxx_mmap ,vmmap ,1 )
SYSMAP(struct msgbuf * ,msgbufmap ,msgbufp ,1 )
virtual_avail = va;
#endif