DragonFly submit List (threaded) for 2005-05
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
some typo in lib/libc/sys/tls.2
this patch fixes some typo in lib/libc/sys/tls.2
please review it.
--
Live Free or Die
Index: tls.2
===================================================================
RCS file: /opt/df_cvs/src/lib/libc/sys/tls.2,v
retrieving revision 1.4
diff -u -r1.4 tls.2
--- tls.2 21 Mar 2005 17:11:38 -0000 1.4
+++ tls.2 9 May 2005 08:54:52 -0000
@@ -86,7 +86,8 @@
If the kernel is unable to accomodate the supplied base address an error
will be returned.
.Sh RETURN VALUES
-A return value of 0 is returned on success, -1 on error.
+On success a descriptor representing the facility is returned,
+-1 on error.
.Sh ERRORS
.Bl -tag -width Er
.It Bq Er ERANGE
@@ -128,21 +129,21 @@
perror("setarea");
exit(1);
}
- printf("gs = %04x\n", gs);
+ printf("gs = %04x\en", gs);
__asm __volatile("movl %0,%%eax; movl %%eax,%%gs" : "=m" (gs) : : "ax");
if (sys_get_tls_area(0, &info, sizeof(info)) < 0) {
perror("getarea");
exit(1);
}
- printf("%p/%d\n", info.base, info.size);
+ printf("%p/%d\en", info.base, info.size);
X = 1;
- printf("should be 1: %d\n", getdata(0));
+ printf("should be 1: %d\en", getdata(0));
X = 2;
- printf("should be 2: %d\n", getdata(0));
+ printf("should be 2: %d\en", getdata(0));
- printf("this should fault:\n");
+ printf("this should fault:\en");
fflush(stdout);
getdata(4);
@@ -153,8 +154,7 @@
getdata(int offset)
{
int rv;
- __asm __volatile("movl %%gs:(%0),%%eax; movl %%eax,%1" : "+r" (offset) : "m"
- (rv) : "ax");
+ __asm __volatile("movl %%gs:(%0),%%eax; movl %%eax,%1" : "+r" (offset) : "m" (rv) : "ax");
return (rv);
}
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]