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

Merge branch 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc

* 'merge' of git://git.kernel.org/pub/scm/linux/kernel/git/benh/powerpc:
serial: Add 16850 uart type support to OF uart driver
hvc_console: Remove tty->low_latency
powerpc: Get the number of SLBs from "slb-size" property
powerpc: is_hugepage_only_range() must account for both 4kB and 64kB slices
powerpc/ps3: printing fixups for l64 to ll64 conversion drivers/video
powerpc/ps3: Printing fixups for l64 to ll64 conversion drivers/scsi
powerpc/ps3: Printing fixups for l64 to ll64 conversion drivers/ps3
powerpc/ps3: Printing fixups for l64 to ll64 conversion sound/ppc
powerpc/ps3: Printing fixups for l64 to ll64 conversion drivers/char
powerpc/ps3: Printing fixups for l64 to ll64 conversion drivers/block
powerpc/ps3: Printing fixups for l64 to ll64 conversion arch/powerpc
powerpc/ps3: ps3_repository_read_mm_info() takes u64 * arguments
powerpc/ps3: clear_bit()/set_bit() operate on unsigned longs
powerpc/ps3: The lv1_ routines have u64 parameters
powerpc/ps3: Use dma_addr_t down through the stack
powerpc/ps3: set_dabr() takes an unsigned long
powerpc: Cleanup from l64 to ll64 change drivers/scsi

