Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6

* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6:
[IA64] kprobes arch consolidation build fix
[IA64] update efi region debugging to use MB, GB and TB as well as KB
[IA64] use dev_printk in video quirk
[IA64] remove remaining __FUNCTION__ occurrences
[IA64] remove unnecessary nfs includes from sys_ia32.c
[IA64] remove CONFIG_SMP ifdef in ia64_send_ipi()
[IA64] arch_ptrace() cleanup
[IA64] remove duplicate code from arch_ptrace()
[IA64] convert sys_ptrace to arch_ptrace
[IA64] remove find_thread_for_addr()
[IA64] do not sync RBS when changing PT_AR_BSP or PT_CFM
[IA64] access user RBS directly

+292 -468
+1 -1
arch/ia64/hp/common/hwsw_iommu.c
··· 71 71 #ifdef CONFIG_IA64_GENERIC 72 72 /* Better to have normal DMA than panic */ 73 73 printk(KERN_WARNING "%s: Failed to initialize software I/O TLB," 74 - " reverting to hpzx1 platform vector\n", __FUNCTION__); 74 + " reverting to hpzx1 platform vector\n", __func__); 75 75 machvec_init("hpzx1"); 76 76 #else 77 77 panic("Unable to initialize software I/O TLB services");
+17 -19
arch/ia64/hp/common/sba_iommu.c
··· 529 529 base_mask = RESMAP_MASK(bits_wanted); 530 530 mask = base_mask << bitshiftcnt; 531 531 532 - DBG_RES("%s() o %ld %p", __FUNCTION__, o, res_ptr); 532 + DBG_RES("%s() o %ld %p", __func__, o, res_ptr); 533 533 for(; res_ptr < res_end ; res_ptr++) 534 534 { 535 535 DBG_RES(" %p %lx %lx\n", res_ptr, mask, *res_ptr); ··· 679 679 #endif 680 680 681 681 DBG_RES("%s(%x) %d -> %lx hint %x/%x\n", 682 - __FUNCTION__, size, pages_needed, pide, 682 + __func__, size, pages_needed, pide, 683 683 (uint) ((unsigned long) ioc->res_hint - (unsigned long) ioc->res_map), 684 684 ioc->res_bitshift ); 685 685 ··· 722 722 m = RESMAP_MASK(bits_not_wanted) << (pide & (BITS_PER_LONG - 1)); 723 723 bits_not_wanted = 0; 724 724 725 - DBG_RES("%s( ,%x,%x) %x/%lx %x %p %lx\n", __FUNCTION__, (uint) iova, size, 726 - bits_not_wanted, m, pide, res_ptr, *res_ptr); 725 + DBG_RES("%s( ,%x,%x) %x/%lx %x %p %lx\n", __func__, (uint) iova, size, 726 + bits_not_wanted, m, pide, res_ptr, *res_ptr); 727 727 728 728 ASSERT(m != 0); 729 729 ASSERT(bits_not_wanted); ··· 940 940 941 941 iovp = (dma_addr_t) pide << iovp_shift; 942 942 943 - DBG_RUN("%s() 0x%p -> 0x%lx\n", 944 - __FUNCTION__, addr, (long) iovp | offset); 943 + DBG_RUN("%s() 0x%p -> 0x%lx\n", __func__, addr, (long) iovp | offset); 945 944 946 945 pdir_start = &(ioc->pdir_base[pide]); 947 946 ··· 1028 1029 #endif 1029 1030 offset = iova & ~iovp_mask; 1030 1031 1031 - DBG_RUN("%s() iovp 0x%lx/%x\n", 1032 - __FUNCTION__, (long) iova, size); 1032 + DBG_RUN("%s() iovp 0x%lx/%x\n", __func__, (long) iova, size); 1033 1033 1034 1034 iova ^= offset; /* clear offset bits */ 1035 1035 size += offset; ··· 1402 1404 struct scatterlist *sg; 1403 1405 #endif 1404 1406 1405 - DBG_RUN_SG("%s() START %d entries\n", __FUNCTION__, nents); 1407 + DBG_RUN_SG("%s() START %d entries\n", __func__, nents); 1406 1408 ioc = GET_IOC(dev); 1407 1409 ASSERT(ioc); 1408 1410 ··· 1466 1468 #endif 1467 1469 1468 1470 ASSERT(coalesced == filled); 1469 - DBG_RUN_SG("%s() DONE %d mappings\n", __FUNCTION__, filled); 1471 + DBG_RUN_SG("%s() DONE %d mappings\n", __func__, filled); 1470 1472 1471 1473 return filled; 1472 1474 } ··· 1489 1491 #endif 1490 1492 1491 1493 DBG_RUN_SG("%s() START %d entries, %p,%x\n", 1492 - __FUNCTION__, nents, sba_sg_address(sglist), sglist->length); 1494 + __func__, nents, sba_sg_address(sglist), sglist->length); 1493 1495 1494 1496 #ifdef ASSERT_PDIR_SANITY 1495 1497 ioc = GET_IOC(dev); ··· 1507 1509 nents--; 1508 1510 } 1509 1511 1510 - DBG_RUN_SG("%s() DONE (nents %d)\n", __FUNCTION__, nents); 1512 + DBG_RUN_SG("%s() DONE (nents %d)\n", __func__, nents); 1511 1513 1512 1514 #ifdef ASSERT_PDIR_SANITY 1513 1515 spin_lock_irqsave(&ioc->res_lock, flags); ··· 1544 1546 ioc->iov_size = ~ioc->imask + 1; 1545 1547 1546 1548 DBG_INIT("%s() hpa %p IOV base 0x%lx mask 0x%lx (%dMB)\n", 1547 - __FUNCTION__, ioc->ioc_hpa, ioc->ibase, ioc->imask, 1549 + __func__, ioc->ioc_hpa, ioc->ibase, ioc->imask, 1548 1550 ioc->iov_size >> 20); 1549 1551 1550 1552 switch (iovp_size) { ··· 1567 1569 1568 1570 memset(ioc->pdir_base, 0, ioc->pdir_size); 1569 1571 1570 - DBG_INIT("%s() IOV page size %ldK pdir %p size %x\n", __FUNCTION__, 1572 + DBG_INIT("%s() IOV page size %ldK pdir %p size %x\n", __func__, 1571 1573 iovp_size >> 10, ioc->pdir_base, ioc->pdir_size); 1572 1574 1573 1575 ASSERT(ALIGN((unsigned long) ioc->pdir_base, 4*1024) == (unsigned long) ioc->pdir_base); ··· 1610 1612 1611 1613 prefetch_spill_page = virt_to_phys(addr); 1612 1614 1613 - DBG_INIT("%s() prefetch spill addr: 0x%lx\n", __FUNCTION__, prefetch_spill_page); 1615 + DBG_INIT("%s() prefetch spill addr: 0x%lx\n", __func__, prefetch_spill_page); 1614 1616 } 1615 1617 /* 1616 1618 ** Set all the PDIR entries valid w/ the spill page as the target ··· 1639 1641 /* resource map size dictated by pdir_size */ 1640 1642 ioc->res_size = ioc->pdir_size / PDIR_ENTRY_SIZE; /* entries */ 1641 1643 ioc->res_size >>= 3; /* convert bit count to byte count */ 1642 - DBG_INIT("%s() res_size 0x%x\n", __FUNCTION__, ioc->res_size); 1644 + DBG_INIT("%s() res_size 0x%x\n", __func__, ioc->res_size); 1643 1645 1644 1646 ioc->res_map = (char *) __get_free_pages(GFP_KERNEL, 1645 1647 get_order(ioc->res_size)); ··· 1662 1664 | prefetch_spill_page); 1663 1665 #endif 1664 1666 1665 - DBG_INIT("%s() res_map %x %p\n", __FUNCTION__, 1667 + DBG_INIT("%s() res_map %x %p\n", __func__, 1666 1668 ioc->res_size, (void *) ioc->res_map); 1667 1669 } 1668 1670 ··· 1765 1767 iovp_size = (1 << iovp_shift); 1766 1768 iovp_mask = ~(iovp_size - 1); 1767 1769 1768 - DBG_INIT("%s: PAGE_SIZE %ldK, iovp_size %ldK\n", __FUNCTION__, 1770 + DBG_INIT("%s: PAGE_SIZE %ldK, iovp_size %ldK\n", __func__, 1769 1771 PAGE_SIZE >> 10, iovp_size >> 10); 1770 1772 1771 1773 if (!ioc->name) { ··· 2135 2137 break; 2136 2138 default: 2137 2139 printk("%s: unknown/unsupported iommu page size %ld\n", 2138 - __FUNCTION__, page_size); 2140 + __func__, page_size); 2139 2141 } 2140 2142 2141 2143 return 1;
+1 -1
arch/ia64/hp/sim/simeth.c
··· 222 222 } 223 223 224 224 if ((rc = assign_irq_vector(AUTO_ASSIGN)) < 0) 225 - panic("%s: out of interrupt vectors!\n", __FUNCTION__); 225 + panic("%s: out of interrupt vectors!\n", __func__); 226 226 dev->irq = rc; 227 227 228 228 /*
+1 -1
arch/ia64/hp/sim/simserial.c
··· 1000 1000 if (!state->irq) { 1001 1001 if ((rc = assign_irq_vector(AUTO_ASSIGN)) < 0) 1002 1002 panic("%s: out of interrupt vectors!\n", 1003 - __FUNCTION__); 1003 + __func__); 1004 1004 state->irq = rc; 1005 1005 ia64_ssc_connect_irq(KEYBOARD_INTR, state->irq); 1006 1006 }
+1 -6
arch/ia64/ia32/sys_ia32.c
··· 32 32 #include <linux/shm.h> 33 33 #include <linux/slab.h> 34 34 #include <linux/uio.h> 35 - #include <linux/nfs_fs.h> 35 + #include <linux/socket.h> 36 36 #include <linux/quota.h> 37 - #include <linux/sunrpc/svc.h> 38 - #include <linux/nfsd/nfsd.h> 39 - #include <linux/nfsd/cache.h> 40 - #include <linux/nfsd/xdr.h> 41 - #include <linux/nfsd/syscall.h> 42 37 #include <linux/poll.h> 43 38 #include <linux/eventpoll.h> 44 39 #include <linux/personality.h>
+1 -1
arch/ia64/kernel/crash.c
··· 155 155 if (val == DIE_INIT_MONARCH_LEAVE) 156 156 ia64_mca_printk(KERN_NOTICE 157 157 "%s: kdump not configured\n", 158 - __FUNCTION__); 158 + __func__); 159 159 return NOTIFY_DONE; 160 160 } 161 161
+25 -7
arch/ia64/kernel/efi.c
··· 379 379 * a dedicated ITR for the PAL code. 380 380 */ 381 381 if ((vaddr & mask) == (KERNEL_START & mask)) { 382 - printk(KERN_INFO "%s: no need to install ITR for " 383 - "PAL code\n", __FUNCTION__); 382 + printk(KERN_INFO "%s: no need to install ITR for PAL code\n", 383 + __func__); 384 384 continue; 385 385 } 386 386 ··· 399 399 return __va(md->phys_addr); 400 400 } 401 401 printk(KERN_WARNING "%s: no PAL-code memory-descriptor found\n", 402 - __FUNCTION__); 402 + __func__); 403 403 return NULL; 404 404 } 405 405 ··· 543 543 for (i = 0, p = efi_map_start; p < efi_map_end; 544 544 ++i, p += efi_desc_size) 545 545 { 546 + const char *unit; 547 + unsigned long size; 548 + 546 549 md = p; 547 - printk("mem%02u: type=%u, attr=0x%lx, " 548 - "range=[0x%016lx-0x%016lx) (%luMB)\n", 550 + size = md->num_pages << EFI_PAGE_SHIFT; 551 + 552 + if ((size >> 40) > 0) { 553 + size >>= 40; 554 + unit = "TB"; 555 + } else if ((size >> 30) > 0) { 556 + size >>= 30; 557 + unit = "GB"; 558 + } else if ((size >> 20) > 0) { 559 + size >>= 20; 560 + unit = "MB"; 561 + } else { 562 + size >>= 10; 563 + unit = "KB"; 564 + } 565 + 566 + printk("mem%02d: type=%2u, attr=0x%016lx, " 567 + "range=[0x%016lx-0x%016lx) (%4lu%s)\n", 549 568 i, md->type, md->attribute, md->phys_addr, 550 - md->phys_addr + efi_md_size(md), 551 - md->num_pages >> (20 - EFI_PAGE_SHIFT)); 569 + md->phys_addr + efi_md_size(md), size, unit); 552 570 } 553 571 } 554 572 #endif
+12 -12
arch/ia64/kernel/iosapic.c
··· 534 534 if (iosapic_intr_info[irq].count) { 535 535 new_irq = create_irq(); 536 536 if (new_irq < 0) 537 - panic("%s: out of interrupt vectors!\n", __FUNCTION__); 537 + panic("%s: out of interrupt vectors!\n", __func__); 538 538 printk(KERN_INFO "Reassigning vector %d to %d\n", 539 539 irq_to_vector(irq), irq_to_vector(new_irq)); 540 540 memcpy(&iosapic_intr_info[new_irq], &iosapic_intr_info[irq], ··· 599 599 index = find_iosapic(gsi); 600 600 if (index < 0) { 601 601 printk(KERN_WARNING "%s: No IOSAPIC for GSI %u\n", 602 - __FUNCTION__, gsi); 602 + __func__, gsi); 603 603 return -ENODEV; 604 604 } 605 605 ··· 608 608 rte = iosapic_alloc_rte(); 609 609 if (!rte) { 610 610 printk(KERN_WARNING "%s: cannot allocate memory\n", 611 - __FUNCTION__); 611 + __func__); 612 612 return -ENOMEM; 613 613 } 614 614 ··· 625 625 (info->trigger != trigger || info->polarity != polarity)){ 626 626 printk (KERN_WARNING 627 627 "%s: cannot override the interrupt\n", 628 - __FUNCTION__); 628 + __func__); 629 629 return -EINVAL; 630 630 } 631 631 rte->refcnt++; ··· 647 647 if (idesc->chip != &no_irq_type) 648 648 printk(KERN_WARNING 649 649 "%s: changing vector %d from %s to %s\n", 650 - __FUNCTION__, irq_to_vector(irq), 650 + __func__, irq_to_vector(irq), 651 651 idesc->chip->name, irq_type->name); 652 652 idesc->chip = irq_type; 653 653 } ··· 920 920 case ACPI_INTERRUPT_INIT: 921 921 irq = create_irq(); 922 922 if (irq < 0) 923 - panic("%s: out of interrupt vectors!\n", __FUNCTION__); 923 + panic("%s: out of interrupt vectors!\n", __func__); 924 924 vector = irq_to_vector(irq); 925 925 delivery = IOSAPIC_INIT; 926 926 break; ··· 931 931 mask = 1; 932 932 break; 933 933 default: 934 - printk(KERN_ERR "%s: invalid int type 0x%x\n", __FUNCTION__, 934 + printk(KERN_ERR "%s: invalid int type 0x%x\n", __func__, 935 935 int_type); 936 936 return -1; 937 937 } ··· 996 996 */ 997 997 printk(KERN_INFO 998 998 "%s: Disabling PC-AT compatible 8259 interrupts\n", 999 - __FUNCTION__); 999 + __func__); 1000 1000 outb(0xff, 0xA1); 1001 1001 outb(0xff, 0x21); 1002 1002 } ··· 1011 1011 if (!iosapic_lists[index].addr) 1012 1012 return index; 1013 1013 1014 - printk(KERN_WARNING "%s: failed to allocate iosapic\n", __FUNCTION__); 1014 + printk(KERN_WARNING "%s: failed to allocate iosapic\n", __func__); 1015 1015 return -1; 1016 1016 } 1017 1017 ··· 1109 1109 index = find_iosapic(gsi_base); 1110 1110 if (index < 0) { 1111 1111 printk(KERN_WARNING "%s: No IOSAPIC for GSI base %u\n", 1112 - __FUNCTION__, gsi_base); 1112 + __func__, gsi_base); 1113 1113 goto out; 1114 1114 } 1115 1115 1116 1116 if (iosapic_lists[index].rtes_inuse) { 1117 1117 err = -EBUSY; 1118 1118 printk(KERN_WARNING "%s: IOSAPIC for GSI base %u is busy\n", 1119 - __FUNCTION__, gsi_base); 1119 + __func__, gsi_base); 1120 1120 goto out; 1121 1121 } 1122 1122 ··· 1137 1137 index = find_iosapic(gsi_base); 1138 1138 if (index < 0) { 1139 1139 printk(KERN_WARNING "%s: No IOSAPIC for GSI %u\n", 1140 - __FUNCTION__, gsi_base); 1140 + __func__, gsi_base); 1141 1141 return; 1142 1142 } 1143 1143 iosapic_lists[index].node = node;
+2 -6
arch/ia64/kernel/irq_ia64.c
··· 507 507 if (unlikely(irq < 0)) { 508 508 printk(KERN_ERR "%s: Unexpected interrupt " 509 509 "vector %d on CPU %d is not mapped " 510 - "to any IRQ!\n", __FUNCTION__, vector, 510 + "to any IRQ!\n", __func__, vector, 511 511 smp_processor_id()); 512 512 } else 513 513 generic_handle_irq(irq); ··· 572 572 if (unlikely(irq < 0)) { 573 573 printk(KERN_ERR "%s: Unexpected interrupt " 574 574 "vector %d on CPU %d not being mapped " 575 - "to any IRQ!!\n", __FUNCTION__, vector, 575 + "to any IRQ!!\n", __func__, vector, 576 576 smp_processor_id()); 577 577 } else { 578 578 vectors_in_migration[irq]=0; ··· 666 666 unsigned long ipi_data; 667 667 unsigned long phys_cpu_id; 668 668 669 - #ifdef CONFIG_SMP 670 669 phys_cpu_id = cpu_physical_id(cpu); 671 - #else 672 - phys_cpu_id = (ia64_getreg(_IA64_REG_CR_LID) >> 16) & 0xffff; 673 - #endif 674 670 675 671 /* 676 672 * cpu number is in 8bit ID and 8bit EID
+1 -1
arch/ia64/kernel/kprobes.c
··· 838 838 return 1; 839 839 } 840 840 841 - int __kprobes kprobes_fault_handler(struct pt_regs *regs, int trapnr) 841 + int __kprobes kprobe_fault_handler(struct pt_regs *regs, int trapnr) 842 842 { 843 843 struct kprobe *cur = kprobe_running(); 844 844 struct kprobe_ctlblk *kcb = get_kprobe_ctlblk();
+35 -38
arch/ia64/kernel/mca.c
··· 413 413 IA64_LOG_INDEX_INC(sal_info_type); 414 414 IA64_LOG_UNLOCK(sal_info_type); 415 415 if (irq_safe) { 416 - IA64_MCA_DEBUG("%s: SAL error record type %d retrieved. " 417 - "Record length = %ld\n", __FUNCTION__, sal_info_type, total_len); 416 + IA64_MCA_DEBUG("%s: SAL error record type %d retrieved. Record length = %ld\n", 417 + __func__, sal_info_type, total_len); 418 418 } 419 419 *buffer = (u8 *) log_buffer; 420 420 return total_len; ··· 518 518 static DEFINE_SPINLOCK(cpe_history_lock); 519 519 520 520 IA64_MCA_DEBUG("%s: received interrupt vector = %#x on CPU %d\n", 521 - __FUNCTION__, cpe_irq, smp_processor_id()); 521 + __func__, cpe_irq, smp_processor_id()); 522 522 523 523 /* SAL spec states this should run w/ interrupts enabled */ 524 524 local_irq_enable(); ··· 594 594 } 595 595 596 596 IA64_MCA_DEBUG("%s: corrected platform error " 597 - "vector %#x registered\n", __FUNCTION__, cpev); 597 + "vector %#x registered\n", __func__, cpev); 598 598 } 599 599 #endif /* CONFIG_ACPI */ 600 600 ··· 621 621 cmcv.cmcv_vector = IA64_CMC_VECTOR; 622 622 ia64_setreg(_IA64_REG_CR_CMCV, cmcv.cmcv_regval); 623 623 624 - IA64_MCA_DEBUG("%s: CPU %d corrected " 625 - "machine check vector %#x registered.\n", 626 - __FUNCTION__, smp_processor_id(), IA64_CMC_VECTOR); 624 + IA64_MCA_DEBUG("%s: CPU %d corrected machine check vector %#x registered.\n", 625 + __func__, smp_processor_id(), IA64_CMC_VECTOR); 627 626 628 627 IA64_MCA_DEBUG("%s: CPU %d CMCV = %#016lx\n", 629 - __FUNCTION__, smp_processor_id(), ia64_getreg(_IA64_REG_CR_CMCV)); 628 + __func__, smp_processor_id(), ia64_getreg(_IA64_REG_CR_CMCV)); 630 629 } 631 630 632 631 /* ··· 650 651 cmcv.cmcv_mask = 1; /* Mask/disable interrupt */ 651 652 ia64_setreg(_IA64_REG_CR_CMCV, cmcv.cmcv_regval); 652 653 653 - IA64_MCA_DEBUG("%s: CPU %d corrected " 654 - "machine check vector %#x disabled.\n", 655 - __FUNCTION__, smp_processor_id(), cmcv.cmcv_vector); 654 + IA64_MCA_DEBUG("%s: CPU %d corrected machine check vector %#x disabled.\n", 655 + __func__, smp_processor_id(), cmcv.cmcv_vector); 656 656 } 657 657 658 658 /* ··· 676 678 cmcv.cmcv_mask = 0; /* Unmask/enable interrupt */ 677 679 ia64_setreg(_IA64_REG_CR_CMCV, cmcv.cmcv_regval); 678 680 679 - IA64_MCA_DEBUG("%s: CPU %d corrected " 680 - "machine check vector %#x enabled.\n", 681 - __FUNCTION__, smp_processor_id(), cmcv.cmcv_vector); 681 + IA64_MCA_DEBUG("%s: CPU %d corrected machine check vector %#x enabled.\n", 682 + __func__, smp_processor_id(), cmcv.cmcv_vector); 682 683 } 683 684 684 685 /* ··· 764 767 local_irq_save(flags); 765 768 if (notify_die(DIE_MCA_RENDZVOUS_ENTER, "MCA", get_irq_regs(), 766 769 (long)&nd, 0, 0) == NOTIFY_STOP) 767 - ia64_mca_spin(__FUNCTION__); 770 + ia64_mca_spin(__func__); 768 771 769 772 ia64_mc_info.imi_rendez_checkin[cpu] = IA64_MCA_RENDEZ_CHECKIN_DONE; 770 773 /* Register with the SAL monarch that the slave has ··· 774 777 775 778 if (notify_die(DIE_MCA_RENDZVOUS_PROCESS, "MCA", get_irq_regs(), 776 779 (long)&nd, 0, 0) == NOTIFY_STOP) 777 - ia64_mca_spin(__FUNCTION__); 780 + ia64_mca_spin(__func__); 778 781 779 782 /* Wait for the monarch cpu to exit. */ 780 783 while (monarch_cpu != -1) ··· 782 785 783 786 if (notify_die(DIE_MCA_RENDZVOUS_LEAVE, "MCA", get_irq_regs(), 784 787 (long)&nd, 0, 0) == NOTIFY_STOP) 785 - ia64_mca_spin(__FUNCTION__); 788 + ia64_mca_spin(__func__); 786 789 787 790 ia64_mc_info.imi_rendez_checkin[cpu] = IA64_MCA_RENDEZ_CHECKIN_NOTDONE; 788 791 /* Enable all interrupts */ ··· 1227 1230 1228 1231 if (notify_die(DIE_MCA_MONARCH_ENTER, "MCA", regs, (long)&nd, 0, 0) 1229 1232 == NOTIFY_STOP) 1230 - ia64_mca_spin(__FUNCTION__); 1233 + ia64_mca_spin(__func__); 1231 1234 1232 1235 ia64_mc_info.imi_rendez_checkin[cpu] = IA64_MCA_RENDEZ_CHECKIN_CONCURRENT_MCA; 1233 1236 if (sos->monarch) { ··· 1243 1246 ia64_mca_wakeup_all(); 1244 1247 if (notify_die(DIE_MCA_MONARCH_PROCESS, "MCA", regs, (long)&nd, 0, 0) 1245 1248 == NOTIFY_STOP) 1246 - ia64_mca_spin(__FUNCTION__); 1249 + ia64_mca_spin(__func__); 1247 1250 } else { 1248 1251 while (cpu_isset(cpu, mca_cpu)) 1249 1252 cpu_relax(); /* spin until monarch wakes us */ ··· 1273 1276 } 1274 1277 if (notify_die(DIE_MCA_MONARCH_LEAVE, "MCA", regs, (long)&nd, 0, recover) 1275 1278 == NOTIFY_STOP) 1276 - ia64_mca_spin(__FUNCTION__); 1279 + ia64_mca_spin(__func__); 1277 1280 1278 1281 1279 1282 if (atomic_dec_return(&mca_count) > 0) { ··· 1325 1328 static DEFINE_SPINLOCK(cmc_history_lock); 1326 1329 1327 1330 IA64_MCA_DEBUG("%s: received interrupt vector = %#x on CPU %d\n", 1328 - __FUNCTION__, cmc_irq, smp_processor_id()); 1331 + __func__, cmc_irq, smp_processor_id()); 1329 1332 1330 1333 /* SAL spec states this should run w/ interrupts enabled */ 1331 1334 local_irq_enable(); ··· 1611 1614 */ 1612 1615 if (!sos->monarch && atomic_add_return(1, &slaves) == num_online_cpus()) { 1613 1616 mprintk(KERN_WARNING "%s: Promoting cpu %d to monarch.\n", 1614 - __FUNCTION__, cpu); 1617 + __func__, cpu); 1615 1618 atomic_dec(&slaves); 1616 1619 sos->monarch = 1; 1617 1620 } ··· 1623 1626 */ 1624 1627 if (sos->monarch && atomic_add_return(1, &monarchs) > 1) { 1625 1628 mprintk(KERN_WARNING "%s: Demoting cpu %d to slave.\n", 1626 - __FUNCTION__, cpu); 1629 + __func__, cpu); 1627 1630 atomic_dec(&monarchs); 1628 1631 sos->monarch = 0; 1629 1632 } ··· 1634 1637 cpu_relax(); /* spin until monarch enters */ 1635 1638 if (notify_die(DIE_INIT_SLAVE_ENTER, "INIT", regs, (long)&nd, 0, 0) 1636 1639 == NOTIFY_STOP) 1637 - ia64_mca_spin(__FUNCTION__); 1640 + ia64_mca_spin(__func__); 1638 1641 if (notify_die(DIE_INIT_SLAVE_PROCESS, "INIT", regs, (long)&nd, 0, 0) 1639 1642 == NOTIFY_STOP) 1640 - ia64_mca_spin(__FUNCTION__); 1643 + ia64_mca_spin(__func__); 1641 1644 while (monarch_cpu != -1) 1642 1645 cpu_relax(); /* spin until monarch leaves */ 1643 1646 if (notify_die(DIE_INIT_SLAVE_LEAVE, "INIT", regs, (long)&nd, 0, 0) 1644 1647 == NOTIFY_STOP) 1645 - ia64_mca_spin(__FUNCTION__); 1648 + ia64_mca_spin(__func__); 1646 1649 mprintk("Slave on cpu %d returning to normal service.\n", cpu); 1647 1650 set_curr_task(cpu, previous_current); 1648 1651 ia64_mc_info.imi_rendez_checkin[cpu] = IA64_MCA_RENDEZ_CHECKIN_NOTDONE; ··· 1653 1656 monarch_cpu = cpu; 1654 1657 if (notify_die(DIE_INIT_MONARCH_ENTER, "INIT", regs, (long)&nd, 0, 0) 1655 1658 == NOTIFY_STOP) 1656 - ia64_mca_spin(__FUNCTION__); 1659 + ia64_mca_spin(__func__); 1657 1660 1658 1661 /* 1659 1662 * Wait for a bit. On some machines (e.g., HP's zx2000 and zx6000, INIT can be ··· 1670 1673 */ 1671 1674 if (notify_die(DIE_INIT_MONARCH_PROCESS, "INIT", regs, (long)&nd, 0, 0) 1672 1675 == NOTIFY_STOP) 1673 - ia64_mca_spin(__FUNCTION__); 1676 + ia64_mca_spin(__func__); 1674 1677 if (notify_die(DIE_INIT_MONARCH_LEAVE, "INIT", regs, (long)&nd, 0, 0) 1675 1678 == NOTIFY_STOP) 1676 - ia64_mca_spin(__FUNCTION__); 1679 + ia64_mca_spin(__func__); 1677 1680 mprintk("\nINIT dump complete. Monarch on cpu %d returning to normal service.\n", cpu); 1678 1681 atomic_dec(&monarchs); 1679 1682 set_curr_task(cpu, previous_current); ··· 1881 1884 .priority = 0/* we need to notified last */ 1882 1885 }; 1883 1886 1884 - IA64_MCA_DEBUG("%s: begin\n", __FUNCTION__); 1887 + IA64_MCA_DEBUG("%s: begin\n", __func__); 1885 1888 1886 1889 /* Clear the Rendez checkin flag for all cpus */ 1887 1890 for(i = 0 ; i < NR_CPUS; i++) ··· 1925 1928 return; 1926 1929 } 1927 1930 1928 - IA64_MCA_DEBUG("%s: registered MCA rendezvous spinloop and wakeup mech.\n", __FUNCTION__); 1931 + IA64_MCA_DEBUG("%s: registered MCA rendezvous spinloop and wakeup mech.\n", __func__); 1929 1932 1930 1933 ia64_mc_info.imi_mca_handler = ia64_tpa(mca_hldlr_ptr->fp); 1931 1934 /* ··· 1946 1949 return; 1947 1950 } 1948 1951 1949 - IA64_MCA_DEBUG("%s: registered OS MCA handler with SAL at 0x%lx, gp = 0x%lx\n", __FUNCTION__, 1952 + IA64_MCA_DEBUG("%s: registered OS MCA handler with SAL at 0x%lx, gp = 0x%lx\n", __func__, 1950 1953 ia64_mc_info.imi_mca_handler, ia64_tpa(mca_hldlr_ptr->gp)); 1951 1954 1952 1955 /* ··· 1958 1961 ia64_mc_info.imi_slave_init_handler = ia64_tpa(init_hldlr_ptr_slave->fp); 1959 1962 ia64_mc_info.imi_slave_init_handler_size = 0; 1960 1963 1961 - IA64_MCA_DEBUG("%s: OS INIT handler at %lx\n", __FUNCTION__, 1964 + IA64_MCA_DEBUG("%s: OS INIT handler at %lx\n", __func__, 1962 1965 ia64_mc_info.imi_monarch_init_handler); 1963 1966 1964 1967 /* Register the os init handler with SAL */ ··· 1979 1982 return; 1980 1983 } 1981 1984 1982 - IA64_MCA_DEBUG("%s: registered OS INIT handler with SAL\n", __FUNCTION__); 1985 + IA64_MCA_DEBUG("%s: registered OS INIT handler with SAL\n", __func__); 1983 1986 1984 1987 /* 1985 1988 * Configure the CMCI/P vector and handler. Interrupts for CMC are ··· 2039 2042 cmc_polling_enabled = 0; 2040 2043 schedule_work(&cmc_enable_work); 2041 2044 2042 - IA64_MCA_DEBUG("%s: CMCI/P setup and enabled.\n", __FUNCTION__); 2045 + IA64_MCA_DEBUG("%s: CMCI/P setup and enabled.\n", __func__); 2043 2046 2044 2047 #ifdef CONFIG_ACPI 2045 2048 /* Setup the CPEI/P vector and handler */ ··· 2062 2065 ia64_cpe_irq = irq; 2063 2066 ia64_mca_register_cpev(cpe_vector); 2064 2067 IA64_MCA_DEBUG("%s: CPEI/P setup and enabled.\n", 2065 - __FUNCTION__); 2068 + __func__); 2066 2069 return 0; 2067 2070 } 2068 2071 printk(KERN_ERR "%s: Failed to find irq for CPE " 2069 2072 "interrupt handler, vector %d\n", 2070 - __FUNCTION__, cpe_vector); 2073 + __func__, cpe_vector); 2071 2074 } 2072 2075 /* If platform doesn't support CPEI, get the timer going. */ 2073 2076 if (cpe_poll_enabled) { 2074 2077 ia64_mca_cpe_poll(0UL); 2075 - IA64_MCA_DEBUG("%s: CPEP setup and enabled.\n", __FUNCTION__); 2078 + IA64_MCA_DEBUG("%s: CPEP setup and enabled.\n", __func__); 2076 2079 } 2077 2080 } 2078 2081 #endif
+11 -11
arch/ia64/kernel/module.c
··· 493 493 mod->arch.opd->sh_addralign = 8; 494 494 mod->arch.opd->sh_size = fdescs * sizeof(struct fdesc); 495 495 DEBUGP("%s: core.plt=%lx, init.plt=%lx, got=%lx, fdesc=%lx\n", 496 - __FUNCTION__, mod->arch.core_plt->sh_size, mod->arch.init_plt->sh_size, 496 + __func__, mod->arch.core_plt->sh_size, mod->arch.init_plt->sh_size, 497 497 mod->arch.got->sh_size, mod->arch.opd->sh_size); 498 498 return 0; 499 499 } ··· 585 585 #if ARCH_MODULE_DEBUG 586 586 if (plt_target(plt) != target_ip) { 587 587 printk("%s: mistargeted PLT: wanted %lx, got %lx\n", 588 - __FUNCTION__, target_ip, plt_target(plt)); 588 + __func__, target_ip, plt_target(plt)); 589 589 *okp = 0; 590 590 return 0; 591 591 } ··· 703 703 if (r_type == R_IA64_PCREL21BI) { 704 704 if (!is_internal(mod, val)) { 705 705 printk(KERN_ERR "%s: %s reloc against non-local symbol (%lx)\n", 706 - __FUNCTION__, reloc_name[r_type], val); 706 + __func__, reloc_name[r_type], val); 707 707 return -ENOEXEC; 708 708 } 709 709 format = RF_INSN21B; ··· 737 737 case R_IA64_LDXMOV: 738 738 if (gp_addressable(mod, val)) { 739 739 /* turn "ld8" into "mov": */ 740 - DEBUGP("%s: patching ld8 at %p to mov\n", __FUNCTION__, location); 740 + DEBUGP("%s: patching ld8 at %p to mov\n", __func__, location); 741 741 ia64_patch((u64) location, 0x1fff80fe000UL, 0x10000000000UL); 742 742 } 743 743 return 0; ··· 771 771 if (!ok) 772 772 return -ENOEXEC; 773 773 774 - DEBUGP("%s: [%p]<-%016lx = %s(%lx)\n", __FUNCTION__, location, val, 774 + DEBUGP("%s: [%p]<-%016lx = %s(%lx)\n", __func__, location, val, 775 775 reloc_name[r_type] ? reloc_name[r_type] : "?", sym->st_value + addend); 776 776 777 777 switch (format) { ··· 807 807 Elf64_Shdr *target_sec; 808 808 int ret; 809 809 810 - DEBUGP("%s: applying section %u (%u relocs) to %u\n", __FUNCTION__, 810 + DEBUGP("%s: applying section %u (%u relocs) to %u\n", __func__, 811 811 relsec, n, sechdrs[relsec].sh_info); 812 812 813 813 target_sec = sechdrs + sechdrs[relsec].sh_info; ··· 835 835 gp = mod->core_size / 2; 836 836 gp = (uint64_t) mod->module_core + ((gp + 7) & -8); 837 837 mod->arch.gp = gp; 838 - DEBUGP("%s: placing gp at 0x%lx\n", __FUNCTION__, gp); 838 + DEBUGP("%s: placing gp at 0x%lx\n", __func__, gp); 839 839 } 840 840 841 841 for (i = 0; i < n; i++) { ··· 903 903 init = start + num_core; 904 904 } 905 905 906 - DEBUGP("%s: name=%s, gp=%lx, num_init=%lu, num_core=%lu\n", __FUNCTION__, 906 + DEBUGP("%s: name=%s, gp=%lx, num_init=%lu, num_core=%lu\n", __func__, 907 907 mod->name, mod->arch.gp, num_init, num_core); 908 908 909 909 /* ··· 912 912 if (num_core > 0) { 913 913 mod->arch.core_unw_table = unw_add_unwind_table(mod->name, 0, mod->arch.gp, 914 914 core, core + num_core); 915 - DEBUGP("%s: core: handle=%p [%p-%p)\n", __FUNCTION__, 915 + DEBUGP("%s: core: handle=%p [%p-%p)\n", __func__, 916 916 mod->arch.core_unw_table, core, core + num_core); 917 917 } 918 918 if (num_init > 0) { 919 919 mod->arch.init_unw_table = unw_add_unwind_table(mod->name, 0, mod->arch.gp, 920 920 init, init + num_init); 921 - DEBUGP("%s: init: handle=%p [%p-%p)\n", __FUNCTION__, 921 + DEBUGP("%s: init: handle=%p [%p-%p)\n", __func__, 922 922 mod->arch.init_unw_table, init, init + num_init); 923 923 } 924 924 } ··· 926 926 int 927 927 module_finalize (const Elf_Ehdr *hdr, const Elf_Shdr *sechdrs, struct module *mod) 928 928 { 929 - DEBUGP("%s: init: entry=%p\n", __FUNCTION__, mod->init); 929 + DEBUGP("%s: init: entry=%p\n", __func__, mod->init); 930 930 if (mod->arch.unwind) 931 931 register_unwind_table(mod); 932 932 return 0;
+2 -2
arch/ia64/kernel/perfmon.c
··· 227 227 #ifdef PFM_DEBUGGING 228 228 #define DPRINT(a) \ 229 229 do { \ 230 - if (unlikely(pfm_sysctl.debug >0)) { printk("%s.%d: CPU%d [%d] ", __FUNCTION__, __LINE__, smp_processor_id(), task_pid_nr(current)); printk a; } \ 230 + if (unlikely(pfm_sysctl.debug >0)) { printk("%s.%d: CPU%d [%d] ", __func__, __LINE__, smp_processor_id(), task_pid_nr(current)); printk a; } \ 231 231 } while (0) 232 232 233 233 #define DPRINT_ovfl(a) \ 234 234 do { \ 235 - if (unlikely(pfm_sysctl.debug > 0 && pfm_sysctl.debug_ovfl >0)) { printk("%s.%d: CPU%d [%d] ", __FUNCTION__, __LINE__, smp_processor_id(), task_pid_nr(current)); printk a; } \ 235 + if (unlikely(pfm_sysctl.debug > 0 && pfm_sysctl.debug_ovfl >0)) { printk("%s.%d: CPU%d [%d] ", __func__, __LINE__, smp_processor_id(), task_pid_nr(current)); printk a; } \ 236 236 } while (0) 237 237 #endif 238 238
+2 -2
arch/ia64/kernel/perfmon_default_smpl.c
··· 24 24 #ifdef DEFAULT_DEBUG 25 25 #define DPRINT(a) \ 26 26 do { \ 27 - if (unlikely(pfm_sysctl.debug >0)) { printk("%s.%d: CPU%d ", __FUNCTION__, __LINE__, smp_processor_id()); printk a; } \ 27 + if (unlikely(pfm_sysctl.debug >0)) { printk("%s.%d: CPU%d ", __func__, __LINE__, smp_processor_id()); printk a; } \ 28 28 } while (0) 29 29 30 30 #define DPRINT_ovfl(a) \ 31 31 do { \ 32 - if (unlikely(pfm_sysctl.debug > 0 && pfm_sysctl.debug_ovfl >0)) { printk("%s.%d: CPU%d ", __FUNCTION__, __LINE__, smp_processor_id()); printk a; } \ 32 + if (unlikely(pfm_sysctl.debug > 0 && pfm_sysctl.debug_ovfl >0)) { printk("%s.%d: CPU%d ", __func__, __LINE__, smp_processor_id()); printk a; } \ 33 33 } while (0) 34 34 35 35 #else
+74 -259
arch/ia64/kernel/ptrace.c
··· 698 698 } 699 699 700 700 /* 701 - * GDB apparently wants to be able to read the register-backing store 702 - * of any thread when attached to a given process. If we are peeking 703 - * or poking an address that happens to reside in the kernel-backing 704 - * store of another thread, we need to attach to that thread, because 705 - * otherwise we end up accessing stale data. 706 - * 707 - * task_list_lock must be read-locked before calling this routine! 708 - */ 709 - static struct task_struct * 710 - find_thread_for_addr (struct task_struct *child, unsigned long addr) 711 - { 712 - struct task_struct *p; 713 - struct mm_struct *mm; 714 - struct list_head *this, *next; 715 - int mm_users; 716 - 717 - if (!(mm = get_task_mm(child))) 718 - return child; 719 - 720 - /* -1 because of our get_task_mm(): */ 721 - mm_users = atomic_read(&mm->mm_users) - 1; 722 - if (mm_users <= 1) 723 - goto out; /* not multi-threaded */ 724 - 725 - /* 726 - * Traverse the current process' children list. Every task that 727 - * one attaches to becomes a child. And it is only attached children 728 - * of the debugger that are of interest (ptrace_check_attach checks 729 - * for this). 730 - */ 731 - list_for_each_safe(this, next, &current->children) { 732 - p = list_entry(this, struct task_struct, sibling); 733 - if (p->tgid != child->tgid) 734 - continue; 735 - if (thread_matches(p, addr)) { 736 - child = p; 737 - goto out; 738 - } 739 - } 740 - 741 - out: 742 - mmput(mm); 743 - return child; 744 - } 745 - 746 - /* 747 701 * Write f32-f127 back to task->thread.fph if it has been modified. 748 702 */ 749 703 inline void ··· 780 826 if ((long)((unsigned long)child + IA64_STK_OFFSET - sp) 781 827 < IA64_PT_REGS_SIZE) { 782 828 dprintk("ptrace.%s: ran off the top of the kernel " 783 - "stack\n", __FUNCTION__); 829 + "stack\n", __func__); 784 830 return; 785 831 } 786 832 if (unw_get_pr (&prev_info, &pr) < 0) { 787 833 unw_get_rp(&prev_info, &ip); 788 834 dprintk("ptrace.%s: failed to read " 789 835 "predicate register (ip=0x%lx)\n", 790 - __FUNCTION__, ip); 836 + __func__, ip); 791 837 return; 792 838 } 793 839 if (unw_is_intr_frame(&info) ··· 862 908 access_uarea (struct task_struct *child, unsigned long addr, 863 909 unsigned long *data, int write_access) 864 910 { 865 - unsigned long *ptr, regnum, urbs_end, rnat_addr, cfm; 911 + unsigned long *ptr, regnum, urbs_end, cfm; 866 912 struct switch_stack *sw; 867 913 struct pt_regs *pt; 868 914 # define pt_reg_addr(pt, reg) ((void *) \ ··· 965 1011 * the kernel was entered. 966 1012 * 967 1013 * Furthermore, when changing the contents of 968 - * PT_AR_BSP (or PT_CFM) we MUST copy any 969 - * users-level stacked registers that are 970 - * stored on the kernel stack back to 971 - * user-space because otherwise, we might end 972 - * up clobbering kernel stacked registers. 973 - * Also, if this happens while the task is 974 - * blocked in a system call, which convert the 975 - * state such that the non-system-call exit 1014 + * PT_AR_BSP (or PT_CFM) while the task is 1015 + * blocked in a system call, convert the state 1016 + * so that the non-system-call exit 976 1017 * path is used. This ensures that the proper 977 1018 * state will be picked up when resuming 978 1019 * execution. However, it *also* means that ··· 984 1035 urbs_end = ia64_get_user_rbs_end(child, pt, &cfm); 985 1036 if (write_access) { 986 1037 if (*data != urbs_end) { 987 - if (ia64_sync_user_rbs(child, sw, 988 - pt->ar_bspstore, 989 - urbs_end) < 0) 990 - return -1; 991 1038 if (in_syscall(pt)) 992 1039 convert_to_non_syscall(child, 993 1040 pt, ··· 1003 1058 urbs_end = ia64_get_user_rbs_end(child, pt, &cfm); 1004 1059 if (write_access) { 1005 1060 if (((cfm ^ *data) & PFM_MASK) != 0) { 1006 - if (ia64_sync_user_rbs(child, sw, 1007 - pt->ar_bspstore, 1008 - urbs_end) < 0) 1009 - return -1; 1010 1061 if (in_syscall(pt)) 1011 1062 convert_to_non_syscall(child, 1012 1063 pt, ··· 1034 1093 return 0; 1035 1094 1036 1095 case PT_AR_RNAT: 1037 - urbs_end = ia64_get_user_rbs_end(child, pt, NULL); 1038 - rnat_addr = (long) ia64_rse_rnat_addr((long *) 1039 - urbs_end); 1040 - if (write_access) 1041 - return ia64_poke(child, sw, urbs_end, 1042 - rnat_addr, *data); 1043 - else 1044 - return ia64_peek(child, sw, urbs_end, 1045 - rnat_addr, data); 1046 - 1096 + ptr = pt_reg_addr(pt, ar_rnat); 1097 + break; 1047 1098 case PT_R1: 1048 1099 ptr = pt_reg_addr(pt, r1); 1049 1100 break; ··· 1454 1521 return ret; 1455 1522 } 1456 1523 1457 - /* 1458 - * Called by kernel/ptrace.c when detaching.. 1459 - * 1460 - * Make sure the single step bit is not set. 1461 - */ 1462 1524 void 1463 - ptrace_disable (struct task_struct *child) 1525 + user_enable_single_step (struct task_struct *child) 1526 + { 1527 + struct ia64_psr *child_psr = ia64_psr(task_pt_regs(child)); 1528 + 1529 + set_tsk_thread_flag(child, TIF_SINGLESTEP); 1530 + child_psr->ss = 1; 1531 + } 1532 + 1533 + void 1534 + user_enable_block_step (struct task_struct *child) 1535 + { 1536 + struct ia64_psr *child_psr = ia64_psr(task_pt_regs(child)); 1537 + 1538 + set_tsk_thread_flag(child, TIF_SINGLESTEP); 1539 + child_psr->tb = 1; 1540 + } 1541 + 1542 + void 1543 + user_disable_single_step (struct task_struct *child) 1464 1544 { 1465 1545 struct ia64_psr *child_psr = ia64_psr(task_pt_regs(child)); 1466 1546 ··· 1483 1537 child_psr->tb = 0; 1484 1538 } 1485 1539 1486 - asmlinkage long 1487 - sys_ptrace (long request, pid_t pid, unsigned long addr, unsigned long data) 1540 + /* 1541 + * Called by kernel/ptrace.c when detaching.. 1542 + * 1543 + * Make sure the single step bit is not set. 1544 + */ 1545 + void 1546 + ptrace_disable (struct task_struct *child) 1488 1547 { 1489 - struct pt_regs *pt; 1490 - unsigned long urbs_end, peek_or_poke; 1491 - struct task_struct *child; 1492 - struct switch_stack *sw; 1493 - long ret; 1494 - struct unw_frame_info info; 1548 + user_disable_single_step(child); 1549 + } 1495 1550 1496 - lock_kernel(); 1497 - ret = -EPERM; 1498 - if (request == PTRACE_TRACEME) { 1499 - ret = ptrace_traceme(); 1500 - goto out; 1501 - } 1502 - 1503 - peek_or_poke = (request == PTRACE_PEEKTEXT 1504 - || request == PTRACE_PEEKDATA 1505 - || request == PTRACE_POKETEXT 1506 - || request == PTRACE_POKEDATA); 1507 - ret = -ESRCH; 1508 - read_lock(&tasklist_lock); 1509 - { 1510 - child = find_task_by_pid(pid); 1511 - if (child) { 1512 - if (peek_or_poke) 1513 - child = find_thread_for_addr(child, addr); 1514 - get_task_struct(child); 1515 - } 1516 - } 1517 - read_unlock(&tasklist_lock); 1518 - if (!child) 1519 - goto out; 1520 - ret = -EPERM; 1521 - if (pid == 1) /* no messing around with init! */ 1522 - goto out_tsk; 1523 - 1524 - if (request == PTRACE_ATTACH) { 1525 - ret = ptrace_attach(child); 1526 - if (!ret) 1527 - arch_ptrace_attach(child); 1528 - goto out_tsk; 1529 - } 1530 - 1531 - ret = ptrace_check_attach(child, request == PTRACE_KILL); 1532 - if (ret < 0) 1533 - goto out_tsk; 1534 - 1535 - pt = task_pt_regs(child); 1536 - sw = (struct switch_stack *) (child->thread.ksp + 16); 1537 - 1551 + long 1552 + arch_ptrace (struct task_struct *child, long request, long addr, long data) 1553 + { 1538 1554 switch (request) { 1539 - case PTRACE_PEEKTEXT: 1540 - case PTRACE_PEEKDATA: 1555 + case PTRACE_PEEKTEXT: 1556 + case PTRACE_PEEKDATA: 1541 1557 /* read word at location addr */ 1542 - urbs_end = ia64_get_user_rbs_end(child, pt, NULL); 1543 - ret = ia64_peek(child, sw, urbs_end, addr, &data); 1544 - if (ret == 0) { 1545 - ret = data; 1546 - /* ensure "ret" is not mistaken as an error code: */ 1547 - force_successful_syscall_return(); 1548 - } 1549 - goto out_tsk; 1550 - 1551 - case PTRACE_POKETEXT: 1552 - case PTRACE_POKEDATA: 1553 - /* write the word at location addr */ 1554 - urbs_end = ia64_get_user_rbs_end(child, pt, NULL); 1555 - ret = ia64_poke(child, sw, urbs_end, addr, data); 1556 - 1557 - /* Make sure user RBS has the latest data */ 1558 - unw_init_from_blocked_task(&info, child); 1559 - do_sync_rbs(&info, ia64_sync_user_rbs); 1560 - 1561 - goto out_tsk; 1562 - 1563 - case PTRACE_PEEKUSR: 1564 - /* read the word at addr in the USER area */ 1565 - if (access_uarea(child, addr, &data, 0) < 0) { 1566 - ret = -EIO; 1567 - goto out_tsk; 1568 - } 1569 - ret = data; 1570 - /* ensure "ret" is not mistaken as an error code */ 1558 + if (access_process_vm(child, addr, &data, sizeof(data), 0) 1559 + != sizeof(data)) 1560 + return -EIO; 1561 + /* ensure return value is not mistaken for error code */ 1571 1562 force_successful_syscall_return(); 1572 - goto out_tsk; 1563 + return data; 1573 1564 1574 - case PTRACE_POKEUSR: 1565 + /* PTRACE_POKETEXT and PTRACE_POKEDATA is handled 1566 + * by the generic ptrace_request(). 1567 + */ 1568 + 1569 + case PTRACE_PEEKUSR: 1570 + /* read the word at addr in the USER area */ 1571 + if (access_uarea(child, addr, &data, 0) < 0) 1572 + return -EIO; 1573 + /* ensure return value is not mistaken for error code */ 1574 + force_successful_syscall_return(); 1575 + return data; 1576 + 1577 + case PTRACE_POKEUSR: 1575 1578 /* write the word at addr in the USER area */ 1576 - if (access_uarea(child, addr, &data, 1) < 0) { 1577 - ret = -EIO; 1578 - goto out_tsk; 1579 - } 1580 - ret = 0; 1581 - goto out_tsk; 1579 + if (access_uarea(child, addr, &data, 1) < 0) 1580 + return -EIO; 1581 + return 0; 1582 1582 1583 - case PTRACE_OLD_GETSIGINFO: 1583 + case PTRACE_OLD_GETSIGINFO: 1584 1584 /* for backwards-compatibility */ 1585 - ret = ptrace_request(child, PTRACE_GETSIGINFO, addr, data); 1586 - goto out_tsk; 1585 + return ptrace_request(child, PTRACE_GETSIGINFO, addr, data); 1587 1586 1588 - case PTRACE_OLD_SETSIGINFO: 1587 + case PTRACE_OLD_SETSIGINFO: 1589 1588 /* for backwards-compatibility */ 1590 - ret = ptrace_request(child, PTRACE_SETSIGINFO, addr, data); 1591 - goto out_tsk; 1589 + return ptrace_request(child, PTRACE_SETSIGINFO, addr, data); 1592 1590 1593 - case PTRACE_SYSCALL: 1594 - /* continue and stop at next (return from) syscall */ 1595 - case PTRACE_CONT: 1596 - /* restart after signal. */ 1597 - ret = -EIO; 1598 - if (!valid_signal(data)) 1599 - goto out_tsk; 1600 - if (request == PTRACE_SYSCALL) 1601 - set_tsk_thread_flag(child, TIF_SYSCALL_TRACE); 1602 - else 1603 - clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); 1604 - child->exit_code = data; 1591 + case PTRACE_GETREGS: 1592 + return ptrace_getregs(child, 1593 + (struct pt_all_user_regs __user *) data); 1605 1594 1606 - /* 1607 - * Make sure the single step/taken-branch trap bits 1608 - * are not set: 1609 - */ 1610 - clear_tsk_thread_flag(child, TIF_SINGLESTEP); 1611 - ia64_psr(pt)->ss = 0; 1612 - ia64_psr(pt)->tb = 0; 1595 + case PTRACE_SETREGS: 1596 + return ptrace_setregs(child, 1597 + (struct pt_all_user_regs __user *) data); 1613 1598 1614 - wake_up_process(child); 1615 - ret = 0; 1616 - goto out_tsk; 1617 - 1618 - case PTRACE_KILL: 1619 - /* 1620 - * Make the child exit. Best I can do is send it a 1621 - * sigkill. Perhaps it should be put in the status 1622 - * that it wants to exit. 1623 - */ 1624 - if (child->exit_state == EXIT_ZOMBIE) 1625 - /* already dead */ 1626 - goto out_tsk; 1627 - child->exit_code = SIGKILL; 1628 - 1629 - ptrace_disable(child); 1630 - wake_up_process(child); 1631 - ret = 0; 1632 - goto out_tsk; 1633 - 1634 - case PTRACE_SINGLESTEP: 1635 - /* let child execute for one instruction */ 1636 - case PTRACE_SINGLEBLOCK: 1637 - ret = -EIO; 1638 - if (!valid_signal(data)) 1639 - goto out_tsk; 1640 - 1641 - clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); 1642 - set_tsk_thread_flag(child, TIF_SINGLESTEP); 1643 - if (request == PTRACE_SINGLESTEP) { 1644 - ia64_psr(pt)->ss = 1; 1645 - } else { 1646 - ia64_psr(pt)->tb = 1; 1647 - } 1648 - child->exit_code = data; 1649 - 1650 - /* give it a chance to run. */ 1651 - wake_up_process(child); 1652 - ret = 0; 1653 - goto out_tsk; 1654 - 1655 - case PTRACE_DETACH: 1656 - /* detach a process that was attached. */ 1657 - ret = ptrace_detach(child, data); 1658 - goto out_tsk; 1659 - 1660 - case PTRACE_GETREGS: 1661 - ret = ptrace_getregs(child, 1662 - (struct pt_all_user_regs __user *) data); 1663 - goto out_tsk; 1664 - 1665 - case PTRACE_SETREGS: 1666 - ret = ptrace_setregs(child, 1667 - (struct pt_all_user_regs __user *) data); 1668 - goto out_tsk; 1669 - 1670 - default: 1671 - ret = ptrace_request(child, request, addr, data); 1672 - goto out_tsk; 1599 + default: 1600 + return ptrace_request(child, request, addr, data); 1673 1601 } 1674 - out_tsk: 1675 - put_task_struct(child); 1676 - out: 1677 - unlock_kernel(); 1678 - return ret; 1679 1602 } 1680 1603 1681 1604
+4 -4
arch/ia64/kernel/setup.c
··· 690 690 if (overflow++ == 0) 691 691 printk(KERN_ERR 692 692 "%s: Table overflow. Some processor model information will be missing\n", 693 - __FUNCTION__); 693 + __func__); 694 694 return "Unknown"; 695 695 } 696 696 ··· 785 785 status = ia64_pal_cache_summary(&levels, &unique_caches); 786 786 if (status != 0) { 787 787 printk(KERN_ERR "%s: ia64_pal_cache_summary() failed (status=%ld)\n", 788 - __FUNCTION__, status); 788 + __func__, status); 789 789 max = SMP_CACHE_BYTES; 790 790 /* Safest setup for "flush_icache_range()" */ 791 791 ia64_i_cache_stride_shift = I_CACHE_STRIDE_SHIFT; ··· 798 798 if (status != 0) { 799 799 printk(KERN_ERR 800 800 "%s: ia64_pal_cache_config_info(l=%lu, 2) failed (status=%ld)\n", 801 - __FUNCTION__, l, status); 801 + __func__, l, status); 802 802 max = SMP_CACHE_BYTES; 803 803 /* The safest setup for "flush_icache_range()" */ 804 804 cci.pcci_stride = I_CACHE_STRIDE_SHIFT; ··· 814 814 if (status != 0) { 815 815 printk(KERN_ERR 816 816 "%s: ia64_pal_cache_config_info(l=%lu, 1) failed (status=%ld)\n", 817 - __FUNCTION__, l, status); 817 + __func__, l, status); 818 818 /* The safest setup for "flush_icache_range()" */ 819 819 cci.pcci_stride = I_CACHE_STRIDE_SHIFT; 820 820 }
+3 -3
arch/ia64/kernel/unaligned.c
··· 28 28 #undef DEBUG_UNALIGNED_TRAP 29 29 30 30 #ifdef DEBUG_UNALIGNED_TRAP 31 - # define DPRINT(a...) do { printk("%s %u: ", __FUNCTION__, __LINE__); printk (a); } while (0) 31 + # define DPRINT(a...) do { printk("%s %u: ", __func__, __LINE__); printk (a); } while (0) 32 32 # define DDUMP(str,vp,len) dump(str, vp, len) 33 33 34 34 static void ··· 674 674 * just in case. 675 675 */ 676 676 if (ld.x6_op == 1 || ld.x6_op == 3) { 677 - printk(KERN_ERR "%s: register update on speculative load, error\n", __FUNCTION__); 677 + printk(KERN_ERR "%s: register update on speculative load, error\n", __func__); 678 678 if (die_if_kernel("unaligned reference on speculative load with register update\n", 679 679 regs, 30)) 680 680 return; ··· 1104 1104 */ 1105 1105 if (ld.x6_op == 1 || ld.x6_op == 3) 1106 1106 printk(KERN_ERR "%s: register update on speculative load pair, error\n", 1107 - __FUNCTION__); 1107 + __func__); 1108 1108 1109 1109 setreg(ld.r3, ifa, 0, regs); 1110 1110 }
+51 -51
arch/ia64/kernel/unwind.c
··· 257 257 off = unw.pt_regs_offsets[reg]; 258 258 259 259 if (off < 0) { 260 - UNW_DPRINT(0, "unwind.%s: bad scratch reg r%lu\n", __FUNCTION__, reg); 260 + UNW_DPRINT(0, "unwind.%s: bad scratch reg r%lu\n", __func__, reg); 261 261 off = 0; 262 262 } 263 263 return (unsigned long) off; ··· 268 268 { 269 269 if (!info->pt) { 270 270 /* This should not happen with valid unwind info. */ 271 - UNW_DPRINT(0, "unwind.%s: bad unwind info: resetting info->pt\n", __FUNCTION__); 271 + UNW_DPRINT(0, "unwind.%s: bad unwind info: resetting info->pt\n", __func__); 272 272 if (info->flags & UNW_FLAG_INTERRUPT_FRAME) 273 273 info->pt = (unsigned long) ((struct pt_regs *) info->psp - 1); 274 274 else 275 275 info->pt = info->sp - 16; 276 276 } 277 - UNW_DPRINT(3, "unwind.%s: sp 0x%lx pt 0x%lx\n", __FUNCTION__, info->sp, info->pt); 277 + UNW_DPRINT(3, "unwind.%s: sp 0x%lx pt 0x%lx\n", __func__, info->sp, info->pt); 278 278 return (struct pt_regs *) info->pt; 279 279 } 280 280 ··· 294 294 return 0; 295 295 } 296 296 UNW_DPRINT(0, "unwind.%s: trying to access non-existent r%u\n", 297 - __FUNCTION__, regnum); 297 + __func__, regnum); 298 298 return -1; 299 299 } 300 300 ··· 341 341 { 342 342 UNW_DPRINT(0, "unwind.%s: %p outside of regstk " 343 343 "[0x%lx-0x%lx)\n", 344 - __FUNCTION__, (void *) addr, 344 + __func__, (void *) addr, 345 345 info->regstk.limit, 346 346 info->regstk.top); 347 347 return -1; ··· 374 374 || (unsigned long) addr >= info->regstk.top) 375 375 { 376 376 UNW_DPRINT(0, "unwind.%s: ignoring attempt to access register outside " 377 - "of rbs\n", __FUNCTION__); 377 + "of rbs\n", __func__); 378 378 return -1; 379 379 } 380 380 if ((unsigned long) nat_addr >= info->regstk.top) ··· 385 385 if (write) { 386 386 if (read_only(addr)) { 387 387 UNW_DPRINT(0, "unwind.%s: ignoring attempt to write read-only location\n", 388 - __FUNCTION__); 388 + __func__); 389 389 } else { 390 390 *addr = *val; 391 391 if (*nat) ··· 427 427 428 428 default: 429 429 UNW_DPRINT(0, "unwind.%s: trying to access non-existent b%u\n", 430 - __FUNCTION__, regnum); 430 + __func__, regnum); 431 431 return -1; 432 432 } 433 433 if (write) 434 434 if (read_only(addr)) { 435 435 UNW_DPRINT(0, "unwind.%s: ignoring attempt to write read-only location\n", 436 - __FUNCTION__); 436 + __func__); 437 437 } else 438 438 *addr = *val; 439 439 else ··· 450 450 451 451 if ((unsigned) (regnum - 2) >= 126) { 452 452 UNW_DPRINT(0, "unwind.%s: trying to access non-existent f%u\n", 453 - __FUNCTION__, regnum); 453 + __func__, regnum); 454 454 return -1; 455 455 } 456 456 ··· 482 482 if (write) 483 483 if (read_only(addr)) { 484 484 UNW_DPRINT(0, "unwind.%s: ignoring attempt to write read-only location\n", 485 - __FUNCTION__); 485 + __func__); 486 486 } else 487 487 *addr = *val; 488 488 else ··· 572 572 573 573 default: 574 574 UNW_DPRINT(0, "unwind.%s: trying to access non-existent ar%u\n", 575 - __FUNCTION__, regnum); 575 + __func__, regnum); 576 576 return -1; 577 577 } 578 578 579 579 if (write) { 580 580 if (read_only(addr)) { 581 581 UNW_DPRINT(0, "unwind.%s: ignoring attempt to write read-only location\n", 582 - __FUNCTION__); 582 + __func__); 583 583 } else 584 584 *addr = *val; 585 585 } else ··· 600 600 if (write) { 601 601 if (read_only(addr)) { 602 602 UNW_DPRINT(0, "unwind.%s: ignoring attempt to write read-only location\n", 603 - __FUNCTION__); 603 + __func__); 604 604 } else 605 605 *addr = *val; 606 606 } else ··· 699 699 default: 700 700 break; 701 701 } 702 - UNW_DPRINT(0, "unwind.%s: bad abreg=0x%x\n", __FUNCTION__, abreg); 702 + UNW_DPRINT(0, "unwind.%s: bad abreg=0x%x\n", __func__, abreg); 703 703 return UNW_REG_LC; 704 704 } 705 705 ··· 739 739 return; 740 740 } 741 741 } 742 - UNW_DPRINT(0, "unwind.%s: excess spill!\n", __FUNCTION__); 742 + UNW_DPRINT(0, "unwind.%s: excess spill!\n", __func__); 743 743 } 744 744 745 745 static inline void ··· 855 855 { 856 856 if (abi == 3 && context == 'i') { 857 857 sr->flags |= UNW_FLAG_INTERRUPT_FRAME; 858 - UNW_DPRINT(3, "unwind.%s: interrupt frame\n", __FUNCTION__); 858 + UNW_DPRINT(3, "unwind.%s: interrupt frame\n", __func__); 859 859 } 860 860 else 861 861 UNW_DPRINT(0, "unwind%s: ignoring unwabi(abi=0x%x,context=0x%x)\n", 862 - __FUNCTION__, abi, context); 862 + __func__, abi, context); 863 863 } 864 864 865 865 static inline void ··· 1347 1347 { 1348 1348 if (script->count >= UNW_MAX_SCRIPT_LEN) { 1349 1349 UNW_DPRINT(0, "unwind.%s: script exceeds maximum size of %u instructions!\n", 1350 - __FUNCTION__, UNW_MAX_SCRIPT_LEN); 1350 + __func__, UNW_MAX_SCRIPT_LEN); 1351 1351 return; 1352 1352 } 1353 1353 script->insn[script->count++] = insn; ··· 1389 1389 1390 1390 default: 1391 1391 UNW_DPRINT(0, "unwind.%s: don't know how to emit nat info for where = %u\n", 1392 - __FUNCTION__, r->where); 1392 + __func__, r->where); 1393 1393 return; 1394 1394 } 1395 1395 insn.opc = opc; ··· 1446 1446 val = offsetof(struct pt_regs, f6) + 16*(rval - 6); 1447 1447 else 1448 1448 UNW_DPRINT(0, "unwind.%s: kernel may not touch f%lu\n", 1449 - __FUNCTION__, rval); 1449 + __func__, rval); 1450 1450 } 1451 1451 break; 1452 1452 ··· 1474 1474 1475 1475 default: 1476 1476 UNW_DPRINT(0, "unwind%s: register %u has unexpected `where' value of %u\n", 1477 - __FUNCTION__, i, r->where); 1477 + __func__, i, r->where); 1478 1478 break; 1479 1479 } 1480 1480 insn.opc = opc; ··· 1547 1547 r->when = UNW_WHEN_NEVER; 1548 1548 sr.pr_val = info->pr; 1549 1549 1550 - UNW_DPRINT(3, "unwind.%s: ip 0x%lx\n", __FUNCTION__, ip); 1550 + UNW_DPRINT(3, "unwind.%s: ip 0x%lx\n", __func__, ip); 1551 1551 script = script_new(ip); 1552 1552 if (!script) { 1553 - UNW_DPRINT(0, "unwind.%s: failed to create unwind script\n", __FUNCTION__); 1553 + UNW_DPRINT(0, "unwind.%s: failed to create unwind script\n", __func__); 1554 1554 STAT(unw.stat.script.build_time += ia64_get_itc() - start); 1555 1555 return NULL; 1556 1556 } ··· 1569 1569 if (!e) { 1570 1570 /* no info, return default unwinder (leaf proc, no mem stack, no saved regs) */ 1571 1571 UNW_DPRINT(1, "unwind.%s: no unwind info for ip=0x%lx (prev ip=0x%lx)\n", 1572 - __FUNCTION__, ip, unw.cache[info->prev_script].ip); 1572 + __func__, ip, unw.cache[info->prev_script].ip); 1573 1573 sr.curr.reg[UNW_REG_RP].where = UNW_WHERE_BR; 1574 1574 sr.curr.reg[UNW_REG_RP].when = -1; 1575 1575 sr.curr.reg[UNW_REG_RP].val = 0; ··· 1618 1618 sr.curr.reg[UNW_REG_RP].when = -1; 1619 1619 sr.curr.reg[UNW_REG_RP].val = sr.return_link_reg; 1620 1620 UNW_DPRINT(1, "unwind.%s: using default for rp at ip=0x%lx where=%d val=0x%lx\n", 1621 - __FUNCTION__, ip, sr.curr.reg[UNW_REG_RP].where, 1621 + __func__, ip, sr.curr.reg[UNW_REG_RP].where, 1622 1622 sr.curr.reg[UNW_REG_RP].val); 1623 1623 } 1624 1624 1625 1625 #ifdef UNW_DEBUG 1626 1626 UNW_DPRINT(1, "unwind.%s: state record for func 0x%lx, t=%u:\n", 1627 - __FUNCTION__, table->segment_base + e->start_offset, sr.when_target); 1627 + __func__, table->segment_base + e->start_offset, sr.when_target); 1628 1628 for (r = sr.curr.reg; r < sr.curr.reg + UNW_NUM_REGS; ++r) { 1629 1629 if (r->where != UNW_WHERE_NONE || r->when != UNW_WHEN_NEVER) { 1630 1630 UNW_DPRINT(1, " %s <- ", unw.preg_name[r - sr.curr.reg]); ··· 1746 1746 } else { 1747 1747 s[dst] = 0; 1748 1748 UNW_DPRINT(0, "unwind.%s: no state->pt, dst=%ld, val=%ld\n", 1749 - __FUNCTION__, dst, val); 1749 + __func__, dst, val); 1750 1750 } 1751 1751 break; 1752 1752 ··· 1756 1756 else { 1757 1757 s[dst] = 0; 1758 1758 UNW_DPRINT(0, "unwind.%s: UNW_INSN_MOVE_CONST bad val=%ld\n", 1759 - __FUNCTION__, val); 1759 + __func__, val); 1760 1760 } 1761 1761 break; 1762 1762 ··· 1791 1791 || s[val] < TASK_SIZE) 1792 1792 { 1793 1793 UNW_DPRINT(0, "unwind.%s: rejecting bad psp=0x%lx\n", 1794 - __FUNCTION__, s[val]); 1794 + __func__, s[val]); 1795 1795 break; 1796 1796 } 1797 1797 #endif ··· 1825 1825 if ((info->ip & (local_cpu_data->unimpl_va_mask | 0xf)) || info->ip < TASK_SIZE) { 1826 1826 /* don't let obviously bad addresses pollute the cache */ 1827 1827 /* FIXME: should really be level 0 but it occurs too often. KAO */ 1828 - UNW_DPRINT(1, "unwind.%s: rejecting bad ip=0x%lx\n", __FUNCTION__, info->ip); 1828 + UNW_DPRINT(1, "unwind.%s: rejecting bad ip=0x%lx\n", __func__, info->ip); 1829 1829 info->rp_loc = NULL; 1830 1830 return -1; 1831 1831 } ··· 1838 1838 spin_unlock_irqrestore(&unw.lock, flags); 1839 1839 UNW_DPRINT(0, 1840 1840 "unwind.%s: failed to locate/build unwind script for ip %lx\n", 1841 - __FUNCTION__, info->ip); 1841 + __func__, info->ip); 1842 1842 return -1; 1843 1843 } 1844 1844 have_write_lock = 1; ··· 1882 1882 if (!unw_valid(info, info->rp_loc)) { 1883 1883 /* FIXME: should really be level 0 but it occurs too often. KAO */ 1884 1884 UNW_DPRINT(1, "unwind.%s: failed to locate return link (ip=0x%lx)!\n", 1885 - __FUNCTION__, info->ip); 1885 + __func__, info->ip); 1886 1886 STAT(unw.stat.api.unwind_time += ia64_get_itc() - start; local_irq_restore(flags)); 1887 1887 return -1; 1888 1888 } 1889 1889 /* restore the ip */ 1890 1890 ip = info->ip = *info->rp_loc; 1891 1891 if (ip < GATE_ADDR) { 1892 - UNW_DPRINT(2, "unwind.%s: reached user-space (ip=0x%lx)\n", __FUNCTION__, ip); 1892 + UNW_DPRINT(2, "unwind.%s: reached user-space (ip=0x%lx)\n", __func__, ip); 1893 1893 STAT(unw.stat.api.unwind_time += ia64_get_itc() - start; local_irq_restore(flags)); 1894 1894 return -1; 1895 1895 } 1896 1896 1897 1897 /* validate the previous stack frame pointer */ 1898 1898 if (!unw_valid(info, info->pfs_loc)) { 1899 - UNW_DPRINT(0, "unwind.%s: failed to locate ar.pfs!\n", __FUNCTION__); 1899 + UNW_DPRINT(0, "unwind.%s: failed to locate ar.pfs!\n", __func__); 1900 1900 STAT(unw.stat.api.unwind_time += ia64_get_itc() - start; local_irq_restore(flags)); 1901 1901 return -1; 1902 1902 } ··· 1912 1912 num_regs = *info->cfm_loc & 0x7f; /* size of frame */ 1913 1913 info->pfs_loc = 1914 1914 (unsigned long *) (info->pt + offsetof(struct pt_regs, ar_pfs)); 1915 - UNW_DPRINT(3, "unwind.%s: interrupt_frame pt 0x%lx\n", __FUNCTION__, info->pt); 1915 + UNW_DPRINT(3, "unwind.%s: interrupt_frame pt 0x%lx\n", __func__, info->pt); 1916 1916 } else 1917 1917 num_regs = (*info->cfm_loc >> 7) & 0x7f; /* size of locals */ 1918 1918 info->bsp = (unsigned long) ia64_rse_skip_regs((unsigned long *) info->bsp, -num_regs); 1919 1919 if (info->bsp < info->regstk.limit || info->bsp > info->regstk.top) { 1920 1920 UNW_DPRINT(0, "unwind.%s: bsp (0x%lx) out of range [0x%lx-0x%lx]\n", 1921 - __FUNCTION__, info->bsp, info->regstk.limit, info->regstk.top); 1921 + __func__, info->bsp, info->regstk.limit, info->regstk.top); 1922 1922 STAT(unw.stat.api.unwind_time += ia64_get_itc() - start; local_irq_restore(flags)); 1923 1923 return -1; 1924 1924 } ··· 1927 1927 info->sp = info->psp; 1928 1928 if (info->sp < info->memstk.top || info->sp > info->memstk.limit) { 1929 1929 UNW_DPRINT(0, "unwind.%s: sp (0x%lx) out of range [0x%lx-0x%lx]\n", 1930 - __FUNCTION__, info->sp, info->memstk.top, info->memstk.limit); 1930 + __func__, info->sp, info->memstk.top, info->memstk.limit); 1931 1931 STAT(unw.stat.api.unwind_time += ia64_get_itc() - start; local_irq_restore(flags)); 1932 1932 return -1; 1933 1933 } 1934 1934 1935 1935 if (info->ip == prev_ip && info->sp == prev_sp && info->bsp == prev_bsp) { 1936 1936 UNW_DPRINT(0, "unwind.%s: ip, sp, bsp unchanged; stopping here (ip=0x%lx)\n", 1937 - __FUNCTION__, ip); 1937 + __func__, ip); 1938 1938 STAT(unw.stat.api.unwind_time += ia64_get_itc() - start; local_irq_restore(flags)); 1939 1939 return -1; 1940 1940 } ··· 1961 1961 if ((long)((unsigned long)info->task + IA64_STK_OFFSET - sp) 1962 1962 < IA64_PT_REGS_SIZE) { 1963 1963 UNW_DPRINT(0, "unwind.%s: ran off the top of the kernel stack\n", 1964 - __FUNCTION__); 1964 + __func__); 1965 1965 break; 1966 1966 } 1967 1967 if (unw_is_intr_frame(info) && ··· 1971 1971 unw_get_rp(info, &ip); 1972 1972 UNW_DPRINT(0, "unwind.%s: failed to read " 1973 1973 "predicate register (ip=0x%lx)\n", 1974 - __FUNCTION__, ip); 1974 + __func__, ip); 1975 1975 return -1; 1976 1976 } 1977 1977 } while (unw_unwind(info) >= 0); 1978 1978 unw_get_ip(info, &ip); 1979 1979 UNW_DPRINT(0, "unwind.%s: failed to unwind to user-level (ip=0x%lx)\n", 1980 - __FUNCTION__, ip); 1980 + __func__, ip); 1981 1981 return -1; 1982 1982 } 1983 1983 EXPORT_SYMBOL(unw_unwind_to_user); ··· 2028 2028 " pr 0x%lx\n" 2029 2029 " sw 0x%lx\n" 2030 2030 " sp 0x%lx\n", 2031 - __FUNCTION__, (unsigned long) t, rbslimit, rbstop, stktop, stklimit, 2031 + __func__, (unsigned long) t, rbslimit, rbstop, stktop, stklimit, 2032 2032 info->pr, (unsigned long) info->sw, info->sp); 2033 2033 STAT(unw.stat.api.init_time += ia64_get_itc() - start; local_irq_restore(flags)); 2034 2034 } ··· 2047 2047 " bsp 0x%lx\n" 2048 2048 " sol 0x%lx\n" 2049 2049 " ip 0x%lx\n", 2050 - __FUNCTION__, info->bsp, sol, info->ip); 2050 + __func__, info->bsp, sol, info->ip); 2051 2051 find_save_locs(info); 2052 2052 } 2053 2053 ··· 2058 2058 { 2059 2059 struct switch_stack *sw = (struct switch_stack *) (t->thread.ksp + 16); 2060 2060 2061 - UNW_DPRINT(1, "unwind.%s\n", __FUNCTION__); 2061 + UNW_DPRINT(1, "unwind.%s\n", __func__); 2062 2062 unw_init_frame_info(info, t, sw); 2063 2063 } 2064 2064 EXPORT_SYMBOL(unw_init_from_blocked_task); ··· 2088 2088 2089 2089 if (end - start <= 0) { 2090 2090 UNW_DPRINT(0, "unwind.%s: ignoring attempt to insert empty unwind table\n", 2091 - __FUNCTION__); 2091 + __func__); 2092 2092 return NULL; 2093 2093 } 2094 2094 ··· 2119 2119 2120 2120 if (!handle) { 2121 2121 UNW_DPRINT(0, "unwind.%s: ignoring attempt to remove non-existent unwind table\n", 2122 - __FUNCTION__); 2122 + __func__); 2123 2123 return; 2124 2124 } 2125 2125 2126 2126 table = handle; 2127 2127 if (table == &unw.kernel_table) { 2128 2128 UNW_DPRINT(0, "unwind.%s: sorry, freeing the kernel's unwind table is a " 2129 - "no-can-do!\n", __FUNCTION__); 2129 + "no-can-do!\n", __func__); 2130 2130 return; 2131 2131 } 2132 2132 ··· 2139 2139 break; 2140 2140 if (!prev) { 2141 2141 UNW_DPRINT(0, "unwind.%s: failed to find unwind table %p\n", 2142 - __FUNCTION__, (void *) table); 2142 + __func__, (void *) table); 2143 2143 spin_unlock_irqrestore(&unw.lock, flags); 2144 2144 return; 2145 2145 } ··· 2185 2185 } 2186 2186 2187 2187 if (!punw) { 2188 - printk("%s: failed to find gate DSO's unwind table!\n", __FUNCTION__); 2188 + printk("%s: failed to find gate DSO's unwind table!\n", __func__); 2189 2189 return 0; 2190 2190 } 2191 2191 ··· 2202 2202 unw.gate_table = kmalloc(size, GFP_KERNEL); 2203 2203 if (!unw.gate_table) { 2204 2204 unw.gate_table_size = 0; 2205 - printk(KERN_ERR "%s: unable to create unwind data for gate page!\n", __FUNCTION__); 2205 + printk(KERN_ERR "%s: unable to create unwind data for gate page!\n", __func__); 2206 2206 return 0; 2207 2207 } 2208 2208 unw.gate_table_size = size;
+1 -1
arch/ia64/mm/fault.c
··· 26 26 if (!user_mode(regs)) { 27 27 /* kprobe_running() needs smp_processor_id() */ 28 28 preempt_disable(); 29 - if (kprobe_running() && kprobes_fault_handler(regs, trap)) 29 + if (kprobe_running() && kprobe_fault_handler(regs, trap)) 30 30 ret = 1; 31 31 preempt_enable(); 32 32 }
+1 -1
arch/ia64/mm/init.c
··· 714 714 715 715 if (ret) 716 716 printk("%s: Problem encountered in __add_pages() as ret=%d\n", 717 - __FUNCTION__, ret); 717 + __func__, ret); 718 718 719 719 return ret; 720 720 }
+1 -1
arch/ia64/pci/fixup.c
··· 63 63 pci_read_config_word(pdev, PCI_COMMAND, &config); 64 64 if (config & (PCI_COMMAND_IO | PCI_COMMAND_MEMORY)) { 65 65 pdev->resource[PCI_ROM_RESOURCE].flags |= IORESOURCE_ROM_SHADOW; 66 - printk(KERN_DEBUG "Boot video device is %s\n", pci_name(pdev)); 66 + dev_printk(KERN_DEBUG, &pdev->dev, "Boot video device\n"); 67 67 } 68 68 } 69 69 DECLARE_PCI_FIXUP_HEADER(PCI_ANY_ID, PCI_ANY_ID, pci_fixup_video);
+2 -2
arch/ia64/pci/pci.c
··· 765 765 status = ia64_pal_cache_summary(&levels, &unique_caches); 766 766 if (status != 0) { 767 767 printk(KERN_ERR "%s: ia64_pal_cache_summary() failed " 768 - "(status=%ld)\n", __FUNCTION__, status); 768 + "(status=%ld)\n", __func__, status); 769 769 return; 770 770 } 771 771 ··· 773 773 /* cache_type (data_or_unified)= */ 2, &cci); 774 774 if (status != 0) { 775 775 printk(KERN_ERR "%s: ia64_pal_cache_config_info() failed " 776 - "(status=%ld)\n", __FUNCTION__, status); 776 + "(status=%ld)\n", __func__, status); 777 777 return; 778 778 } 779 779 pci_cache_line_size = (1 << cci.pcci_line_size) / 4;
+2 -2
arch/ia64/sn/kernel/huberror.c
··· 37 37 (u64) nasid, 0, 0, 0, 0, 0, 0); 38 38 39 39 if ((int)ret_stuff.v0) 40 - panic("%s: Fatal %s Error", __FUNCTION__, 40 + panic("%s: Fatal %s Error", __func__, 41 41 ((nasid & 1) ? "TIO" : "HUBII")); 42 42 43 43 if (!(nasid & 1)) /* Not a TIO, handle CRB errors */ ··· 48 48 (u64) nasid, 0, 0, 0, 0, 0, 0); 49 49 50 50 if ((int)ret_stuff.v0) 51 - panic("%s: Fatal TIO Error", __FUNCTION__); 51 + panic("%s: Fatal TIO Error", __func__); 52 52 } else 53 53 bte_error_handler((unsigned long)NODEPDA(nasid_to_cnodeid(nasid))); 54 54
+18 -18
arch/ia64/sn/kernel/io_acpi_init.c
··· 133 133 if (ACPI_FAILURE(status)) { 134 134 printk(KERN_ERR "%s: " 135 135 "acpi_get_vendor_resource() failed (0x%x) for: ", 136 - __FUNCTION__, status); 136 + __func__, status); 137 137 acpi_ns_print_node_pathname(handle, NULL); 138 138 printk("\n"); 139 139 return NULL; ··· 145 145 sizeof(struct pcibus_bussoft *)) { 146 146 printk(KERN_ERR 147 147 "%s: Invalid vendor data length %d\n", 148 - __FUNCTION__, vendor->byte_length); 148 + __func__, vendor->byte_length); 149 149 kfree(buffer.pointer); 150 150 return NULL; 151 151 } ··· 184 184 if (ACPI_FAILURE(status)) { 185 185 printk(KERN_ERR 186 186 "%s: acpi_get_vendor_resource() failed (0x%x) for: ", 187 - __FUNCTION__, status); 187 + __func__, status); 188 188 acpi_ns_print_node_pathname(handle, NULL); 189 189 printk("\n"); 190 190 return 1; ··· 196 196 sizeof(struct pci_devdev_info *)) { 197 197 printk(KERN_ERR 198 198 "%s: Invalid vendor data length: %d for: ", 199 - __FUNCTION__, vendor->byte_length); 199 + __func__, vendor->byte_length); 200 200 acpi_ns_print_node_pathname(handle, NULL); 201 201 printk("\n"); 202 202 ret = 1; ··· 205 205 206 206 pcidev_ptr = kzalloc(sizeof(struct pcidev_info), GFP_KERNEL); 207 207 if (!pcidev_ptr) 208 - panic("%s: Unable to alloc memory for pcidev_info", __FUNCTION__); 208 + panic("%s: Unable to alloc memory for pcidev_info", __func__); 209 209 210 210 memcpy(&addr, vendor->byte_data, sizeof(struct pcidev_info *)); 211 211 pcidev_prom_ptr = __va(addr); ··· 214 214 /* Get the IRQ info */ 215 215 irq_info = kzalloc(sizeof(struct sn_irq_info), GFP_KERNEL); 216 216 if (!irq_info) 217 - panic("%s: Unable to alloc memory for sn_irq_info", __FUNCTION__); 217 + panic("%s: Unable to alloc memory for sn_irq_info", __func__); 218 218 219 219 if (pcidev_ptr->pdi_sn_irq_info) { 220 220 irq_info_prom = __va(pcidev_ptr->pdi_sn_irq_info); ··· 249 249 status = acpi_get_parent(child, &parent); 250 250 if (ACPI_FAILURE(status)) { 251 251 printk(KERN_ERR "%s: acpi_get_parent() failed " 252 - "(0x%x) for: ", __FUNCTION__, status); 252 + "(0x%x) for: ", __func__, status); 253 253 acpi_ns_print_node_pathname(child, NULL); 254 254 printk("\n"); 255 - panic("%s: Unable to find host devfn\n", __FUNCTION__); 255 + panic("%s: Unable to find host devfn\n", __func__); 256 256 } 257 257 if (parent == rootbus_handle) 258 258 break; ··· 260 260 } 261 261 if (!child) { 262 262 printk(KERN_ERR "%s: Unable to find root bus for: ", 263 - __FUNCTION__); 263 + __func__); 264 264 acpi_ns_print_node_pathname(device_handle, NULL); 265 265 printk("\n"); 266 266 BUG(); ··· 269 269 status = acpi_evaluate_integer(child, METHOD_NAME__ADR, NULL, &adr); 270 270 if (ACPI_FAILURE(status)) { 271 271 printk(KERN_ERR "%s: Unable to get _ADR (0x%x) for: ", 272 - __FUNCTION__, status); 272 + __func__, status); 273 273 acpi_ns_print_node_pathname(child, NULL); 274 274 printk("\n"); 275 - panic("%s: Unable to find host devfn\n", __FUNCTION__); 275 + panic("%s: Unable to find host devfn\n", __func__); 276 276 } 277 277 278 278 slot = (adr >> 16) & 0xffff; ··· 308 308 if (ACPI_FAILURE(status)) { 309 309 printk(KERN_ERR 310 310 "%s: acpi_get_parent() failed (0x%x) for: ", 311 - __FUNCTION__, status); 311 + __func__, status); 312 312 acpi_ns_print_node_pathname(handle, NULL); 313 313 printk("\n"); 314 314 return AE_OK; ··· 318 318 if (ACPI_FAILURE(status)) { 319 319 printk(KERN_ERR 320 320 "%s: Failed to find _BBN in parent of: ", 321 - __FUNCTION__); 321 + __func__); 322 322 acpi_ns_print_node_pathname(handle, NULL); 323 323 printk("\n"); 324 324 return AE_OK; ··· 358 358 if (segment != pci_domain_nr(dev)) { 359 359 printk(KERN_ERR 360 360 "%s: Segment number mismatch, 0x%lx vs 0x%x for: ", 361 - __FUNCTION__, segment, pci_domain_nr(dev)); 361 + __func__, segment, pci_domain_nr(dev)); 362 362 acpi_ns_print_node_pathname(rootbus_handle, NULL); 363 363 printk("\n"); 364 364 return 1; 365 365 } 366 366 } else { 367 367 printk(KERN_ERR "%s: Unable to get __SEG from: ", 368 - __FUNCTION__); 368 + __func__); 369 369 acpi_ns_print_node_pathname(rootbus_handle, NULL); 370 370 printk("\n"); 371 371 return 1; ··· 386 386 if (!pcidev_match.handle) { 387 387 printk(KERN_ERR 388 388 "%s: Could not find matching ACPI device for %s.\n", 389 - __FUNCTION__, pci_name(dev)); 389 + __func__, pci_name(dev)); 390 390 return 1; 391 391 } 392 392 ··· 422 422 423 423 if (sn_acpi_get_pcidev_info(dev, &pcidev_info, &sn_irq_info)) { 424 424 panic("%s: Failure obtaining pcidev_info for %s\n", 425 - __FUNCTION__, pci_name(dev)); 425 + __func__, pci_name(dev)); 426 426 } 427 427 428 428 if (pcidev_info->pdi_pio_mapped_addr[PCI_ROM_RESOURCE]) { ··· 463 463 printk(KERN_ERR 464 464 "%s: 0x%04x:0x%02x Unable to " 465 465 "obtain prom_bussoft_ptr\n", 466 - __FUNCTION__, pci_domain_nr(bus), bus->number); 466 + __func__, pci_domain_nr(bus), bus->number); 467 467 return; 468 468 } 469 469 sn_common_bus_fixup(bus, prom_bussoft_ptr);
+1 -1
arch/ia64/sn/kernel/io_common.c
··· 364 364 365 365 element = kzalloc(sizeof(struct sysdata_el), GFP_KERNEL); 366 366 if (!element) { 367 - dev_dbg(&dev->dev, "%s: out of memory!\n", __FUNCTION__); 367 + dev_dbg(&dev->dev, "%s: out of memory!\n", __func__); 368 368 return; 369 369 } 370 370 element->sysdata = SN_PCIDEV_INFO(dev);
+2 -2
arch/ia64/sn/kernel/io_init.c
··· 209 209 210 210 pcidev_info = kzalloc(sizeof(struct pcidev_info), GFP_KERNEL); 211 211 if (!pcidev_info) 212 - panic("%s: Unable to alloc memory for pcidev_info", __FUNCTION__); 212 + panic("%s: Unable to alloc memory for pcidev_info", __func__); 213 213 214 214 sn_irq_info = kzalloc(sizeof(struct sn_irq_info), GFP_KERNEL); 215 215 if (!sn_irq_info) 216 - panic("%s: Unable to alloc memory for sn_irq_info", __FUNCTION__); 216 + panic("%s: Unable to alloc memory for sn_irq_info", __func__); 217 217 218 218 /* Call to retrieve pci device information needed by kernel. */ 219 219 status = sal_get_pcidev_info((u64) pci_domain_nr(dev),
+1 -1
arch/ia64/sn/kernel/mca.c
··· 100 100 if (!newbuf) { 101 101 mutex_unlock(&sn_oemdata_mutex); 102 102 printk(KERN_ERR "%s: unable to extend sn_oemdata\n", 103 - __FUNCTION__); 103 + __func__); 104 104 return 1; 105 105 } 106 106 vfree(*sn_oemdata);
+3 -3
arch/ia64/sn/pci/pci_dma.c
··· 116 116 *dma_handle = provider->dma_map_consistent(pdev, phys_addr, size, 117 117 SN_DMA_ADDR_PHYS); 118 118 if (!*dma_handle) { 119 - printk(KERN_ERR "%s: out of ATEs\n", __FUNCTION__); 119 + printk(KERN_ERR "%s: out of ATEs\n", __func__); 120 120 free_pages((unsigned long)cpuaddr, get_order(size)); 121 121 return NULL; 122 122 } ··· 179 179 phys_addr = __pa(cpu_addr); 180 180 dma_addr = provider->dma_map(pdev, phys_addr, size, SN_DMA_ADDR_PHYS); 181 181 if (!dma_addr) { 182 - printk(KERN_ERR "%s: out of ATEs\n", __FUNCTION__); 182 + printk(KERN_ERR "%s: out of ATEs\n", __func__); 183 183 return 0; 184 184 } 185 185 return dma_addr; ··· 266 266 SN_DMA_ADDR_PHYS); 267 267 268 268 if (!sg->dma_address) { 269 - printk(KERN_ERR "%s: out of ATEs\n", __FUNCTION__); 269 + printk(KERN_ERR "%s: out of ATEs\n", __func__); 270 270 271 271 /* 272 272 * Free any successfully allocated entries.
+6 -6
arch/ia64/sn/pci/tioca_provider.c
··· 88 88 break; 89 89 default: 90 90 printk(KERN_ERR "%s: Invalid CA_APERATURE_SIZE " 91 - "0x%lx\n", __FUNCTION__, (ulong) CA_APERATURE_SIZE); 91 + "0x%lx\n", __func__, (ulong) CA_APERATURE_SIZE); 92 92 return -1; 93 93 } 94 94 ··· 124 124 if (!tmp) { 125 125 printk(KERN_ERR "%s: Could not allocate " 126 126 "%lu bytes (order %d) for GART\n", 127 - __FUNCTION__, 127 + __func__, 128 128 tioca_kern->ca_gart_size, 129 129 get_order(tioca_kern->ca_gart_size)); 130 130 return -ENOMEM; ··· 341 341 342 342 if (node_upper > 64) { 343 343 printk(KERN_ERR "%s: coretalk addr 0x%p node id out " 344 - "of range\n", __FUNCTION__, (void *)ct_addr); 344 + "of range\n", __func__, (void *)ct_addr); 345 345 return 0; 346 346 } 347 347 ··· 349 349 if (node_upper != (agp_dma_extn >> CA_AGP_DMA_NODE_ID_SHFT)) { 350 350 printk(KERN_ERR "%s: coretalk upper node (%u) " 351 351 "mismatch with ca_agp_dma_addr_extn (%lu)\n", 352 - __FUNCTION__, 352 + __func__, 353 353 node_upper, (agp_dma_extn >> CA_AGP_DMA_NODE_ID_SHFT)); 354 354 return 0; 355 355 } ··· 597 597 if (is_shub1() && sn_sal_rev() < 0x0406) { 598 598 printk 599 599 (KERN_ERR "%s: SGI prom rev 4.06 or greater required " 600 - "for tioca support\n", __FUNCTION__); 600 + "for tioca support\n", __func__); 601 601 return NULL; 602 602 } 603 603 ··· 651 651 printk(KERN_WARNING 652 652 "%s: Unable to get irq %d. " 653 653 "Error interrupts won't be routed for TIOCA bus %d\n", 654 - __FUNCTION__, SGI_TIOCA_ERROR, 654 + __func__, SGI_TIOCA_ERROR, 655 655 (int)tioca_common->ca_common.bs_persist_busnum); 656 656 657 657 sn_set_err_irq_affinity(SGI_TIOCA_ERROR);
+2 -2
arch/ia64/sn/pci/tioce_provider.c
··· 494 494 if (&map->ce_dmamap_list == &ce_kern->ce_dmamap_list) { 495 495 printk(KERN_WARNING 496 496 "%s: %s - no map found for bus_addr 0x%lx\n", 497 - __FUNCTION__, pci_name(pdev), bus_addr); 497 + __func__, pci_name(pdev), bus_addr); 498 498 } else if (--map->refcnt == 0) { 499 499 for (i = 0; i < map->ate_count; i++) { 500 500 map->ate_shadow[i] = 0; ··· 1030 1030 "%s: Unable to get irq %d. " 1031 1031 "Error interrupts won't be routed for " 1032 1032 "TIOCE bus %04x:%02x\n", 1033 - __FUNCTION__, SGI_PCIASIC_ERROR, 1033 + __func__, SGI_PCIASIC_ERROR, 1034 1034 tioce_common->ce_pcibus.bs_persist_segment, 1035 1035 tioce_common->ce_pcibus.bs_persist_busnum); 1036 1036
+1 -1
include/asm-ia64/kprobes.h
··· 117 117 unsigned short slot; 118 118 }; 119 119 120 - extern int kprobes_fault_handler(struct pt_regs *regs, int trapnr); 120 + extern int kprobe_fault_handler(struct pt_regs *regs, int trapnr); 121 121 extern int kprobe_exceptions_notify(struct notifier_block *self, 122 122 unsigned long val, void *data); 123 123
+7 -2
include/asm-ia64/ptrace.h
··· 233 233 #include <asm/current.h> 234 234 #include <asm/page.h> 235 235 236 - #define __ARCH_SYS_PTRACE 1 237 - 238 236 /* 239 237 * We use the ia64_psr(regs)->ri to determine which of the three 240 238 * instructions in bundle (16 bytes) took the sample. Generate ··· 311 313 extern void ptrace_attach_sync_user_rbs (struct task_struct *); 312 314 #define arch_ptrace_attach(child) \ 313 315 ptrace_attach_sync_user_rbs(child) 316 + 317 + #define arch_has_single_step() (1) 318 + extern void user_enable_single_step(struct task_struct *); 319 + extern void user_disable_single_step(struct task_struct *); 320 + 321 + #define arch_has_block_step() (1) 322 + extern void user_enable_block_step(struct task_struct *); 314 323 315 324 #endif /* !__KERNEL__ */ 316 325