aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Wemm <peter@FreeBSD.org>2002-06-20 07:23:08 +0000
committerPeter Wemm <peter@FreeBSD.org>2002-06-20 07:23:08 +0000
commite8aef1d3b5bab81b8f9a9630763557b149c88ec9 (patch)
tree0e1b49bbdb34361cf643633b49c292df203f3282
parent49d54362f1b55237206bb61dc87fcc0933ab2716 (diff)
Notes
-rw-r--r--sys/gnu/i386/fpemul/load_store.c6
-rw-r--r--sys/gnu/i386/fpemul/reg_ld_str.c24
-rw-r--r--sys/i386/i386/math_emulate.c4
-rw-r--r--sys/i386/i386/vm86.c4
-rw-r--r--sys/sys/systm.h8
5 files changed, 23 insertions, 23 deletions
diff --git a/sys/gnu/i386/fpemul/load_store.c b/sys/gnu/i386/fpemul/load_store.c
index 2cfbba506147..28e35f474479 100644
--- a/sys/gnu/i386/fpemul/load_store.c
+++ b/sys/gnu/i386/fpemul/load_store.c
@@ -201,7 +201,7 @@ load_store_instr(char type)
break;
case 024: /* fldcw */
REENTRANT_CHECK(OFF);
- control_word = fusword((unsigned short *) FPU_data_address);
+ control_word = fuword16((unsigned short *) FPU_data_address);
REENTRANT_CHECK(ON);
#ifdef NO_UNDERFLOW_TRAP
if (!(control_word & EX_Underflow)) {
@@ -242,7 +242,7 @@ load_store_instr(char type)
case 034: /* fstcw m16int */
REENTRANT_CHECK(OFF);
/* verify_area(VERIFY_WRITE, FPU_data_address, 2);*/
- susword( (short *) FPU_data_address,control_word);
+ suword16( (short *) FPU_data_address,control_word);
REENTRANT_CHECK(ON);
/* We want no net effect: */
FPU_data_address = (void *) (intptr_t ) data_operand_offset;
@@ -258,7 +258,7 @@ load_store_instr(char type)
status_word |= (top & 7) << SW_Top_Shift;
REENTRANT_CHECK(OFF);
/* verify_area(VERIFY_WRITE, FPU_data_address, 2);*/
- susword( (short *) FPU_data_address,status_word);
+ suword16( (short *) FPU_data_address,status_word);
REENTRANT_CHECK(ON);
/* We want no net effect: */
FPU_data_address = (void *) (intptr_t) data_operand_offset;
diff --git a/sys/gnu/i386/fpemul/reg_ld_str.c b/sys/gnu/i386/fpemul/reg_ld_str.c
index 5a2bcb812695..9c13b11f3666 100644
--- a/sys/gnu/i386/fpemul/reg_ld_str.c
+++ b/sys/gnu/i386/fpemul/reg_ld_str.c
@@ -110,7 +110,7 @@ reg_load_extended(void)
* hence re-entrancy problems can arise */
sigl = fuword((unsigned long *) s);
sigh = fuword(1 + (unsigned long *) s);
- exp = fusword(4 + (unsigned short *) s);
+ exp = fuword16(4 + (unsigned short *) s);
REENTRANT_CHECK(ON);
FPU_loaded_data.sigl = sigl;
@@ -361,7 +361,7 @@ reg_load_int16(void)
REENTRANT_CHECK(OFF);
/* Cast as short to get the sign extended. */
- s = (short) fusword((unsigned short *) _s);
+ s = (short) fuword16((unsigned short *) _s);
REENTRANT_CHECK(ON);
if (s == 0) {
@@ -527,7 +527,7 @@ reg_store_extended(void)
/* verify_area(VERIFY_WRITE, d, 10); */
suword((unsigned long *) d, ls);
suword(1 + (unsigned long *) d, ms);
- susword(4 + (short *) d, (unsigned short) e | sign);
+ suword16(4 + (short *) d, (unsigned short) e | sign);
REENTRANT_CHECK(ON);
return 1;
@@ -1001,7 +1001,7 @@ reg_store_int16(void)
/* Put out the QNaN indefinite */
REENTRANT_CHECK(OFF);
/* verify_area(VERIFY_WRITE, d, 2);*/
- susword((unsigned short *) d, 0x8000);
+ suword16((unsigned short *) d, 0x8000);
REENTRANT_CHECK(ON);
return 1;
} else
@@ -1025,7 +1025,7 @@ reg_store_int16(void)
REENTRANT_CHECK(OFF);
/* verify_area(VERIFY_WRITE, d, 2); */
- susword((short *) d, (short) t.sigl);
+ suword16((short *) d, (short) t.sigl);
REENTRANT_CHECK(ON);
return 1;
@@ -1164,9 +1164,9 @@ fldenv(void)
int i;
REENTRANT_CHECK(OFF);
- control_word = fusword((unsigned short *) s);
- status_word = fusword((unsigned short *) (s + 4));
- tag_word = fusword((unsigned short *) (s + 8));
+ control_word = fuword16((unsigned short *) s);
+ status_word = fuword16((unsigned short *) (s + 4));
+ tag_word = fuword16((unsigned short *) (s + 8));
ip_offset = fuword((unsigned long *) (s + 0x0c));
cs_selector = fuword((unsigned long *) (s + 0x10));
data_operand_offset = fuword((unsigned long *) (s + 0x14));
@@ -1285,9 +1285,9 @@ fstenv(void)
#endif /****/
REENTRANT_CHECK(OFF);
- susword((unsigned short *) d, control_word);
- susword((unsigned short *) (d + 4), (status_word & ~SW_Top) | ((top & 7) << SW_Top_Shift));
- susword((unsigned short *) (d + 8), tag_word());
+ suword16((unsigned short *) d, control_word);
+ suword16((unsigned short *) (d + 4), (status_word & ~SW_Top) | ((top & 7) << SW_Top_Shift));
+ suword16((unsigned short *) (d + 8), tag_word());
suword((unsigned long *) (d + 0x0c), ip_offset);
suword((unsigned long *) (d + 0x10), cs_selector);
suword((unsigned long *) (d + 0x14), data_operand_offset);
@@ -1378,7 +1378,7 @@ fsave(void)
}
e |= rp->sign == SIGN_POS ? 0 : 0x8000;
REENTRANT_CHECK(OFF);
- susword((unsigned short *) (d + i * 10 + 8), e);
+ suword16((unsigned short *) (d + i * 10 + 8), e);
REENTRANT_CHECK(ON);
}
diff --git a/sys/i386/i386/math_emulate.c b/sys/i386/i386/math_emulate.c
index 296598a1e0ab..a7887f4cd959 100644
--- a/sys/i386/i386/math_emulate.c
+++ b/sys/i386/i386/math_emulate.c
@@ -71,7 +71,7 @@ get_fs_byte(char *adr)
static unsigned short
get_fs_word(unsigned short *adr)
- { return(fuword(adr)); }
+ { return(fuword16(adr)); }
static u_int32_t
get_fs_long(u_int32_t *adr)
@@ -83,7 +83,7 @@ put_fs_byte(unsigned char val, char *adr)
static void
put_fs_word(unsigned short val, short *adr)
- { (void)susword(adr,val); }
+ { (void)suword16(adr,val); }
static void
put_fs_long(u_long val, u_int32_t *adr)
diff --git a/sys/i386/i386/vm86.c b/sys/i386/i386/vm86.c
index ab854782c05e..eb0c98bff831 100644
--- a/sys/i386/i386/vm86.c
+++ b/sys/i386/i386/vm86.c
@@ -98,7 +98,7 @@ static __inline void
PUSH(u_short x, struct vm86frame *vmf)
{
vmf->vmf_sp -= 2;
- susword(MAKE_ADDR(vmf->vmf_ss, vmf->vmf_sp), x);
+ suword16(MAKE_ADDR(vmf->vmf_ss, vmf->vmf_sp), x);
}
static __inline void
@@ -111,7 +111,7 @@ PUSHL(u_int x, struct vm86frame *vmf)
static __inline u_short
POP(struct vm86frame *vmf)
{
- u_short x = fusword(MAKE_ADDR(vmf->vmf_ss, vmf->vmf_sp));
+ u_short x = fuword16(MAKE_ADDR(vmf->vmf_ss, vmf->vmf_sp));
vmf->vmf_sp += 2;
return (x);
diff --git a/sys/sys/systm.h b/sys/sys/systm.h
index 4128267946de..ccba6266a058 100644
--- a/sys/sys/systm.h
+++ b/sys/sys/systm.h
@@ -180,15 +180,15 @@ int copyin(const void *udaddr, void *kaddr, size_t len);
int copyout(const void *kaddr, void *udaddr, size_t len);
int fubyte(const void *base);
-int subyte(void *base, int byte);
+long fuword(const void *base);
+int fuword16(void *base);
int32_t fuword32(const void *base);
int64_t fuword64(const void *base);
-long fuword(const void *base);
+int subyte(void *base, int byte);
int suword(void *base, long word);
+int suword16(void *base, int word);
int suword32(void *base, int32_t word);
int suword64(void *base, int64_t word);
-int fusword(void *base);
-int susword(void *base, int word);
void realitexpire(void *);