+196 -168
+4 -4
arch/powerpc/include/asm/ps3.h
··· 103 103 int (*map)(struct ps3_dma_region *, 104 104 unsigned long virt_addr, 105 105 unsigned long len, 106 - unsigned long *bus_addr, 106 + dma_addr_t *bus_addr, 107 107 u64 iopte_pp); 108 108 int (*unmap)(struct ps3_dma_region *, 109 - unsigned long bus_addr, 109 + dma_addr_t bus_addr, 110 110 unsigned long len); 111 111 }; 112 112 /** ··· 124 124 int ps3_dma_region_create(struct ps3_dma_region *r); 125 125 int ps3_dma_region_free(struct ps3_dma_region *r); 126 126 int ps3_dma_map(struct ps3_dma_region *r, unsigned long virt_addr, 127 - unsigned long len, unsigned long *bus_addr, 127 + unsigned long len, dma_addr_t *bus_addr, 128 128 u64 iopte_pp); 129 - int ps3_dma_unmap(struct ps3_dma_region *r, unsigned long bus_addr, 129 + int ps3_dma_unmap(struct ps3_dma_region *r, dma_addr_t bus_addr, 130 130 unsigned long len); 131 131 132 132 /* mmio routines */
+5
arch/powerpc/kernel/prom.c
··· 590 590 { 591 591 u32 *slb_size_ptr; 592 592 593 + slb_size_ptr = of_get_flat_dt_prop(node, "slb-size", NULL); 594 + if (slb_size_ptr != NULL) { 595 + mmu_slb_size = *slb_size_ptr; 596 + return; 597 + } 593 598 slb_size_ptr = of_get_flat_dt_prop(node, "ibm,slb-size", NULL); 594 599 if (slb_size_ptr != NULL) { 595 600 mmu_slb_size = *slb_size_ptr;
+10 -1
arch/powerpc/mm/slice.c
··· 710 710 unsigned long len) 711 711 { 712 712 struct slice_mask mask, available; 713 + unsigned int psize = mm->context.user_psize; 713 714 714 715 mask = slice_range_to_mask(addr, len); 715 - available = slice_mask_for_size(mm, mm->context.user_psize); 716 + available = slice_mask_for_size(mm, psize); 717 + #ifdef CONFIG_PPC_64K_PAGES 718 + /* We need to account for 4k slices too */ 719 + if (psize == MMU_PAGE_64K) { 720 + struct slice_mask compat_mask; 721 + compat_mask = slice_mask_for_size(mm, MMU_PAGE_4K); 722 + or_mask(available, compat_mask); 723 + } 724 + #endif 716 725 717 726 #if 0 /* too verbose */ 718 727 slice_dbg("is_hugepage_only_range(mm=%p, addr=%lx, len=%lx)\n",
+13 -13
arch/powerpc/platforms/ps3/device-init.c
··· 82 82 goto fail_rights; 83 83 } 84 84 85 - pr_debug("%s:%d: pu_id %lu, rights %lu(%lxh)\n", 85 + pr_debug("%s:%d: pu_id %llu, rights %llu(%llxh)\n", 86 86 __func__, __LINE__, dev->lpm.pu_id, dev->lpm.rights, 87 87 dev->lpm.rights); 88 88 ··· 348 348 return -ENODEV; 349 349 } 350 350 351 - pr_debug("%s:%u: (%u:%u:%u): port %lu blk_size %lu num_blocks %lu " 351 + pr_debug("%s:%u: (%u:%u:%u): port %llu blk_size %llu num_blocks %llu " 352 352 "num_regions %u\n", __func__, __LINE__, repo->bus_index, 353 353 repo->dev_index, repo->dev_type, port, blk_size, num_blocks, 354 354 num_regions); ··· 394 394 result = -ENODEV; 395 395 goto fail_read_region; 396 396 } 397 - pr_debug("%s:%u: region %u: id %u start %lu size %lu\n", 397 + pr_debug("%s:%u: region %u: id %u start %llu size %llu\n", 398 398 __func__, __LINE__, i, id, start, size); 399 399 400 400 p->regions[i].id = id; ··· 662 662 if (rem) 663 663 break; 664 664 } 665 - pr_warning("%s:%u: device %lu:%lu not found\n", __func__, __LINE__, 665 + pr_warning("%s:%u: device %llu:%llu not found\n", __func__, __LINE__, 666 666 bus_id, dev_id); 667 667 return; 668 668 669 669 found: 670 670 if (retries) 671 - pr_debug("%s:%u: device %lu:%lu found after %u retries\n", 671 + pr_debug("%s:%u: device %llu:%llu found after %u retries\n", 672 672 __func__, __LINE__, bus_id, dev_id, retries); 673 673 674 674 ps3_setup_dynamic_device(&repo); ··· 715 715 res = lv1_storage_get_async_status(PS3_NOTIFICATION_DEV_ID, &tag, 716 716 &status); 717 717 if (tag != dev->tag) 718 - pr_err("%s:%u: tag mismatch, got %lx, expected %lx\n", 718 + pr_err("%s:%u: tag mismatch, got %llx, expected %llx\n", 719 719 __func__, __LINE__, tag, dev->tag); 720 720 721 721 if (res) { 722 - pr_err("%s:%u: res %d status 0x%lx\n", __func__, __LINE__, res, 722 + pr_err("%s:%u: res %d status 0x%llx\n", __func__, __LINE__, res, 723 723 status); 724 724 } else { 725 - pr_debug("%s:%u: completed, status 0x%lx\n", __func__, 725 + pr_debug("%s:%u: completed, status 0x%llx\n", __func__, 726 726 __LINE__, status); 727 727 dev->lv1_status = status; 728 728 complete(&dev->done); ··· 761 761 } 762 762 763 763 if (dev->lv1_status) { 764 - pr_err("%s:%u: %s not completed, status 0x%lx\n", __func__, 764 + pr_err("%s:%u: %s not completed, status 0x%llx\n", __func__, 765 765 __LINE__, op, dev->lv1_status); 766 766 return -EIO; 767 767 } ··· 850 850 if (res) 851 851 break; 852 852 853 - pr_debug("%s:%u: notify event type 0x%lx bus id %lu dev id %lu" 854 - " type %lu port %lu\n", __func__, __LINE__, 853 + pr_debug("%s:%u: notify event type 0x%llx bus id %llu dev id %llu" 854 + " type %llu port %llu\n", __func__, __LINE__, 855 855 notify_event->event_type, notify_event->bus_id, 856 856 notify_event->dev_id, notify_event->dev_type, 857 857 notify_event->dev_port); 858 858 859 859 if (notify_event->event_type != notify_region_probe || 860 860 notify_event->bus_id != dev.sbd.bus_id) { 861 - pr_warning("%s:%u: bad notify_event: event %lu, " 862 - "dev_id %lu, dev_type %lu\n", 861 + pr_warning("%s:%u: bad notify_event: event %llu, " 862 + "dev_id %llu, dev_type %llu\n", 863 863 __func__, __LINE__, notify_event->event_type, 864 864 notify_event->dev_id, 865 865 notify_event->dev_type);
+1 -1
arch/powerpc/platforms/ps3/htab.c
··· 75 75 76 76 if (result) { 77 77 /* all entries bolted !*/ 78 - pr_info("%s:result=%d va=%lx pa=%lx ix=%lx v=%lx r=%lx\n", 78 + pr_info("%s:result=%d va=%lx pa=%lx ix=%lx v=%llx r=%llx\n", 79 79 __func__, result, va, pa, hpte_group, hpte_v, hpte_r); 80 80 BUG(); 81 81 }
+15 -13
arch/powerpc/platforms/ps3/interrupt.c
··· 60 60 * gives a usable range of plug values of {NUM_ISA_INTERRUPTS..63}. Note 61 61 * that there is no constraint on how many in this set an individual thread 62 62 * can acquire. 63 + * 64 + * The mask is declared as unsigned long so we can use set/clear_bit on it. 63 65 */ 64 66 65 67 #define PS3_BMP_MINALIGN 64 ··· 70 68 struct { 71 69 u64 status; 72 70 u64 unused_1[3]; 73 - u64 mask; 71 + unsigned long mask; 74 72 u64 unused_2[3]; 75 73 }; 76 74 u64 ipi_debug_brk_mask; ··· 104 102 struct ps3_private *pd = get_irq_chip_data(virq); 105 103 unsigned long flags; 106 104 107 - pr_debug("%s:%d: thread_id %lu, virq %d\n", __func__, __LINE__, 105 + pr_debug("%s:%d: thread_id %llu, virq %d\n", __func__, __LINE__, 108 106 pd->thread_id, virq); 109 107 110 108 local_irq_save(flags); ··· 125 123 struct ps3_private *pd = get_irq_chip_data(virq); 126 124 unsigned long flags; 127 125 128 - pr_debug("%s:%d: thread_id %lu, virq %d\n", __func__, __LINE__, 126 + pr_debug("%s:%d: thread_id %llu, virq %d\n", __func__, __LINE__, 129 127 pd->thread_id, virq); 130 128 131 129 local_irq_save(flags); ··· 223 221 { 224 222 const struct ps3_private *pd = get_irq_chip_data(virq); 225 223 226 - pr_debug("%s:%d: ppe_id %lu, thread_id %lu, virq %u\n", __func__, 224 + pr_debug("%s:%d: ppe_id %llu, thread_id %llu, virq %u\n", __func__, 227 225 __LINE__, pd->ppe_id, pd->thread_id, virq); 228 226 229 227 set_irq_chip_data(virq, NULL); ··· 293 291 int result; 294 292 const struct ps3_private *pd = get_irq_chip_data(virq); 295 293 296 - pr_debug("%s:%d: ppe_id %lu, thread_id %lu, virq %u\n", __func__, 294 + pr_debug("%s:%d: ppe_id %llu, thread_id %llu, virq %u\n", __func__, 297 295 __LINE__, pd->ppe_id, pd->thread_id, virq); 298 296 299 297 ps3_chip_mask(virq); ··· 324 322 int ps3_event_receive_port_setup(enum ps3_cpu_binding cpu, unsigned int *virq) 325 323 { 326 324 int result; 327 - unsigned long outlet; 325 + u64 outlet; 328 326 329 327 result = lv1_construct_event_receive_port(&outlet); 330 328 ··· 470 468 unsigned int *virq) 471 469 { 472 470 int result; 473 - unsigned long outlet; 471 + u64 outlet; 474 472 475 473 result = lv1_construct_io_irq_outlet(interrupt_id, &outlet); 476 474 ··· 527 525 unsigned int *virq) 528 526 { 529 527 int result; 530 - unsigned long outlet; 528 + u64 outlet; 531 529 u64 lpar_addr; 532 530 533 531 BUG_ON(!is_kernel_addr((u64)virt_addr_bmp)); ··· 583 581 unsigned int class, unsigned int *virq) 584 582 { 585 583 int result; 586 - unsigned long outlet; 584 + u64 outlet; 587 585 588 586 BUG_ON(class > 2); 589 587 ··· 693 691 694 692 pd->bmp.ipi_debug_brk_mask = 0x8000000000000000UL >> virq; 695 693 696 - pr_debug("%s:%d: cpu %u, virq %u, mask %lxh\n", __func__, __LINE__, 694 + pr_debug("%s:%d: cpu %u, virq %u, mask %llxh\n", __func__, __LINE__, 697 695 cpu, virq, pd->bmp.ipi_debug_brk_mask); 698 696 } 699 697 ··· 712 710 plug &= 0x3f; 713 711 714 712 if (unlikely(plug == NO_IRQ)) { 715 - pr_debug("%s:%d: no plug found: thread_id %lu\n", __func__, 713 + pr_debug("%s:%d: no plug found: thread_id %llu\n", __func__, 716 714 __LINE__, pd->thread_id); 717 715 dump_bmp(&per_cpu(ps3_private, 0)); 718 716 dump_bmp(&per_cpu(ps3_private, 1)); ··· 747 745 pd->thread_id = get_hard_smp_processor_id(cpu); 748 746 spin_lock_init(&pd->bmp.lock); 749 747 750 - pr_debug("%s:%d: ppe_id %lu, thread_id %lu, bmp %lxh\n", 748 + pr_debug("%s:%d: ppe_id %llu, thread_id %llu, bmp %lxh\n", 751 749 __func__, __LINE__, pd->ppe_id, pd->thread_id, 752 750 ps3_mm_phys_to_lpar(__pa(&pd->bmp))); 753 751 ··· 772 770 lv1_get_logical_ppe_id(&ppe_id); 773 771 result = lv1_configure_irq_state_bitmap(ppe_id, thread_id, 0); 774 772 775 - DBG("%s:%d: lv1_configure_irq_state_bitmap (%lu:%lu/%d) %s\n", __func__, 773 + DBG("%s:%d: lv1_configure_irq_state_bitmap (%llu:%llu/%d) %s\n", __func__, 776 774 __LINE__, ppe_id, thread_id, cpu, ps3_result(result)); 777 775 }
+51 -46
arch/powerpc/platforms/ps3/mm.c
··· 79 79 */ 80 80 81 81 struct mem_region { 82 - unsigned long base; 83 - unsigned long size; 82 + u64 base; 83 + u64 size; 84 84 unsigned long offset; 85 85 }; 86 86 ··· 103 103 */ 104 104 105 105 struct map { 106 - unsigned long total; 107 - unsigned long vas_id; 108 - unsigned long htab_size; 106 + u64 total; 107 + u64 vas_id; 108 + u64 htab_size; 109 109 struct mem_region rm; 110 110 struct mem_region r1; 111 111 }; ··· 114 114 static void __maybe_unused _debug_dump_map(const struct map *m, 115 115 const char *func, int line) 116 116 { 117 - DBG("%s:%d: map.total = %lxh\n", func, line, m->total); 118 - DBG("%s:%d: map.rm.size = %lxh\n", func, line, m->rm.size); 119 - DBG("%s:%d: map.vas_id = %lu\n", func, line, m->vas_id); 120 - DBG("%s:%d: map.htab_size = %lxh\n", func, line, m->htab_size); 121 - DBG("%s:%d: map.r1.base = %lxh\n", func, line, m->r1.base); 117 + DBG("%s:%d: map.total = %llxh\n", func, line, m->total); 118 + DBG("%s:%d: map.rm.size = %llxh\n", func, line, m->rm.size); 119 + DBG("%s:%d: map.vas_id = %llu\n", func, line, m->vas_id); 120 + DBG("%s:%d: map.htab_size = %llxh\n", func, line, m->htab_size); 121 + DBG("%s:%d: map.r1.base = %llxh\n", func, line, m->r1.base); 122 122 DBG("%s:%d: map.r1.offset = %lxh\n", func, line, m->r1.offset); 123 - DBG("%s:%d: map.r1.size = %lxh\n", func, line, m->r1.size); 123 + DBG("%s:%d: map.r1.size = %llxh\n", func, line, m->r1.size); 124 124 } 125 125 126 126 static struct map map; ··· 146 146 void __init ps3_mm_vas_create(unsigned long* htab_size) 147 147 { 148 148 int result; 149 - unsigned long start_address; 150 - unsigned long size; 151 - unsigned long access_right; 152 - unsigned long max_page_size; 153 - unsigned long flags; 149 + u64 start_address; 150 + u64 size; 151 + u64 access_right; 152 + u64 max_page_size; 153 + u64 flags; 154 154 155 155 result = lv1_query_logical_partition_address_region_info(0, 156 156 &start_address, &size, &access_right, &max_page_size, ··· 164 164 } 165 165 166 166 if (max_page_size < PAGE_SHIFT_16M) { 167 - DBG("%s:%d: bad max_page_size %lxh\n", __func__, __LINE__, 167 + DBG("%s:%d: bad max_page_size %llxh\n", __func__, __LINE__, 168 168 max_page_size); 169 169 goto fail; 170 170 } ··· 208 208 { 209 209 int result; 210 210 211 - DBG("%s:%d: map.vas_id = %lu\n", __func__, __LINE__, map.vas_id); 211 + DBG("%s:%d: map.vas_id = %llu\n", __func__, __LINE__, map.vas_id); 212 212 213 213 if (map.vas_id) { 214 214 result = lv1_select_virtual_address_space(0); ··· 235 235 static int ps3_mm_region_create(struct mem_region *r, unsigned long size) 236 236 { 237 237 int result; 238 - unsigned long muid; 238 + u64 muid; 239 239 240 240 r->size = _ALIGN_DOWN(size, 1 << PAGE_SHIFT_16M); 241 241 242 242 DBG("%s:%d requested %lxh\n", __func__, __LINE__, size); 243 - DBG("%s:%d actual %lxh\n", __func__, __LINE__, r->size); 244 - DBG("%s:%d difference %lxh (%luMB)\n", __func__, __LINE__, 245 - (unsigned long)(size - r->size), 246 - (size - r->size) / 1024 / 1024); 243 + DBG("%s:%d actual %llxh\n", __func__, __LINE__, r->size); 244 + DBG("%s:%d difference %llxh (%lluMB)\n", __func__, __LINE__, 245 + size - r->size, (size - r->size) / 1024 / 1024); 247 246 248 247 if (r->size == 0) { 249 248 DBG("%s:%d: size == 0\n", __func__, __LINE__); ··· 276 277 { 277 278 int result; 278 279 279 - DBG("%s:%d: r->base = %lxh\n", __func__, __LINE__, r->base); 280 + DBG("%s:%d: r->base = %llxh\n", __func__, __LINE__, r->base); 280 281 if (r->base) { 281 282 result = lv1_release_memory(r->base); 282 283 BUG_ON(result); ··· 354 355 static void __maybe_unused _dma_dump_region(const struct ps3_dma_region *r, 355 356 const char *func, int line) 356 357 { 357 - DBG("%s:%d: dev %lu:%lu\n", func, line, r->dev->bus_id, 358 + DBG("%s:%d: dev %llu:%llu\n", func, line, r->dev->bus_id, 358 359 r->dev->dev_id); 359 360 DBG("%s:%d: page_size %u\n", func, line, r->page_size); 360 361 DBG("%s:%d: bus_addr %lxh\n", func, line, r->bus_addr); ··· 389 390 static void _dma_dump_chunk (const struct dma_chunk* c, const char* func, 390 391 int line) 391 392 { 392 - DBG("%s:%d: r.dev %lu:%lu\n", func, line, 393 + DBG("%s:%d: r.dev %llu:%llu\n", func, line, 393 394 c->region->dev->bus_id, c->region->dev->dev_id); 394 395 DBG("%s:%d: r.bus_addr %lxh\n", func, line, c->region->bus_addr); 395 396 DBG("%s:%d: r.page_size %u\n", func, line, c->region->page_size); ··· 595 596 596 597 /* build ioptes for the area */ 597 598 pages = len >> r->page_size; 598 - DBG("%s: pgsize=%#x len=%#lx pages=%#x iopteflag=%#lx\n", __func__, 599 + DBG("%s: pgsize=%#x len=%#lx pages=%#x iopteflag=%#llx\n", __func__, 599 600 r->page_size, r->len, pages, iopte_flag); 600 601 for (iopage = 0; iopage < pages; iopage++) { 601 602 offset = (1 << r->page_size) * iopage; ··· 647 648 static int dma_sb_region_create(struct ps3_dma_region *r) 648 649 { 649 650 int result; 651 + u64 bus_addr; 650 652 651 653 DBG(" -> %s:%d:\n", __func__, __LINE__); 652 654 653 655 BUG_ON(!r); 654 656 655 657 if (!r->dev->bus_id) { 656 - pr_info("%s:%d: %lu:%lu no dma\n", __func__, __LINE__, 658 + pr_info("%s:%d: %llu:%llu no dma\n", __func__, __LINE__, 657 659 r->dev->bus_id, r->dev->dev_id); 658 660 return 0; 659 661 } ··· 671 671 672 672 result = lv1_allocate_device_dma_region(r->dev->bus_id, r->dev->dev_id, 673 673 roundup_pow_of_two(r->len), r->page_size, r->region_type, 674 - &r->bus_addr); 674 + &bus_addr); 675 + r->bus_addr = bus_addr; 675 676 676 677 if (result) { 677 678 DBG("%s:%d: lv1_allocate_device_dma_region failed: %s\n", ··· 686 685 static int dma_ioc0_region_create(struct ps3_dma_region *r) 687 686 { 688 687 int result; 688 + u64 bus_addr; 689 689 690 690 INIT_LIST_HEAD(&r->chunk_list.head); 691 691 spin_lock_init(&r->chunk_list.lock); ··· 694 692 result = lv1_allocate_io_segment(0, 695 693 r->len, 696 694 r->page_size, 697 - &r->bus_addr); 695 + &bus_addr); 696 + r->bus_addr = bus_addr; 698 697 if (result) { 699 698 DBG("%s:%d: lv1_allocate_io_segment failed: %s\n", 700 699 __func__, __LINE__, ps3_result(result)); ··· 723 720 BUG_ON(!r); 724 721 725 722 if (!r->dev->bus_id) { 726 - pr_info("%s:%d: %lu:%lu no dma\n", __func__, __LINE__, 723 + pr_info("%s:%d: %llu:%llu no dma\n", __func__, __LINE__, 727 724 r->dev->bus_id, r->dev->dev_id); 728 725 return 0; 729 726 } ··· 780 777 */ 781 778 782 779 static int dma_sb_map_area(struct ps3_dma_region *r, unsigned long virt_addr, 783 - unsigned long len, unsigned long *bus_addr, 780 + unsigned long len, dma_addr_t *bus_addr, 784 781 u64 iopte_flag) 785 782 { 786 783 int result; ··· 803 800 DBG("%s:%d lpar_addr %lxh\n", __func__, __LINE__, 804 801 lpar_addr); 805 802 DBG("%s:%d len %lxh\n", __func__, __LINE__, len); 806 - DBG("%s:%d bus_addr %lxh (%lxh)\n", __func__, __LINE__, 803 + DBG("%s:%d bus_addr %llxh (%lxh)\n", __func__, __LINE__, 807 804 *bus_addr, len); 808 805 } 809 806 ··· 835 832 } 836 833 837 834 static int dma_ioc0_map_area(struct ps3_dma_region *r, unsigned long virt_addr, 838 - unsigned long len, unsigned long *bus_addr, 835 + unsigned long len, dma_addr_t *bus_addr, 839 836 u64 iopte_flag) 840 837 { 841 838 int result; ··· 875 872 return result; 876 873 } 877 874 *bus_addr = c->bus_addr + phys_addr - aligned_phys; 878 - DBG("%s: va=%#lx pa=%#lx a_pa=%#lx bus=%#lx\n", __func__, 875 + DBG("%s: va=%#lx pa=%#lx a_pa=%#lx bus=%#llx\n", __func__, 879 876 virt_addr, phys_addr, aligned_phys, *bus_addr); 880 877 c->usage_count = 1; 881 878 ··· 892 889 * This is the common dma unmap routine. 893 890 */ 894 891 895 - static int dma_sb_unmap_area(struct ps3_dma_region *r, unsigned long bus_addr, 892 + static int dma_sb_unmap_area(struct ps3_dma_region *r, dma_addr_t bus_addr, 896 893 unsigned long len) 897 894 { 898 895 unsigned long flags; ··· 906 903 1 << r->page_size); 907 904 unsigned long aligned_len = _ALIGN_UP(len + bus_addr 908 905 - aligned_bus, 1 << r->page_size); 909 - DBG("%s:%d: not found: bus_addr %lxh\n", 906 + DBG("%s:%d: not found: bus_addr %llxh\n", 910 907 __func__, __LINE__, bus_addr); 911 908 DBG("%s:%d: not found: len %lxh\n", 912 909 __func__, __LINE__, len); ··· 929 926 } 930 927 931 928 static int dma_ioc0_unmap_area(struct ps3_dma_region *r, 932 - unsigned long bus_addr, unsigned long len) 929 + dma_addr_t bus_addr, unsigned long len) 933 930 { 934 931 unsigned long flags; 935 932 struct dma_chunk *c; 936 933 937 - DBG("%s: start a=%#lx l=%#lx\n", __func__, bus_addr, len); 934 + DBG("%s: start a=%#llx l=%#lx\n", __func__, bus_addr, len); 938 935 spin_lock_irqsave(&r->chunk_list.lock, flags); 939 936 c = dma_find_chunk(r, bus_addr, len); 940 937 ··· 944 941 unsigned long aligned_len = _ALIGN_UP(len + bus_addr 945 942 - aligned_bus, 946 943 1 << r->page_size); 947 - DBG("%s:%d: not found: bus_addr %lxh\n", 944 + DBG("%s:%d: not found: bus_addr %llxh\n", 948 945 __func__, __LINE__, bus_addr); 949 946 DBG("%s:%d: not found: len %lxh\n", 950 947 __func__, __LINE__, len); ··· 978 975 static int dma_sb_region_create_linear(struct ps3_dma_region *r) 979 976 { 980 977 int result; 981 - unsigned long virt_addr, len, tmp; 978 + unsigned long virt_addr, len; 979 + dma_addr_t tmp; 982 980 983 981 if (r->len > 16*1024*1024) { /* FIXME: need proper fix */ 984 982 /* force 16M dma pages for linear mapping */ ··· 1031 1027 static int dma_sb_region_free_linear(struct ps3_dma_region *r) 1032 1028 { 1033 1029 int result; 1034 - unsigned long bus_addr, len, lpar_addr; 1030 + dma_addr_t bus_addr; 1031 + unsigned long len, lpar_addr; 1035 1032 1036 1033 if (r->offset < map.rm.size) { 1037 1034 /* Unmap (part of) 1st RAM chunk */ ··· 1077 1072 */ 1078 1073 1079 1074 static int dma_sb_map_area_linear(struct ps3_dma_region *r, 1080 - unsigned long virt_addr, unsigned long len, unsigned long *bus_addr, 1075 + unsigned long virt_addr, unsigned long len, dma_addr_t *bus_addr, 1081 1076 u64 iopte_flag) 1082 1077 { 1083 1078 unsigned long phys_addr = is_kernel_addr(virt_addr) ? __pa(virt_addr) ··· 1096 1091 */ 1097 1092 1098 1093 static int dma_sb_unmap_area_linear(struct ps3_dma_region *r, 1099 - unsigned long bus_addr, unsigned long len) 1094 + dma_addr_t bus_addr, unsigned long len) 1100 1095 { 1101 1096 return 0; 1102 1097 }; ··· 1174 1169 EXPORT_SYMBOL(ps3_dma_region_free); 1175 1170 1176 1171 int ps3_dma_map(struct ps3_dma_region *r, unsigned long virt_addr, 1177 - unsigned long len, unsigned long *bus_addr, 1172 + unsigned long len, dma_addr_t *bus_addr, 1178 1173 u64 iopte_flag) 1179 1174 { 1180 1175 return r->region_ops->map(r, virt_addr, len, bus_addr, iopte_flag); 1181 1176 } 1182 1177 1183 - int ps3_dma_unmap(struct ps3_dma_region *r, unsigned long bus_addr, 1178 + int ps3_dma_unmap(struct ps3_dma_region *r, dma_addr_t bus_addr, 1184 1179 unsigned long len) 1185 1180 { 1186 1181 return r->region_ops->unmap(r, bus_addr, len);
+1 -1
arch/powerpc/platforms/ps3/os-area.c
··· 306 306 { 307 307 pr_debug("%s:%d: p.boot_flag: %u\n", func, line, p->boot_flag); 308 308 pr_debug("%s:%d: p.num_params: %u\n", func, line, p->num_params); 309 - pr_debug("%s:%d: p.rtc_diff %ld\n", func, line, p->rtc_diff); 309 + pr_debug("%s:%d: p.rtc_diff %lld\n", func, line, p->rtc_diff); 310 310 pr_debug("%s:%d: p.av_multi_out %u\n", func, line, p->av_multi_out); 311 311 pr_debug("%s:%d: p.ctrl_button: %u\n", func, line, p->ctrl_button); 312 312 pr_debug("%s:%d: p.static_ip_addr: %u.%u.%u.%u\n", func, line,
+11 -11
arch/powerpc/platforms/ps3/repository.c
··· 44 44 s[i] = (in[i] <= 126 && in[i] >= 32) ? in[i] : '.'; 45 45 s[i] = 0; 46 46 47 - pr_debug("%s:%d: %s%016lx : %s\n", func, line, hdr, n, s); 47 + pr_debug("%s:%d: %s%016llx : %s\n", func, line, hdr, n, s); 48 48 #endif 49 49 } 50 50 ··· 70 70 _dump_field("n2: ", n2, func, line); 71 71 _dump_field("n3: ", n3, func, line); 72 72 _dump_field("n4: ", n4, func, line); 73 - pr_debug("%s:%d: v1: %016lx\n", func, line, v1); 74 - pr_debug("%s:%d: v2: %016lx\n", func, line, v2); 73 + pr_debug("%s:%d: v1: %016llx\n", func, line, v1); 74 + pr_debug("%s:%d: v2: %016llx\n", func, line, v2); 75 75 } 76 76 77 77 /** ··· 149 149 *_v2 = v2; 150 150 151 151 if (v1 && !_v1) 152 - pr_debug("%s:%d: warning: discarding non-zero v1: %016lx\n", 152 + pr_debug("%s:%d: warning: discarding non-zero v1: %016llx\n", 153 153 __func__, __LINE__, v1); 154 154 if (v2 && !_v2) 155 - pr_debug("%s:%d: warning: discarding non-zero v2: %016lx\n", 155 + pr_debug("%s:%d: warning: discarding non-zero v2: %016llx\n", 156 156 __func__, __LINE__, v2); 157 157 158 158 return 0; ··· 327 327 return result; 328 328 } 329 329 330 - pr_debug("%s:%d: bus_type %u, bus_index %u, bus_id %lu, num_dev %u\n", 330 + pr_debug("%s:%d: bus_type %u, bus_index %u, bus_id %llu, num_dev %u\n", 331 331 __func__, __LINE__, tmp.bus_type, tmp.bus_index, tmp.bus_id, 332 332 num_dev); 333 333 ··· 353 353 return result; 354 354 } 355 355 356 - pr_debug("%s:%d: found: dev_type %u, dev_index %u, dev_id %lu\n", 356 + pr_debug("%s:%d: found: dev_type %u, dev_index %u, dev_id %llu\n", 357 357 __func__, __LINE__, tmp.dev_type, tmp.dev_index, tmp.dev_id); 358 358 359 359 *repo = tmp; ··· 367 367 struct ps3_repository_device tmp; 368 368 unsigned int num_dev; 369 369 370 - pr_debug(" -> %s:%u: find device by id %lu:%lu\n", __func__, __LINE__, 370 + pr_debug(" -> %s:%u: find device by id %llu:%llu\n", __func__, __LINE__, 371 371 bus_id, dev_id); 372 372 373 373 for (tmp.bus_index = 0; tmp.bus_index < 10; tmp.bus_index++) { ··· 382 382 if (tmp.bus_id == bus_id) 383 383 goto found_bus; 384 384 385 - pr_debug("%s:%u: skip, bus_id %lu\n", __func__, __LINE__, 385 + pr_debug("%s:%u: skip, bus_id %llu\n", __func__, __LINE__, 386 386 tmp.bus_id); 387 387 } 388 388 pr_debug(" <- %s:%u: bus not found\n", __func__, __LINE__); ··· 416 416 if (tmp.dev_id == dev_id) 417 417 goto found_dev; 418 418 419 - pr_debug("%s:%u: skip, dev_id %lu\n", __func__, __LINE__, 419 + pr_debug("%s:%u: skip, dev_id %llu\n", __func__, __LINE__, 420 420 tmp.dev_id); 421 421 } 422 422 pr_debug(" <- %s:%u: dev not found\n", __func__, __LINE__); ··· 430 430 return result; 431 431 } 432 432 433 - pr_debug(" <- %s:%u: found: type (%u:%u) index (%u:%u) id (%lu:%lu)\n", 433 + pr_debug(" <- %s:%u: found: type (%u:%u) index (%u:%u) id (%llu:%llu)\n", 434 434 __func__, __LINE__, tmp.bus_type, tmp.dev_type, tmp.bus_index, 435 435 tmp.dev_index, tmp.bus_id, tmp.dev_id); 436 436 *repo = tmp;
+1 -1
arch/powerpc/platforms/ps3/setup.c
··· 186 186 #define prealloc_ps3flash_bounce_buffer() do { } while (0) 187 187 #endif 188 188 189 - static int ps3_set_dabr(u64 dabr) 189 + static int ps3_set_dabr(unsigned long dabr) 190 190 { 191 191 enum {DABR_USER = 1, DABR_KERNEL = 2,}; 192 192
+8 -4
arch/powerpc/platforms/ps3/spu.c
··· 149 149 150 150 static unsigned long get_vas_id(void) 151 151 { 152 - unsigned long id; 152 + u64 id; 153 153 154 154 lv1_get_logical_ppe_id(&id); 155 155 lv1_get_virtual_address_space_id_of_ppe(id, &id); ··· 160 160 static int __init construct_spu(struct spu *spu) 161 161 { 162 162 int result; 163 - unsigned long unused; 163 + u64 unused; 164 + u64 problem_phys; 165 + u64 local_store_phys; 164 166 165 167 result = lv1_construct_logical_spe(PAGE_SHIFT, PAGE_SHIFT, PAGE_SHIFT, 166 168 PAGE_SHIFT, PAGE_SHIFT, get_vas_id(), SPE_TYPE_LOGICAL, 167 - &spu_pdata(spu)->priv2_addr, &spu->problem_phys, 168 - &spu->local_store_phys, &unused, 169 + &spu_pdata(spu)->priv2_addr, &problem_phys, 170 + &local_store_phys, &unused, 169 171 &spu_pdata(spu)->shadow_addr, 170 172 &spu_pdata(spu)->spe_id); 173 + spu->problem_phys = problem_phys; 174 + spu->local_store_phys = local_store_phys; 171 175 172 176 if (result) { 173 177 pr_debug("%s:%d: lv1_construct_logical_spe failed: %s\n",
+8 -6
arch/powerpc/platforms/ps3/system-bus.c
··· 182 182 case PS3_MATCH_ID_SYSTEM_MANAGER: 183 183 pr_debug("%s:%d: unsupported match_id: %u\n", __func__, 184 184 __LINE__, dev->match_id); 185 - pr_debug("%s:%d: bus_id: %lu\n", __func__, __LINE__, 185 + pr_debug("%s:%d: bus_id: %llu\n", __func__, __LINE__, 186 186 dev->bus_id); 187 187 BUG(); 188 188 return -EINVAL; ··· 220 220 case PS3_MATCH_ID_SYSTEM_MANAGER: 221 221 pr_debug("%s:%d: unsupported match_id: %u\n", __func__, 222 222 __LINE__, dev->match_id); 223 - pr_debug("%s:%d: bus_id: %lu\n", __func__, __LINE__, 223 + pr_debug("%s:%d: bus_id: %llu\n", __func__, __LINE__, 224 224 dev->bus_id); 225 225 BUG(); 226 226 return -EINVAL; ··· 240 240 static void _dump_mmio_region(const struct ps3_mmio_region* r, 241 241 const char* func, int line) 242 242 { 243 - pr_debug("%s:%d: dev %lu:%lu\n", func, line, r->dev->bus_id, 243 + pr_debug("%s:%d: dev %llu:%llu\n", func, line, r->dev->bus_id, 244 244 r->dev->dev_id); 245 245 pr_debug("%s:%d: bus_addr %lxh\n", func, line, r->bus_addr); 246 246 pr_debug("%s:%d: len %lxh\n", func, line, r->len); ··· 250 250 static int ps3_sb_mmio_region_create(struct ps3_mmio_region *r) 251 251 { 252 252 int result; 253 + u64 lpar_addr; 253 254 254 255 result = lv1_map_device_mmio_region(r->dev->bus_id, r->dev->dev_id, 255 - r->bus_addr, r->len, r->page_size, &r->lpar_addr); 256 + r->bus_addr, r->len, r->page_size, &lpar_addr); 257 + r->lpar_addr = lpar_addr; 256 258 257 259 if (result) { 258 260 pr_debug("%s:%d: lv1_map_device_mmio_region failed: %s\n", ··· 570 568 { 571 569 struct ps3_system_bus_device *dev = ps3_dev_to_system_bus_dev(_dev); 572 570 int result; 573 - unsigned long bus_addr; 571 + dma_addr_t bus_addr; 574 572 void *ptr = page_address(page) + offset; 575 573 576 574 result = ps3_dma_map(dev->d_region, (unsigned long)ptr, size, ··· 592 590 { 593 591 struct ps3_system_bus_device *dev = ps3_dev_to_system_bus_dev(_dev); 594 592 int result; 595 - unsigned long bus_addr; 593 + dma_addr_t bus_addr; 596 594 u64 iopte_flag; 597 595 void *ptr = page_address(page) + offset; 598 596
+9 -9
drivers/block/ps3disk.c
··· 141 141 142 142 start_sector = req->sector * priv->blocking_factor; 143 143 sectors = req->nr_sectors * priv->blocking_factor; 144 - dev_dbg(&dev->sbd.core, "%s:%u: %s %lu sectors starting at %lu\n", 144 + dev_dbg(&dev->sbd.core, "%s:%u: %s %llu sectors starting at %llu\n", 145 145 __func__, __LINE__, op, sectors, start_sector); 146 146 147 147 if (write) { ··· 178 178 LV1_STORAGE_ATA_HDDOUT, 0, 0, 0, 179 179 0, &dev->tag); 180 180 if (res) { 181 - dev_err(&dev->sbd.core, "%s:%u: sync cache failed 0x%lx\n", 181 + dev_err(&dev->sbd.core, "%s:%u: sync cache failed 0x%llx\n", 182 182 __func__, __LINE__, res); 183 183 end_request(req, 0); 184 184 return 0; ··· 238 238 239 239 if (tag != dev->tag) 240 240 dev_err(&dev->sbd.core, 241 - "%s:%u: tag mismatch, got %lx, expected %lx\n", 241 + "%s:%u: tag mismatch, got %llx, expected %llx\n", 242 242 __func__, __LINE__, tag, dev->tag); 243 243 244 244 if (res) { 245 - dev_err(&dev->sbd.core, "%s:%u: res=%d status=0x%lx\n", 245 + dev_err(&dev->sbd.core, "%s:%u: res=%d status=0x%llx\n", 246 246 __func__, __LINE__, res, status); 247 247 return IRQ_HANDLED; 248 248 } ··· 269 269 op = read ? "read" : "write"; 270 270 } 271 271 if (status) { 272 - dev_dbg(&dev->sbd.core, "%s:%u: %s failed 0x%lx\n", __func__, 272 + dev_dbg(&dev->sbd.core, "%s:%u: %s failed 0x%llx\n", __func__, 273 273 __LINE__, op, status); 274 274 error = -EIO; 275 275 } else { ··· 297 297 298 298 res = ps3stor_send_command(dev, LV1_STORAGE_ATA_HDDOUT, 0, 0, 0, 0); 299 299 if (res) { 300 - dev_err(&dev->sbd.core, "%s:%u: sync cache failed 0x%lx\n", 300 + dev_err(&dev->sbd.core, "%s:%u: sync cache failed 0x%llx\n", 301 301 __func__, __LINE__, res); 302 302 return -EIO; 303 303 } ··· 388 388 sizeof(ata_cmnd), ata_cmnd.buffer, 389 389 ata_cmnd.arglen); 390 390 if (res) { 391 - dev_err(&dev->sbd.core, "%s:%u: identify disk failed 0x%lx\n", 391 + dev_err(&dev->sbd.core, "%s:%u: identify disk failed 0x%llx\n", 392 392 __func__, __LINE__, res); 393 393 return -EIO; 394 394 } ··· 426 426 427 427 if (dev->blk_size < 512) { 428 428 dev_err(&dev->sbd.core, 429 - "%s:%u: cannot handle block size %lu\n", __func__, 429 + "%s:%u: cannot handle block size %llu\n", __func__, 430 430 __LINE__, dev->blk_size); 431 431 return -EINVAL; 432 432 } ··· 512 512 dev->regions[dev->region_idx].size*priv->blocking_factor); 513 513 514 514 dev_info(&dev->sbd.core, 515 - "%s is a %s (%lu MiB total, %lu MiB for OtherOS)\n", 515 + "%s is a %s (%llu MiB total, %lu MiB for OtherOS)\n", 516 516 gendisk->disk_name, priv->model, priv->raw_capacity >> 11, 517 517 get_capacity(gendisk) >> 11); 518 518
-2
drivers/char/hvc_console.c
··· 318 318 } /* else count == 0 */ 319 319 320 320 tty->driver_data = hp; 321 - if (!hp->irq_requested) 322 - tty->low_latency = 1; /* Makes flushes to ldisc synchronous. */ 323 321 324 322 hp->tty = tty; 325 323
+9 -9
drivers/char/ps3flash.c
··· 44 44 u64 res = ps3stor_read_write_sectors(dev, lpar, start_sector, sectors, 45 45 write); 46 46 if (res) { 47 - dev_err(&dev->sbd.core, "%s:%u: %s failed 0x%lx\n", __func__, 47 + dev_err(&dev->sbd.core, "%s:%u: %s failed 0x%llx\n", __func__, 48 48 __LINE__, write ? "write" : "read", res); 49 49 return -EIO; 50 50 } ··· 59 59 60 60 max_sectors = dev->bounce_size / dev->blk_size; 61 61 if (sectors > max_sectors) { 62 - dev_dbg(&dev->sbd.core, "%s:%u Limiting sectors to %lu\n", 62 + dev_dbg(&dev->sbd.core, "%s:%u Limiting sectors to %llu\n", 63 63 __func__, __LINE__, max_sectors); 64 64 sectors = max_sectors; 65 65 } ··· 144 144 goto fail; 145 145 } 146 146 147 - n = min(remaining, sectors_read*dev->blk_size-offset); 147 + n = min_t(u64, remaining, sectors_read*dev->blk_size-offset); 148 148 dev_dbg(&dev->sbd.core, 149 149 "%s:%u: copy %lu bytes from 0x%p to user 0x%p\n", 150 150 __func__, __LINE__, n, dev->bounce_buf+offset, buf); ··· 225 225 if (end_read_sector >= start_read_sector) { 226 226 /* Merge head and tail */ 227 227 dev_dbg(&dev->sbd.core, 228 - "Merged head and tail: %lu sectors at %lu\n", 228 + "Merged head and tail: %llu sectors at %llu\n", 229 229 chunk_sectors, start_write_sector); 230 230 res = ps3flash_read_sectors(dev, start_write_sector, 231 231 chunk_sectors, 0); ··· 235 235 if (head) { 236 236 /* Read head */ 237 237 dev_dbg(&dev->sbd.core, 238 - "head: %lu sectors at %lu\n", head, 238 + "head: %llu sectors at %llu\n", head, 239 239 start_write_sector); 240 240 res = ps3flash_read_sectors(dev, 241 241 start_write_sector, ··· 247 247 start_write_sector+chunk_sectors) { 248 248 /* Read tail */ 249 249 dev_dbg(&dev->sbd.core, 250 - "tail: %lu sectors at %lu\n", tail, 250 + "tail: %llu sectors at %llu\n", tail, 251 251 start_read_sector); 252 252 sec_off = start_read_sector-start_write_sector; 253 253 res = ps3flash_read_sectors(dev, ··· 258 258 } 259 259 } 260 260 261 - n = min(remaining, dev->bounce_size-offset); 261 + n = min_t(u64, remaining, dev->bounce_size-offset); 262 262 dev_dbg(&dev->sbd.core, 263 263 "%s:%u: copy %lu bytes from user 0x%p to 0x%p\n", 264 264 __func__, __LINE__, n, buf, dev->bounce_buf+offset); ··· 299 299 300 300 if (tag != dev->tag) 301 301 dev_err(&dev->sbd.core, 302 - "%s:%u: tag mismatch, got %lx, expected %lx\n", 302 + "%s:%u: tag mismatch, got %llx, expected %llx\n", 303 303 __func__, __LINE__, tag, dev->tag); 304 304 305 305 if (res) { 306 - dev_err(&dev->sbd.core, "%s:%u: res=%d status=0x%lx\n", 306 + dev_err(&dev->sbd.core, "%s:%u: res=%d status=0x%llx\n", 307 307 __func__, __LINE__, res, status); 308 308 } else { 309 309 dev->lv1_status = status;
+8 -8
drivers/ps3/ps3-lpm.c
··· 732 732 case 8: 733 733 return pm_translate_signal_group_number_on_island8(subgroup); 734 734 default: 735 - dev_dbg(sbd_core(), "%s:%u: island not found: %lu\n", __func__, 735 + dev_dbg(sbd_core(), "%s:%u: island not found: %llu\n", __func__, 736 736 __LINE__, group); 737 737 BUG(); 738 738 break; ··· 765 765 signal_select, attr1, attr2, attr3); 766 766 if (ret) 767 767 dev_err(sbd_core(), 768 - "%s:%u: error:%d 0x%lx 0x%lx 0x%lx 0x%lx 0x%lx 0x%lx\n", 768 + "%s:%u: error:%d 0x%llx 0x%llx 0x%llx 0x%llx 0x%llx 0x%llx\n", 769 769 __func__, __LINE__, ret, lv1_signal_group, bus_select, 770 770 signal_select, attr1, attr2, attr3); 771 771 ··· 908 908 909 909 lpm_priv->tb_count = tmp; 910 910 911 - dev_dbg(sbd_core(), "%s:%u: tb_count %lu (%lxh)\n", __func__, __LINE__, 911 + dev_dbg(sbd_core(), "%s:%u: tb_count %llu (%llxh)\n", __func__, __LINE__, 912 912 lpm_priv->tb_count, lpm_priv->tb_count); 913 913 } 914 914 EXPORT_SYMBOL_GPL(ps3_disable_pm); ··· 938 938 if (offset >= lpm_priv->tb_count) 939 939 return 0; 940 940 941 - count = min(count, lpm_priv->tb_count - offset); 941 + count = min_t(u64, count, lpm_priv->tb_count - offset); 942 942 943 943 while (*bytes_copied < count) { 944 944 const unsigned long request = count - *bytes_copied; ··· 993 993 if (offset >= lpm_priv->tb_count) 994 994 return 0; 995 995 996 - count = min(count, lpm_priv->tb_count - offset); 996 + count = min_t(u64, count, lpm_priv->tb_count - offset); 997 997 998 998 while (*bytes_copied < count) { 999 999 const unsigned long request = count - *bytes_copied; ··· 1013 1013 result = copy_to_user(buf, lpm_priv->tb_cache, tmp); 1014 1014 1015 1015 if (result) { 1016 - dev_dbg(sbd_core(), "%s:%u: 0x%lx bytes at 0x%p\n", 1016 + dev_dbg(sbd_core(), "%s:%u: 0x%llx bytes at 0x%p\n", 1017 1017 __func__, __LINE__, tmp, buf); 1018 1018 dev_err(sbd_core(), "%s:%u: copy_to_user failed: %d\n", 1019 1019 __func__, __LINE__, result); ··· 1148 1148 lpm_priv->shadow.group_control = PS3_LPM_SHADOW_REG_INIT; 1149 1149 lpm_priv->shadow.debug_bus_control = PS3_LPM_SHADOW_REG_INIT; 1150 1150 1151 - dev_dbg(sbd_core(), "%s:%u: lpm_id 0x%lx, outlet_id 0x%lx, " 1152 - "tb_size 0x%lx\n", __func__, __LINE__, lpm_priv->lpm_id, 1151 + dev_dbg(sbd_core(), "%s:%u: lpm_id 0x%llx, outlet_id 0x%llx, " 1152 + "tb_size 0x%llx\n", __func__, __LINE__, lpm_priv->lpm_id, 1153 1153 lpm_priv->outlet_id, tb_size); 1154 1154 1155 1155 return 0;
+17 -15
drivers/ps3/ps3-vuart.c
··· 114 114 static void __maybe_unused _dump_ports_bmp( 115 115 const struct ports_bmp *bmp, const char *func, int line) 116 116 { 117 - pr_debug("%s:%d: ports_bmp: %016lxh\n", func, line, bmp->status); 117 + pr_debug("%s:%d: ports_bmp: %016llxh\n", func, line, bmp->status); 118 118 } 119 119 120 120 #define dump_port_params(_b) _dump_port_params(_b, __func__, __LINE__) ··· 159 159 struct vuart_triggers *trig) 160 160 { 161 161 int result; 162 - unsigned long size; 163 - unsigned long val; 162 + u64 size; 163 + u64 val; 164 + u64 tx; 164 165 165 166 result = lv1_get_virtual_uart_param(dev->port_number, 166 - PARAM_TX_TRIGGER, &trig->tx); 167 + PARAM_TX_TRIGGER, &tx); 168 + trig->tx = tx; 167 169 168 170 if (result) { 169 171 dev_dbg(&dev->core, "%s:%d: tx_trigger failed: %s\n", ··· 203 201 unsigned int rx) 204 202 { 205 203 int result; 206 - unsigned long size; 204 + u64 size; 207 205 208 206 result = lv1_set_virtual_uart_param(dev->port_number, 209 207 PARAM_TX_TRIGGER, tx); ··· 250 248 dev_dbg(&dev->core, "%s:%d: rx_bytes failed: %s\n", 251 249 __func__, __LINE__, ps3_result(result)); 252 250 253 - dev_dbg(&dev->core, "%s:%d: %lxh\n", __func__, __LINE__, 251 + dev_dbg(&dev->core, "%s:%d: %llxh\n", __func__, __LINE__, 254 252 *bytes_waiting); 255 253 return result; 256 254 } ··· 297 295 298 296 *status = tmp & priv->interrupt_mask; 299 297 300 - dev_dbg(&dev->core, "%s:%d: m %lxh, s %lxh, m&s %lxh\n", 298 + dev_dbg(&dev->core, "%s:%d: m %llxh, s %llxh, m&s %lxh\n", 301 299 __func__, __LINE__, priv->interrupt_mask, tmp, *status); 302 300 303 301 return result; ··· 365 363 */ 366 364 367 365 static int ps3_vuart_raw_write(struct ps3_system_bus_device *dev, 368 - const void *buf, unsigned int bytes, unsigned long *bytes_written) 366 + const void *buf, unsigned int bytes, u64 *bytes_written) 369 367 { 370 368 int result; 371 369 struct ps3_vuart_port_priv *priv = to_port_priv(dev); ··· 381 379 382 380 priv->stats.bytes_written += *bytes_written; 383 381 384 - dev_dbg(&dev->core, "%s:%d: wrote %lxh/%xh=>%lxh\n", __func__, __LINE__, 382 + dev_dbg(&dev->core, "%s:%d: wrote %llxh/%xh=>%lxh\n", __func__, __LINE__, 385 383 *bytes_written, bytes, priv->stats.bytes_written); 386 384 387 385 return result; ··· 395 393 */ 396 394 397 395 static int ps3_vuart_raw_read(struct ps3_system_bus_device *dev, void *buf, 398 - unsigned int bytes, unsigned long *bytes_read) 396 + unsigned int bytes, u64 *bytes_read) 399 397 { 400 398 int result; 401 399 struct ps3_vuart_port_priv *priv = to_port_priv(dev); ··· 413 411 414 412 priv->stats.bytes_read += *bytes_read; 415 413 416 - dev_dbg(&dev->core, "%s:%d: read %lxh/%xh=>%lxh\n", __func__, __LINE__, 414 + dev_dbg(&dev->core, "%s:%d: read %llxh/%xh=>%lxh\n", __func__, __LINE__, 417 415 *bytes_read, bytes, priv->stats.bytes_read); 418 416 419 417 return result; ··· 502 500 spin_lock_irqsave(&priv->tx_list.lock, flags); 503 501 504 502 if (list_empty(&priv->tx_list.head)) { 505 - unsigned long bytes_written; 503 + u64 bytes_written; 506 504 507 505 result = ps3_vuart_raw_write(dev, buf, bytes, &bytes_written); 508 506 ··· 594 592 list_add_tail(&lb->link, &priv->rx_list.head); 595 593 priv->rx_list.bytes_held += bytes; 596 594 597 - dev_dbg(&dev->core, "%s:%d: buf_%lu: queued %lxh bytes\n", 595 + dev_dbg(&dev->core, "%s:%d: buf_%lu: queued %llxh bytes\n", 598 596 __func__, __LINE__, lb->dbg_number, bytes); 599 597 600 598 *bytes_queued = bytes; ··· 747 745 748 746 list_for_each_entry_safe(lb, n, &priv->tx_list.head, link) { 749 747 750 - unsigned long bytes_written; 748 + u64 bytes_written; 751 749 752 750 result = ps3_vuart_raw_write(dev, lb->head, lb->tail - lb->head, 753 751 &bytes_written); ··· 764 762 if (bytes_written < lb->tail - lb->head) { 765 763 lb->head += bytes_written; 766 764 dev_dbg(&dev->core, 767 - "%s:%d cleared buf_%lu, %lxh bytes\n", 765 + "%s:%d cleared buf_%lu, %llxh bytes\n", 768 766 __func__, __LINE__, lb->dbg_number, 769 767 bytes_written); 770 768 goto port_full;
+7 -7
drivers/ps3/ps3stor_lib.c
··· 70 70 __func__, __LINE__, n); 71 71 dev->region_idx = __ffs(dev->accessible_regions); 72 72 dev_info(&dev->sbd.core, 73 - "First accessible region has index %u start %lu size %lu\n", 73 + "First accessible region has index %u start %llu size %llu\n", 74 74 dev->region_idx, dev->regions[dev->region_idx].start, 75 75 dev->regions[dev->region_idx].size); 76 76 ··· 220 220 const char *op = write ? "write" : "read"; 221 221 int res; 222 222 223 - dev_dbg(&dev->sbd.core, "%s:%u: %s %lu sectors starting at %lu\n", 223 + dev_dbg(&dev->sbd.core, "%s:%u: %s %llu sectors starting at %llu\n", 224 224 __func__, __LINE__, op, sectors, start_sector); 225 225 226 226 init_completion(&dev->done); ··· 238 238 239 239 wait_for_completion(&dev->done); 240 240 if (dev->lv1_status) { 241 - dev_dbg(&dev->sbd.core, "%s:%u: %s failed 0x%lx\n", __func__, 241 + dev_dbg(&dev->sbd.core, "%s:%u: %s failed 0x%llx\n", __func__, 242 242 __LINE__, op, dev->lv1_status); 243 243 return dev->lv1_status; 244 244 } ··· 268 268 { 269 269 int res; 270 270 271 - dev_dbg(&dev->sbd.core, "%s:%u: send device command 0x%lx\n", __func__, 271 + dev_dbg(&dev->sbd.core, "%s:%u: send device command 0x%llx\n", __func__, 272 272 __LINE__, cmd); 273 273 274 274 init_completion(&dev->done); ··· 277 277 arg2, arg3, arg4, &dev->tag); 278 278 if (res) { 279 279 dev_err(&dev->sbd.core, 280 - "%s:%u: send_device_command 0x%lx failed %d\n", 280 + "%s:%u: send_device_command 0x%llx failed %d\n", 281 281 __func__, __LINE__, cmd, res); 282 282 return -1; 283 283 } 284 284 285 285 wait_for_completion(&dev->done); 286 286 if (dev->lv1_status) { 287 - dev_dbg(&dev->sbd.core, "%s:%u: command 0x%lx failed 0x%lx\n", 287 + dev_dbg(&dev->sbd.core, "%s:%u: command 0x%llx failed 0x%llx\n", 288 288 __func__, __LINE__, cmd, dev->lv1_status); 289 289 return dev->lv1_status; 290 290 } 291 291 292 - dev_dbg(&dev->sbd.core, "%s:%u: command 0x%lx completed\n", __func__, 292 + dev_dbg(&dev->sbd.core, "%s:%u: command 0x%llx completed\n", __func__, 293 293 __LINE__, cmd); 294 294 295 295 return 0;
+7 -7
drivers/scsi/ibmvscsi/ibmvfc.c
··· 933 933 fc_host_speed(shost) = FC_PORTSPEED_16GBIT; 934 934 break; 935 935 default: 936 - ibmvfc_log(vhost, 3, "Unknown port speed: %ld Gbit\n", 936 + ibmvfc_log(vhost, 3, "Unknown port speed: %lld Gbit\n", 937 937 vhost->login_buf->resp.link_speed / 100); 938 938 fc_host_speed(shost) = FC_PORTSPEED_UNKNOWN; 939 939 break; ··· 2149 2149 { 2150 2150 const char *desc = ibmvfc_get_ae_desc(crq->event); 2151 2151 2152 - ibmvfc_log(vhost, 3, "%s event received. scsi_id: %lx, wwpn: %lx," 2153 - " node_name: %lx\n", desc, crq->scsi_id, crq->wwpn, crq->node_name); 2152 + ibmvfc_log(vhost, 3, "%s event received. scsi_id: %llx, wwpn: %llx," 2153 + " node_name: %llx\n", desc, crq->scsi_id, crq->wwpn, crq->node_name); 2154 2154 2155 2155 switch (crq->event) { 2156 2156 case IBMVFC_AE_LINK_UP: ··· 2184 2184 ibmvfc_link_down(vhost, IBMVFC_HALTED); 2185 2185 break; 2186 2186 default: 2187 - dev_err(vhost->dev, "Unknown async event received: %ld\n", crq->event); 2187 + dev_err(vhost->dev, "Unknown async event received: %lld\n", crq->event); 2188 2188 break; 2189 2189 }; 2190 2190 } ··· 2261 2261 * actually sent 2262 2262 */ 2263 2263 if (unlikely(!ibmvfc_valid_event(&vhost->pool, evt))) { 2264 - dev_err(vhost->dev, "Returned correlation_token 0x%08lx is invalid!\n", 2264 + dev_err(vhost->dev, "Returned correlation_token 0x%08llx is invalid!\n", 2265 2265 crq->ioba); 2266 2266 return; 2267 2267 } 2268 2268 2269 2269 if (unlikely(atomic_read(&evt->free))) { 2270 - dev_err(vhost->dev, "Received duplicate correlation_token 0x%08lx!\n", 2270 + dev_err(vhost->dev, "Received duplicate correlation_token 0x%08llx!\n", 2271 2271 crq->ioba); 2272 2272 return; 2273 2273 } ··· 3259 3259 3260 3260 tgt = mempool_alloc(vhost->tgt_pool, GFP_KERNEL); 3261 3261 if (!tgt) { 3262 - dev_err(vhost->dev, "Target allocation failure for scsi id %08lx\n", 3262 + dev_err(vhost->dev, "Target allocation failure for scsi id %08llx\n", 3263 3263 scsi_id); 3264 3264 return -ENOMEM; 3265 3265 }
+3 -3
drivers/scsi/ibmvscsi/ibmvfc.h
··· 691 691 #define DBG_CMD(CMD) do { if (ibmvfc_debug) CMD; } while (0) 692 692 693 693 #define tgt_dbg(t, fmt, ...) \ 694 - DBG_CMD(dev_info((t)->vhost->dev, "%lX: " fmt, (t)->scsi_id, ##__VA_ARGS__)) 694 + DBG_CMD(dev_info((t)->vhost->dev, "%llX: " fmt, (t)->scsi_id, ##__VA_ARGS__)) 695 695 696 696 #define tgt_info(t, fmt, ...) \ 697 - dev_info((t)->vhost->dev, "%lX: " fmt, (t)->scsi_id, ##__VA_ARGS__) 697 + dev_info((t)->vhost->dev, "%llX: " fmt, (t)->scsi_id, ##__VA_ARGS__) 698 698 699 699 #define tgt_err(t, fmt, ...) \ 700 - dev_err((t)->vhost->dev, "%lX: " fmt, (t)->scsi_id, ##__VA_ARGS__) 700 + dev_err((t)->vhost->dev, "%llX: " fmt, (t)->scsi_id, ##__VA_ARGS__) 701 701 702 702 #define ibmvfc_dbg(vhost, ...) \ 703 703 DBG_CMD(dev_info((vhost)->dev, ##__VA_ARGS__))
+3 -3
drivers/scsi/ps3rom.c
··· 290 290 291 291 if (tag != dev->tag) 292 292 dev_err(&dev->sbd.core, 293 - "%s:%u: tag mismatch, got %lx, expected %lx\n", 293 + "%s:%u: tag mismatch, got %llx, expected %llx\n", 294 294 __func__, __LINE__, tag, dev->tag); 295 295 296 296 if (res) { 297 - dev_err(&dev->sbd.core, "%s:%u: res=%d status=0x%lx\n", 297 + dev_err(&dev->sbd.core, "%s:%u: res=%d status=0x%llx\n", 298 298 __func__, __LINE__, res, status); 299 299 return IRQ_HANDLED; 300 300 } ··· 364 364 365 365 if (dev->blk_size != CD_FRAMESIZE) { 366 366 dev_err(&dev->sbd.core, 367 - "%s:%u: cannot handle block size %lu\n", __func__, 367 + "%s:%u: cannot handle block size %llu\n", __func__, 368 368 __LINE__, dev->blk_size); 369 369 return -EINVAL; 370 370 }
+1
drivers/serial/of_serial.c
··· 163 163 { .type = "serial", .compatible = "ns16450", .data = (void *)PORT_16450, }, 164 164 { .type = "serial", .compatible = "ns16550", .data = (void *)PORT_16550, }, 165 165 { .type = "serial", .compatible = "ns16750", .data = (void *)PORT_16750, }, 166 + { .type = "serial", .compatible = "ns16850", .data = (void *)PORT_16850, }, 166 167 #ifdef CONFIG_SERIAL_OF_PLATFORM_NWPSERIAL 167 168 { .type = "serial", .compatible = "ibm,qpace-nwp-serial", 168 169 .data = (void *)PORT_NWPSERIAL, },
+2 -2
drivers/video/ps3fb.c
··· 1006 1006 __func__, status); 1007 1007 return -ENXIO; 1008 1008 } 1009 - dev_dbg(dev, "video:%p ioif:%lx lpar:%lx size:%lx\n", 1009 + dev_dbg(dev, "video:%p ioif:%lx lpar:%llx size:%lx\n", 1010 1010 ps3fb_videomemory.address, GPU_IOIF, xdr_lpar, 1011 1011 ps3fb_videomemory.size); 1012 1012 ··· 1133 1133 __func__, status); 1134 1134 goto err; 1135 1135 } 1136 - dev_dbg(&dev->core, "ddr:lpar:0x%lx\n", ddr_lpar); 1136 + dev_dbg(&dev->core, "ddr:lpar:0x%llx\n", ddr_lpar); 1137 1137 1138 1138 status = lv1_gpu_context_allocate(ps3fb.memory_handle, 0, 1139 1139 &ps3fb.context_handle,
+2 -2
sound/ppc/snd_ps3.c
··· 477 477 card->dma_start_bus_addr[SND_PS3_CH_R] = 478 478 runtime->dma_addr + (runtime->dma_bytes / 2); 479 479 480 - pr_debug("%s: vaddr=%p bus=%#lx\n", __func__, 480 + pr_debug("%s: vaddr=%p bus=%#llx\n", __func__, 481 481 card->dma_start_vaddr[SND_PS3_CH_L], 482 482 card->dma_start_bus_addr[SND_PS3_CH_L]); 483 483 ··· 1030 1030 pr_info("%s: nullbuffer alloc failed\n", __func__); 1031 1031 goto clean_preallocate; 1032 1032 } 1033 - pr_debug("%s: null vaddr=%p dma=%#lx\n", __func__, 1033 + pr_debug("%s: null vaddr=%p dma=%#llx\n", __func__, 1034 1034 the_card.null_buffer_start_vaddr, 1035 1035 the_card.null_buffer_start_dma_addr); 1036 1036 /* set default sample rate/word width */