aboutsummaryrefslogtreecommitdiffstats
path: root/arch/tile/kernel/unaligned.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/tile/kernel/unaligned.c')
-rw-r--r--arch/tile/kernel/unaligned.c22
1 files changed, 10 insertions, 12 deletions
diff --git a/arch/tile/kernel/unaligned.c b/arch/tile/kernel/unaligned.c
index c02ea2a45f67..7d9a83be0aca 100644
--- a/arch/tile/kernel/unaligned.c
+++ b/arch/tile/kernel/unaligned.c
@@ -969,8 +969,7 @@ void jit_bundle_gen(struct pt_regs *regs, tilegx_bundle_bits bundle,
969 unaligned_fixup_count++; 969 unaligned_fixup_count++;
970 970
971 if (unaligned_printk) { 971 if (unaligned_printk) {
972 pr_info("%s/%d. Unalign fixup for kernel access " 972 pr_info("%s/%d - Unalign fixup for kernel access to userspace %lx\n",
973 "to userspace %lx.",
974 current->comm, current->pid, regs->regs[ra]); 973 current->comm, current->pid, regs->regs[ra]);
975 } 974 }
976 975
@@ -985,7 +984,7 @@ void jit_bundle_gen(struct pt_regs *regs, tilegx_bundle_bits bundle,
985 .si_addr = (unsigned char __user *)0 984 .si_addr = (unsigned char __user *)0
986 }; 985 };
987 if (unaligned_printk) 986 if (unaligned_printk)
988 pr_info("Unalign bundle: unexp @%llx, %llx", 987 pr_info("Unalign bundle: unexp @%llx, %llx\n",
989 (unsigned long long)regs->pc, 988 (unsigned long long)regs->pc,
990 (unsigned long long)bundle); 989 (unsigned long long)bundle);
991 990
@@ -1370,8 +1369,7 @@ void jit_bundle_gen(struct pt_regs *regs, tilegx_bundle_bits bundle,
1370 frag.bundle = bundle; 1369 frag.bundle = bundle;
1371 1370
1372 if (unaligned_printk) { 1371 if (unaligned_printk) {
1373 pr_info("%s/%d, Unalign fixup: pc=%lx " 1372 pr_info("%s/%d, Unalign fixup: pc=%lx bundle=%lx %d %d %d %d %d %d %d %d\n",
1374 "bundle=%lx %d %d %d %d %d %d %d %d.",
1375 current->comm, current->pid, 1373 current->comm, current->pid,
1376 (unsigned long)frag.pc, 1374 (unsigned long)frag.pc,
1377 (unsigned long)frag.bundle, 1375 (unsigned long)frag.bundle,
@@ -1380,8 +1378,8 @@ void jit_bundle_gen(struct pt_regs *regs, tilegx_bundle_bits bundle,
1380 (int)y1_lr, (int)y1_br, (int)x1_add); 1378 (int)y1_lr, (int)y1_br, (int)x1_add);
1381 1379
1382 for (k = 0; k < n; k += 2) 1380 for (k = 0; k < n; k += 2)
1383 pr_info("[%d] %016llx %016llx", k, 1381 pr_info("[%d] %016llx %016llx\n",
1384 (unsigned long long)frag.insn[k], 1382 k, (unsigned long long)frag.insn[k],
1385 (unsigned long long)frag.insn[k+1]); 1383 (unsigned long long)frag.insn[k+1]);
1386 } 1384 }
1387 1385
@@ -1402,7 +1400,7 @@ void jit_bundle_gen(struct pt_regs *regs, tilegx_bundle_bits bundle,
1402 .si_addr = (void __user *)&jit_code_area[idx] 1400 .si_addr = (void __user *)&jit_code_area[idx]
1403 }; 1401 };
1404 1402
1405 pr_warn("Unalign fixup: pid=%d %s jit_code_area=%llx", 1403 pr_warn("Unalign fixup: pid=%d %s jit_code_area=%llx\n",
1406 current->pid, current->comm, 1404 current->pid, current->comm,
1407 (unsigned long long)&jit_code_area[idx]); 1405 (unsigned long long)&jit_code_area[idx]);
1408 1406
@@ -1485,7 +1483,7 @@ void do_unaligned(struct pt_regs *regs, int vecnum)
1485 /* If exception came from kernel, try fix it up. */ 1483 /* If exception came from kernel, try fix it up. */
1486 if (fixup_exception(regs)) { 1484 if (fixup_exception(regs)) {
1487 if (unaligned_printk) 1485 if (unaligned_printk)
1488 pr_info("Unalign fixup: %d %llx @%llx", 1486 pr_info("Unalign fixup: %d %llx @%llx\n",
1489 (int)unaligned_fixup, 1487 (int)unaligned_fixup,
1490 (unsigned long long)regs->ex1, 1488 (unsigned long long)regs->ex1,
1491 (unsigned long long)regs->pc); 1489 (unsigned long long)regs->pc);
@@ -1519,7 +1517,7 @@ void do_unaligned(struct pt_regs *regs, int vecnum)
1519 }; 1517 };
1520 1518
1521 if (unaligned_printk) 1519 if (unaligned_printk)
1522 pr_info("Unalign fixup: %d %llx @%llx", 1520 pr_info("Unalign fixup: %d %llx @%llx\n",
1523 (int)unaligned_fixup, 1521 (int)unaligned_fixup,
1524 (unsigned long long)regs->ex1, 1522 (unsigned long long)regs->ex1,
1525 (unsigned long long)regs->pc); 1523 (unsigned long long)regs->pc);
@@ -1579,14 +1577,14 @@ void do_unaligned(struct pt_regs *regs, int vecnum)
1579 0); 1577 0);
1580 1578
1581 if (IS_ERR((void __force *)user_page)) { 1579 if (IS_ERR((void __force *)user_page)) {
1582 pr_err("Out of kernel pages trying do_mmap.\n"); 1580 pr_err("Out of kernel pages trying do_mmap\n");
1583 return; 1581 return;
1584 } 1582 }
1585 1583
1586 /* Save the address in the thread_info struct */ 1584 /* Save the address in the thread_info struct */
1587 info->unalign_jit_base = user_page; 1585 info->unalign_jit_base = user_page;
1588 if (unaligned_printk) 1586 if (unaligned_printk)
1589 pr_info("Unalign bundle: %d:%d, allocate page @%llx", 1587 pr_info("Unalign bundle: %d:%d, allocate page @%llx\n",
1590 raw_smp_processor_id(), current->pid, 1588 raw_smp_processor_id(), current->pid,
1591 (unsigned long long)user_page); 1589 (unsigned long long)user_page);
1592 } 1590 }