提交 58f5c1eb 编写于 作者: E Edgar E. Iglesias 提交者: Edgar E. Iglesias

cris: Correct settls1 testcase.

Signed-off-by: NEdgar E. Iglesias <edgar.iglesias@gmail.com>
上级 61eb865a
......@@ -11,11 +11,15 @@
int main (void)
{
unsigned long tp;
unsigned long tp, old_tp;
int ret;
asm volatile ("move $pid,%0" : "=r" (old_tp));
old_tp &= ~0xff;
ret = syscall (SYS_set_thread_area, 0xf0);
if (ret != -1 || errno != EINVAL) {
syscall (SYS_set_thread_area, old_tp);
perror ("Invalid thread area accepted:");
abort();
}
......@@ -26,10 +30,12 @@ int main (void)
abort ();
}
asm ("move $pid,%0" : "=r" (tp));
asm volatile ("move $pid,%0" : "=r" (tp));
tp &= ~0xff;
syscall (SYS_set_thread_area, old_tp);
if (tp != 0xeddeed00) {
* (volatile int *) 0 = 0;
perror ("tls2");
abort ();
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册