diff options
-rw-r--r-- | Documentation/DocBook/Makefile | 2 | ||||
-rw-r--r-- | Documentation/DocBook/sh.tmpl | 105 | ||||
-rw-r--r-- | Documentation/powerpc/booting-without-of.txt | 4 | ||||
-rw-r--r-- | Documentation/powerpc/eeh-pci-error-recovery.txt | 2 | ||||
-rw-r--r-- | arch/mn10300/kernel/module.c | 4 | ||||
-rw-r--r-- | arch/powerpc/Kconfig.debug | 2 | ||||
-rw-r--r-- | arch/powerpc/boot/io.h | 2 | ||||
-rw-r--r-- | arch/powerpc/include/asm/8253pit.h (renamed from include/asm-powerpc/8253pit.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/8xx_immap.h (renamed from include/asm-powerpc/8xx_immap.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/Kbuild (renamed from include/asm-powerpc/Kbuild) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/a.out.h (renamed from include/asm-powerpc/a.out.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/abs_addr.h (renamed from include/asm-powerpc/abs_addr.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/agp.h (renamed from include/asm-powerpc/agp.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/asm-compat.h (renamed from include/asm-powerpc/asm-compat.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/atomic.h (renamed from include/asm-powerpc/atomic.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/auxvec.h (renamed from include/asm-powerpc/auxvec.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/backlight.h (renamed from include/asm-powerpc/backlight.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/bitops.h (renamed from include/asm-powerpc/bitops.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/bootx.h (renamed from include/asm-powerpc/bootx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/btext.h (renamed from include/asm-powerpc/btext.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/bug.h (renamed from include/asm-powerpc/bug.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/bugs.h (renamed from include/asm-powerpc/bugs.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/byteorder.h (renamed from include/asm-powerpc/byteorder.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cache.h (renamed from include/asm-powerpc/cache.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cacheflush.h (renamed from include/asm-powerpc/cacheflush.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cell-pmu.h (renamed from include/asm-powerpc/cell-pmu.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cell-regs.h (renamed from include/asm-powerpc/cell-regs.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/checksum.h (renamed from include/asm-powerpc/checksum.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/clk_interface.h (renamed from include/asm-powerpc/clk_interface.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/code-patching.h (renamed from include/asm-powerpc/code-patching.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/compat.h (renamed from include/asm-powerpc/compat.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cpm.h (renamed from include/asm-powerpc/cpm.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cpm1.h (renamed from include/asm-powerpc/cpm1.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cpm2.h (renamed from include/asm-powerpc/cpm2.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cputable.h (renamed from include/asm-powerpc/cputable.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cputhreads.h (renamed from include/asm-powerpc/cputhreads.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/cputime.h (renamed from include/asm-powerpc/cputime.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/current.h (renamed from include/asm-powerpc/current.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/dbdma.h (renamed from include/asm-powerpc/dbdma.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/dcr-generic.h (renamed from include/asm-powerpc/dcr-generic.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/dcr-mmio.h (renamed from include/asm-powerpc/dcr-mmio.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/dcr-native.h (renamed from include/asm-powerpc/dcr-native.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/dcr-regs.h (renamed from include/asm-powerpc/dcr-regs.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/dcr.h (renamed from include/asm-powerpc/dcr.h) | 6 | ||||
-rw-r--r-- | arch/powerpc/include/asm/delay.h (renamed from include/asm-powerpc/delay.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/device.h (renamed from include/asm-powerpc/device.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/div64.h (renamed from include/asm-powerpc/div64.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/dma-mapping.h (renamed from include/asm-powerpc/dma-mapping.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/dma.h (renamed from include/asm-powerpc/dma.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/edac.h (renamed from include/asm-powerpc/edac.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/eeh.h (renamed from include/asm-powerpc/eeh.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/eeh_event.h (renamed from include/asm-powerpc/eeh_event.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/elf.h (renamed from include/asm-powerpc/elf.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/emergency-restart.h (renamed from include/asm-powerpc/emergency-restart.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/errno.h (renamed from include/asm-powerpc/errno.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/exception.h (renamed from include/asm-powerpc/exception.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/fb.h (renamed from include/asm-powerpc/fb.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/fcntl.h (renamed from include/asm-powerpc/fcntl.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/feature-fixups.h (renamed from include/asm-powerpc/feature-fixups.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/firmware.h (renamed from include/asm-powerpc/firmware.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/fixmap.h (renamed from include/asm-powerpc/fixmap.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/floppy.h (renamed from include/asm-powerpc/floppy.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/fs_pd.h (renamed from include/asm-powerpc/fs_pd.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/fsl_gtm.h (renamed from include/asm-powerpc/fsl_gtm.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/fsl_lbc.h (renamed from include/asm-powerpc/fsl_lbc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ftrace.h (renamed from include/asm-powerpc/ftrace.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/futex.h (renamed from include/asm-powerpc/futex.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/gpio.h (renamed from include/asm-powerpc/gpio.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/grackle.h (renamed from include/asm-powerpc/grackle.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/hardirq.h (renamed from include/asm-powerpc/hardirq.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/heathrow.h (renamed from include/asm-powerpc/heathrow.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/highmem.h (renamed from include/asm-powerpc/highmem.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/hugetlb.h (renamed from include/asm-powerpc/hugetlb.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/hvcall.h (renamed from include/asm-powerpc/hvcall.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/hvconsole.h (renamed from include/asm-powerpc/hvconsole.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/hvcserver.h (renamed from include/asm-powerpc/hvcserver.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/hw_irq.h (renamed from include/asm-powerpc/hw_irq.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/hydra.h (renamed from include/asm-powerpc/hydra.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/i8259.h (renamed from include/asm-powerpc/i8259.h) | 5 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ibmebus.h (renamed from include/asm-powerpc/ibmebus.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ide.h (renamed from include/asm-powerpc/ide.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/immap_86xx.h (renamed from include/asm-powerpc/immap_86xx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/immap_cpm2.h (renamed from include/asm-powerpc/immap_cpm2.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/immap_qe.h (renamed from include/asm-powerpc/immap_qe.h) | 2 | ||||
-rw-r--r-- | arch/powerpc/include/asm/io-defs.h (renamed from include/asm-powerpc/io-defs.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/io.h (renamed from include/asm-powerpc/io.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ioctl.h (renamed from include/asm-powerpc/ioctl.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ioctls.h (renamed from include/asm-powerpc/ioctls.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iommu.h (renamed from include/asm-powerpc/iommu.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ipcbuf.h (renamed from include/asm-powerpc/ipcbuf.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ipic.h (renamed from include/asm-powerpc/ipic.h) | 9 | ||||
-rw-r--r-- | arch/powerpc/include/asm/irq.h (renamed from include/asm-powerpc/irq.h) | 288 | ||||
-rw-r--r-- | arch/powerpc/include/asm/irq_regs.h (renamed from include/asm-powerpc/irq_regs.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/irqflags.h (renamed from include/asm-powerpc/irqflags.h) | 4 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/alpaca.h (renamed from include/asm-powerpc/iseries/alpaca.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/hv_call.h (renamed from include/asm-powerpc/iseries/hv_call.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/hv_call_event.h (renamed from include/asm-powerpc/iseries/hv_call_event.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/hv_call_sc.h (renamed from include/asm-powerpc/iseries/hv_call_sc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/hv_call_xm.h (renamed from include/asm-powerpc/iseries/hv_call_xm.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/hv_lp_config.h (renamed from include/asm-powerpc/iseries/hv_lp_config.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/hv_lp_event.h (renamed from include/asm-powerpc/iseries/hv_lp_event.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/hv_types.h (renamed from include/asm-powerpc/iseries/hv_types.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/iommu.h (renamed from include/asm-powerpc/iseries/iommu.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/it_lp_queue.h (renamed from include/asm-powerpc/iseries/it_lp_queue.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/lpar_map.h (renamed from include/asm-powerpc/iseries/lpar_map.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/mf.h (renamed from include/asm-powerpc/iseries/mf.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/iseries/vio.h (renamed from include/asm-powerpc/iseries/vio.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kdebug.h (renamed from include/asm-powerpc/kdebug.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kdump.h (renamed from include/asm-powerpc/kdump.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kexec.h (renamed from include/asm-powerpc/kexec.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/keylargo.h (renamed from include/asm-powerpc/keylargo.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kgdb.h (renamed from include/asm-powerpc/kgdb.h) | 2 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kmap_types.h (renamed from include/asm-powerpc/kmap_types.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kprobes.h (renamed from include/asm-powerpc/kprobes.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kvm.h (renamed from include/asm-powerpc/kvm.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kvm_asm.h (renamed from include/asm-powerpc/kvm_asm.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kvm_host.h (renamed from include/asm-powerpc/kvm_host.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kvm_para.h (renamed from include/asm-powerpc/kvm_para.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/kvm_ppc.h (renamed from include/asm-powerpc/kvm_ppc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/libata-portmap.h (renamed from include/asm-powerpc/libata-portmap.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/linkage.h (renamed from include/asm-powerpc/linkage.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/lmb.h (renamed from include/asm-powerpc/lmb.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/local.h (renamed from include/asm-powerpc/local.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/lppaca.h (renamed from include/asm-powerpc/lppaca.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/lv1call.h (renamed from include/asm-powerpc/lv1call.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/machdep.h (renamed from include/asm-powerpc/machdep.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/macio.h (renamed from include/asm-powerpc/macio.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mc146818rtc.h (renamed from include/asm-powerpc/mc146818rtc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mediabay.h (renamed from include/asm-powerpc/mediabay.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mman.h (renamed from include/asm-powerpc/mman.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmu-40x.h (renamed from include/asm-powerpc/mmu-40x.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmu-44x.h (renamed from include/asm-powerpc/mmu-44x.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmu-8xx.h (renamed from include/asm-powerpc/mmu-8xx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmu-fsl-booke.h (renamed from include/asm-powerpc/mmu-fsl-booke.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmu-hash32.h (renamed from include/asm-powerpc/mmu-hash32.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmu-hash64.h (renamed from include/asm-powerpc/mmu-hash64.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmu.h (renamed from include/asm-powerpc/mmu.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmu_context.h (renamed from include/asm-powerpc/mmu_context.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mmzone.h (renamed from include/asm-powerpc/mmzone.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/module.h (renamed from include/asm-powerpc/module.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mpc512x.h (renamed from include/asm-powerpc/mpc512x.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mpc52xx.h (renamed from include/asm-powerpc/mpc52xx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mpc52xx_psc.h (renamed from include/asm-powerpc/mpc52xx_psc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mpc6xx.h (renamed from include/asm-powerpc/mpc6xx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mpc8260.h (renamed from include/asm-powerpc/mpc8260.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mpc86xx.h (renamed from include/asm-powerpc/mpc86xx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mpc8xx.h (renamed from include/asm-powerpc/mpc8xx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mpic.h (renamed from include/asm-powerpc/mpic.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/msgbuf.h (renamed from include/asm-powerpc/msgbuf.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/mutex.h (renamed from include/asm-powerpc/mutex.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/nvram.h (renamed from include/asm-powerpc/nvram.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/of_device.h (renamed from include/asm-powerpc/of_device.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/of_platform.h (renamed from include/asm-powerpc/of_platform.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ohare.h (renamed from include/asm-powerpc/ohare.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/oprofile_impl.h (renamed from include/asm-powerpc/oprofile_impl.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pSeries_reconfig.h (renamed from include/asm-powerpc/pSeries_reconfig.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/paca.h (renamed from include/asm-powerpc/paca.h) | 2 | ||||
-rw-r--r-- | arch/powerpc/include/asm/page.h (renamed from include/asm-powerpc/page.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/page_32.h (renamed from include/asm-powerpc/page_32.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/page_64.h (renamed from include/asm-powerpc/page_64.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/param.h (renamed from include/asm-powerpc/param.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/parport.h (renamed from include/asm-powerpc/parport.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pasemi_dma.h (renamed from include/asm-powerpc/pasemi_dma.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pci-bridge.h (renamed from include/asm-powerpc/pci-bridge.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pci.h (renamed from include/asm-powerpc/pci.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/percpu.h (renamed from include/asm-powerpc/percpu.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pgalloc-32.h (renamed from include/asm-powerpc/pgalloc-32.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pgalloc-64.h (renamed from include/asm-powerpc/pgalloc-64.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pgalloc.h (renamed from include/asm-powerpc/pgalloc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pgtable-4k.h (renamed from include/asm-powerpc/pgtable-4k.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pgtable-64k.h (renamed from include/asm-powerpc/pgtable-64k.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pgtable-ppc32.h (renamed from include/asm-powerpc/pgtable-ppc32.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pgtable-ppc64.h (renamed from include/asm-powerpc/pgtable-ppc64.h) | 2 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pgtable.h (renamed from include/asm-powerpc/pgtable.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/phyp_dump.h (renamed from include/asm-powerpc/phyp_dump.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pmac_feature.h (renamed from include/asm-powerpc/pmac_feature.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pmac_low_i2c.h (renamed from include/asm-powerpc/pmac_low_i2c.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pmac_pfunc.h (renamed from include/asm-powerpc/pmac_pfunc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pmc.h (renamed from include/asm-powerpc/pmc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/pmi.h (renamed from include/asm-powerpc/pmi.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/poll.h (renamed from include/asm-powerpc/poll.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/posix_types.h (renamed from include/asm-powerpc/posix_types.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ppc-pci.h (renamed from include/asm-powerpc/ppc-pci.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ppc4xx.h (renamed from include/asm-powerpc/ppc4xx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ppc_asm.h (renamed from include/asm-powerpc/ppc_asm.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/processor.h (renamed from include/asm-powerpc/processor.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/prom.h (renamed from include/asm-powerpc/prom.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ps3.h (renamed from include/asm-powerpc/ps3.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ps3av.h (renamed from include/asm-powerpc/ps3av.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ps3fb.h (renamed from include/asm-powerpc/ps3fb.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ps3stor.h (renamed from include/asm-powerpc/ps3stor.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ptrace.h (renamed from include/asm-powerpc/ptrace.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/qe.h (renamed from include/asm-powerpc/qe.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/qe_ic.h (renamed from include/asm-powerpc/qe_ic.h) | 2 | ||||
-rw-r--r-- | arch/powerpc/include/asm/reg.h (renamed from include/asm-powerpc/reg.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/reg_8xx.h (renamed from include/asm-powerpc/reg_8xx.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/reg_booke.h (renamed from include/asm-powerpc/reg_booke.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/reg_fsl_emb.h (renamed from include/asm-powerpc/reg_fsl_emb.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/resource.h (renamed from include/asm-powerpc/resource.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/rheap.h (renamed from include/asm-powerpc/rheap.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/rio.h (renamed from include/asm-powerpc/rio.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/rtas.h (renamed from include/asm-powerpc/rtas.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/rtc.h (renamed from include/asm-powerpc/rtc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/rwsem.h (renamed from include/asm-powerpc/rwsem.h) | 4 | ||||
-rw-r--r-- | arch/powerpc/include/asm/scatterlist.h (renamed from include/asm-powerpc/scatterlist.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/seccomp.h (renamed from include/asm-powerpc/seccomp.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/sections.h (renamed from include/asm-powerpc/sections.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/sembuf.h (renamed from include/asm-powerpc/sembuf.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/serial.h (renamed from include/asm-powerpc/serial.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/setjmp.h (renamed from include/asm-powerpc/setjmp.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/setup.h (renamed from include/asm-powerpc/setup.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/shmbuf.h (renamed from include/asm-powerpc/shmbuf.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/shmparam.h (renamed from include/asm-powerpc/shmparam.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/sigcontext.h (renamed from include/asm-powerpc/sigcontext.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/siginfo.h (renamed from include/asm-powerpc/siginfo.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/signal.h (renamed from include/asm-powerpc/signal.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/smp.h (renamed from include/asm-powerpc/smp.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/smu.h (renamed from include/asm-powerpc/smu.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/socket.h (renamed from include/asm-powerpc/socket.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/sockios.h (renamed from include/asm-powerpc/sockios.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/sparsemem.h (renamed from include/asm-powerpc/sparsemem.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/spinlock.h (renamed from include/asm-powerpc/spinlock.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/spinlock_types.h (renamed from include/asm-powerpc/spinlock_types.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/spu.h (renamed from include/asm-powerpc/spu.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/spu_csa.h (renamed from include/asm-powerpc/spu_csa.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/spu_info.h (renamed from include/asm-powerpc/spu_info.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/spu_priv1.h (renamed from include/asm-powerpc/spu_priv1.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/sstep.h (renamed from include/asm-powerpc/sstep.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/stat.h (renamed from include/asm-powerpc/stat.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/statfs.h (renamed from include/asm-powerpc/statfs.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/string.h (renamed from include/asm-powerpc/string.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/suspend.h (renamed from include/asm-powerpc/suspend.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/synch.h (renamed from include/asm-powerpc/synch.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/syscall.h (renamed from include/asm-powerpc/syscall.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/syscalls.h (renamed from include/asm-powerpc/syscalls.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/systbl.h (renamed from include/asm-powerpc/systbl.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/system.h (renamed from include/asm-powerpc/system.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/tce.h (renamed from include/asm-powerpc/tce.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/termbits.h (renamed from include/asm-powerpc/termbits.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/termios.h (renamed from include/asm-powerpc/termios.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/thread_info.h (renamed from include/asm-powerpc/thread_info.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/time.h (renamed from include/asm-powerpc/time.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/timex.h (renamed from include/asm-powerpc/timex.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/tlb.h (renamed from include/asm-powerpc/tlb.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/tlbflush.h (renamed from include/asm-powerpc/tlbflush.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/topology.h (renamed from include/asm-powerpc/topology.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/tsi108.h (renamed from include/asm-powerpc/tsi108.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/tsi108_irq.h (renamed from include/asm-powerpc/tsi108_irq.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/tsi108_pci.h (renamed from include/asm-powerpc/tsi108_pci.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/types.h (renamed from include/asm-powerpc/types.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/uaccess.h (renamed from include/asm-powerpc/uaccess.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ucc.h (renamed from include/asm-powerpc/ucc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ucc_fast.h (renamed from include/asm-powerpc/ucc_fast.h) | 2 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ucc_slow.h (renamed from include/asm-powerpc/ucc_slow.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/ucontext.h (renamed from include/asm-powerpc/ucontext.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/udbg.h (renamed from include/asm-powerpc/udbg.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/uic.h (renamed from include/asm-powerpc/uic.h) | 2 | ||||
-rw-r--r-- | arch/powerpc/include/asm/unaligned.h (renamed from include/asm-powerpc/unaligned.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/uninorth.h (renamed from include/asm-powerpc/uninorth.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/unistd.h (renamed from include/asm-powerpc/unistd.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/user.h (renamed from include/asm-powerpc/user.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/vdso.h (renamed from include/asm-powerpc/vdso.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/vdso_datapage.h (renamed from include/asm-powerpc/vdso_datapage.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/vga.h (renamed from include/asm-powerpc/vga.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/vio.h (renamed from include/asm-powerpc/vio.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/xilinx_intc.h (renamed from include/asm-powerpc/xilinx_intc.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/xmon.h (renamed from include/asm-powerpc/xmon.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/include/asm/xor.h (renamed from include/asm-powerpc/xor.h) | 0 | ||||
-rw-r--r-- | arch/powerpc/kernel/Makefile | 14 | ||||
-rw-r--r-- | arch/powerpc/kernel/cpu_setup_44x.S | 6 | ||||
-rw-r--r-- | arch/powerpc/kernel/irq.c | 25 | ||||
-rw-r--r-- | arch/powerpc/kernel/process.c | 2 | ||||
-rw-r--r-- | arch/powerpc/kernel/vdso.c | 2 | ||||
-rw-r--r-- | arch/powerpc/lib/Makefile | 2 | ||||
-rw-r--r-- | arch/powerpc/mm/mem.c | 2 | ||||
-rw-r--r-- | arch/powerpc/mm/ppc_mmu_32.c | 4 | ||||
-rw-r--r-- | arch/powerpc/mm/tlb_64.c | 2 | ||||
-rw-r--r-- | arch/powerpc/platforms/52xx/Makefile | 4 | ||||
-rw-r--r-- | arch/powerpc/platforms/86xx/mpc86xx_smp.c | 2 | ||||
-rw-r--r-- | arch/powerpc/platforms/Makefile | 6 | ||||
-rw-r--r-- | arch/powerpc/platforms/powermac/Makefile | 3 | ||||
-rw-r--r-- | arch/powerpc/sysdev/Makefile | 2 | ||||
-rw-r--r-- | arch/s390/include/asm/Kbuild (renamed from include/asm-s390/Kbuild) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/airq.h (renamed from include/asm-s390/airq.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/appldata.h (renamed from include/asm-s390/appldata.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/atomic.h (renamed from include/asm-s390/atomic.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/auxvec.h (renamed from include/asm-s390/auxvec.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/bitops.h (renamed from include/asm-s390/bitops.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/bug.h (renamed from include/asm-s390/bug.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/bugs.h (renamed from include/asm-s390/bugs.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/byteorder.h (renamed from include/asm-s390/byteorder.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/cache.h (renamed from include/asm-s390/cache.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/cacheflush.h (renamed from include/asm-s390/cacheflush.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ccwdev.h (renamed from include/asm-s390/ccwdev.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ccwgroup.h (renamed from include/asm-s390/ccwgroup.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/checksum.h (renamed from include/asm-s390/checksum.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/chpid.h (renamed from include/asm-s390/chpid.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/chsc.h (renamed from include/asm-s390/chsc.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/cio.h (renamed from include/asm-s390/cio.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/cmb.h (renamed from include/asm-s390/cmb.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/compat.h (renamed from include/asm-s390/compat.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/cpcmd.h (renamed from include/asm-s390/cpcmd.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/cpu.h (renamed from include/asm-s390/cpu.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/cputime.h (renamed from include/asm-s390/cputime.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/current.h (renamed from include/asm-s390/current.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/dasd.h (renamed from include/asm-s390/dasd.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/debug.h (renamed from include/asm-s390/debug.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/delay.h (renamed from include/asm-s390/delay.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/device.h (renamed from include/asm-s390/device.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/diag.h (renamed from include/asm-s390/diag.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/div64.h (renamed from include/asm-s390/div64.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/dma.h (renamed from include/asm-s390/dma.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ebcdic.h (renamed from include/asm-s390/ebcdic.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/elf.h (renamed from include/asm-s390/elf.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/emergency-restart.h (renamed from include/asm-s390/emergency-restart.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/errno.h (renamed from include/asm-s390/errno.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/etr.h (renamed from include/asm-s390/etr.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/extmem.h (renamed from include/asm-s390/extmem.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/fb.h (renamed from include/asm-s390/fb.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/fcntl.h (renamed from include/asm-s390/fcntl.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/fcx.h (renamed from include/asm-s390/fcx.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/futex.h (renamed from include/asm-s390/futex.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/hardirq.h (renamed from include/asm-s390/hardirq.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/hugetlb.h (renamed from include/asm-s390/hugetlb.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/idals.h (renamed from include/asm-s390/idals.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/io.h (renamed from include/asm-s390/io.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ioctl.h (renamed from include/asm-s390/ioctl.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ioctls.h (renamed from include/asm-s390/ioctls.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ipcbuf.h (renamed from include/asm-s390/ipcbuf.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ipl.h (renamed from include/asm-s390/ipl.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/irq.h (renamed from include/asm-s390/irq.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/irq_regs.h (renamed from include/asm-s390/irq_regs.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/irqflags.h (renamed from include/asm-s390/irqflags.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/isc.h (renamed from include/asm-s390/isc.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/itcw.h (renamed from include/asm-s390/itcw.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/kdebug.h (renamed from include/asm-s390/kdebug.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/kexec.h (renamed from include/asm-s390/kexec.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/kmap_types.h (renamed from include/asm-s390/kmap_types.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/kprobes.h (renamed from include/asm-s390/kprobes.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/kvm.h (renamed from include/asm-s390/kvm.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/kvm_host.h (renamed from include/asm-s390/kvm_host.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/kvm_para.h (renamed from include/asm-s390/kvm_para.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/kvm_virtio.h (renamed from include/asm-s390/kvm_virtio.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/linkage.h (renamed from include/asm-s390/linkage.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/local.h (renamed from include/asm-s390/local.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/lowcore.h (renamed from include/asm-s390/lowcore.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/mathemu.h (renamed from include/asm-s390/mathemu.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/mman.h (renamed from include/asm-s390/mman.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/mmu.h (renamed from include/asm-s390/mmu.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/mmu_context.h (renamed from include/asm-s390/mmu_context.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/module.h (renamed from include/asm-s390/module.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/monwriter.h (renamed from include/asm-s390/monwriter.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/msgbuf.h (renamed from include/asm-s390/msgbuf.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/mutex.h (renamed from include/asm-s390/mutex.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/page.h (renamed from include/asm-s390/page.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/param.h (renamed from include/asm-s390/param.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/pci.h (renamed from include/asm-s390/pci.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/percpu.h (renamed from include/asm-s390/percpu.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/pgalloc.h (renamed from include/asm-s390/pgalloc.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/pgtable.h (renamed from include/asm-s390/pgtable.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/poll.h (renamed from include/asm-s390/poll.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/posix_types.h (renamed from include/asm-s390/posix_types.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/processor.h (renamed from include/asm-s390/processor.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ptrace.h (renamed from include/asm-s390/ptrace.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/qdio.h (renamed from include/asm-s390/qdio.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/qeth.h (renamed from include/asm-s390/qeth.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/reset.h (renamed from include/asm-s390/reset.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/resource.h (renamed from include/asm-s390/resource.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/rwsem.h (renamed from include/asm-s390/rwsem.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/s390_ext.h (renamed from include/asm-s390/s390_ext.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/s390_rdev.h (renamed from include/asm-s390/s390_rdev.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/scatterlist.h (renamed from include/asm-s390/scatterlist.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/schid.h (renamed from include/asm-s390/schid.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sclp.h (renamed from include/asm-s390/sclp.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sections.h (renamed from include/asm-s390/sections.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/segment.h (renamed from include/asm-s390/segment.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sembuf.h (renamed from include/asm-s390/sembuf.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/setup.h (renamed from include/asm-s390/setup.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sfp-machine.h (renamed from include/asm-s390/sfp-machine.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sfp-util.h (renamed from include/asm-s390/sfp-util.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/shmbuf.h (renamed from include/asm-s390/shmbuf.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/shmparam.h (renamed from include/asm-s390/shmparam.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sigcontext.h (renamed from include/asm-s390/sigcontext.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/siginfo.h (renamed from include/asm-s390/siginfo.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/signal.h (renamed from include/asm-s390/signal.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sigp.h (renamed from include/asm-s390/sigp.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/smp.h (renamed from include/asm-s390/smp.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/socket.h (renamed from include/asm-s390/socket.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sockios.h (renamed from include/asm-s390/sockios.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sparsemem.h (renamed from include/asm-s390/sparsemem.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/spinlock.h (renamed from include/asm-s390/spinlock.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/spinlock_types.h (renamed from include/asm-s390/spinlock_types.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/stat.h (renamed from include/asm-s390/stat.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/statfs.h (renamed from include/asm-s390/statfs.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/string.h (renamed from include/asm-s390/string.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/suspend.h (renamed from include/asm-s390/suspend.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/sysinfo.h (renamed from include/asm-s390/sysinfo.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/system.h (renamed from include/asm-s390/system.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/tape390.h (renamed from include/asm-s390/tape390.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/termbits.h (renamed from include/asm-s390/termbits.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/termios.h (renamed from include/asm-s390/termios.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/thread_info.h (renamed from include/asm-s390/thread_info.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/timer.h (renamed from include/asm-s390/timer.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/timex.h (renamed from include/asm-s390/timex.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/tlb.h (renamed from include/asm-s390/tlb.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/tlbflush.h (renamed from include/asm-s390/tlbflush.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/todclk.h (renamed from include/asm-s390/todclk.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/topology.h (renamed from include/asm-s390/topology.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/types.h (renamed from include/asm-s390/types.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/uaccess.h (renamed from include/asm-s390/uaccess.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/ucontext.h (renamed from include/asm-s390/ucontext.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/unaligned.h (renamed from include/asm-s390/unaligned.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/unistd.h (renamed from include/asm-s390/unistd.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/user.h (renamed from include/asm-s390/user.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/vtoc.h (renamed from include/asm-s390/vtoc.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/xor.h (renamed from include/asm-s390/xor.h) | 0 | ||||
-rw-r--r-- | arch/s390/include/asm/zcrypt.h (renamed from include/asm-s390/zcrypt.h) | 0 | ||||
-rw-r--r-- | arch/sh/Kconfig | 27 | ||||
-rw-r--r-- | arch/sh/Kconfig.debug | 2 | ||||
-rw-r--r-- | arch/sh/Makefile | 16 | ||||
-rw-r--r-- | arch/sh/boards/Makefile | 2 | ||||
-rw-r--r-- | arch/sh/boards/board-ap325rxa.c | 1 | ||||
-rw-r--r-- | arch/sh/boards/mach-se/7343/irq.c | 1 | ||||
-rw-r--r-- | arch/sh/configs/dreamcast_defconfig | 14 | ||||
-rw-r--r-- | arch/sh/include/asm/a.out.h | 20 | ||||
-rw-r--r-- | arch/sh/include/asm/ptrace.h | 9 | ||||
-rw-r--r-- | arch/sh/include/asm/seccomp.h | 10 | ||||
-rw-r--r-- | arch/sh/include/asm/thread_info.h | 51 | ||||
-rw-r--r-- | arch/sh/include/asm/tlb_64.h | 12 | ||||
-rw-r--r-- | arch/sh/include/cpu-sh2/cpu/cache.h | 6 | ||||
-rw-r--r-- | arch/sh/include/cpu-sh2a/cpu/addrspace.h | 10 | ||||
-rw-r--r-- | arch/sh/include/cpu-sh2a/cpu/cache.h | 3 | ||||
-rw-r--r-- | arch/sh/include/cpu-sh2a/cpu/cacheflush.h | 34 | ||||
-rw-r--r-- | arch/sh/kernel/cpu/sh4/sq.c | 2 | ||||
-rw-r--r-- | arch/sh/kernel/cpu/sh5/entry.S | 19 | ||||
-rw-r--r-- | arch/sh/kernel/entry-common.S | 16 | ||||
-rw-r--r-- | arch/sh/kernel/machine_kexec.c | 8 | ||||
-rw-r--r-- | arch/sh/kernel/module.c | 7 | ||||
-rw-r--r-- | arch/sh/kernel/ptrace_32.c | 157 | ||||
-rw-r--r-- | arch/sh/kernel/ptrace_64.c | 144 | ||||
-rw-r--r-- | arch/sh/kernel/setup.c | 20 | ||||
-rw-r--r-- | arch/sh/kernel/signal_32.c | 22 | ||||
-rw-r--r-- | arch/sh/kernel/signal_64.c | 166 | ||||
-rw-r--r-- | arch/sh/mm/Kconfig | 1 | ||||
-rw-r--r-- | arch/sh/mm/Makefile_32 | 11 | ||||
-rw-r--r-- | arch/sh/mm/cache-sh2.c | 45 | ||||
-rw-r--r-- | arch/sh/mm/cache-sh2a.c | 129 | ||||
-rw-r--r-- | arch/sh/mm/tlb-sh5.c | 20 | ||||
-rw-r--r-- | arch/sh/tools/Makefile | 4 | ||||
-rw-r--r-- | block/scsi_ioctl.c | 2 | ||||
-rw-r--r-- | drivers/char/efirtc.c | 1 | ||||
-rw-r--r-- | drivers/char/hvc_console.h | 2 | ||||
-rw-r--r-- | drivers/char/hvcs.c | 2 | ||||
-rw-r--r-- | drivers/char/vt.c | 2 | ||||
-rw-r--r-- | drivers/infiniband/hw/ehca/ehca_reqs.c | 2 | ||||
-rw-r--r-- | drivers/input/keyboard/maple_keyb.c | 172 | ||||
-rw-r--r-- | drivers/isdn/Makefile | 2 | ||||
-rw-r--r-- | drivers/isdn/hardware/mISDN/hfcmulti.c | 37 | ||||
-rw-r--r-- | drivers/isdn/hardware/mISDN/hfcpci.c | 2 | ||||
-rw-r--r-- | drivers/isdn/mISDN/l1oip_core.c | 6 | ||||
-rw-r--r-- | drivers/isdn/mISDN/socket.c | 4 | ||||
-rw-r--r-- | drivers/net/stnic.c | 2 | ||||
-rw-r--r-- | drivers/pcmcia/rsrc_nonstatic.c | 2 | ||||
-rw-r--r-- | drivers/scsi/hptiop.c | 7 | ||||
-rw-r--r-- | drivers/scsi/scsi_transport_spi.c | 8 | ||||
-rw-r--r-- | drivers/scsi/sd.c | 21 | ||||
-rw-r--r-- | drivers/scsi/sd.h | 6 | ||||
-rw-r--r-- | drivers/scsi/ses.c | 18 | ||||
-rw-r--r-- | drivers/serial/bfin_5xx.c | 2 | ||||
-rw-r--r-- | drivers/serial/crisv10.c | 79 | ||||
-rw-r--r-- | drivers/serial/crisv10.h | 3 | ||||
-rw-r--r-- | drivers/sh/maple/maple.c | 65 | ||||
-rw-r--r-- | drivers/spi/atmel_spi.c | 17 | ||||
-rw-r--r-- | drivers/spi/spi_s3c24xx.c | 25 | ||||
-rw-r--r-- | drivers/watchdog/ar7_wdt.c | 29 | ||||
-rw-r--r-- | drivers/watchdog/it8712f_wdt.c | 77 | ||||
-rw-r--r-- | drivers/watchdog/s3c2410_wdt.c | 148 | ||||
-rw-r--r-- | drivers/watchdog/sc1200wdt.c | 205 | ||||
-rw-r--r-- | drivers/watchdog/wdt.c | 176 | ||||
-rw-r--r-- | drivers/watchdog/wdt_pci.c | 301 | ||||
-rw-r--r-- | firmware/ihex2fw.c | 6 | ||||
-rw-r--r-- | fs/nfs/nfsroot.c | 2 | ||||
-rw-r--r-- | fs/ufs/super.c | 2 | ||||
-rw-r--r-- | include/asm-m68k/contregs.h | 51 | ||||
-rw-r--r-- | include/asm-m68k/fbio.h | 331 | ||||
-rw-r--r-- | include/asm-m68k/idprom.h | 21 | ||||
-rw-r--r-- | include/linux/ihex.h | 2 | ||||
-rw-r--r-- | include/linux/mISDNif.h | 32 | ||||
-rw-r--r-- | include/linux/maple.h | 8 | ||||
-rw-r--r-- | include/linux/parser.h | 2 | ||||
-rw-r--r-- | include/linux/tracehook.h | 5 | ||||
-rw-r--r-- | include/linux/vt_kern.h | 1 | ||||
-rw-r--r-- | include/scsi/scsi_device.h | 3 | ||||
-rw-r--r-- | kernel/auditsc.c | 7 | ||||
-rw-r--r-- | kernel/sched.c | 22 | ||||
-rw-r--r-- | mm/memory.c | 16 | ||||
-rw-r--r-- | mm/mlock.c | 2 | ||||
-rw-r--r-- | mm/nommu.c | 21 | ||||
-rw-r--r-- | scripts/kconfig/conf.c | 2 | ||||
-rw-r--r-- | scripts/kconfig/confdata.c | 8 | ||||
-rw-r--r-- | sound/core/seq/oss/seq_oss_synth.c | 3 |
501 files changed, 1987 insertions, 1501 deletions
diff --git a/Documentation/DocBook/Makefile b/Documentation/DocBook/Makefile index 0eb0d027eb32..1d1b34500b69 100644 --- a/Documentation/DocBook/Makefile +++ b/Documentation/DocBook/Makefile @@ -12,7 +12,7 @@ DOCBOOKS := wanbook.xml z8530book.xml mcabook.xml videobook.xml \ kernel-api.xml filesystems.xml lsm.xml usb.xml kgdb.xml \ gadget.xml libata.xml mtdnand.xml librs.xml rapidio.xml \ genericirq.xml s390-drivers.xml uio-howto.xml scsi.xml \ - mac80211.xml debugobjects.xml + mac80211.xml debugobjects.xml sh.xml ### # The build process is as follows (targets): diff --git a/Documentation/DocBook/sh.tmpl b/Documentation/DocBook/sh.tmpl new file mode 100644 index 000000000000..0c3dc4c69dd1 --- /dev/null +++ b/Documentation/DocBook/sh.tmpl @@ -0,0 +1,105 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" + "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" []> + +<book id="sh-drivers"> + <bookinfo> + <title>SuperH Interfaces Guide</title> + + <authorgroup> + <author> + <firstname>Paul</firstname> + <surname>Mundt</surname> + <affiliation> + <address> + <email>lethal@linux-sh.org</email> + </address> + </affiliation> + </author> + </authorgroup> + + <copyright> + <year>2008</year> + <holder>Paul Mundt</holder> + </copyright> + <copyright> + <year>2008</year> + <holder>Renesas Technology Corp.</holder> + </copyright> + + <legalnotice> + <para> + This documentation is free software; you can redistribute + it and/or modify it under the terms of the GNU General Public + License version 2 as published by the Free Software Foundation. + </para> + + <para> + This program is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied + warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + See the GNU General Public License for more details. + </para> + + <para> + You should have received a copy of the GNU General Public + License along with this program; if not, write to the Free + Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, + MA 02111-1307 USA + </para> + + <para> + For more details see the file COPYING in the source + distribution of Linux. + </para> + </legalnotice> + </bookinfo> + +<toc></toc> + + <chapter id="mm"> + <title>Memory Management</title> + <sect1 id="sh4"> + <title>SH-4</title> + <sect2 id="sq"> + <title>Store Queue API</title> +!Earch/sh/kernel/cpu/sh4/sq.c + </sect2> + </sect1> + <sect1 id="sh5"> + <title>SH-5</title> + <sect2 id="tlb"> + <title>TLB Interfaces</title> +!Iarch/sh/mm/tlb-sh5.c +!Iarch/sh/include/asm/tlb_64.h + </sect2> + </sect1> + </chapter> + <chapter id="clk"> + <title>Clock Framework Extensions</title> +!Iarch/sh/include/asm/clock.h + </chapter> + <chapter id="mach"> + <title>Machine Specific Interfaces</title> + <sect1 id="dreamcast"> + <title>mach-dreamcast</title> +!Iarch/sh/boards/mach-dreamcast/rtc.c + </sect1> + <sect1 id="x3proto"> + <title>mach-x3proto</title> +!Earch/sh/boards/mach-x3proto/ilsel.c + </sect1> + </chapter> + <chapter id="busses"> + <title>Busses</title> + <sect1 id="superhyway"> + <title>SuperHyway</title> +!Edrivers/sh/superhyway/superhyway.c + </sect1> + + <sect1 id="maple"> + <title>Maple</title> +!Edrivers/sh/maple/maple.c + </sect1> + </chapter> +</book> diff --git a/Documentation/powerpc/booting-without-of.txt b/Documentation/powerpc/booting-without-of.txt index 928a79ceb7aa..de4063cb4fdc 100644 --- a/Documentation/powerpc/booting-without-of.txt +++ b/Documentation/powerpc/booting-without-of.txt @@ -278,7 +278,7 @@ it with special cases. a 64-bit platform. d) request and get assigned a platform number (see PLATFORM_* - constants in include/asm-powerpc/processor.h + constants in arch/powerpc/include/asm/processor.h 32-bit embedded kernels: @@ -340,7 +340,7 @@ the block to RAM before passing it to the kernel. --------- The kernel is entered with r3 pointing to an area of memory that is - roughly described in include/asm-powerpc/prom.h by the structure + roughly described in arch/powerpc/include/asm/prom.h by the structure boot_param_header: struct boot_param_header { diff --git a/Documentation/powerpc/eeh-pci-error-recovery.txt b/Documentation/powerpc/eeh-pci-error-recovery.txt index df7afe43d462..9d4e33df624c 100644 --- a/Documentation/powerpc/eeh-pci-error-recovery.txt +++ b/Documentation/powerpc/eeh-pci-error-recovery.txt @@ -133,7 +133,7 @@ error. Given an arbitrary address, the routine pci_get_device_by_addr() will find the pci device associated with that address (if any). -The default include/asm-powerpc/io.h macros readb(), inb(), insb(), +The default arch/powerpc/include/asm/io.h macros readb(), inb(), insb(), etc. include a check to see if the i/o read returned all-0xff's. If so, these make a call to eeh_dn_check_failure(), which in turn asks the firmware if the all-ff's value is the sign of a true EEH diff --git a/arch/mn10300/kernel/module.c b/arch/mn10300/kernel/module.c index 0e4d2f6fa6e8..8fa36893df7a 100644 --- a/arch/mn10300/kernel/module.c +++ b/arch/mn10300/kernel/module.c @@ -24,6 +24,7 @@ #include <linux/fs.h> #include <linux/string.h> #include <linux/kernel.h> +#include <linux/bug.h> #if 0 #define DEBUGP printk @@ -195,7 +196,7 @@ int module_finalize(const Elf_Ehdr *hdr, const Elf_Shdr *sechdrs, struct module *me) { - return 0; + return module_bug_finalize(hdr, sechdrs, me); } /* @@ -203,4 +204,5 @@ int module_finalize(const Elf_Ehdr *hdr, */ void module_arch_cleanup(struct module *mod) { + module_bug_cleanup(mod); } diff --git a/arch/powerpc/Kconfig.debug b/arch/powerpc/Kconfig.debug index 8c8aadbe9563..4ebc52a19f0a 100644 --- a/arch/powerpc/Kconfig.debug +++ b/arch/powerpc/Kconfig.debug @@ -97,7 +97,7 @@ config IRQSTACKS config VIRQ_DEBUG bool "Expose hardware/virtual IRQ mapping via debugfs" - depends on DEBUG_FS && PPC_MERGE + depends on DEBUG_FS help This option will show the mapping relationship between hardware irq numbers and virtual irq numbers. The mapping is exposed via debugfs diff --git a/arch/powerpc/boot/io.h b/arch/powerpc/boot/io.h index ccaedaec50d5..7c09f4861fe1 100644 --- a/arch/powerpc/boot/io.h +++ b/arch/powerpc/boot/io.h @@ -6,7 +6,7 @@ /* * Low-level I/O routines. * - * Copied from <file:include/asm-powerpc/io.h> (which has no copyright) + * Copied from <file:arch/powerpc/include/asm/io.h> (which has no copyright) */ static inline int in_8(const volatile unsigned char *addr) { diff --git a/include/asm-powerpc/8253pit.h b/arch/powerpc/include/asm/8253pit.h index b70d6e53b303..b70d6e53b303 100644 --- a/include/asm-powerpc/8253pit.h +++ b/arch/powerpc/include/asm/8253pit.h diff --git a/include/asm-powerpc/8xx_immap.h b/arch/powerpc/include/asm/8xx_immap.h index 4b0e15206006..4b0e15206006 100644 --- a/include/asm-powerpc/8xx_immap.h +++ b/arch/powerpc/include/asm/8xx_immap.h diff --git a/include/asm-powerpc/Kbuild b/arch/powerpc/include/asm/Kbuild index 5ab7d7fe198c..5ab7d7fe198c 100644 --- a/include/asm-powerpc/Kbuild +++ b/arch/powerpc/include/asm/Kbuild diff --git a/include/asm-powerpc/a.out.h b/arch/powerpc/include/asm/a.out.h index 89cead6b176e..89cead6b176e 100644 --- a/include/asm-powerpc/a.out.h +++ b/arch/powerpc/include/asm/a.out.h diff --git a/include/asm-powerpc/abs_addr.h b/arch/powerpc/include/asm/abs_addr.h index 98324c5a8286..98324c5a8286 100644 --- a/include/asm-powerpc/abs_addr.h +++ b/arch/powerpc/include/asm/abs_addr.h diff --git a/include/asm-powerpc/agp.h b/arch/powerpc/include/asm/agp.h index 86455c4c31ee..86455c4c31ee 100644 --- a/include/asm-powerpc/agp.h +++ b/arch/powerpc/include/asm/agp.h diff --git a/include/asm-powerpc/asm-compat.h b/arch/powerpc/include/asm/asm-compat.h index 8f0fe7971949..8f0fe7971949 100644 --- a/include/asm-powerpc/asm-compat.h +++ b/arch/powerpc/include/asm/asm-compat.h diff --git a/include/asm-powerpc/atomic.h b/arch/powerpc/include/asm/atomic.h index f3fc733758f5..f3fc733758f5 100644 --- a/include/asm-powerpc/atomic.h +++ b/arch/powerpc/include/asm/atomic.h diff --git a/include/asm-powerpc/auxvec.h b/arch/powerpc/include/asm/auxvec.h index 19a099b62cd6..19a099b62cd6 100644 --- a/include/asm-powerpc/auxvec.h +++ b/arch/powerpc/include/asm/auxvec.h diff --git a/include/asm-powerpc/backlight.h b/arch/powerpc/include/asm/backlight.h index 8cf5c37c3817..8cf5c37c3817 100644 --- a/include/asm-powerpc/backlight.h +++ b/arch/powerpc/include/asm/backlight.h diff --git a/include/asm-powerpc/bitops.h b/arch/powerpc/include/asm/bitops.h index 897eade3afbe..897eade3afbe 100644 --- a/include/asm-powerpc/bitops.h +++ b/arch/powerpc/include/asm/bitops.h diff --git a/include/asm-powerpc/bootx.h b/arch/powerpc/include/asm/bootx.h index 57b82e3f89ce..57b82e3f89ce 100644 --- a/include/asm-powerpc/bootx.h +++ b/arch/powerpc/include/asm/bootx.h diff --git a/include/asm-powerpc/btext.h b/arch/powerpc/include/asm/btext.h index 906f46e31006..906f46e31006 100644 --- a/include/asm-powerpc/btext.h +++ b/arch/powerpc/include/asm/btext.h diff --git a/include/asm-powerpc/bug.h b/arch/powerpc/include/asm/bug.h index e55d1f66b86f..e55d1f66b86f 100644 --- a/include/asm-powerpc/bug.h +++ b/arch/powerpc/include/asm/bug.h diff --git a/include/asm-powerpc/bugs.h b/arch/powerpc/include/asm/bugs.h index 42fdb73e3068..42fdb73e3068 100644 --- a/include/asm-powerpc/bugs.h +++ b/arch/powerpc/include/asm/bugs.h diff --git a/include/asm-powerpc/byteorder.h b/arch/powerpc/include/asm/byteorder.h index b37752214a16..b37752214a16 100644 --- a/include/asm-powerpc/byteorder.h +++ b/arch/powerpc/include/asm/byteorder.h diff --git a/include/asm-powerpc/cache.h b/arch/powerpc/include/asm/cache.h index 81de6eb3455d..81de6eb3455d 100644 --- a/include/asm-powerpc/cache.h +++ b/arch/powerpc/include/asm/cache.h diff --git a/include/asm-powerpc/cacheflush.h b/arch/powerpc/include/asm/cacheflush.h index ba667a383b8c..ba667a383b8c 100644 --- a/include/asm-powerpc/cacheflush.h +++ b/arch/powerpc/include/asm/cacheflush.h diff --git a/include/asm-powerpc/cell-pmu.h b/arch/powerpc/include/asm/cell-pmu.h index 8066eede3a0c..8066eede3a0c 100644 --- a/include/asm-powerpc/cell-pmu.h +++ b/arch/powerpc/include/asm/cell-pmu.h diff --git a/include/asm-powerpc/cell-regs.h b/arch/powerpc/include/asm/cell-regs.h index fd6fd00434ef..fd6fd00434ef 100644 --- a/include/asm-powerpc/cell-regs.h +++ b/arch/powerpc/include/asm/cell-regs.h diff --git a/include/asm-powerpc/checksum.h b/arch/powerpc/include/asm/checksum.h index 7cdf358337cf..7cdf358337cf 100644 --- a/include/asm-powerpc/checksum.h +++ b/arch/powerpc/include/asm/checksum.h diff --git a/include/asm-powerpc/clk_interface.h b/arch/powerpc/include/asm/clk_interface.h index ab1882c1e176..ab1882c1e176 100644 --- a/include/asm-powerpc/clk_interface.h +++ b/arch/powerpc/include/asm/clk_interface.h diff --git a/include/asm-powerpc/code-patching.h b/arch/powerpc/include/asm/code-patching.h index 107d9b915e33..107d9b915e33 100644 --- a/include/asm-powerpc/code-patching.h +++ b/arch/powerpc/include/asm/code-patching.h diff --git a/include/asm-powerpc/compat.h b/arch/powerpc/include/asm/compat.h index d811a8cd7b58..d811a8cd7b58 100644 --- a/include/asm-powerpc/compat.h +++ b/arch/powerpc/include/asm/compat.h diff --git a/include/asm-powerpc/cpm.h b/arch/powerpc/include/asm/cpm.h index 24d79e3abd8e..24d79e3abd8e 100644 --- a/include/asm-powerpc/cpm.h +++ b/arch/powerpc/include/asm/cpm.h diff --git a/include/asm-powerpc/cpm1.h b/arch/powerpc/include/asm/cpm1.h index 2ff798744c1d..2ff798744c1d 100644 --- a/include/asm-powerpc/cpm1.h +++ b/arch/powerpc/include/asm/cpm1.h diff --git a/include/asm-powerpc/cpm2.h b/arch/powerpc/include/asm/cpm2.h index 2a6fa0183ac9..2a6fa0183ac9 100644 --- a/include/asm-powerpc/cpm2.h +++ b/arch/powerpc/include/asm/cpm2.h diff --git a/include/asm-powerpc/cputable.h b/arch/powerpc/include/asm/cputable.h index ef8a248dfd55..ef8a248dfd55 100644 --- a/include/asm-powerpc/cputable.h +++ b/arch/powerpc/include/asm/cputable.h diff --git a/include/asm-powerpc/cputhreads.h b/arch/powerpc/include/asm/cputhreads.h index fb11b0c459b8..fb11b0c459b8 100644 --- a/include/asm-powerpc/cputhreads.h +++ b/arch/powerpc/include/asm/cputhreads.h diff --git a/include/asm-powerpc/cputime.h b/arch/powerpc/include/asm/cputime.h index f42e623030ee..f42e623030ee 100644 --- a/include/asm-powerpc/cputime.h +++ b/arch/powerpc/include/asm/cputime.h diff --git a/include/asm-powerpc/current.h b/arch/powerpc/include/asm/current.h index e2c7f06931e7..e2c7f06931e7 100644 --- a/include/asm-powerpc/current.h +++ b/arch/powerpc/include/asm/current.h diff --git a/include/asm-powerpc/dbdma.h b/arch/powerpc/include/asm/dbdma.h index e23f07e73cb3..e23f07e73cb3 100644 --- a/include/asm-powerpc/dbdma.h +++ b/arch/powerpc/include/asm/dbdma.h diff --git a/include/asm-powerpc/dcr-generic.h b/arch/powerpc/include/asm/dcr-generic.h index 35b71599ec46..35b71599ec46 100644 --- a/include/asm-powerpc/dcr-generic.h +++ b/arch/powerpc/include/asm/dcr-generic.h diff --git a/include/asm-powerpc/dcr-mmio.h b/arch/powerpc/include/asm/dcr-mmio.h index acd491dbd45a..acd491dbd45a 100644 --- a/include/asm-powerpc/dcr-mmio.h +++ b/arch/powerpc/include/asm/dcr-mmio.h diff --git a/include/asm-powerpc/dcr-native.h b/arch/powerpc/include/asm/dcr-native.h index 72d2b72c7390..72d2b72c7390 100644 --- a/include/asm-powerpc/dcr-native.h +++ b/arch/powerpc/include/asm/dcr-native.h diff --git a/include/asm-powerpc/dcr-regs.h b/arch/powerpc/include/asm/dcr-regs.h index 29b0ecef980a..29b0ecef980a 100644 --- a/include/asm-powerpc/dcr-regs.h +++ b/arch/powerpc/include/asm/dcr-regs.h diff --git a/include/asm-powerpc/dcr.h b/arch/powerpc/include/asm/dcr.h index 53b283050ab3..d13fb68bb5c0 100644 --- a/include/asm-powerpc/dcr.h +++ b/arch/powerpc/include/asm/dcr.h @@ -65,17 +65,13 @@ typedef dcr_host_mmio_t dcr_host_t; #endif /* defined(CONFIG_PPC_DCR_NATIVE) && defined(CONFIG_PPC_DCR_MMIO) */ /* - * On CONFIG_PPC_MERGE, we have additional helpers to read the DCR - * base from the device-tree + * additional helpers to read the DCR * base from the device-tree */ -#ifdef CONFIG_PPC_MERGE struct device_node; extern unsigned int dcr_resource_start(struct device_node *np, unsigned int index); extern unsigned int dcr_resource_len(struct device_node *np, unsigned int index); -#endif /* CONFIG_PPC_MERGE */ - #endif /* CONFIG_PPC_DCR */ #endif /* __ASSEMBLY__ */ #endif /* __KERNEL__ */ diff --git a/include/asm-powerpc/delay.h b/arch/powerpc/include/asm/delay.h index f9200a65c632..f9200a65c632 100644 --- a/include/asm-powerpc/delay.h +++ b/arch/powerpc/include/asm/delay.h diff --git a/include/asm-powerpc/device.h b/arch/powerpc/include/asm/device.h index 228ab2a315b9..228ab2a315b9 100644 --- a/include/asm-powerpc/device.h +++ b/arch/powerpc/include/asm/device.h diff --git a/include/asm-powerpc/div64.h b/arch/powerpc/include/asm/div64.h index 6cd978cefb28..6cd978cefb28 100644 --- a/include/asm-powerpc/div64.h +++ b/arch/powerpc/include/asm/div64.h diff --git a/include/asm-powerpc/dma-mapping.h b/arch/powerpc/include/asm/dma-mapping.h index c7ca45f97dd2..c7ca45f97dd2 100644 --- a/include/asm-powerpc/dma-mapping.h +++ b/arch/powerpc/include/asm/dma-mapping.h diff --git a/include/asm-powerpc/dma.h b/arch/powerpc/include/asm/dma.h index a7e06e25c708..a7e06e25c708 100644 --- a/include/asm-powerpc/dma.h +++ b/arch/powerpc/include/asm/dma.h diff --git a/include/asm-powerpc/edac.h b/arch/powerpc/include/asm/edac.h index 6ead88bbfbb8..6ead88bbfbb8 100644 --- a/include/asm-powerpc/edac.h +++ b/arch/powerpc/include/asm/edac.h diff --git a/include/asm-powerpc/eeh.h b/arch/powerpc/include/asm/eeh.h index b886bec67016..b886bec67016 100644 --- a/include/asm-powerpc/eeh.h +++ b/arch/powerpc/include/asm/eeh.h diff --git a/include/asm-powerpc/eeh_event.h b/arch/powerpc/include/asm/eeh_event.h index cc3cb04539ac..cc3cb04539ac 100644 --- a/include/asm-powerpc/eeh_event.h +++ b/arch/powerpc/include/asm/eeh_event.h diff --git a/include/asm-powerpc/elf.h b/arch/powerpc/include/asm/elf.h index 80d1f399ee51..80d1f399ee51 100644 --- a/include/asm-powerpc/elf.h +++ b/arch/powerpc/include/asm/elf.h diff --git a/include/asm-powerpc/emergency-restart.h b/arch/powerpc/include/asm/emergency-restart.h index 3711bd9d50bd..3711bd9d50bd 100644 --- a/include/asm-powerpc/emergency-restart.h +++ b/arch/powerpc/include/asm/emergency-restart.h diff --git a/include/asm-powerpc/errno.h b/arch/powerpc/include/asm/errno.h index 8c145fd17d86..8c145fd17d86 100644 --- a/include/asm-powerpc/errno.h +++ b/arch/powerpc/include/asm/errno.h diff --git a/include/asm-powerpc/exception.h b/arch/powerpc/include/asm/exception.h index 329148b5acc6..329148b5acc6 100644 --- a/include/asm-powerpc/exception.h +++ b/arch/powerpc/include/asm/exception.h diff --git a/include/asm-powerpc/fb.h b/arch/powerpc/include/asm/fb.h index 411af8d17a69..411af8d17a69 100644 --- a/include/asm-powerpc/fb.h +++ b/arch/powerpc/include/asm/fb.h diff --git a/include/asm-powerpc/fcntl.h b/arch/powerpc/include/asm/fcntl.h index ce5c4516d404..ce5c4516d404 100644 --- a/include/asm-powerpc/fcntl.h +++ b/arch/powerpc/include/asm/fcntl.h diff --git a/include/asm-powerpc/feature-fixups.h b/arch/powerpc/include/asm/feature-fixups.h index a1029967620b..a1029967620b 100644 --- a/include/asm-powerpc/feature-fixups.h +++ b/arch/powerpc/include/asm/feature-fixups.h diff --git a/include/asm-powerpc/firmware.h b/arch/powerpc/include/asm/firmware.h index 3a179827528d..3a179827528d 100644 --- a/include/asm-powerpc/firmware.h +++ b/arch/powerpc/include/asm/firmware.h diff --git a/include/asm-powerpc/fixmap.h b/arch/powerpc/include/asm/fixmap.h index 8428b38a3d30..8428b38a3d30 100644 --- a/include/asm-powerpc/fixmap.h +++ b/arch/powerpc/include/asm/fixmap.h diff --git a/include/asm-powerpc/floppy.h b/arch/powerpc/include/asm/floppy.h index 24bd34c57e9d..24bd34c57e9d 100644 --- a/include/asm-powerpc/floppy.h +++ b/arch/powerpc/include/asm/floppy.h diff --git a/include/asm-powerpc/fs_pd.h b/arch/powerpc/include/asm/fs_pd.h index 9361cd5342cc..9361cd5342cc 100644 --- a/include/asm-powerpc/fs_pd.h +++ b/arch/powerpc/include/asm/fs_pd.h diff --git a/include/asm-powerpc/fsl_gtm.h b/arch/powerpc/include/asm/fsl_gtm.h index 8e8c9b5032d3..8e8c9b5032d3 100644 --- a/include/asm-powerpc/fsl_gtm.h +++ b/arch/powerpc/include/asm/fsl_gtm.h diff --git a/include/asm-powerpc/fsl_lbc.h b/arch/powerpc/include/asm/fsl_lbc.h index 303f5484c050..303f5484c050 100644 --- a/include/asm-powerpc/fsl_lbc.h +++ b/arch/powerpc/include/asm/fsl_lbc.h diff --git a/include/asm-powerpc/ftrace.h b/arch/powerpc/include/asm/ftrace.h index de921326cca8..de921326cca8 100644 --- a/include/asm-powerpc/ftrace.h +++ b/arch/powerpc/include/asm/ftrace.h diff --git a/include/asm-powerpc/futex.h b/arch/powerpc/include/asm/futex.h index 6d406c5c5de4..6d406c5c5de4 100644 --- a/include/asm-powerpc/futex.h +++ b/arch/powerpc/include/asm/futex.h diff --git a/include/asm-powerpc/gpio.h b/arch/powerpc/include/asm/gpio.h index ea04632399d8..ea04632399d8 100644 --- a/include/asm-powerpc/gpio.h +++ b/arch/powerpc/include/asm/gpio.h diff --git a/include/asm-powerpc/grackle.h b/arch/powerpc/include/asm/grackle.h index bd7812a519d4..bd7812a519d4 100644 --- a/include/asm-powerpc/grackle.h +++ b/arch/powerpc/include/asm/grackle.h diff --git a/include/asm-powerpc/hardirq.h b/arch/powerpc/include/asm/hardirq.h index 288e14d53b7f..288e14d53b7f 100644 --- a/include/asm-powerpc/hardirq.h +++ b/arch/powerpc/include/asm/hardirq.h diff --git a/include/asm-powerpc/heathrow.h b/arch/powerpc/include/asm/heathrow.h index 93f54958a9d1..93f54958a9d1 100644 --- a/include/asm-powerpc/heathrow.h +++ b/arch/powerpc/include/asm/heathrow.h diff --git a/include/asm-powerpc/highmem.h b/arch/powerpc/include/asm/highmem.h index 5d99b6489d56..5d99b6489d56 100644 --- a/include/asm-powerpc/highmem.h +++ b/arch/powerpc/include/asm/highmem.h diff --git a/include/asm-powerpc/hugetlb.h b/arch/powerpc/include/asm/hugetlb.h index 26f0d0ab27a5..26f0d0ab27a5 100644 --- a/include/asm-powerpc/hugetlb.h +++ b/arch/powerpc/include/asm/hugetlb.h diff --git a/include/asm-powerpc/hvcall.h b/arch/powerpc/include/asm/hvcall.h index fbe2932fa9e9..fbe2932fa9e9 100644 --- a/include/asm-powerpc/hvcall.h +++ b/arch/powerpc/include/asm/hvcall.h diff --git a/include/asm-powerpc/hvconsole.h b/arch/powerpc/include/asm/hvconsole.h index 35ea69e8121f..35ea69e8121f 100644 --- a/include/asm-powerpc/hvconsole.h +++ b/arch/powerpc/include/asm/hvconsole.h diff --git a/include/asm-powerpc/hvcserver.h b/arch/powerpc/include/asm/hvcserver.h index 67d7da3a4da4..67d7da3a4da4 100644 --- a/include/asm-powerpc/hvcserver.h +++ b/arch/powerpc/include/asm/hvcserver.h diff --git a/include/asm-powerpc/hw_irq.h b/arch/powerpc/include/asm/hw_irq.h index f75a5fc64d2e..f75a5fc64d2e 100644 --- a/include/asm-powerpc/hw_irq.h +++ b/arch/powerpc/include/asm/hw_irq.h diff --git a/include/asm-powerpc/hydra.h b/arch/powerpc/include/asm/hydra.h index 1ad4eed07fbe..1ad4eed07fbe 100644 --- a/include/asm-powerpc/hydra.h +++ b/arch/powerpc/include/asm/hydra.h diff --git a/include/asm-powerpc/i8259.h b/arch/powerpc/include/asm/i8259.h index db1362f8c603..105ade297aad 100644 --- a/include/asm-powerpc/i8259.h +++ b/arch/powerpc/include/asm/i8259.h @@ -4,14 +4,9 @@ #include <linux/irq.h> -#ifdef CONFIG_PPC_MERGE extern void i8259_init(struct device_node *node, unsigned long intack_addr); extern unsigned int i8259_irq(void); extern struct irq_host *i8259_get_host(void); -#else -extern void i8259_init(unsigned long intack_addr, int offset); -extern int i8259_irq(void); -#endif #endif /* __KERNEL__ */ #endif /* _ASM_POWERPC_I8259_H */ diff --git a/include/asm-powerpc/ibmebus.h b/arch/powerpc/include/asm/ibmebus.h index 1a9d9aea21fa..1a9d9aea21fa 100644 --- a/include/asm-powerpc/ibmebus.h +++ b/arch/powerpc/include/asm/ibmebus.h diff --git a/include/asm-powerpc/ide.h b/arch/powerpc/include/asm/ide.h index 1aaf27be8741..1aaf27be8741 100644 --- a/include/asm-powerpc/ide.h +++ b/arch/powerpc/include/asm/ide.h diff --git a/include/asm-powerpc/immap_86xx.h b/arch/powerpc/include/asm/immap_86xx.h index 0f165e59c326..0f165e59c326 100644 --- a/include/asm-powerpc/immap_86xx.h +++ b/arch/powerpc/include/asm/immap_86xx.h diff --git a/include/asm-powerpc/immap_cpm2.h b/arch/powerpc/include/asm/immap_cpm2.h index 4080bab0468c..4080bab0468c 100644 --- a/include/asm-powerpc/immap_cpm2.h +++ b/arch/powerpc/include/asm/immap_cpm2.h diff --git a/include/asm-powerpc/immap_qe.h b/arch/powerpc/include/asm/immap_qe.h index 7b6f411db3e6..3c2fced3ac22 100644 --- a/include/asm-powerpc/immap_qe.h +++ b/arch/powerpc/include/asm/immap_qe.h @@ -1,6 +1,4 @@ /* - * include/asm-powerpc/immap_qe.h - * * QUICC Engine (QE) Internal Memory Map. * The Internal Memory Map for devices with QE on them. This * is the superset of all QE devices (8360, etc.). diff --git a/include/asm-powerpc/io-defs.h b/arch/powerpc/include/asm/io-defs.h index 44d7927aec69..44d7927aec69 100644 --- a/include/asm-powerpc/io-defs.h +++ b/arch/powerpc/include/asm/io-defs.h diff --git a/include/asm-powerpc/io.h b/arch/powerpc/include/asm/io.h index 77c7fa025e65..77c7fa025e65 100644 --- a/include/asm-powerpc/io.h +++ b/arch/powerpc/include/asm/io.h diff --git a/include/asm-powerpc/ioctl.h b/arch/powerpc/include/asm/ioctl.h index 57d68304218b..57d68304218b 100644 --- a/include/asm-powerpc/ioctl.h +++ b/arch/powerpc/include/asm/ioctl.h diff --git a/include/asm-powerpc/ioctls.h b/arch/powerpc/include/asm/ioctls.h index 279a6229584b..279a6229584b 100644 --- a/include/asm-powerpc/ioctls.h +++ b/arch/powerpc/include/asm/ioctls.h diff --git a/include/asm-powerpc/iommu.h b/arch/powerpc/include/asm/iommu.h index 51ecfef8d843..51ecfef8d843 100644 --- a/include/asm-powerpc/iommu.h +++ b/arch/powerpc/include/asm/iommu.h diff --git a/include/asm-powerpc/ipcbuf.h b/arch/powerpc/include/asm/ipcbuf.h index 2c3e1d94db1d..2c3e1d94db1d 100644 --- a/include/asm-powerpc/ipcbuf.h +++ b/arch/powerpc/include/asm/ipcbuf.h diff --git a/include/asm-powerpc/ipic.h b/arch/powerpc/include/asm/ipic.h index 8ff08be00146..fb59829983b8 100644 --- a/include/asm-powerpc/ipic.h +++ b/arch/powerpc/include/asm/ipic.h @@ -1,6 +1,4 @@ /* - * include/asm-powerpc/ipic.h - * * IPIC external definitions and structure. * * Maintainer: Kumar Gala <galak@kernel.crashing.org> @@ -79,15 +77,8 @@ extern void ipic_disable_mcp(enum ipic_mcp_irq mcp_irq); extern u32 ipic_get_mcp_status(void); extern void ipic_clear_mcp_status(u32 mask); -#ifdef CONFIG_PPC_MERGE extern struct ipic * ipic_init(struct device_node *node, unsigned int flags); extern unsigned int ipic_get_irq(void); -#else -extern void ipic_init(phys_addr_t phys_addr, unsigned int flags, - unsigned int irq_offset, - unsigned char *senses, unsigned int senses_count); -extern int ipic_get_irq(void); -#endif #endif /* __ASM_IPIC_H__ */ #endif /* __KERNEL__ */ diff --git a/include/asm-powerpc/irq.h b/arch/powerpc/include/asm/irq.h index 1ef8e304e0ea..a372f76836c2 100644 --- a/include/asm-powerpc/irq.h +++ b/arch/powerpc/include/asm/irq.h @@ -25,8 +25,6 @@ extern atomic_t ppc_n_lost_interrupts; -#ifdef CONFIG_PPC_MERGE - /* This number is used when no interrupt has been assigned */ #define NO_IRQ (0) @@ -326,292 +324,6 @@ static __inline__ int irq_canonicalize(int irq) return irq; } - -#else /* CONFIG_PPC_MERGE */ - -/* This number is used when no interrupt has been assigned */ -#define NO_IRQ (-1) -#define NO_IRQ_IGNORE (-2) - - -/* - * These constants are used for passing information about interrupt - * signal polarity and level/edge sensing to the low-level PIC chip - * drivers. - */ -#define IRQ_SENSE_MASK 0x1 -#define IRQ_SENSE_LEVEL 0x1 /* interrupt on active level */ -#define IRQ_SENSE_EDGE 0x0 /* interrupt triggered by edge */ - -#define IRQ_POLARITY_MASK 0x2 -#define IRQ_POLARITY_POSITIVE 0x2 /* high level or low->high edge */ -#define IRQ_POLARITY_NEGATIVE 0x0 /* low level or high->low edge */ - - -#if defined(CONFIG_40x) -#include <asm/ibm4xx.h> - -#ifndef NR_BOARD_IRQS -#define NR_BOARD_IRQS 0 -#endif - -#ifndef UIC_WIDTH /* Number of interrupts per device */ -#define UIC_WIDTH 32 -#endif - -#ifndef NR_UICS /* number of UIC devices */ -#define NR_UICS 1 -#endif - -#if defined (CONFIG_403) -/* - * The PowerPC 403 cores' Asynchronous Interrupt Controller (AIC) has - * 32 possible interrupts, a majority of which are not implemented on - * all cores. There are six configurable, external interrupt pins and - * there are eight internal interrupts for the on-chip serial port - * (SPU), DMA controller, and JTAG controller. - * - */ - -#define NR_AIC_IRQS 32 -#define NR_IRQS (NR_AIC_IRQS + NR_BOARD_IRQS) - -#elif !defined (CONFIG_403) - -/* - * The PowerPC 405 cores' Universal Interrupt Controller (UIC) has 32 - * possible interrupts as well. There are seven, configurable external - * interrupt pins and there are 17 internal interrupts for the on-chip - * serial port, DMA controller, on-chip Ethernet controller, PCI, etc. - * - */ - - -#define NR_UIC_IRQS UIC_WIDTH -#define NR_IRQS ((NR_UIC_IRQS * NR_UICS) + NR_BOARD_IRQS) -#endif - -#elif defined(CONFIG_44x) -#include <asm/ibm44x.h> - -#define NR_UIC_IRQS 32 -#define NR_IRQS ((NR_UIC_IRQS * NR_UICS) + NR_BOARD_IRQS) - -#elif defined(CONFIG_8xx) - -/* Now include the board configuration specific associations. -*/ -#include <asm/mpc8xx.h> - -/* The MPC8xx cores have 16 possible interrupts. There are eight - * possible level sensitive interrupts assigned and generated internally - * from such devices as CPM, PCMCIA, RTC, PIT, TimeBase and Decrementer. - * There are eight external interrupts (IRQs) that can be configured - * as either level or edge sensitive. - * - * On some implementations, there is also the possibility of an 8259 - * through the PCI and PCI-ISA bridges. - * - * We are "flattening" the interrupt vectors of the cascaded CPM - * and 8259 interrupt controllers so that we can uniquely identify - * any interrupt source with a single integer. - */ -#define NR_SIU_INTS 16 -#define NR_CPM_INTS 32 -#ifndef NR_8259_INTS -#define NR_8259_INTS 0 -#endif - -#define SIU_IRQ_OFFSET 0 -#define CPM_IRQ_OFFSET (SIU_IRQ_OFFSET + NR_SIU_INTS) -#define I8259_IRQ_OFFSET (CPM_IRQ_OFFSET + NR_CPM_INTS) - -#define NR_IRQS (NR_SIU_INTS + NR_CPM_INTS + NR_8259_INTS) - -/* These values must be zero-based and map 1:1 with the SIU configuration. - * They are used throughout the 8xx I/O subsystem to generate - * interrupt masks, flags, and other control patterns. This is why the - * current kernel assumption of the 8259 as the base controller is such - * a pain in the butt. - */ -#define SIU_IRQ0 (0) /* Highest priority */ -#define SIU_LEVEL0 (1) -#define SIU_IRQ1 (2) -#define SIU_LEVEL1 (3) -#define SIU_IRQ2 (4) -#define SIU_LEVEL2 (5) -#define SIU_IRQ3 (6) -#define SIU_LEVEL3 (7) -#define SIU_IRQ4 (8) -#define SIU_LEVEL4 (9) -#define SIU_IRQ5 (10) -#define SIU_LEVEL5 (11) -#define SIU_IRQ6 (12) -#define SIU_LEVEL6 (13) -#define SIU_IRQ7 (14) -#define SIU_LEVEL7 (15) - -#define MPC8xx_INT_FEC1 SIU_LEVEL1 -#define MPC8xx_INT_FEC2 SIU_LEVEL3 - -#define MPC8xx_INT_SCC1 (CPM_IRQ_OFFSET + CPMVEC_SCC1) -#define MPC8xx_INT_SCC2 (CPM_IRQ_OFFSET + CPMVEC_SCC2) -#define MPC8xx_INT_SCC3 (CPM_IRQ_OFFSET + CPMVEC_SCC3) -#define MPC8xx_INT_SCC4 (CPM_IRQ_OFFSET + CPMVEC_SCC4) -#define MPC8xx_INT_SMC1 (CPM_IRQ_OFFSET + CPMVEC_SMC1) -#define MPC8xx_INT_SMC2 (CPM_IRQ_OFFSET + CPMVEC_SMC2) - -/* The internal interrupts we can configure as we see fit. - * My personal preference is CPM at level 2, which puts it above the - * MBX PCI/ISA/IDE interrupts. - */ -#ifndef PIT_INTERRUPT -#define PIT_INTERRUPT SIU_LEVEL0 -#endif -#ifndef CPM_INTERRUPT -#define CPM_INTERRUPT SIU_LEVEL2 -#endif -#ifndef PCMCIA_INTERRUPT -#define PCMCIA_INTERRUPT SIU_LEVEL6 -#endif -#ifndef DEC_INTERRUPT -#define DEC_INTERRUPT SIU_LEVEL7 -#endif - -/* Some internal interrupt registers use an 8-bit mask for the interrupt - * level instead of a number. - */ -#define mk_int_int_mask(IL) (1 << (7 - (IL/2))) - -#else /* CONFIG_40x + CONFIG_8xx */ -/* - * this is the # irq's for all ppc arch's (pmac/chrp/prep) - * so it is the max of them all - */ -#define NR_IRQS 256 -#define __DO_IRQ_CANON 1 - -#ifndef CONFIG_8260 - -#define NUM_8259_INTERRUPTS 16 - -#else /* CONFIG_8260 */ - -/* The 8260 has an internal interrupt controller with a maximum of - * 64 IRQs. We will use NR_IRQs from above since it is large enough. - * Don't be confused by the 8260 documentation where they list an - * "interrupt number" and "interrupt vector". We are only interested - * in the interrupt vector. There are "reserved" holes where the - * vector number increases, but the interrupt number in the table does not. - * (Document errata updates have fixed this...make sure you have up to - * date processor documentation -- Dan). - */ - -#ifndef CPM_IRQ_OFFSET -#define CPM_IRQ_OFFSET 0 -#endif - -#define NR_CPM_INTS 64 - -#define SIU_INT_ERROR ((uint)0x00 + CPM_IRQ_OFFSET) -#define SIU_INT_I2C ((uint)0x01 + CPM_IRQ_OFFSET) -#define SIU_INT_SPI ((uint)0x02 + CPM_IRQ_OFFSET) -#define SIU_INT_RISC ((uint)0x03 + CPM_IRQ_OFFSET) -#define SIU_INT_SMC1 ((uint)0x04 + CPM_IRQ_OFFSET) -#define SIU_INT_SMC2 ((uint)0x05 + CPM_IRQ_OFFSET) -#define SIU_INT_IDMA1 ((uint)0x06 + CPM_IRQ_OFFSET) -#define SIU_INT_IDMA2 ((uint)0x07 + CPM_IRQ_OFFSET) -#define SIU_INT_IDMA3 ((uint)0x08 + CPM_IRQ_OFFSET) -#define SIU_INT_IDMA4 ((uint)0x09 + CPM_IRQ_OFFSET) -#define SIU_INT_SDMA ((uint)0x0a + CPM_IRQ_OFFSET) -#define SIU_INT_USB ((uint)0x0b + CPM_IRQ_OFFSET) -#define SIU_INT_TIMER1 ((uint)0x0c + CPM_IRQ_OFFSET) -#define SIU_INT_TIMER2 ((uint)0x0d + CPM_IRQ_OFFSET) -#define SIU_INT_TIMER3 ((uint)0x0e + CPM_IRQ_OFFSET) -#define SIU_INT_TIMER4 ((uint)0x0f + CPM_IRQ_OFFSET) -#define SIU_INT_TMCNT ((uint)0x10 + CPM_IRQ_OFFSET) -#define SIU_INT_PIT ((uint)0x11 + CPM_IRQ_OFFSET) -#define SIU_INT_PCI ((uint)0x12 + CPM_IRQ_OFFSET) -#define SIU_INT_IRQ1 ((uint)0x13 + CPM_IRQ_OFFSET) -#define SIU_INT_IRQ2 ((uint)0x14 + CPM_IRQ_OFFSET) -#define SIU_INT_IRQ3 ((uint)0x15 + CPM_IRQ_OFFSET) -#define SIU_INT_IRQ4 ((uint)0x16 + CPM_IRQ_OFFSET) -#define SIU_INT_IRQ5 ((uint)0x17 + CPM_IRQ_OFFSET) -#define SIU_INT_IRQ6 ((uint)0x18 + CPM_IRQ_OFFSET) -#define SIU_INT_IRQ7 ((uint)0x19 + CPM_IRQ_OFFSET) -#define SIU_INT_FCC1 ((uint)0x20 + CPM_IRQ_OFFSET) -#define SIU_INT_FCC2 ((uint)0x21 + CPM_IRQ_OFFSET) -#define SIU_INT_FCC3 ((uint)0x22 + CPM_IRQ_OFFSET) -#define SIU_INT_MCC1 ((uint)0x24 + CPM_IRQ_OFFSET) -#define SIU_INT_MCC2 ((uint)0x25 + CPM_IRQ_OFFSET) -#define SIU_INT_SCC1 ((uint)0x28 + CPM_IRQ_OFFSET) -#define SIU_INT_SCC2 ((uint)0x29 + CPM_IRQ_OFFSET) -#define SIU_INT_SCC3 ((uint)0x2a + CPM_IRQ_OFFSET) -#define SIU_INT_SCC4 ((uint)0x2b + CPM_IRQ_OFFSET) -#define SIU_INT_PC15 ((uint)0x30 + CPM_IRQ_OFFSET) -#define SIU_INT_PC14 ((uint)0x31 + CPM_IRQ_OFFSET) -#define SIU_INT_PC13 ((uint)0x32 + CPM_IRQ_OFFSET) -#define SIU_INT_PC12 ((uint)0x33 + CPM_IRQ_OFFSET) -#define SIU_INT_PC11 ((uint)0x34 + CPM_IRQ_OFFSET) -#define SIU_INT_PC10 ((uint)0x35 + CPM_IRQ_OFFSET) -#define SIU_INT_PC9 ((uint)0x36 + CPM_IRQ_OFFSET) -#define SIU_INT_PC8 ((uint)0x37 + CPM_IRQ_OFFSET) -#define SIU_INT_PC7 ((uint)0x38 + CPM_IRQ_OFFSET) -#define SIU_INT_PC6 ((uint)0x39 + CPM_IRQ_OFFSET) -#define SIU_INT_PC5 ((uint)0x3a + CPM_IRQ_OFFSET) -#define SIU_INT_PC4 ((uint)0x3b + CPM_IRQ_OFFSET) -#define SIU_INT_PC3 ((uint)0x3c + CPM_IRQ_OFFSET) -#define SIU_INT_PC2 ((uint)0x3d + CPM_IRQ_OFFSET) -#define SIU_INT_PC1 ((uint)0x3e + CPM_IRQ_OFFSET) -#define SIU_INT_PC0 ((uint)0x3f + CPM_IRQ_OFFSET) - -#endif /* CONFIG_8260 */ - -#endif /* Whatever way too big #ifdef */ - -#define NR_MASK_WORDS ((NR_IRQS + 31) / 32) -/* pedantic: these are long because they are used with set_bit --RR */ -extern unsigned long ppc_cached_irq_mask[NR_MASK_WORDS]; - -/* - * Because many systems have two overlapping names spaces for - * interrupts (ISA and XICS for example), and the ISA interrupts - * have historically not been easy to renumber, we allow ISA - * interrupts to take values 0 - 15, and shift up the remaining - * interrupts by 0x10. - */ -#define NUM_ISA_INTERRUPTS 0x10 -extern int __irq_offset_value; - -static inline int irq_offset_up(int irq) -{ - return(irq + __irq_offset_value); -} - -static inline int irq_offset_down(int irq) -{ - return(irq - __irq_offset_value); -} - -static inline int irq_offset_value(void) -{ - return __irq_offset_value; -} - -#ifdef __DO_IRQ_CANON -extern int ppc_do_canonicalize_irqs; -#else -#define ppc_do_canonicalize_irqs 0 -#endif - -static __inline__ int irq_canonicalize(int irq) -{ - if (ppc_do_canonicalize_irqs && irq == 2) - irq = 9; - return irq; -} -#endif /* CONFIG_PPC_MERGE */ - extern int distribute_irqs; struct irqaction; diff --git a/include/asm-powerpc/irq_regs.h b/arch/powerpc/include/asm/irq_regs.h index ba94b51a0a70..ba94b51a0a70 100644 --- a/include/asm-powerpc/irq_regs.h +++ b/arch/powerpc/include/asm/irq_regs.h diff --git a/include/asm-powerpc/irqflags.h b/arch/powerpc/include/asm/irqflags.h index cc6fdba33660..17ba3a881bfd 100644 --- a/include/asm-powerpc/irqflags.h +++ b/arch/powerpc/include/asm/irqflags.h @@ -1,6 +1,4 @@ /* - * include/asm-powerpc/irqflags.h - * * IRQ flags handling */ #ifndef _ASM_IRQFLAGS_H @@ -10,7 +8,7 @@ /* * Get definitions for raw_local_save_flags(x), etc. */ -#include <asm-powerpc/hw_irq.h> +#include <asm/hw_irq.h> #else #ifdef CONFIG_TRACE_IRQFLAGS diff --git a/include/asm-powerpc/iseries/alpaca.h b/arch/powerpc/include/asm/iseries/alpaca.h index c0cce6727a69..c0cce6727a69 100644 --- a/include/asm-powerpc/iseries/alpaca.h +++ b/arch/powerpc/include/asm/iseries/alpaca.h diff --git a/include/asm-powerpc/iseries/hv_call.h b/arch/powerpc/include/asm/iseries/hv_call.h index 162d653ad51f..162d653ad51f 100644 --- a/include/asm-powerpc/iseries/hv_call.h +++ b/arch/powerpc/include/asm/iseries/hv_call.h diff --git a/include/asm-powerpc/iseries/hv_call_event.h b/arch/powerpc/include/asm/iseries/hv_call_event.h index cc029d388e11..cc029d388e11 100644 --- a/include/asm-powerpc/iseries/hv_call_event.h +++ b/arch/powerpc/include/asm/iseries/hv_call_event.h diff --git a/include/asm-powerpc/iseries/hv_call_sc.h b/arch/powerpc/include/asm/iseries/hv_call_sc.h index f5d210959250..f5d210959250 100644 --- a/include/asm-powerpc/iseries/hv_call_sc.h +++ b/arch/powerpc/include/asm/iseries/hv_call_sc.h diff --git a/include/asm-powerpc/iseries/hv_call_xm.h b/arch/powerpc/include/asm/iseries/hv_call_xm.h index 392ac3f54df0..392ac3f54df0 100644 --- a/include/asm-powerpc/iseries/hv_call_xm.h +++ b/arch/powerpc/include/asm/iseries/hv_call_xm.h diff --git a/include/asm-powerpc/iseries/hv_lp_config.h b/arch/powerpc/include/asm/iseries/hv_lp_config.h index a006fd1e4a2c..a006fd1e4a2c 100644 --- a/include/asm-powerpc/iseries/hv_lp_config.h +++ b/arch/powerpc/include/asm/iseries/hv_lp_config.h diff --git a/include/asm-powerpc/iseries/hv_lp_event.h b/arch/powerpc/include/asm/iseries/hv_lp_event.h index 8f5da7d77202..8f5da7d77202 100644 --- a/include/asm-powerpc/iseries/hv_lp_event.h +++ b/arch/powerpc/include/asm/iseries/hv_lp_event.h diff --git a/include/asm-powerpc/iseries/hv_types.h b/arch/powerpc/include/asm/iseries/hv_types.h index c3e6d2a1d1c3..c3e6d2a1d1c3 100644 --- a/include/asm-powerpc/iseries/hv_types.h +++ b/arch/powerpc/include/asm/iseries/hv_types.h diff --git a/include/asm-powerpc/iseries/iommu.h b/arch/powerpc/include/asm/iseries/iommu.h index c59ee7e4bed1..c59ee7e4bed1 100644 --- a/include/asm-powerpc/iseries/iommu.h +++ b/arch/powerpc/include/asm/iseries/iommu.h diff --git a/include/asm-powerpc/iseries/it_lp_queue.h b/arch/powerpc/include/asm/iseries/it_lp_queue.h index 428278838821..428278838821 100644 --- a/include/asm-powerpc/iseries/it_lp_queue.h +++ b/arch/powerpc/include/asm/iseries/it_lp_queue.h diff --git a/include/asm-powerpc/iseries/lpar_map.h b/arch/powerpc/include/asm/iseries/lpar_map.h index 5e9f3e128ee2..5e9f3e128ee2 100644 --- a/include/asm-powerpc/iseries/lpar_map.h +++ b/arch/powerpc/include/asm/iseries/lpar_map.h diff --git a/include/asm-powerpc/iseries/mf.h b/arch/powerpc/include/asm/iseries/mf.h index eb851a9c9e5c..eb851a9c9e5c 100644 --- a/include/asm-powerpc/iseries/mf.h +++ b/arch/powerpc/include/asm/iseries/mf.h diff --git a/include/asm-powerpc/iseries/vio.h b/arch/powerpc/include/asm/iseries/vio.h index f9ac0d00b951..f9ac0d00b951 100644 --- a/include/asm-powerpc/iseries/vio.h +++ b/arch/powerpc/include/asm/iseries/vio.h diff --git a/include/asm-powerpc/kdebug.h b/arch/powerpc/include/asm/kdebug.h index ae6d206728af..ae6d206728af 100644 --- a/include/asm-powerpc/kdebug.h +++ b/arch/powerpc/include/asm/kdebug.h diff --git a/include/asm-powerpc/kdump.h b/arch/powerpc/include/asm/kdump.h index f6c93c716898..f6c93c716898 100644 --- a/include/asm-powerpc/kdump.h +++ b/arch/powerpc/include/asm/kdump.h diff --git a/include/asm-powerpc/kexec.h b/arch/powerpc/include/asm/kexec.h index acdcdc66f1b6..acdcdc66f1b6 100644 --- a/include/asm-powerpc/kexec.h +++ b/arch/powerpc/include/asm/kexec.h diff --git a/include/asm-powerpc/keylargo.h b/arch/powerpc/include/asm/keylargo.h index d8520ef121f9..d8520ef121f9 100644 --- a/include/asm-powerpc/keylargo.h +++ b/arch/powerpc/include/asm/keylargo.h diff --git a/include/asm-powerpc/kgdb.h b/arch/powerpc/include/asm/kgdb.h index 1399caf719ae..edd217006d27 100644 --- a/include/asm-powerpc/kgdb.h +++ b/arch/powerpc/include/asm/kgdb.h @@ -1,6 +1,4 @@ /* - * include/asm-powerpc/kgdb.h - * * The PowerPC (32/64) specific defines / externs for KGDB. Based on * the previous 32bit and 64bit specific files, which had the following * copyrights: diff --git a/include/asm-powerpc/kmap_types.h b/arch/powerpc/include/asm/kmap_types.h index b6bac6f61c16..b6bac6f61c16 100644 --- a/include/asm-powerpc/kmap_types.h +++ b/arch/powerpc/include/asm/kmap_types.h diff --git a/include/asm-powerpc/kprobes.h b/arch/powerpc/include/asm/kprobes.h index d0e7701fa1f6..d0e7701fa1f6 100644 --- a/include/asm-powerpc/kprobes.h +++ b/arch/powerpc/include/asm/kprobes.h diff --git a/include/asm-powerpc/kvm.h b/arch/powerpc/include/asm/kvm.h index f993e4198d5c..f993e4198d5c 100644 --- a/include/asm-powerpc/kvm.h +++ b/arch/powerpc/include/asm/kvm.h diff --git a/include/asm-powerpc/kvm_asm.h b/arch/powerpc/include/asm/kvm_asm.h index 2197764796d9..2197764796d9 100644 --- a/include/asm-powerpc/kvm_asm.h +++ b/arch/powerpc/include/asm/kvm_asm.h diff --git a/include/asm-powerpc/kvm_host.h b/arch/powerpc/include/asm/kvm_host.h index 2655e2a4831e..2655e2a4831e 100644 --- a/include/asm-powerpc/kvm_host.h +++ b/arch/powerpc/include/asm/kvm_host.h diff --git a/include/asm-powerpc/kvm_para.h b/arch/powerpc/include/asm/kvm_para.h index 2d48f6a63d0b..2d48f6a63d0b 100644 --- a/include/asm-powerpc/kvm_para.h +++ b/arch/powerpc/include/asm/kvm_para.h diff --git a/include/asm-powerpc/kvm_ppc.h b/arch/powerpc/include/asm/kvm_ppc.h index a8b068792260..a8b068792260 100644 --- a/include/asm-powerpc/kvm_ppc.h +++ b/arch/powerpc/include/asm/kvm_ppc.h diff --git a/include/asm-powerpc/libata-portmap.h b/arch/powerpc/include/asm/libata-portmap.h index 4d8518049f4d..4d8518049f4d 100644 --- a/include/asm-powerpc/libata-portmap.h +++ b/arch/powerpc/include/asm/libata-portmap.h diff --git a/include/asm-powerpc/linkage.h b/arch/powerpc/include/asm/linkage.h index e1c4ac1cc4ba..e1c4ac1cc4ba 100644 --- a/include/asm-powerpc/linkage.h +++ b/arch/powerpc/include/asm/linkage.h diff --git a/include/asm-powerpc/lmb.h b/arch/powerpc/include/asm/lmb.h index 6f5fdf0a19ae..6f5fdf0a19ae 100644 --- a/include/asm-powerpc/lmb.h +++ b/arch/powerpc/include/asm/lmb.h diff --git a/include/asm-powerpc/local.h b/arch/powerpc/include/asm/local.h index 612d83276653..612d83276653 100644 --- a/include/asm-powerpc/local.h +++ b/arch/powerpc/include/asm/local.h diff --git a/include/asm-powerpc/lppaca.h b/arch/powerpc/include/asm/lppaca.h index 2fe268b10333..2fe268b10333 100644 --- a/include/asm-powerpc/lppaca.h +++ b/arch/powerpc/include/asm/lppaca.h diff --git a/include/asm-powerpc/lv1call.h b/arch/powerpc/include/asm/lv1call.h index 81713acf7529..81713acf7529 100644 --- a/include/asm-powerpc/lv1call.h +++ b/arch/powerpc/include/asm/lv1call.h diff --git a/include/asm-powerpc/machdep.h b/arch/powerpc/include/asm/machdep.h index 893aafd87fde..893aafd87fde 100644 --- a/include/asm-powerpc/machdep.h +++ b/arch/powerpc/include/asm/machdep.h diff --git a/include/asm-powerpc/macio.h b/arch/powerpc/include/asm/macio.h index 079c06eae446..079c06eae446 100644 --- a/include/asm-powerpc/macio.h +++ b/arch/powerpc/include/asm/macio.h diff --git a/include/asm-powerpc/mc146818rtc.h b/arch/powerpc/include/asm/mc146818rtc.h index f2741c8b59a1..f2741c8b59a1 100644 --- a/include/asm-powerpc/mc146818rtc.h +++ b/arch/powerpc/include/asm/mc146818rtc.h diff --git a/include/asm-powerpc/mediabay.h b/arch/powerpc/include/asm/mediabay.h index b2efb3325808..b2efb3325808 100644 --- a/include/asm-powerpc/mediabay.h +++ b/arch/powerpc/include/asm/mediabay.h diff --git a/include/asm-powerpc/mman.h b/arch/powerpc/include/asm/mman.h index 9209f755763e..9209f755763e 100644 --- a/include/asm-powerpc/mman.h +++ b/arch/powerpc/include/asm/mman.h diff --git a/include/asm-powerpc/mmu-40x.h b/arch/powerpc/include/asm/mmu-40x.h index 3d108676584c..3d108676584c 100644 --- a/include/asm-powerpc/mmu-40x.h +++ b/arch/powerpc/include/asm/mmu-40x.h diff --git a/include/asm-powerpc/mmu-44x.h b/arch/powerpc/include/asm/mmu-44x.h index a825524c981a..a825524c981a 100644 --- a/include/asm-powerpc/mmu-44x.h +++ b/arch/powerpc/include/asm/mmu-44x.h diff --git a/include/asm-powerpc/mmu-8xx.h b/arch/powerpc/include/asm/mmu-8xx.h index 9db877eb88db..9db877eb88db 100644 --- a/include/asm-powerpc/mmu-8xx.h +++ b/arch/powerpc/include/asm/mmu-8xx.h diff --git a/include/asm-powerpc/mmu-fsl-booke.h b/arch/powerpc/include/asm/mmu-fsl-booke.h index 925d93cf64d8..925d93cf64d8 100644 --- a/include/asm-powerpc/mmu-fsl-booke.h +++ b/arch/powerpc/include/asm/mmu-fsl-booke.h diff --git a/include/asm-powerpc/mmu-hash32.h b/arch/powerpc/include/asm/mmu-hash32.h index 16b1a1e77e64..16b1a1e77e64 100644 --- a/include/asm-powerpc/mmu-hash32.h +++ b/arch/powerpc/include/asm/mmu-hash32.h diff --git a/include/asm-powerpc/mmu-hash64.h b/arch/powerpc/include/asm/mmu-hash64.h index 19c7a9403490..19c7a9403490 100644 --- a/include/asm-powerpc/mmu-hash64.h +++ b/arch/powerpc/include/asm/mmu-hash64.h diff --git a/include/asm-powerpc/mmu.h b/arch/powerpc/include/asm/mmu.h index 4c0e1b4f975c..4c0e1b4f975c 100644 --- a/include/asm-powerpc/mmu.h +++ b/arch/powerpc/include/asm/mmu.h diff --git a/include/asm-powerpc/mmu_context.h b/arch/powerpc/include/asm/mmu_context.h index 9102b8bf0ead..9102b8bf0ead 100644 --- a/include/asm-powerpc/mmu_context.h +++ b/arch/powerpc/include/asm/mmu_context.h diff --git a/include/asm-powerpc/mmzone.h b/arch/powerpc/include/asm/mmzone.h index 19f299b7e256..19f299b7e256 100644 --- a/include/asm-powerpc/mmzone.h +++ b/arch/powerpc/include/asm/mmzone.h diff --git a/include/asm-powerpc/module.h b/arch/powerpc/include/asm/module.h index e5f14b13ccf0..e5f14b13ccf0 100644 --- a/include/asm-powerpc/module.h +++ b/arch/powerpc/include/asm/module.h diff --git a/include/asm-powerpc/mpc512x.h b/arch/powerpc/include/asm/mpc512x.h index c48a1658eeac..c48a1658eeac 100644 --- a/include/asm-powerpc/mpc512x.h +++ b/arch/powerpc/include/asm/mpc512x.h diff --git a/include/asm-powerpc/mpc52xx.h b/arch/powerpc/include/asm/mpc52xx.h index 81ef10b6b672..81ef10b6b672 100644 --- a/include/asm-powerpc/mpc52xx.h +++ b/arch/powerpc/include/asm/mpc52xx.h diff --git a/include/asm-powerpc/mpc52xx_psc.h b/arch/powerpc/include/asm/mpc52xx_psc.h index 8917ed630565..8917ed630565 100644 --- a/include/asm-powerpc/mpc52xx_psc.h +++ b/arch/powerpc/include/asm/mpc52xx_psc.h diff --git a/include/asm-powerpc/mpc6xx.h b/arch/powerpc/include/asm/mpc6xx.h index effc2291beb2..effc2291beb2 100644 --- a/include/asm-powerpc/mpc6xx.h +++ b/arch/powerpc/include/asm/mpc6xx.h diff --git a/include/asm-powerpc/mpc8260.h b/arch/powerpc/include/asm/mpc8260.h index 03317e1e6185..03317e1e6185 100644 --- a/include/asm-powerpc/mpc8260.h +++ b/arch/powerpc/include/asm/mpc8260.h diff --git a/include/asm-powerpc/mpc86xx.h b/arch/powerpc/include/asm/mpc86xx.h index 15f650f987e7..15f650f987e7 100644 --- a/include/asm-powerpc/mpc86xx.h +++ b/arch/powerpc/include/asm/mpc86xx.h diff --git a/include/asm-powerpc/mpc8xx.h b/arch/powerpc/include/asm/mpc8xx.h index 98f3c4f17328..98f3c4f17328 100644 --- a/include/asm-powerpc/mpc8xx.h +++ b/arch/powerpc/include/asm/mpc8xx.h diff --git a/include/asm-powerpc/mpic.h b/arch/powerpc/include/asm/mpic.h index fe566a348a86..fe566a348a86 100644 --- a/include/asm-powerpc/mpic.h +++ b/arch/powerpc/include/asm/mpic.h diff --git a/include/asm-powerpc/msgbuf.h b/arch/powerpc/include/asm/msgbuf.h index dd76743c7537..dd76743c7537 100644 --- a/include/asm-powerpc/msgbuf.h +++ b/arch/powerpc/include/asm/msgbuf.h diff --git a/include/asm-powerpc/mutex.h b/arch/powerpc/include/asm/mutex.h index 458c1f7fbc18..458c1f7fbc18 100644 --- a/include/asm-powerpc/mutex.h +++ b/arch/powerpc/include/asm/mutex.h diff --git a/include/asm-powerpc/nvram.h b/arch/powerpc/include/asm/nvram.h index efde5ac82f7b..efde5ac82f7b 100644 --- a/include/asm-powerpc/nvram.h +++ b/arch/powerpc/include/asm/nvram.h diff --git a/include/asm-powerpc/of_device.h b/arch/powerpc/include/asm/of_device.h index 3c123990ca2e..3c123990ca2e 100644 --- a/include/asm-powerpc/of_device.h +++ b/arch/powerpc/include/asm/of_device.h diff --git a/include/asm-powerpc/of_platform.h b/arch/powerpc/include/asm/of_platform.h index 18659ef72139..18659ef72139 100644 --- a/include/asm-powerpc/of_platform.h +++ b/arch/powerpc/include/asm/of_platform.h diff --git a/include/asm-powerpc/ohare.h b/arch/powerpc/include/asm/ohare.h index 0d030f9dea24..0d030f9dea24 100644 --- a/include/asm-powerpc/ohare.h +++ b/arch/powerpc/include/asm/ohare.h diff --git a/include/asm-powerpc/oprofile_impl.h b/arch/powerpc/include/asm/oprofile_impl.h index 95035c602ba6..95035c602ba6 100644 --- a/include/asm-powerpc/oprofile_impl.h +++ b/arch/powerpc/include/asm/oprofile_impl.h diff --git a/include/asm-powerpc/pSeries_reconfig.h b/arch/powerpc/include/asm/pSeries_reconfig.h index e482e5352e69..e482e5352e69 100644 --- a/include/asm-powerpc/pSeries_reconfig.h +++ b/arch/powerpc/include/asm/pSeries_reconfig.h diff --git a/include/asm-powerpc/paca.h b/arch/powerpc/include/asm/paca.h index 7b564444ff61..6493a395508b 100644 --- a/include/asm-powerpc/paca.h +++ b/arch/powerpc/include/asm/paca.h @@ -1,6 +1,4 @@ /* - * include/asm-powerpc/paca.h - * * This control block defines the PACA which defines the processor * specific data for each logical processor on the system. * There are some pointers defined that are utilized by PLIC. diff --git a/include/asm-powerpc/page.h b/arch/powerpc/include/asm/page.h index e088545cb3f5..e088545cb3f5 100644 --- a/include/asm-powerpc/page.h +++ b/arch/powerpc/include/asm/page.h diff --git a/include/asm-powerpc/page_32.h b/arch/powerpc/include/asm/page_32.h index ebfae530a379..ebfae530a379 100644 --- a/include/asm-powerpc/page_32.h +++ b/arch/powerpc/include/asm/page_32.h diff --git a/include/asm-powerpc/page_64.h b/arch/powerpc/include/asm/page_64.h index 043bfdfe4f73..043bfdfe4f73 100644 --- a/include/asm-powerpc/page_64.h +++ b/arch/powerpc/include/asm/page_64.h diff --git a/include/asm-powerpc/param.h b/arch/powerpc/include/asm/param.h index 094f63d4d5ca..094f63d4d5ca 100644 --- a/include/asm-powerpc/param.h +++ b/arch/powerpc/include/asm/param.h diff --git a/include/asm-powerpc/parport.h b/arch/powerpc/include/asm/parport.h index 414c50e2e881..414c50e2e881 100644 --- a/include/asm-powerpc/parport.h +++ b/arch/powerpc/include/asm/parport.h diff --git a/include/asm-powerpc/pasemi_dma.h b/arch/powerpc/include/asm/pasemi_dma.h index 19fd7933e2d9..19fd7933e2d9 100644 --- a/include/asm-powerpc/pasemi_dma.h +++ b/arch/powerpc/include/asm/pasemi_dma.h diff --git a/include/asm-powerpc/pci-bridge.h b/arch/powerpc/include/asm/pci-bridge.h index ae2ea803a0f2..ae2ea803a0f2 100644 --- a/include/asm-powerpc/pci-bridge.h +++ b/arch/powerpc/include/asm/pci-bridge.h diff --git a/include/asm-powerpc/pci.h b/arch/powerpc/include/asm/pci.h index a05a942b1c25..a05a942b1c25 100644 --- a/include/asm-powerpc/pci.h +++ b/arch/powerpc/include/asm/pci.h diff --git a/include/asm-powerpc/percpu.h b/arch/powerpc/include/asm/percpu.h index f879252b7ea6..f879252b7ea6 100644 --- a/include/asm-powerpc/percpu.h +++ b/arch/powerpc/include/asm/percpu.h diff --git a/include/asm-powerpc/pgalloc-32.h b/arch/powerpc/include/asm/pgalloc-32.h index 58c07147b3ea..58c07147b3ea 100644 --- a/include/asm-powerpc/pgalloc-32.h +++ b/arch/powerpc/include/asm/pgalloc-32.h diff --git a/include/asm-powerpc/pgalloc-64.h b/arch/powerpc/include/asm/pgalloc-64.h index 812a1d8f35cb..812a1d8f35cb 100644 --- a/include/asm-powerpc/pgalloc-64.h +++ b/arch/powerpc/include/asm/pgalloc-64.h diff --git a/include/asm-powerpc/pgalloc.h b/arch/powerpc/include/asm/pgalloc.h index b4505ed0f0f2..b4505ed0f0f2 100644 --- a/include/asm-powerpc/pgalloc.h +++ b/arch/powerpc/include/asm/pgalloc.h diff --git a/include/asm-powerpc/pgtable-4k.h b/arch/powerpc/include/asm/pgtable-4k.h index 6b18ba9d2d85..6b18ba9d2d85 100644 --- a/include/asm-powerpc/pgtable-4k.h +++ b/arch/powerpc/include/asm/pgtable-4k.h diff --git a/include/asm-powerpc/pgtable-64k.h b/arch/powerpc/include/asm/pgtable-64k.h index 07b0d8f09cb6..07b0d8f09cb6 100644 --- a/include/asm-powerpc/pgtable-64k.h +++ b/arch/powerpc/include/asm/pgtable-64k.h diff --git a/include/asm-powerpc/pgtable-ppc32.h b/arch/powerpc/include/asm/pgtable-ppc32.h index 6fe39e327047..6fe39e327047 100644 --- a/include/asm-powerpc/pgtable-ppc32.h +++ b/arch/powerpc/include/asm/pgtable-ppc32.h diff --git a/include/asm-powerpc/pgtable-ppc64.h b/arch/powerpc/include/asm/pgtable-ppc64.h index 74c6f380b805..db0b8f3b8807 100644 --- a/include/asm-powerpc/pgtable-ppc64.h +++ b/arch/powerpc/include/asm/pgtable-ppc64.h @@ -100,7 +100,7 @@ #define _PAGE_WRENABLE (_PAGE_RW | _PAGE_DIRTY) -/* __pgprot defined in asm-powerpc/page.h */ +/* __pgprot defined in arch/powerpc/incliude/asm/page.h */ #define PAGE_NONE __pgprot(_PAGE_PRESENT | _PAGE_ACCESSED) #define PAGE_SHARED __pgprot(_PAGE_BASE | _PAGE_RW | _PAGE_USER) diff --git a/include/asm-powerpc/pgtable.h b/arch/powerpc/include/asm/pgtable.h index dbb8ca172e44..dbb8ca172e44 100644 --- a/include/asm-powerpc/pgtable.h +++ b/arch/powerpc/include/asm/pgtable.h diff --git a/include/asm-powerpc/phyp_dump.h b/arch/powerpc/include/asm/phyp_dump.h index fa74c6c3e106..fa74c6c3e106 100644 --- a/include/asm-powerpc/phyp_dump.h +++ b/arch/powerpc/include/asm/phyp_dump.h diff --git a/include/asm-powerpc/pmac_feature.h b/arch/powerpc/include/asm/pmac_feature.h index 877c35a4356e..877c35a4356e 100644 --- a/include/asm-powerpc/pmac_feature.h +++ b/arch/powerpc/include/asm/pmac_feature.h diff --git a/include/asm-powerpc/pmac_low_i2c.h b/arch/powerpc/include/asm/pmac_low_i2c.h index 131011bd7e76..131011bd7e76 100644 --- a/include/asm-powerpc/pmac_low_i2c.h +++ b/arch/powerpc/include/asm/pmac_low_i2c.h diff --git a/include/asm-powerpc/pmac_pfunc.h b/arch/powerpc/include/asm/pmac_pfunc.h index 1330d6a58c57..1330d6a58c57 100644 --- a/include/asm-powerpc/pmac_pfunc.h +++ b/arch/powerpc/include/asm/pmac_pfunc.h diff --git a/include/asm-powerpc/pmc.h b/arch/powerpc/include/asm/pmc.h index d6a616a1b3ea..d6a616a1b3ea 100644 --- a/include/asm-powerpc/pmc.h +++ b/arch/powerpc/include/asm/pmc.h diff --git a/include/asm-powerpc/pmi.h b/arch/powerpc/include/asm/pmi.h index b4e91fbf5081..b4e91fbf5081 100644 --- a/include/asm-powerpc/pmi.h +++ b/arch/powerpc/include/asm/pmi.h diff --git a/include/asm-powerpc/poll.h b/arch/powerpc/include/asm/poll.h index c98509d3149e..c98509d3149e 100644 --- a/include/asm-powerpc/poll.h +++ b/arch/powerpc/include/asm/poll.h diff --git a/include/asm-powerpc/posix_types.h b/arch/powerpc/include/asm/posix_types.h index c4e396b540df..c4e396b540df 100644 --- a/include/asm-powerpc/posix_types.h +++ b/arch/powerpc/include/asm/posix_types.h diff --git a/include/asm-powerpc/ppc-pci.h b/arch/powerpc/include/asm/ppc-pci.h index 854ab713f56c..854ab713f56c 100644 --- a/include/asm-powerpc/ppc-pci.h +++ b/arch/powerpc/include/asm/ppc-pci.h diff --git a/include/asm-powerpc/ppc4xx.h b/arch/powerpc/include/asm/ppc4xx.h index 033039a80c42..033039a80c42 100644 --- a/include/asm-powerpc/ppc4xx.h +++ b/arch/powerpc/include/asm/ppc4xx.h diff --git a/include/asm-powerpc/ppc_asm.h b/arch/powerpc/include/asm/ppc_asm.h index 0966899d974b..0966899d974b 100644 --- a/include/asm-powerpc/ppc_asm.h +++ b/arch/powerpc/include/asm/ppc_asm.h diff --git a/include/asm-powerpc/processor.h b/arch/powerpc/include/asm/processor.h index 101ed87f7d84..101ed87f7d84 100644 --- a/include/asm-powerpc/processor.h +++ b/arch/powerpc/include/asm/processor.h diff --git a/include/asm-powerpc/prom.h b/arch/powerpc/include/asm/prom.h index eb3bd2e1c7f6..eb3bd2e1c7f6 100644 --- a/include/asm-powerpc/prom.h +++ b/arch/powerpc/include/asm/prom.h diff --git a/include/asm-powerpc/ps3.h b/arch/powerpc/include/asm/ps3.h index f9e34c493cbb..f9e34c493cbb 100644 --- a/include/asm-powerpc/ps3.h +++ b/arch/powerpc/include/asm/ps3.h diff --git a/include/asm-powerpc/ps3av.h b/arch/powerpc/include/asm/ps3av.h index fda98715cd35..fda98715cd35 100644 --- a/include/asm-powerpc/ps3av.h +++ b/arch/powerpc/include/asm/ps3av.h diff --git a/include/asm-powerpc/ps3fb.h b/arch/powerpc/include/asm/ps3fb.h index 3f121fe4010d..3f121fe4010d 100644 --- a/include/asm-powerpc/ps3fb.h +++ b/arch/powerpc/include/asm/ps3fb.h diff --git a/include/asm-powerpc/ps3stor.h b/arch/powerpc/include/asm/ps3stor.h index 6fcaf714fa50..6fcaf714fa50 100644 --- a/include/asm-powerpc/ps3stor.h +++ b/arch/powerpc/include/asm/ps3stor.h diff --git a/include/asm-powerpc/ptrace.h b/arch/powerpc/include/asm/ptrace.h index 734e0754fb9b..734e0754fb9b 100644 --- a/include/asm-powerpc/ptrace.h +++ b/arch/powerpc/include/asm/ptrace.h diff --git a/include/asm-powerpc/qe.h b/arch/powerpc/include/asm/qe.h index edee15d269ea..edee15d269ea 100644 --- a/include/asm-powerpc/qe.h +++ b/arch/powerpc/include/asm/qe.h diff --git a/include/asm-powerpc/qe_ic.h b/arch/powerpc/include/asm/qe_ic.h index a779b2c9eaf1..56a7745ca343 100644 --- a/include/asm-powerpc/qe_ic.h +++ b/arch/powerpc/include/asm/qe_ic.h @@ -1,6 +1,4 @@ /* - * include/asm-powerpc/qe_ic.h - * * Copyright (C) 2006 Freescale Semicondutor, Inc. All rights reserved. * * Authors: Shlomi Gridish <gridish@freescale.com> diff --git a/include/asm-powerpc/reg.h b/arch/powerpc/include/asm/reg.h index c6d1ab650778..c6d1ab650778 100644 --- a/include/asm-powerpc/reg.h +++ b/arch/powerpc/include/asm/reg.h diff --git a/include/asm-powerpc/reg_8xx.h b/arch/powerpc/include/asm/reg_8xx.h index e8ea346b21d3..e8ea346b21d3 100644 --- a/include/asm-powerpc/reg_8xx.h +++ b/arch/powerpc/include/asm/reg_8xx.h diff --git a/include/asm-powerpc/reg_booke.h b/arch/powerpc/include/asm/reg_booke.h index be980f4ee495..be980f4ee495 100644 --- a/include/asm-powerpc/reg_booke.h +++ b/arch/powerpc/include/asm/reg_booke.h diff --git a/include/asm-powerpc/reg_fsl_emb.h b/arch/powerpc/include/asm/reg_fsl_emb.h index 1e180a594589..1e180a594589 100644 --- a/include/asm-powerpc/reg_fsl_emb.h +++ b/arch/powerpc/include/asm/reg_fsl_emb.h diff --git a/include/asm-powerpc/resource.h b/arch/powerpc/include/asm/resource.h index 04bc4db8921b..04bc4db8921b 100644 --- a/include/asm-powerpc/resource.h +++ b/arch/powerpc/include/asm/resource.h diff --git a/include/asm-powerpc/rheap.h b/arch/powerpc/include/asm/rheap.h index 172381769cfc..172381769cfc 100644 --- a/include/asm-powerpc/rheap.h +++ b/arch/powerpc/include/asm/rheap.h diff --git a/include/asm-powerpc/rio.h b/arch/powerpc/include/asm/rio.h index 0018bf80cb25..0018bf80cb25 100644 --- a/include/asm-powerpc/rio.h +++ b/arch/powerpc/include/asm/rio.h diff --git a/include/asm-powerpc/rtas.h b/arch/powerpc/include/asm/rtas.h index 8eaa7b28d9d0..8eaa7b28d9d0 100644 --- a/include/asm-powerpc/rtas.h +++ b/arch/powerpc/include/asm/rtas.h diff --git a/include/asm-powerpc/rtc.h b/arch/powerpc/include/asm/rtc.h index f5802926b6c0..f5802926b6c0 100644 --- a/include/asm-powerpc/rtc.h +++ b/arch/powerpc/include/asm/rtc.h diff --git a/include/asm-powerpc/rwsem.h b/arch/powerpc/include/asm/rwsem.h index a6cc93b78b98..24cd9281ec37 100644 --- a/include/asm-powerpc/rwsem.h +++ b/arch/powerpc/include/asm/rwsem.h @@ -8,8 +8,8 @@ #ifdef __KERNEL__ /* - * include/asm-powerpc/rwsem.h: R/W semaphores for PPC using the stuff - * in lib/rwsem.c. Adapted largely from include/asm-i386/rwsem.h + * R/W semaphores for PPC using the stuff in lib/rwsem.c. + * Adapted largely from include/asm-i386/rwsem.h * by Paul Mackerras <paulus@samba.org>. */ diff --git a/include/asm-powerpc/scatterlist.h b/arch/powerpc/include/asm/scatterlist.h index fcf7d55afe45..fcf7d55afe45 100644 --- a/include/asm-powerpc/scatterlist.h +++ b/arch/powerpc/include/asm/scatterlist.h diff --git a/include/asm-powerpc/seccomp.h b/arch/powerpc/include/asm/seccomp.h index 853765eb1f65..853765eb1f65 100644 --- a/include/asm-powerpc/seccomp.h +++ b/arch/powerpc/include/asm/seccomp.h diff --git a/include/asm-powerpc/sections.h b/arch/powerpc/include/asm/sections.h index 916018e425c4..916018e425c4 100644 --- a/include/asm-powerpc/sections.h +++ b/arch/powerpc/include/asm/sections.h diff --git a/include/asm-powerpc/sembuf.h b/arch/powerpc/include/asm/sembuf.h index 99a41938ae3d..99a41938ae3d 100644 --- a/include/asm-powerpc/sembuf.h +++ b/arch/powerpc/include/asm/sembuf.h diff --git a/include/asm-powerpc/serial.h b/arch/powerpc/include/asm/serial.h index 3e8589b43cb2..3e8589b43cb2 100644 --- a/include/asm-powerpc/serial.h +++ b/arch/powerpc/include/asm/serial.h diff --git a/include/asm-powerpc/setjmp.h b/arch/powerpc/include/asm/setjmp.h index 279d03a1eec6..279d03a1eec6 100644 --- a/include/asm-powerpc/setjmp.h +++ b/arch/powerpc/include/asm/setjmp.h diff --git a/include/asm-powerpc/setup.h b/arch/powerpc/include/asm/setup.h index 817fac0a0714..817fac0a0714 100644 --- a/include/asm-powerpc/setup.h +++ b/arch/powerpc/include/asm/setup.h diff --git a/include/asm-powerpc/shmbuf.h b/arch/powerpc/include/asm/shmbuf.h index 8efa39698b6c..8efa39698b6c 100644 --- a/include/asm-powerpc/shmbuf.h +++ b/arch/powerpc/include/asm/shmbuf.h diff --git a/include/asm-powerpc/shmparam.h b/arch/powerpc/include/asm/shmparam.h index 5cda42a6d39e..5cda42a6d39e 100644 --- a/include/asm-powerpc/shmparam.h +++ b/arch/powerpc/include/asm/shmparam.h diff --git a/include/asm-powerpc/sigcontext.h b/arch/powerpc/include/asm/sigcontext.h index 9c1f24fd5d11..9c1f24fd5d11 100644 --- a/include/asm-powerpc/sigcontext.h +++ b/arch/powerpc/include/asm/sigcontext.h diff --git a/include/asm-powerpc/siginfo.h b/arch/powerpc/include/asm/siginfo.h index 12f1bce037be..12f1bce037be 100644 --- a/include/asm-powerpc/siginfo.h +++ b/arch/powerpc/include/asm/siginfo.h diff --git a/include/asm-powerpc/signal.h b/arch/powerpc/include/asm/signal.h index a7360cdd99eb..a7360cdd99eb 100644 --- a/include/asm-powerpc/signal.h +++ b/arch/powerpc/include/asm/signal.h diff --git a/include/asm-powerpc/smp.h b/arch/powerpc/include/asm/smp.h index 4d28e1e4521b..4d28e1e4521b 100644 --- a/include/asm-powerpc/smp.h +++ b/arch/powerpc/include/asm/smp.h diff --git a/include/asm-powerpc/smu.h b/arch/powerpc/include/asm/smu.h index 7ae2753da565..7ae2753da565 100644 --- a/include/asm-powerpc/smu.h +++ b/arch/powerpc/include/asm/smu.h diff --git a/include/asm-powerpc/socket.h b/arch/powerpc/include/asm/socket.h index f5a4e168e498..f5a4e168e498 100644 --- a/include/asm-powerpc/socket.h +++ b/arch/powerpc/include/asm/socket.h diff --git a/include/asm-powerpc/sockios.h b/arch/powerpc/include/asm/sockios.h index 55cef7675a31..55cef7675a31 100644 --- a/include/asm-powerpc/sockios.h +++ b/arch/powerpc/include/asm/sockios.h diff --git a/include/asm-powerpc/sparsemem.h b/arch/powerpc/include/asm/sparsemem.h index 54a47ea2c3aa..54a47ea2c3aa 100644 --- a/include/asm-powerpc/sparsemem.h +++ b/arch/powerpc/include/asm/sparsemem.h diff --git a/include/asm-powerpc/spinlock.h b/arch/powerpc/include/asm/spinlock.h index f56a843f4705..f56a843f4705 100644 --- a/include/asm-powerpc/spinlock.h +++ b/arch/powerpc/include/asm/spinlock.h diff --git a/include/asm-powerpc/spinlock_types.h b/arch/powerpc/include/asm/spinlock_types.h index 74236c9f05b1..74236c9f05b1 100644 --- a/include/asm-powerpc/spinlock_types.h +++ b/arch/powerpc/include/asm/spinlock_types.h diff --git a/include/asm-powerpc/spu.h b/arch/powerpc/include/asm/spu.h index 8b2eb044270a..8b2eb044270a 100644 --- a/include/asm-powerpc/spu.h +++ b/arch/powerpc/include/asm/spu.h diff --git a/include/asm-powerpc/spu_csa.h b/arch/powerpc/include/asm/spu_csa.h index a40fd491250c..a40fd491250c 100644 --- a/include/asm-powerpc/spu_csa.h +++ b/arch/powerpc/include/asm/spu_csa.h diff --git a/include/asm-powerpc/spu_info.h b/arch/powerpc/include/asm/spu_info.h index 3545efbf9891..3545efbf9891 100644 --- a/include/asm-powerpc/spu_info.h +++ b/arch/powerpc/include/asm/spu_info.h diff --git a/include/asm-powerpc/spu_priv1.h b/arch/powerpc/include/asm/spu_priv1.h index 25020a34ce7f..25020a34ce7f 100644 --- a/include/asm-powerpc/spu_priv1.h +++ b/arch/powerpc/include/asm/spu_priv1.h diff --git a/include/asm-powerpc/sstep.h b/arch/powerpc/include/asm/sstep.h index f593b0f9b627..f593b0f9b627 100644 --- a/include/asm-powerpc/sstep.h +++ b/arch/powerpc/include/asm/sstep.h diff --git a/include/asm-powerpc/stat.h b/arch/powerpc/include/asm/stat.h index e4edc510b530..e4edc510b530 100644 --- a/include/asm-powerpc/stat.h +++ b/arch/powerpc/include/asm/stat.h diff --git a/include/asm-powerpc/statfs.h b/arch/powerpc/include/asm/statfs.h index 67024026c10d..67024026c10d 100644 --- a/include/asm-powerpc/statfs.h +++ b/arch/powerpc/include/asm/statfs.h diff --git a/include/asm-powerpc/string.h b/arch/powerpc/include/asm/string.h index e40010abcaf1..e40010abcaf1 100644 --- a/include/asm-powerpc/string.h +++ b/arch/powerpc/include/asm/string.h diff --git a/include/asm-powerpc/suspend.h b/arch/powerpc/include/asm/suspend.h index cbf2c9404c37..cbf2c9404c37 100644 --- a/include/asm-powerpc/suspend.h +++ b/arch/powerpc/include/asm/suspend.h diff --git a/include/asm-powerpc/synch.h b/arch/powerpc/include/asm/synch.h index 45963e80f557..45963e80f557 100644 --- a/include/asm-powerpc/synch.h +++ b/arch/powerpc/include/asm/synch.h diff --git a/include/asm-powerpc/syscall.h b/arch/powerpc/include/asm/syscall.h index efa7f0b879f3..efa7f0b879f3 100644 --- a/include/asm-powerpc/syscall.h +++ b/arch/powerpc/include/asm/syscall.h diff --git a/include/asm-powerpc/syscalls.h b/arch/powerpc/include/asm/syscalls.h index eb8eb400c664..eb8eb400c664 100644 --- a/include/asm-powerpc/syscalls.h +++ b/arch/powerpc/include/asm/syscalls.h diff --git a/include/asm-powerpc/systbl.h b/arch/powerpc/include/asm/systbl.h index e084272ed1c2..e084272ed1c2 100644 --- a/include/asm-powerpc/systbl.h +++ b/arch/powerpc/include/asm/systbl.h diff --git a/include/asm-powerpc/system.h b/arch/powerpc/include/asm/system.h index d6648c143322..d6648c143322 100644 --- a/include/asm-powerpc/system.h +++ b/arch/powerpc/include/asm/system.h diff --git a/include/asm-powerpc/tce.h b/arch/powerpc/include/asm/tce.h index f663634cccc9..f663634cccc9 100644 --- a/include/asm-powerpc/tce.h +++ b/arch/powerpc/include/asm/tce.h diff --git a/include/asm-powerpc/termbits.h b/arch/powerpc/include/asm/termbits.h index 6698188ca550..6698188ca550 100644 --- a/include/asm-powerpc/termbits.h +++ b/arch/powerpc/include/asm/termbits.h diff --git a/include/asm-powerpc/termios.h b/arch/powerpc/include/asm/termios.h index 2c14fea07c8a..2c14fea07c8a 100644 --- a/include/asm-powerpc/termios.h +++ b/arch/powerpc/include/asm/termios.h diff --git a/include/asm-powerpc/thread_info.h b/arch/powerpc/include/asm/thread_info.h index 9665a26a253a..9665a26a253a 100644 --- a/include/asm-powerpc/thread_info.h +++ b/arch/powerpc/include/asm/thread_info.h diff --git a/include/asm-powerpc/time.h b/arch/powerpc/include/asm/time.h index febd581ec9b0..febd581ec9b0 100644 --- a/include/asm-powerpc/time.h +++ b/arch/powerpc/include/asm/time.h diff --git a/include/asm-powerpc/timex.h b/arch/powerpc/include/asm/timex.h index c55e14f7ef44..c55e14f7ef44 100644 --- a/include/asm-powerpc/timex.h +++ b/arch/powerpc/include/asm/timex.h diff --git a/include/asm-powerpc/tlb.h b/arch/powerpc/include/asm/tlb.h index e20ff7541f36..e20ff7541f36 100644 --- a/include/asm-powerpc/tlb.h +++ b/arch/powerpc/include/asm/tlb.h diff --git a/include/asm-powerpc/tlbflush.h b/arch/powerpc/include/asm/tlbflush.h index 361cd5c7a32b..361cd5c7a32b 100644 --- a/include/asm-powerpc/tlbflush.h +++ b/arch/powerpc/include/asm/tlbflush.h diff --git a/include/asm-powerpc/topology.h b/arch/powerpc/include/asm/topology.h index c32da6f97999..c32da6f97999 100644 --- a/include/asm-powerpc/topology.h +++ b/arch/powerpc/include/asm/topology.h diff --git a/include/asm-powerpc/tsi108.h b/arch/powerpc/include/asm/tsi108.h index f8b60793b7a9..f8b60793b7a9 100644 --- a/include/asm-powerpc/tsi108.h +++ b/arch/powerpc/include/asm/tsi108.h diff --git a/include/asm-powerpc/tsi108_irq.h b/arch/powerpc/include/asm/tsi108_irq.h index 6ed93979fbe4..6ed93979fbe4 100644 --- a/include/asm-powerpc/tsi108_irq.h +++ b/arch/powerpc/include/asm/tsi108_irq.h diff --git a/include/asm-powerpc/tsi108_pci.h b/arch/powerpc/include/asm/tsi108_pci.h index 5653d7cc3e24..5653d7cc3e24 100644 --- a/include/asm-powerpc/tsi108_pci.h +++ b/arch/powerpc/include/asm/tsi108_pci.h diff --git a/include/asm-powerpc/types.h b/arch/powerpc/include/asm/types.h index d3374bc865ba..d3374bc865ba 100644 --- a/include/asm-powerpc/types.h +++ b/arch/powerpc/include/asm/types.h diff --git a/include/asm-powerpc/uaccess.h b/arch/powerpc/include/asm/uaccess.h index bd0fb8495154..bd0fb8495154 100644 --- a/include/asm-powerpc/uaccess.h +++ b/arch/powerpc/include/asm/uaccess.h diff --git a/include/asm-powerpc/ucc.h b/arch/powerpc/include/asm/ucc.h index 46b09ba6bead..46b09ba6bead 100644 --- a/include/asm-powerpc/ucc.h +++ b/arch/powerpc/include/asm/ucc.h diff --git a/include/asm-powerpc/ucc_fast.h b/arch/powerpc/include/asm/ucc_fast.h index fce16abe7ee1..839aab8bf37d 100644 --- a/include/asm-powerpc/ucc_fast.h +++ b/arch/powerpc/include/asm/ucc_fast.h @@ -1,6 +1,4 @@ /* - * include/asm-powerpc/ucc_fast.h - * * Internal header file for UCC FAST unit routines. * * Copyright (C) 2006 Freescale Semicondutor, Inc. All rights reserved. diff --git a/include/asm-powerpc/ucc_slow.h b/arch/powerpc/include/asm/ucc_slow.h index 0980e6ad335b..0980e6ad335b 100644 --- a/include/asm-powerpc/ucc_slow.h +++ b/arch/powerpc/include/asm/ucc_slow.h diff --git a/include/asm-powerpc/ucontext.h b/arch/powerpc/include/asm/ucontext.h index d9a4ddf0cc86..d9a4ddf0cc86 100644 --- a/include/asm-powerpc/ucontext.h +++ b/arch/powerpc/include/asm/ucontext.h diff --git a/include/asm-powerpc/udbg.h b/arch/powerpc/include/asm/udbg.h index 6418ceea44b7..6418ceea44b7 100644 --- a/include/asm-powerpc/udbg.h +++ b/arch/powerpc/include/asm/udbg.h diff --git a/include/asm-powerpc/uic.h b/arch/powerpc/include/asm/uic.h index 970eb7e2186a..597edfcae3d6 100644 --- a/include/asm-powerpc/uic.h +++ b/arch/powerpc/include/asm/uic.h @@ -1,6 +1,4 @@ /* - * include/asm-powerpc/uic.h - * * IBM PPC4xx UIC external definitions and structure. * * Maintainer: David Gibson <dwg@au1.ibm.com> diff --git a/include/asm-powerpc/unaligned.h b/arch/powerpc/include/asm/unaligned.h index 5f1b1e3c2137..5f1b1e3c2137 100644 --- a/include/asm-powerpc/unaligned.h +++ b/arch/powerpc/include/asm/unaligned.h diff --git a/include/asm-powerpc/uninorth.h b/arch/powerpc/include/asm/uninorth.h index f737732c3861..f737732c3861 100644 --- a/include/asm-powerpc/uninorth.h +++ b/arch/powerpc/include/asm/uninorth.h diff --git a/include/asm-powerpc/unistd.h b/arch/powerpc/include/asm/unistd.h index e07d0c76ed77..e07d0c76ed77 100644 --- a/include/asm-powerpc/unistd.h +++ b/arch/powerpc/include/asm/unistd.h diff --git a/include/asm-powerpc/user.h b/arch/powerpc/include/asm/user.h index 3fd4545dd74e..3fd4545dd74e 100644 --- a/include/asm-powerpc/user.h +++ b/arch/powerpc/include/asm/user.h diff --git a/include/asm-powerpc/vdso.h b/arch/powerpc/include/asm/vdso.h index 26fc449bd989..26fc449bd989 100644 --- a/include/asm-powerpc/vdso.h +++ b/arch/powerpc/include/asm/vdso.h diff --git a/include/asm-powerpc/vdso_datapage.h b/arch/powerpc/include/asm/vdso_datapage.h index f01393224b52..f01393224b52 100644 --- a/include/asm-powerpc/vdso_datapage.h +++ b/arch/powerpc/include/asm/vdso_datapage.h diff --git a/include/asm-powerpc/vga.h b/arch/powerpc/include/asm/vga.h index a2eac409c1ec..a2eac409c1ec 100644 --- a/include/asm-powerpc/vga.h +++ b/arch/powerpc/include/asm/vga.h diff --git a/include/asm-powerpc/vio.h b/arch/powerpc/include/asm/vio.h index 0a290a195946..0a290a195946 100644 --- a/include/asm-powerpc/vio.h +++ b/arch/powerpc/include/asm/vio.h diff --git a/include/asm-powerpc/xilinx_intc.h b/arch/powerpc/include/asm/xilinx_intc.h index 343612f8fece..343612f8fece 100644 --- a/include/asm-powerpc/xilinx_intc.h +++ b/arch/powerpc/include/asm/xilinx_intc.h diff --git a/include/asm-powerpc/xmon.h b/arch/powerpc/include/asm/xmon.h index 5eb8e599e5cc..5eb8e599e5cc 100644 --- a/include/asm-powerpc/xmon.h +++ b/arch/powerpc/include/asm/xmon.h diff --git a/include/asm-powerpc/xor.h b/arch/powerpc/include/asm/xor.h index c82eb12a5b18..c82eb12a5b18 100644 --- a/include/asm-powerpc/xor.h +++ b/arch/powerpc/include/asm/xor.h diff --git a/arch/powerpc/kernel/Makefile b/arch/powerpc/kernel/Makefile index 1a4094704b1f..64f5948ebc9d 100644 --- a/arch/powerpc/kernel/Makefile +++ b/arch/powerpc/kernel/Makefile @@ -59,8 +59,6 @@ obj64-$(CONFIG_HIBERNATION) += swsusp_asm64.o obj-$(CONFIG_MODULES) += module.o module_$(CONFIG_WORD_SIZE).o obj-$(CONFIG_44x) += cpu_setup_44x.o -ifeq ($(CONFIG_PPC_MERGE),y) - extra-$(CONFIG_PPC_STD_MMU) := head_32.o extra-$(CONFIG_PPC64) := head_64.o extra-$(CONFIG_40x) := head_40x.o @@ -100,12 +98,6 @@ ifneq ($(CONFIG_PPC_INDIRECT_IO),y) obj-y += iomap.o endif -else -# stuff used from here for ARCH=ppc -smpobj-$(CONFIG_SMP) += smp.o - -endif - obj-$(CONFIG_PPC64) += $(obj64-y) extra-$(CONFIG_PPC_FPU) += fpu.o @@ -121,9 +113,6 @@ PHONY += systbl_chk systbl_chk: $(src)/systbl_chk.sh $(obj)/systbl_chk.i $(call cmd,systbl_chk) - -ifeq ($(CONFIG_PPC_MERGE),y) - $(obj)/built-in.o: prom_init_check quiet_cmd_prom_init_check = CALL $< @@ -133,7 +122,4 @@ PHONY += prom_init_check prom_init_check: $(src)/prom_init_check.sh $(obj)/prom_init.o $(call cmd,prom_init_check) -endif - - clean-files := vmlinux.lds diff --git a/arch/powerpc/kernel/cpu_setup_44x.S b/arch/powerpc/kernel/cpu_setup_44x.S index 5465e8de0e61..80cac984d85d 100644 --- a/arch/powerpc/kernel/cpu_setup_44x.S +++ b/arch/powerpc/kernel/cpu_setup_44x.S @@ -39,12 +39,6 @@ _GLOBAL(__setup_cpu_440gx) _GLOBAL(__setup_cpu_440spe) b __fixup_440A_mcheck - /* Temporary fixup for arch/ppc until we kill the whole thing */ -#ifndef CONFIG_PPC_MERGE -_GLOBAL(__fixup_440A_mcheck) - blr -#endif - /* enable APU between CPU and FPU */ _GLOBAL(__init_fpu_44x) mfspr r3,SPRN_CCR0 diff --git a/arch/powerpc/kernel/irq.c b/arch/powerpc/kernel/irq.c index 6ac8612da3c3..d972decf0324 100644 --- a/arch/powerpc/kernel/irq.c +++ b/arch/powerpc/kernel/irq.c @@ -77,22 +77,12 @@ static int ppc_spurious_interrupts; EXPORT_SYMBOL(__irq_offset_value); atomic_t ppc_n_lost_interrupts; -#ifndef CONFIG_PPC_MERGE -#define NR_MASK_WORDS ((NR_IRQS + 31) / 32) -unsigned long ppc_cached_irq_mask[NR_MASK_WORDS]; -#endif - #ifdef CONFIG_TAU_INT extern int tau_initialized; extern int tau_interrupts(int); #endif #endif /* CONFIG_PPC32 */ -#if defined(CONFIG_SMP) && !defined(CONFIG_PPC_MERGE) -extern atomic_t ipi_recv; -extern atomic_t ipi_sent; -#endif - #ifdef CONFIG_PPC64 EXPORT_SYMBOL(irq_desc); @@ -216,21 +206,14 @@ int show_interrupts(struct seq_file *p, void *v) skip: spin_unlock_irqrestore(&desc->lock, flags); } else if (i == NR_IRQS) { -#ifdef CONFIG_PPC32 -#ifdef CONFIG_TAU_INT +#if defined(CONFIG_PPC32) && defined(CONFIG_TAU_INT) if (tau_initialized){ seq_puts(p, "TAU: "); for_each_online_cpu(j) seq_printf(p, "%10u ", tau_interrupts(j)); seq_puts(p, " PowerPC Thermal Assist (cpu temp)\n"); } -#endif -#if defined(CONFIG_SMP) && !defined(CONFIG_PPC_MERGE) - /* should this be per processor send/receive? */ - seq_printf(p, "IPI (recv/sent): %10u/%u\n", - atomic_read(&ipi_recv), atomic_read(&ipi_sent)); -#endif -#endif /* CONFIG_PPC32 */ +#endif /* CONFIG_PPC32 && CONFIG_TAU_INT*/ seq_printf(p, "BAD: %10u\n", ppc_spurious_interrupts); } return 0; @@ -454,8 +437,6 @@ void do_softirq(void) * IRQ controller and virtual interrupts */ -#ifdef CONFIG_PPC_MERGE - static LIST_HEAD(irq_hosts); static DEFINE_SPINLOCK(irq_big_lock); static DEFINE_PER_CPU(unsigned int, irq_radix_reader); @@ -1114,8 +1095,6 @@ static int __init irq_debugfs_init(void) __initcall(irq_debugfs_init); #endif /* CONFIG_VIRQ_DEBUG */ -#endif /* CONFIG_PPC_MERGE */ - #ifdef CONFIG_PPC64 static int __init setup_noirqdistrib(char *str) { diff --git a/arch/powerpc/kernel/process.c b/arch/powerpc/kernel/process.c index e030f3bd5024..957bded0020d 100644 --- a/arch/powerpc/kernel/process.c +++ b/arch/powerpc/kernel/process.c @@ -276,10 +276,8 @@ int set_dabr(unsigned long dabr) { __get_cpu_var(current_dabr) = dabr; -#ifdef CONFIG_PPC_MERGE /* XXX for now */ if (ppc_md.set_dabr) return ppc_md.set_dabr(dabr); -#endif /* XXX should we have a CPU_FTR_HAS_DABR ? */ #if defined(CONFIG_PPC64) || defined(CONFIG_6xx) diff --git a/arch/powerpc/kernel/vdso.c b/arch/powerpc/kernel/vdso.c index f177c60ea766..65639a43e644 100644 --- a/arch/powerpc/kernel/vdso.c +++ b/arch/powerpc/kernel/vdso.c @@ -788,9 +788,7 @@ static int __init vdso_init(void) return 0; } -#ifdef CONFIG_PPC_MERGE arch_initcall(vdso_init); -#endif int in_gate_area_no_task(unsigned long addr) { diff --git a/arch/powerpc/lib/Makefile b/arch/powerpc/lib/Makefile index 2a88e8b9a3c6..d69912c07ce7 100644 --- a/arch/powerpc/lib/Makefile +++ b/arch/powerpc/lib/Makefile @@ -6,12 +6,10 @@ ifeq ($(CONFIG_PPC64),y) EXTRA_CFLAGS += -mno-minimal-toc endif -ifeq ($(CONFIG_PPC_MERGE),y) obj-y := string.o alloc.o \ checksum_$(CONFIG_WORD_SIZE).o obj-$(CONFIG_PPC32) += div64.o copy_32.o crtsavres.o obj-$(CONFIG_HAS_IOMEM) += devres.o -endif obj-$(CONFIG_PPC64) += copypage_64.o copyuser_64.o \ memcpy_64.o usercopy_64.o mem_64.o string.o diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c index 702691cb9e82..1c93c255873b 100644 --- a/arch/powerpc/mm/mem.c +++ b/arch/powerpc/mm/mem.c @@ -311,7 +311,7 @@ void __init paging_init(void) #endif /* CONFIG_HIGHMEM */ printk(KERN_DEBUG "Top of RAM: 0x%llx, Total RAM: 0x%lx\n", - (u64)top_of_ram, total_ram); + (unsigned long long)top_of_ram, total_ram); printk(KERN_DEBUG "Memory hole size: %ldMB\n", (long int)((top_of_ram - total_ram) >> 20)); memset(max_zone_pfns, 0, sizeof(max_zone_pfns)); diff --git a/arch/powerpc/mm/ppc_mmu_32.c b/arch/powerpc/mm/ppc_mmu_32.c index c53145f61942..6aa120813775 100644 --- a/arch/powerpc/mm/ppc_mmu_32.c +++ b/arch/powerpc/mm/ppc_mmu_32.c @@ -236,8 +236,8 @@ void __init MMU_init_hw(void) Hash_end = (struct hash_pte *) ((unsigned long)Hash + Hash_size); - printk("Total memory = %ldMB; using %ldkB for hash table (at %p)\n", - total_memory >> 20, Hash_size >> 10, Hash); + printk("Total memory = %lldMB; using %ldkB for hash table (at %p)\n", + (unsigned long long)(total_memory >> 20), Hash_size >> 10, Hash); /* diff --git a/arch/powerpc/mm/tlb_64.c b/arch/powerpc/mm/tlb_64.c index 409fcc7b63ce..be7dd422c0fa 100644 --- a/arch/powerpc/mm/tlb_64.c +++ b/arch/powerpc/mm/tlb_64.c @@ -34,7 +34,7 @@ DEFINE_PER_CPU(struct ppc64_tlb_batch, ppc64_tlb_batch); /* This is declared as we are using the more or less generic - * include/asm-powerpc/tlb.h file -- tgall + * arch/powerpc/include/asm/tlb.h file -- tgall */ DEFINE_PER_CPU(struct mmu_gather, mmu_gathers); static DEFINE_PER_CPU(struct pte_freelist_batch *, pte_freelist_cur); diff --git a/arch/powerpc/platforms/52xx/Makefile b/arch/powerpc/platforms/52xx/Makefile index daf0e1568d6d..b8a52062738a 100644 --- a/arch/powerpc/platforms/52xx/Makefile +++ b/arch/powerpc/platforms/52xx/Makefile @@ -1,10 +1,8 @@ # # Makefile for 52xx based boards # -ifeq ($(CONFIG_PPC_MERGE),y) obj-y += mpc52xx_pic.o mpc52xx_common.o obj-$(CONFIG_PCI) += mpc52xx_pci.o -endif obj-$(CONFIG_PPC_MPC5200_SIMPLE) += mpc5200_simple.o obj-$(CONFIG_PPC_EFIKA) += efika.o @@ -15,4 +13,4 @@ ifeq ($(CONFIG_PPC_LITE5200),y) obj-$(CONFIG_PM) += lite5200_sleep.o lite5200_pm.o endif -obj-$(CONFIG_PPC_MPC5200_GPIO) += mpc52xx_gpio.o
\ No newline at end of file +obj-$(CONFIG_PPC_MPC5200_GPIO) += mpc52xx_gpio.o diff --git a/arch/powerpc/platforms/86xx/mpc86xx_smp.c b/arch/powerpc/platforms/86xx/mpc86xx_smp.c index 835f2dc24dc9..014e26cda08d 100644 --- a/arch/powerpc/platforms/86xx/mpc86xx_smp.c +++ b/arch/powerpc/platforms/86xx/mpc86xx_smp.c @@ -19,7 +19,7 @@ #include <asm/page.h> #include <asm/pgtable.h> #include <asm/pci-bridge.h> -#include <asm-powerpc/mpic.h> +#include <asm/mpic.h> #include <asm/mpc86xx.h> #include <asm/cacheflush.h> diff --git a/arch/powerpc/platforms/Makefile b/arch/powerpc/platforms/Makefile index 423a0234dc31..8079e0b4fd69 100644 --- a/arch/powerpc/platforms/Makefile +++ b/arch/powerpc/platforms/Makefile @@ -1,13 +1,7 @@ obj-$(CONFIG_FSL_ULI1575) += fsl_uli1575.o -ifeq ($(CONFIG_PPC_MERGE),y) obj-$(CONFIG_PPC_PMAC) += powermac/ -else -ifeq ($(CONFIG_PPC64),y) -obj-$(CONFIG_PPC_PMAC) += powermac/ -endif -endif obj-$(CONFIG_PPC_CHRP) += chrp/ obj-$(CONFIG_40x) += 40x/ obj-$(CONFIG_44x) += 44x/ diff --git a/arch/powerpc/platforms/powermac/Makefile b/arch/powerpc/platforms/powermac/Makefile index 89774177b209..58ecdd72630f 100644 --- a/arch/powerpc/platforms/powermac/Makefile +++ b/arch/powerpc/platforms/powermac/Makefile @@ -7,7 +7,7 @@ endif obj-y += pic.o setup.o time.o feature.o pci.o \ sleep.o low_i2c.o cache.o pfunc_core.o \ - pfunc_base.o + pfunc_base.o udbg_scc.o udbg_adb.o obj-$(CONFIG_PMAC_BACKLIGHT) += backlight.o obj-$(CONFIG_CPU_FREQ_PMAC) += cpufreq_32.o obj-$(CONFIG_CPU_FREQ_PMAC64) += cpufreq_64.o @@ -19,4 +19,3 @@ obj-$(CONFIG_NVRAM:m=y) += nvram.o obj-$(CONFIG_PPC64) += nvram.o obj-$(CONFIG_PPC32) += bootx_init.o obj-$(CONFIG_SMP) += smp.o -obj-$(CONFIG_PPC_MERGE) += udbg_scc.o udbg_adb.o diff --git a/arch/powerpc/sysdev/Makefile b/arch/powerpc/sysdev/Makefile index 16a0ed28eb00..a90054b56d5c 100644 --- a/arch/powerpc/sysdev/Makefile +++ b/arch/powerpc/sysdev/Makefile @@ -25,7 +25,6 @@ obj-$(CONFIG_MV64X60) += $(mv64x60-y) mv64x60_pic.o mv64x60_dev.o \ obj-$(CONFIG_RTC_DRV_CMOS) += rtc_cmos_setup.o obj-$(CONFIG_AXON_RAM) += axonram.o -ifeq ($(CONFIG_PPC_MERGE),y) obj-$(CONFIG_PPC_INDIRECT_PCI) += indirect_pci.o obj-$(CONFIG_PPC_I8259) += i8259.o obj-$(CONFIG_IPIC) += ipic.o @@ -36,7 +35,6 @@ obj-$(CONFIG_OF_RTC) += of_rtc.o ifeq ($(CONFIG_PCI),y) obj-$(CONFIG_4xx) += ppc4xx_pci.o endif -endif # Temporary hack until we have migrated to asm-powerpc ifeq ($(ARCH),powerpc) diff --git a/include/asm-s390/Kbuild b/arch/s390/include/asm/Kbuild index 63a23415fba6..63a23415fba6 100644 --- a/include/asm-s390/Kbuild +++ b/arch/s390/include/asm/Kbuild diff --git a/include/asm-s390/airq.h b/arch/s390/include/asm/airq.h index 1ac80d6b0588..1ac80d6b0588 100644 --- a/include/asm-s390/airq.h +++ b/arch/s390/include/asm/airq.h diff --git a/include/asm-s390/appldata.h b/arch/s390/include/asm/appldata.h index 79283dac8281..79283dac8281 100644 --- a/include/asm-s390/appldata.h +++ b/arch/s390/include/asm/appldata.h diff --git a/include/asm-s390/atomic.h b/arch/s390/include/asm/atomic.h index 2d184655bc5d..2d184655bc5d 100644 --- a/include/asm-s390/atomic.h +++ b/arch/s390/include/asm/atomic.h diff --git a/include/asm-s390/auxvec.h b/arch/s390/include/asm/auxvec.h index 0d340720fd99..0d340720fd99 100644 --- a/include/asm-s390/auxvec.h +++ b/arch/s390/include/asm/auxvec.h diff --git a/include/asm-s390/bitops.h b/arch/s390/include/asm/bitops.h index b4eb24ab5af9..b4eb24ab5af9 100644 --- a/include/asm-s390/bitops.h +++ b/arch/s390/include/asm/bitops.h diff --git a/include/asm-s390/bug.h b/arch/s390/include/asm/bug.h index 384e3621e341..384e3621e341 100644 --- a/include/asm-s390/bug.h +++ b/arch/s390/include/asm/bug.h diff --git a/include/asm-s390/bugs.h b/arch/s390/include/asm/bugs.h index 011f1e6a2a6c..011f1e6a2a6c 100644 --- a/include/asm-s390/bugs.h +++ b/arch/s390/include/asm/bugs.h diff --git a/include/asm-s390/byteorder.h b/arch/s390/include/asm/byteorder.h index 1fe2492baa8d..1fe2492baa8d 100644 --- a/include/asm-s390/byteorder.h +++ b/arch/s390/include/asm/byteorder.h diff --git a/include/asm-s390/cache.h b/arch/s390/include/asm/cache.h index 9b866816863c..9b866816863c 100644 --- a/include/asm-s390/cache.h +++ b/arch/s390/include/asm/cache.h diff --git a/include/asm-s390/cacheflush.h b/arch/s390/include/asm/cacheflush.h index 49d5af916d01..49d5af916d01 100644 --- a/include/asm-s390/cacheflush.h +++ b/arch/s390/include/asm/cacheflush.h diff --git a/include/asm-s390/ccwdev.h b/arch/s390/include/asm/ccwdev.h index ba007d8df941..ba007d8df941 100644 --- a/include/asm-s390/ccwdev.h +++ b/arch/s390/include/asm/ccwdev.h diff --git a/include/asm-s390/ccwgroup.h b/arch/s390/include/asm/ccwgroup.h index a27f68985a79..a27f68985a79 100644 --- a/include/asm-s390/ccwgroup.h +++ b/arch/s390/include/asm/ccwgroup.h diff --git a/include/asm-s390/checksum.h b/arch/s390/include/asm/checksum.h index d5a8e7c1477c..d5a8e7c1477c 100644 --- a/include/asm-s390/checksum.h +++ b/arch/s390/include/asm/checksum.h diff --git a/include/asm-s390/chpid.h b/arch/s390/include/asm/chpid.h index dfe3c7f3439a..dfe3c7f3439a 100644 --- a/include/asm-s390/chpid.h +++ b/arch/s390/include/asm/chpid.h diff --git a/include/asm-s390/chsc.h b/arch/s390/include/asm/chsc.h index d38d0cf62d4b..d38d0cf62d4b 100644 --- a/include/asm-s390/chsc.h +++ b/arch/s390/include/asm/chsc.h diff --git a/include/asm-s390/cio.h b/arch/s390/include/asm/cio.h index 6dccb071aec3..6dccb071aec3 100644 --- a/include/asm-s390/cio.h +++ b/arch/s390/include/asm/cio.h diff --git a/include/asm-s390/cmb.h b/arch/s390/include/asm/cmb.h index 50196857d27a..50196857d27a 100644 --- a/include/asm-s390/cmb.h +++ b/arch/s390/include/asm/cmb.h diff --git a/include/asm-s390/compat.h b/arch/s390/include/asm/compat.h index de065b32381a..de065b32381a 100644 --- a/include/asm-s390/compat.h +++ b/arch/s390/include/asm/compat.h diff --git a/include/asm-s390/cpcmd.h b/arch/s390/include/asm/cpcmd.h index 48a9eab16429..48a9eab16429 100644 --- a/include/asm-s390/cpcmd.h +++ b/arch/s390/include/asm/cpcmd.h diff --git a/include/asm-s390/cpu.h b/arch/s390/include/asm/cpu.h index e5a6a9ba3adf..e5a6a9ba3adf 100644 --- a/include/asm-s390/cpu.h +++ b/arch/s390/include/asm/cpu.h diff --git a/include/asm-s390/cputime.h b/arch/s390/include/asm/cputime.h index 133ce054fc89..133ce054fc89 100644 --- a/include/asm-s390/cputime.h +++ b/arch/s390/include/asm/cputime.h diff --git a/include/asm-s390/current.h b/arch/s390/include/asm/current.h index 83cf36cde2da..83cf36cde2da 100644 --- a/include/asm-s390/current.h +++ b/arch/s390/include/asm/current.h diff --git a/include/asm-s390/dasd.h b/arch/s390/include/asm/dasd.h index 3f002e13d024..3f002e13d024 100644 --- a/include/asm-s390/dasd.h +++ b/arch/s390/include/asm/dasd.h diff --git a/include/asm-s390/debug.h b/arch/s390/include/asm/debug.h index 9450ce6e32de..9450ce6e32de 100644 --- a/include/asm-s390/debug.h +++ b/arch/s390/include/asm/debug.h diff --git a/include/asm-s390/delay.h b/arch/s390/include/asm/delay.h index 78357314c450..78357314c450 100644 --- a/include/asm-s390/delay.h +++ b/arch/s390/include/asm/delay.h diff --git a/include/asm-s390/device.h b/arch/s390/include/asm/device.h index d8f9872b0e2d..d8f9872b0e2d 100644 --- a/include/asm-s390/device.h +++ b/arch/s390/include/asm/device.h diff --git a/include/asm-s390/diag.h b/arch/s390/include/asm/diag.h index 72b2e2f2d32d..72b2e2f2d32d 100644 --- a/include/asm-s390/diag.h +++ b/arch/s390/include/asm/diag.h diff --git a/include/asm-s390/div64.h b/arch/s390/include/asm/div64.h index 6cd978cefb28..6cd978cefb28 100644 --- a/include/asm-s390/div64.h +++ b/arch/s390/include/asm/div64.h diff --git a/include/asm-s390/dma.h b/arch/s390/include/asm/dma.h index 7425c6af6cd4..7425c6af6cd4 100644 --- a/include/asm-s390/dma.h +++ b/arch/s390/include/asm/dma.h diff --git a/include/asm-s390/ebcdic.h b/arch/s390/include/asm/ebcdic.h index 7f6f641d32f4..7f6f641d32f4 100644 --- a/include/asm-s390/ebcdic.h +++ b/arch/s390/include/asm/ebcdic.h diff --git a/include/asm-s390/elf.h b/arch/s390/include/asm/elf.h index 3cad56923815..3cad56923815 100644 --- a/include/asm-s390/elf.h +++ b/arch/s390/include/asm/elf.h diff --git a/include/asm-s390/emergency-restart.h b/arch/s390/include/asm/emergency-restart.h index 108d8c48e42e..108d8c48e42e 100644 --- a/include/asm-s390/emergency-restart.h +++ b/arch/s390/include/asm/emergency-restart.h diff --git a/include/asm-s390/errno.h b/arch/s390/include/asm/errno.h index e41d5b37c4d6..e41d5b37c4d6 100644 --- a/include/asm-s390/errno.h +++ b/arch/s390/include/asm/errno.h diff --git a/include/asm-s390/etr.h b/arch/s390/include/asm/etr.h index 80ef58c61970..80ef58c61970 100644 --- a/include/asm-s390/etr.h +++ b/arch/s390/include/asm/etr.h diff --git a/include/asm-s390/extmem.h b/arch/s390/include/asm/extmem.h index 33837d756184..33837d756184 100644 --- a/include/asm-s390/extmem.h +++ b/arch/s390/include/asm/extmem.h diff --git a/include/asm-s390/fb.h b/arch/s390/include/asm/fb.h index c7df38030992..c7df38030992 100644 --- a/include/asm-s390/fb.h +++ b/arch/s390/include/asm/fb.h diff --git a/include/asm-s390/fcntl.h b/arch/s390/include/asm/fcntl.h index 46ab12db5739..46ab12db5739 100644 --- a/include/asm-s390/fcntl.h +++ b/arch/s390/include/asm/fcntl.h diff --git a/include/asm-s390/fcx.h b/arch/s390/include/asm/fcx.h index 8be1f3a58042..8be1f3a58042 100644 --- a/include/asm-s390/fcx.h +++ b/arch/s390/include/asm/fcx.h diff --git a/include/asm-s390/futex.h b/arch/s390/include/asm/futex.h index 5c5d02de49e9..5c5d02de49e9 100644 --- a/include/asm-s390/futex.h +++ b/arch/s390/include/asm/futex.h diff --git a/include/asm-s390/hardirq.h b/arch/s390/include/asm/hardirq.h index 89ec7056da28..89ec7056da28 100644 --- a/include/asm-s390/hardirq.h +++ b/arch/s390/include/asm/hardirq.h diff --git a/include/asm-s390/hugetlb.h b/arch/s390/include/asm/hugetlb.h index 670a1d1745d2..670a1d1745d2 100644 --- a/include/asm-s390/hugetlb.h +++ b/arch/s390/include/asm/hugetlb.h diff --git a/include/asm-s390/idals.h b/arch/s390/include/asm/idals.h index e82c10efe65a..e82c10efe65a 100644 --- a/include/asm-s390/idals.h +++ b/arch/s390/include/asm/idals.h diff --git a/include/asm-s390/io.h b/arch/s390/include/asm/io.h index b7ff6afc3caa..b7ff6afc3caa 100644 --- a/include/asm-s390/io.h +++ b/arch/s390/include/asm/io.h diff --git a/include/asm-s390/ioctl.h b/arch/s390/include/asm/ioctl.h index b279fe06dfe5..b279fe06dfe5 100644 --- a/include/asm-s390/ioctl.h +++ b/arch/s390/include/asm/ioctl.h diff --git a/include/asm-s390/ioctls.h b/arch/s390/include/asm/ioctls.h index 40e481b1b461..40e481b1b461 100644 --- a/include/asm-s390/ioctls.h +++ b/arch/s390/include/asm/ioctls.h diff --git a/include/asm-s390/ipcbuf.h b/arch/s390/include/asm/ipcbuf.h index 37f293d12c8f..37f293d12c8f 100644 --- a/include/asm-s390/ipcbuf.h +++ b/arch/s390/include/asm/ipcbuf.h diff --git a/include/asm-s390/ipl.h b/arch/s390/include/asm/ipl.h index 1171e6d144a3..1171e6d144a3 100644 --- a/include/asm-s390/ipl.h +++ b/arch/s390/include/asm/ipl.h diff --git a/include/asm-s390/irq.h b/arch/s390/include/asm/irq.h index 7da991a858f8..7da991a858f8 100644 --- a/include/asm-s390/irq.h +++ b/arch/s390/include/asm/irq.h diff --git a/include/asm-s390/irq_regs.h b/arch/s390/include/asm/irq_regs.h index 3dd9c0b70270..3dd9c0b70270 100644 --- a/include/asm-s390/irq_regs.h +++ b/arch/s390/include/asm/irq_regs.h diff --git a/include/asm-s390/irqflags.h b/arch/s390/include/asm/irqflags.h index 3f26131120b7..3f26131120b7 100644 --- a/include/asm-s390/irqflags.h +++ b/arch/s390/include/asm/irqflags.h diff --git a/include/asm-s390/isc.h b/arch/s390/include/asm/isc.h index 34bb8916db4f..34bb8916db4f 100644 --- a/include/asm-s390/isc.h +++ b/arch/s390/include/asm/isc.h diff --git a/include/asm-s390/itcw.h b/arch/s390/include/asm/itcw.h index a9bc5c36b32a..a9bc5c36b32a 100644 --- a/include/asm-s390/itcw.h +++ b/arch/s390/include/asm/itcw.h diff --git a/include/asm-s390/kdebug.h b/arch/s390/include/asm/kdebug.h index 40db27cd6e60..40db27cd6e60 100644 --- a/include/asm-s390/kdebug.h +++ b/arch/s390/include/asm/kdebug.h diff --git a/include/asm-s390/kexec.h b/arch/s390/include/asm/kexec.h index f219c6411e0b..f219c6411e0b 100644 --- a/include/asm-s390/kexec.h +++ b/arch/s390/include/asm/kexec.h diff --git a/include/asm-s390/kmap_types.h b/arch/s390/include/asm/kmap_types.h index fd1574648223..fd1574648223 100644 --- a/include/asm-s390/kmap_types.h +++ b/arch/s390/include/asm/kmap_types.h diff --git a/include/asm-s390/kprobes.h b/arch/s390/include/asm/kprobes.h index 330f68caffe4..330f68caffe4 100644 --- a/include/asm-s390/kprobes.h +++ b/arch/s390/include/asm/kprobes.h diff --git a/include/asm-s390/kvm.h b/arch/s390/include/asm/kvm.h index d74002f95794..d74002f95794 100644 --- a/include/asm-s390/kvm.h +++ b/arch/s390/include/asm/kvm.h diff --git a/include/asm-s390/kvm_host.h b/arch/s390/include/asm/kvm_host.h index 3c55e4107dcc..3c55e4107dcc 100644 --- a/include/asm-s390/kvm_host.h +++ b/arch/s390/include/asm/kvm_host.h diff --git a/include/asm-s390/kvm_para.h b/arch/s390/include/asm/kvm_para.h index 2c503796b619..2c503796b619 100644 --- a/include/asm-s390/kvm_para.h +++ b/arch/s390/include/asm/kvm_para.h diff --git a/include/asm-s390/kvm_virtio.h b/arch/s390/include/asm/kvm_virtio.h index 146100224def..146100224def 100644 --- a/include/asm-s390/kvm_virtio.h +++ b/arch/s390/include/asm/kvm_virtio.h diff --git a/include/asm-s390/linkage.h b/arch/s390/include/asm/linkage.h index 291c2d01c44f..291c2d01c44f 100644 --- a/include/asm-s390/linkage.h +++ b/arch/s390/include/asm/linkage.h diff --git a/include/asm-s390/local.h b/arch/s390/include/asm/local.h index c11c530f74d0..c11c530f74d0 100644 --- a/include/asm-s390/local.h +++ b/arch/s390/include/asm/local.h diff --git a/include/asm-s390/lowcore.h b/arch/s390/include/asm/lowcore.h index 0bc51d52a899..0bc51d52a899 100644 --- a/include/asm-s390/lowcore.h +++ b/arch/s390/include/asm/lowcore.h diff --git a/include/asm-s390/mathemu.h b/arch/s390/include/asm/mathemu.h index e8dd1ba8edb0..e8dd1ba8edb0 100644 --- a/include/asm-s390/mathemu.h +++ b/arch/s390/include/asm/mathemu.h diff --git a/include/asm-s390/mman.h b/arch/s390/include/asm/mman.h index 7839767d837e..7839767d837e 100644 --- a/include/asm-s390/mman.h +++ b/arch/s390/include/asm/mman.h diff --git a/include/asm-s390/mmu.h b/arch/s390/include/asm/mmu.h index 5dd5e7b3476f..5dd5e7b3476f 100644 --- a/include/asm-s390/mmu.h +++ b/arch/s390/include/asm/mmu.h diff --git a/include/asm-s390/mmu_context.h b/arch/s390/include/asm/mmu_context.h index 4c2fbf48c9c4..4c2fbf48c9c4 100644 --- a/include/asm-s390/mmu_context.h +++ b/arch/s390/include/asm/mmu_context.h diff --git a/include/asm-s390/module.h b/arch/s390/include/asm/module.h index 1cc1c5af705a..1cc1c5af705a 100644 --- a/include/asm-s390/module.h +++ b/arch/s390/include/asm/module.h diff --git a/include/asm-s390/monwriter.h b/arch/s390/include/asm/monwriter.h index f0cbf96c52e6..f0cbf96c52e6 100644 --- a/include/asm-s390/monwriter.h +++ b/arch/s390/include/asm/monwriter.h diff --git a/include/asm-s390/msgbuf.h b/arch/s390/include/asm/msgbuf.h index 1bbdee927924..1bbdee927924 100644 --- a/include/asm-s390/msgbuf.h +++ b/arch/s390/include/asm/msgbuf.h diff --git a/include/asm-s390/mutex.h b/arch/s390/include/asm/mutex.h index 458c1f7fbc18..458c1f7fbc18 100644 --- a/include/asm-s390/mutex.h +++ b/arch/s390/include/asm/mutex.h diff --git a/include/asm-s390/page.h b/arch/s390/include/asm/page.h index 991ba939408c..991ba939408c 100644 --- a/include/asm-s390/page.h +++ b/arch/s390/include/asm/page.h diff --git a/include/asm-s390/param.h b/arch/s390/include/asm/param.h index 34aaa4603347..34aaa4603347 100644 --- a/include/asm-s390/param.h +++ b/arch/s390/include/asm/param.h diff --git a/include/asm-s390/pci.h b/arch/s390/include/asm/pci.h index 42a145c9ddd6..42a145c9ddd6 100644 --- a/include/asm-s390/pci.h +++ b/arch/s390/include/asm/pci.h diff --git a/include/asm-s390/percpu.h b/arch/s390/include/asm/percpu.h index 408d60b4f75b..408d60b4f75b 100644 --- a/include/asm-s390/percpu.h +++ b/arch/s390/include/asm/percpu.h diff --git a/include/asm-s390/pgalloc.h b/arch/s390/include/asm/pgalloc.h index f5b2bf3d7c1d..f5b2bf3d7c1d 100644 --- a/include/asm-s390/pgalloc.h +++ b/arch/s390/include/asm/pgalloc.h diff --git a/include/asm-s390/pgtable.h b/arch/s390/include/asm/pgtable.h index 0bdb704ae051..0bdb704ae051 100644 --- a/include/asm-s390/pgtable.h +++ b/arch/s390/include/asm/pgtable.h diff --git a/include/asm-s390/poll.h b/arch/s390/include/asm/poll.h index c98509d3149e..c98509d3149e 100644 --- a/include/asm-s390/poll.h +++ b/arch/s390/include/asm/poll.h diff --git a/include/asm-s390/posix_types.h b/arch/s390/include/asm/posix_types.h index 397d93fba3a7..397d93fba3a7 100644 --- a/include/asm-s390/posix_types.h +++ b/arch/s390/include/asm/posix_types.h diff --git a/include/asm-s390/processor.h b/arch/s390/include/asm/processor.h index 4af80af2a88f..4af80af2a88f 100644 --- a/include/asm-s390/processor.h +++ b/arch/s390/include/asm/processor.h diff --git a/include/asm-s390/ptrace.h b/arch/s390/include/asm/ptrace.h index af2c9ac28a07..af2c9ac28a07 100644 --- a/include/asm-s390/ptrace.h +++ b/arch/s390/include/asm/ptrace.h diff --git a/include/asm-s390/qdio.h b/arch/s390/include/asm/qdio.h index 6813772171f2..6813772171f2 100644 --- a/include/asm-s390/qdio.h +++ b/arch/s390/include/asm/qdio.h diff --git a/include/asm-s390/qeth.h b/arch/s390/include/asm/qeth.h index 930d378ef75a..930d378ef75a 100644 --- a/include/asm-s390/qeth.h +++ b/arch/s390/include/asm/qeth.h diff --git a/include/asm-s390/reset.h b/arch/s390/include/asm/reset.h index f584f4a52581..f584f4a52581 100644 --- a/include/asm-s390/reset.h +++ b/arch/s390/include/asm/reset.h diff --git a/include/asm-s390/resource.h b/arch/s390/include/asm/resource.h index 366c01de04f2..366c01de04f2 100644 --- a/include/asm-s390/resource.h +++ b/arch/s390/include/asm/resource.h diff --git a/include/asm-s390/rwsem.h b/arch/s390/include/asm/rwsem.h index 9d2a17971805..9d2a17971805 100644 --- a/include/asm-s390/rwsem.h +++ b/arch/s390/include/asm/rwsem.h diff --git a/include/asm-s390/s390_ext.h b/arch/s390/include/asm/s390_ext.h index 2afc060266a2..2afc060266a2 100644 --- a/include/asm-s390/s390_ext.h +++ b/arch/s390/include/asm/s390_ext.h diff --git a/include/asm-s390/s390_rdev.h b/arch/s390/include/asm/s390_rdev.h index 6fa20442a48c..6fa20442a48c 100644 --- a/include/asm-s390/s390_rdev.h +++ b/arch/s390/include/asm/s390_rdev.h diff --git a/include/asm-s390/scatterlist.h b/arch/s390/include/asm/scatterlist.h index 29ec8e28c8df..29ec8e28c8df 100644 --- a/include/asm-s390/scatterlist.h +++ b/arch/s390/include/asm/scatterlist.h diff --git a/include/asm-s390/schid.h b/arch/s390/include/asm/schid.h index 825503cf3dc2..825503cf3dc2 100644 --- a/include/asm-s390/schid.h +++ b/arch/s390/include/asm/schid.h diff --git a/include/asm-s390/sclp.h b/arch/s390/include/asm/sclp.h index fed7bee650a0..fed7bee650a0 100644 --- a/include/asm-s390/sclp.h +++ b/arch/s390/include/asm/sclp.h diff --git a/include/asm-s390/sections.h b/arch/s390/include/asm/sections.h index fbd9116eb17b..fbd9116eb17b 100644 --- a/include/asm-s390/sections.h +++ b/arch/s390/include/asm/sections.h diff --git a/include/asm-s390/segment.h b/arch/s390/include/asm/segment.h index 8bfce3475b1c..8bfce3475b1c 100644 --- a/include/asm-s390/segment.h +++ b/arch/s390/include/asm/segment.h diff --git a/include/asm-s390/sembuf.h b/arch/s390/include/asm/sembuf.h index 32626b0cac4b..32626b0cac4b 100644 --- a/include/asm-s390/sembuf.h +++ b/arch/s390/include/asm/sembuf.h diff --git a/include/asm-s390/setup.h b/arch/s390/include/asm/setup.h index 2bd9faeb3919..2bd9faeb3919 100644 --- a/include/asm-s390/setup.h +++ b/arch/s390/include/asm/setup.h diff --git a/include/asm-s390/sfp-machine.h b/arch/s390/include/asm/sfp-machine.h index 4e16aede4b06..4e16aede4b06 100644 --- a/include/asm-s390/sfp-machine.h +++ b/arch/s390/include/asm/sfp-machine.h diff --git a/include/asm-s390/sfp-util.h b/arch/s390/include/asm/sfp-util.h index 0addc6466d95..0addc6466d95 100644 --- a/include/asm-s390/sfp-util.h +++ b/arch/s390/include/asm/sfp-util.h diff --git a/include/asm-s390/shmbuf.h b/arch/s390/include/asm/shmbuf.h index eed2e280ce37..eed2e280ce37 100644 --- a/include/asm-s390/shmbuf.h +++ b/arch/s390/include/asm/shmbuf.h diff --git a/include/asm-s390/shmparam.h b/arch/s390/include/asm/shmparam.h index c2e0c0508e73..c2e0c0508e73 100644 --- a/include/asm-s390/shmparam.h +++ b/arch/s390/include/asm/shmparam.h diff --git a/include/asm-s390/sigcontext.h b/arch/s390/include/asm/sigcontext.h index aeb6e0b13329..aeb6e0b13329 100644 --- a/include/asm-s390/sigcontext.h +++ b/arch/s390/include/asm/sigcontext.h diff --git a/include/asm-s390/siginfo.h b/arch/s390/include/asm/siginfo.h index e0ff1ab054be..e0ff1ab054be 100644 --- a/include/asm-s390/siginfo.h +++ b/arch/s390/include/asm/siginfo.h diff --git a/include/asm-s390/signal.h b/arch/s390/include/asm/signal.h index f6cfddb278cb..f6cfddb278cb 100644 --- a/include/asm-s390/signal.h +++ b/arch/s390/include/asm/signal.h diff --git a/include/asm-s390/sigp.h b/arch/s390/include/asm/sigp.h index e16d56f8dfe1..e16d56f8dfe1 100644 --- a/include/asm-s390/sigp.h +++ b/arch/s390/include/asm/sigp.h diff --git a/include/asm-s390/smp.h b/arch/s390/include/asm/smp.h index ae89cf2478fc..ae89cf2478fc 100644 --- a/include/asm-s390/smp.h +++ b/arch/s390/include/asm/smp.h diff --git a/include/asm-s390/socket.h b/arch/s390/include/asm/socket.h index c786ab623b2d..c786ab623b2d 100644 --- a/include/asm-s390/socket.h +++ b/arch/s390/include/asm/socket.h diff --git a/include/asm-s390/sockios.h b/arch/s390/include/asm/sockios.h index f4fc16c7da59..f4fc16c7da59 100644 --- a/include/asm-s390/sockios.h +++ b/arch/s390/include/asm/sockios.h diff --git a/include/asm-s390/sparsemem.h b/arch/s390/include/asm/sparsemem.h index 545d219e6a2d..545d219e6a2d 100644 --- a/include/asm-s390/sparsemem.h +++ b/arch/s390/include/asm/sparsemem.h diff --git a/include/asm-s390/spinlock.h b/arch/s390/include/asm/spinlock.h index df84ae96915f..df84ae96915f 100644 --- a/include/asm-s390/spinlock.h +++ b/arch/s390/include/asm/spinlock.h diff --git a/include/asm-s390/spinlock_types.h b/arch/s390/include/asm/spinlock_types.h index 654abc40de04..654abc40de04 100644 --- a/include/asm-s390/spinlock_types.h +++ b/arch/s390/include/asm/spinlock_types.h diff --git a/include/asm-s390/stat.h b/arch/s390/include/asm/stat.h index d92959eebb65..d92959eebb65 100644 --- a/include/asm-s390/stat.h +++ b/arch/s390/include/asm/stat.h diff --git a/include/asm-s390/statfs.h b/arch/s390/include/asm/statfs.h index 099a45579190..099a45579190 100644 --- a/include/asm-s390/statfs.h +++ b/arch/s390/include/asm/statfs.h diff --git a/include/asm-s390/string.h b/arch/s390/include/asm/string.h index d074673a6d9b..d074673a6d9b 100644 --- a/include/asm-s390/string.h +++ b/arch/s390/include/asm/string.h diff --git a/include/asm-s390/suspend.h b/arch/s390/include/asm/suspend.h index 1f34580e67a7..1f34580e67a7 100644 --- a/include/asm-s390/suspend.h +++ b/arch/s390/include/asm/suspend.h diff --git a/include/asm-s390/sysinfo.h b/arch/s390/include/asm/sysinfo.h index 79d01343f8b0..79d01343f8b0 100644 --- a/include/asm-s390/sysinfo.h +++ b/arch/s390/include/asm/sysinfo.h diff --git a/include/asm-s390/system.h b/arch/s390/include/asm/system.h index 819e7d99ca0c..819e7d99ca0c 100644 --- a/include/asm-s390/system.h +++ b/arch/s390/include/asm/system.h diff --git a/include/asm-s390/tape390.h b/arch/s390/include/asm/tape390.h index 884fba48f1ff..884fba48f1ff 100644 --- a/include/asm-s390/tape390.h +++ b/arch/s390/include/asm/tape390.h diff --git a/include/asm-s390/termbits.h b/arch/s390/include/asm/termbits.h index 58731853d529..58731853d529 100644 --- a/include/asm-s390/termbits.h +++ b/arch/s390/include/asm/termbits.h diff --git a/include/asm-s390/termios.h b/arch/s390/include/asm/termios.h index 67f66278f533..67f66278f533 100644 --- a/include/asm-s390/termios.h +++ b/arch/s390/include/asm/termios.h diff --git a/include/asm-s390/thread_info.h b/arch/s390/include/asm/thread_info.h index 91a8f93ad355..91a8f93ad355 100644 --- a/include/asm-s390/thread_info.h +++ b/arch/s390/include/asm/thread_info.h diff --git a/include/asm-s390/timer.h b/arch/s390/include/asm/timer.h index d98d79e35cd6..d98d79e35cd6 100644 --- a/include/asm-s390/timer.h +++ b/arch/s390/include/asm/timer.h diff --git a/include/asm-s390/timex.h b/arch/s390/include/asm/timex.h index d744c3d62de5..d744c3d62de5 100644 --- a/include/asm-s390/timex.h +++ b/arch/s390/include/asm/timex.h diff --git a/include/asm-s390/tlb.h b/arch/s390/include/asm/tlb.h index 3d8a96d39d9d..3d8a96d39d9d 100644 --- a/include/asm-s390/tlb.h +++ b/arch/s390/include/asm/tlb.h diff --git a/include/asm-s390/tlbflush.h b/arch/s390/include/asm/tlbflush.h index d60394b9745e..d60394b9745e 100644 --- a/include/asm-s390/tlbflush.h +++ b/arch/s390/include/asm/tlbflush.h diff --git a/include/asm-s390/todclk.h b/arch/s390/include/asm/todclk.h index c7f62055488a..c7f62055488a 100644 --- a/include/asm-s390/todclk.h +++ b/arch/s390/include/asm/todclk.h diff --git a/include/asm-s390/topology.h b/arch/s390/include/asm/topology.h index d96c91643458..d96c91643458 100644 --- a/include/asm-s390/topology.h +++ b/arch/s390/include/asm/topology.h diff --git a/include/asm-s390/types.h b/arch/s390/include/asm/types.h index 41c547656130..41c547656130 100644 --- a/include/asm-s390/types.h +++ b/arch/s390/include/asm/types.h diff --git a/include/asm-s390/uaccess.h b/arch/s390/include/asm/uaccess.h index 0235970278f0..0235970278f0 100644 --- a/include/asm-s390/uaccess.h +++ b/arch/s390/include/asm/uaccess.h diff --git a/include/asm-s390/ucontext.h b/arch/s390/include/asm/ucontext.h index d69bec0b03f5..d69bec0b03f5 100644 --- a/include/asm-s390/ucontext.h +++ b/arch/s390/include/asm/ucontext.h diff --git a/include/asm-s390/unaligned.h b/arch/s390/include/asm/unaligned.h index da9627afe5d8..da9627afe5d8 100644 --- a/include/asm-s390/unaligned.h +++ b/arch/s390/include/asm/unaligned.h diff --git a/include/asm-s390/unistd.h b/arch/s390/include/asm/unistd.h index c8ad350d1444..c8ad350d1444 100644 --- a/include/asm-s390/unistd.h +++ b/arch/s390/include/asm/unistd.h diff --git a/include/asm-s390/user.h b/arch/s390/include/asm/user.h index 1b050e35fdc6..1b050e35fdc6 100644 --- a/include/asm-s390/user.h +++ b/arch/s390/include/asm/user.h diff --git a/include/asm-s390/vtoc.h b/arch/s390/include/asm/vtoc.h index 3a5267d90d29..3a5267d90d29 100644 --- a/include/asm-s390/vtoc.h +++ b/arch/s390/include/asm/vtoc.h diff --git a/include/asm-s390/xor.h b/arch/s390/include/asm/xor.h index c82eb12a5b18..c82eb12a5b18 100644 --- a/include/asm-s390/xor.h +++ b/arch/s390/include/asm/xor.h diff --git a/include/asm-s390/zcrypt.h b/arch/s390/include/asm/zcrypt.h index 00d3bbd44117..00d3bbd44117 100644 --- a/include/asm-s390/zcrypt.h +++ b/arch/s390/include/asm/zcrypt.h diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index cb992c3d6b71..5131d50f851a 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig @@ -48,6 +48,9 @@ config GENERIC_HWEIGHT config GENERIC_HARDIRQS def_bool y +config GENERIC_HARDIRQS_NO__DO_IRQ + def_bool y + config GENERIC_IRQ_PROBE def_bool y @@ -63,6 +66,10 @@ config GENERIC_TIME config GENERIC_CLOCKEVENTS def_bool n +config GENERIC_LOCKBREAK + def_bool y + depends on SMP && PREEMPT + config SYS_SUPPORTS_PM bool @@ -94,9 +101,6 @@ config ARCH_HAS_ILOG2_U64 config ARCH_NO_VIRT_TO_BUS def_bool y -config ARCH_SUPPORTS_AOUT - def_bool y - config IO_TRAPPED bool @@ -483,6 +487,23 @@ config CRASH_DUMP For more details see Documentation/kdump/kdump.txt +config SECCOMP + bool "Enable seccomp to safely compute untrusted bytecode" + depends on PROC_FS + default y + help + This kernel feature is useful for number crunching applications + that may need to compute untrusted bytecode during their + execution. By using pipes or other transports made available to + the process as file descriptors supporting the read/write + syscalls, it's possible to isolate those applications in + their own address space using seccomp. Once seccomp is + enabled via prctl, it cannot be disabled and the task is only + allowed to execute a few safe syscalls defined by each seccomp + mode. + + If unsure, say N. + config SMP bool "Symmetric multi-processing support" depends on SYS_SUPPORTS_SMP diff --git a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug index 36f4b1f7066d..4d2d102e00d5 100644 --- a/arch/sh/Kconfig.debug +++ b/arch/sh/Kconfig.debug @@ -182,7 +182,7 @@ if SUPERH64 config SH64_PROC_ASIDS bool "Debug: report ASIDs through /proc/asids" - depends on PROC_FS + depends on PROC_FS && MMU config SH64_SR_WATCH bool "Debug: set SR.WATCH to enable hardware watchpoints and trace" diff --git a/arch/sh/Makefile b/arch/sh/Makefile index 25659ce74baa..01d85c74481d 100644 --- a/arch/sh/Makefile +++ b/arch/sh/Makefile @@ -95,8 +95,6 @@ head-y := arch/sh/kernel/init_task.o head-$(CONFIG_SUPERH32) += arch/sh/kernel/head_32.o head-$(CONFIG_SUPERH64) += arch/sh/kernel/head_64.o -LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name) - core-y += arch/sh/kernel/ arch/sh/mm/ arch/sh/boards/ core-$(CONFIG_SH_FPU_EMU) += arch/sh/math-emu/ @@ -145,10 +143,6 @@ cpuincdir-$(CONFIG_CPU_SH4) += cpu-sh4 cpuincdir-$(CONFIG_CPU_SH5) += cpu-sh5 cpuincdir-y += cpu-common # Must be last -libs-$(CONFIG_SUPERH32) := arch/sh/lib/ $(libs-y) -libs-$(CONFIG_SUPERH64) := arch/sh/lib64/ $(libs-y) -libs-y += $(LIBGCC) - drivers-y += arch/sh/drivers/ drivers-$(CONFIG_OPROFILE) += arch/sh/oprofile/ @@ -161,10 +155,16 @@ KBUILD_CFLAGS += -pipe $(cflags-y) KBUILD_CPPFLAGS += $(cflags-y) KBUILD_AFLAGS += $(cflags-y) +LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name) + +libs-$(CONFIG_SUPERH32) := arch/sh/lib/ $(libs-y) +libs-$(CONFIG_SUPERH64) := arch/sh/lib64/ $(libs-y) +libs-y += $(LIBGCC) + PHONY += maketools FORCE maketools: include/linux/version.h FORCE - $(Q)$(MAKE) $(build)=arch/sh/tools arch/sh/include/asm/machtypes.h + $(Q)$(MAKE) $(build)=arch/sh/tools include/asm-sh/machtypes.h all: $(KBUILD_IMAGE) @@ -215,4 +215,4 @@ arch/sh/lib64/syscalltab.h: arch/sh/kernel/syscalls_64.S $(call filechk,gen-syscalltab) CLEAN_FILES += arch/sh/lib64/syscalltab.h \ - arch/sh/include/asm/machtypes.h + include/asm-sh/machtypes.h diff --git a/arch/sh/boards/Makefile b/arch/sh/boards/Makefile index ff9b93c5a91b..463022c7df3c 100644 --- a/arch/sh/boards/Makefile +++ b/arch/sh/boards/Makefile @@ -5,4 +5,4 @@ obj-$(CONFIG_SH_AP325RXA) += board-ap325rxa.o obj-$(CONFIG_SH_MAGIC_PANEL_R2) += board-magicpanelr2.o obj-$(CONFIG_SH_RSK7203) += board-rsk7203.o obj-$(CONFIG_SH_SH7785LCR) += board-sh7785lcr.o -obj-$(CONFIG_SH_SHMIN) += board-shmin..o +obj-$(CONFIG_SH_SHMIN) += board-shmin.o diff --git a/arch/sh/boards/board-ap325rxa.c b/arch/sh/boards/board-ap325rxa.c index 9c71603d29a2..025d4fe55a58 100644 --- a/arch/sh/boards/board-ap325rxa.c +++ b/arch/sh/boards/board-ap325rxa.c @@ -17,7 +17,6 @@ #include <linux/mtd/physmap.h> #include <linux/delay.h> #include <linux/i2c.h> -#include <linux/delay.h> #include <linux/smc911x.h> #include <media/soc_camera_platform.h> #include <media/sh_mobile_ceu.h> diff --git a/arch/sh/boards/mach-se/7343/irq.c b/arch/sh/boards/mach-se/7343/irq.c index 5d96e2eef82a..051c29d4eae0 100644 --- a/arch/sh/boards/mach-se/7343/irq.c +++ b/arch/sh/boards/mach-se/7343/irq.c @@ -13,7 +13,6 @@ #include <linux/init.h> #include <linux/irq.h> #include <linux/interrupt.h> -#include <linux/irq.h> #include <linux/io.h> #include <mach-se/mach/se7343.h> diff --git a/arch/sh/configs/dreamcast_defconfig b/arch/sh/configs/dreamcast_defconfig index d4075283956d..3dc1cbd8a981 100644 --- a/arch/sh/configs/dreamcast_defconfig +++ b/arch/sh/configs/dreamcast_defconfig @@ -1,7 +1,7 @@ # # Automatically generated make config: don't edit -# Linux kernel version: 2.6.26 -# Wed Jul 30 01:34:24 2008 +# Linux kernel version: 2.6.27-rc1 +# Mon Aug 4 16:49:13 2008 # CONFIG_SUPERH=y CONFIG_SUPERH32=y @@ -11,6 +11,7 @@ CONFIG_GENERIC_BUG=y CONFIG_GENERIC_FIND_NEXT_BIT=y CONFIG_GENERIC_HWEIGHT=y CONFIG_GENERIC_HARDIRQS=y +CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y CONFIG_GENERIC_IRQ_PROBE=y CONFIG_GENERIC_CALIBRATE_DELAY=y CONFIG_GENERIC_TIME=y @@ -21,7 +22,6 @@ CONFIG_LOCKDEP_SUPPORT=y # CONFIG_ARCH_HAS_ILOG2_U32 is not set # CONFIG_ARCH_HAS_ILOG2_U64 is not set CONFIG_ARCH_NO_VIRT_TO_BUS=y -CONFIG_ARCH_SUPPORTS_AOUT=y CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" # @@ -87,6 +87,7 @@ CONFIG_HAVE_OPROFILE=y # CONFIG_USE_GENERIC_SMP_HELPERS is not set CONFIG_HAVE_CLK=y CONFIG_PROC_PAGE_MONITOR=y +CONFIG_HAVE_GENERIC_DMA_COHERENT=y CONFIG_SLABINFO=y CONFIG_RT_MUTEXES=y # CONFIG_TINY_SHMEM is not set @@ -284,6 +285,7 @@ CONFIG_HZ=250 # CONFIG_SCHED_HRTICK is not set # CONFIG_KEXEC is not set # CONFIG_CRASH_DUMP is not set +CONFIG_SECCOMP=y # CONFIG_PREEMPT_NONE is not set # CONFIG_PREEMPT_VOLUNTARY is not set CONFIG_PREEMPT=y @@ -317,10 +319,6 @@ CONFIG_PCI_LEGACY=y # CONFIG_BINFMT_ELF=y # CONFIG_BINFMT_MISC is not set - -# -# Networking -# CONFIG_NET=y # @@ -555,7 +553,7 @@ CONFIG_INPUT_KEYBOARD=y # CONFIG_KEYBOARD_XTKBD is not set # CONFIG_KEYBOARD_NEWTON is not set # CONFIG_KEYBOARD_STOWAWAY is not set -# CONFIG_KEYBOARD_MAPLE is not set +CONFIG_KEYBOARD_MAPLE=y # CONFIG_KEYBOARD_SH_KEYSC is not set CONFIG_INPUT_MOUSE=y # CONFIG_MOUSE_PS2 is not set diff --git a/arch/sh/include/asm/a.out.h b/arch/sh/include/asm/a.out.h deleted file mode 100644 index 1f93130e179c..000000000000 --- a/arch/sh/include/asm/a.out.h +++ /dev/null @@ -1,20 +0,0 @@ -#ifndef __ASM_SH_A_OUT_H -#define __ASM_SH_A_OUT_H - -struct exec -{ - unsigned long a_info; /* Use macros N_MAGIC, etc for access */ - unsigned a_text; /* length of text, in bytes */ - unsigned a_data; /* length of data, in bytes */ - unsigned a_bss; /* length of uninitialized data area for file, in bytes */ - unsigned a_syms; /* length of symbol table data in file, in bytes */ - unsigned a_entry; /* start address */ - unsigned a_trsize; /* length of relocation info for text, in bytes */ - unsigned a_drsize; /* length of relocation info for data, in bytes */ -}; - -#define N_TRSIZE(a) ((a).a_trsize) -#define N_DRSIZE(a) ((a).a_drsize) -#define N_SYMSIZE(a) ((a).a_syms) - -#endif /* __ASM_SH_A_OUT_H */ diff --git a/arch/sh/include/asm/ptrace.h b/arch/sh/include/asm/ptrace.h index 643ab5a7cf3b..b86aeabba61a 100644 --- a/arch/sh/include/asm/ptrace.h +++ b/arch/sh/include/asm/ptrace.h @@ -104,6 +104,15 @@ struct pt_dspregs { extern void show_regs(struct pt_regs *); +/* + * These are defined as per linux/ptrace.h. + */ +struct task_struct; + +#define arch_has_single_step() (1) +extern void user_enable_single_step(struct task_struct *); +extern void user_disable_single_step(struct task_struct *); + #ifdef CONFIG_SH_DSP #define task_pt_regs(task) \ ((struct pt_regs *) (task_stack_page(task) + THREAD_SIZE \ diff --git a/arch/sh/include/asm/seccomp.h b/arch/sh/include/asm/seccomp.h new file mode 100644 index 000000000000..3280ed3802ef --- /dev/null +++ b/arch/sh/include/asm/seccomp.h @@ -0,0 +1,10 @@ +#ifndef __ASM_SECCOMP_H + +#include <linux/unistd.h> + +#define __NR_seccomp_read __NR_read +#define __NR_seccomp_write __NR_write +#define __NR_seccomp_exit __NR_exit +#define __NR_seccomp_sigreturn __NR_rt_sigreturn + +#endif /* __ASM_SECCOMP_H */ diff --git a/arch/sh/include/asm/thread_info.h b/arch/sh/include/asm/thread_info.h index eeb4c747119e..0a894cafb1dd 100644 --- a/arch/sh/include/asm/thread_info.h +++ b/arch/sh/include/asm/thread_info.h @@ -117,24 +117,45 @@ static inline struct thread_info *current_thread_info(void) #define TIF_NEED_RESCHED 2 /* rescheduling necessary */ #define TIF_RESTORE_SIGMASK 3 /* restore signal mask in do_signal() */ #define TIF_SINGLESTEP 4 /* singlestepping active */ -#define TIF_SYSCALL_AUDIT 5 +#define TIF_SYSCALL_AUDIT 5 /* syscall auditing active */ +#define TIF_SECCOMP 6 /* secure computing */ +#define TIF_NOTIFY_RESUME 7 /* callback before returning to user */ #define TIF_USEDFPU 16 /* FPU was used by this task this quantum (SMP) */ #define TIF_POLLING_NRFLAG 17 /* true if poll_idle() is polling TIF_NEED_RESCHED */ #define TIF_MEMDIE 18 -#define TIF_FREEZE 19 - -#define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) -#define _TIF_SIGPENDING (1<<TIF_SIGPENDING) -#define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) -#define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK) -#define _TIF_SINGLESTEP (1<<TIF_SINGLESTEP) -#define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT) -#define _TIF_USEDFPU (1<<TIF_USEDFPU) -#define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) -#define _TIF_FREEZE (1<<TIF_FREEZE) - -#define _TIF_WORK_MASK 0x000000FE /* work to do on interrupt/exception return */ -#define _TIF_ALLWORK_MASK 0x000000FF /* work to do on any return to u-space */ +#define TIF_FREEZE 19 /* Freezing for suspend */ + +#define _TIF_SYSCALL_TRACE (1 << TIF_SYSCALL_TRACE) +#define _TIF_SIGPENDING (1 << TIF_SIGPENDING) +#define _TIF_NEED_RESCHED (1 << TIF_NEED_RESCHED) +#define _TIF_RESTORE_SIGMASK (1 << TIF_RESTORE_SIGMASK) +#define _TIF_SINGLESTEP (1 << TIF_SINGLESTEP) +#define _TIF_SYSCALL_AUDIT (1 << TIF_SYSCALL_AUDIT) +#define _TIF_SECCOMP (1 << TIF_SECCOMP) +#define _TIF_NOTIFY_RESUME (1 << TIF_NOTIFY_RESUME) +#define _TIF_USEDFPU (1 << TIF_USEDFPU) +#define _TIF_POLLING_NRFLAG (1 << TIF_POLLING_NRFLAG) +#define _TIF_FREEZE (1 << TIF_FREEZE) + +/* + * _TIF_ALLWORK_MASK and _TIF_WORK_MASK need to fit within a byte, or we + * blow the tst immediate size constraints and need to fix up + * arch/sh/kernel/entry-common.S. + */ + +/* work to do in syscall trace */ +#define _TIF_WORK_SYSCALL_MASK (_TIF_SYSCALL_TRACE | _TIF_SINGLESTEP | \ + _TIF_SYSCALL_AUDIT | _TIF_SECCOMP) + +/* work to do on any return to u-space */ +#define _TIF_ALLWORK_MASK (_TIF_SYSCALL_TRACE | _TIF_SIGPENDING | \ + _TIF_NEED_RESCHED | _TIF_SYSCALL_AUDIT | \ + _TIF_SINGLESTEP | _TIF_RESTORE_SIGMASK | \ + _TIF_NOTIFY_RESUME) + +/* work to do on interrupt/exception return */ +#define _TIF_WORK_MASK (_TIF_ALLWORK_MASK & ~(_TIF_SYSCALL_TRACE | \ + _TIF_SYSCALL_AUDIT | _TIF_SINGLESTEP)) #endif /* __KERNEL__ */ diff --git a/arch/sh/include/asm/tlb_64.h b/arch/sh/include/asm/tlb_64.h index 0a96f3af69e3..ef0ae2a28f23 100644 --- a/arch/sh/include/asm/tlb_64.h +++ b/arch/sh/include/asm/tlb_64.h @@ -21,11 +21,9 @@ #ifndef __ASSEMBLY__ /** - * for_each_dtlb_entry + * for_each_dtlb_entry - Iterate over free (non-wired) DTLB entries * * @tlb: TLB entry - * - * Iterate over free (non-wired) DTLB entries */ #define for_each_dtlb_entry(tlb) \ for (tlb = cpu_data->dtlb.first; \ @@ -33,11 +31,9 @@ tlb += cpu_data->dtlb.step) /** - * for_each_itlb_entry + * for_each_itlb_entry - Iterate over free (non-wired) ITLB entries * * @tlb: TLB entry - * - * Iterate over free (non-wired) ITLB entries */ #define for_each_itlb_entry(tlb) \ for (tlb = cpu_data->itlb.first; \ @@ -45,11 +41,9 @@ tlb += cpu_data->itlb.step) /** - * __flush_tlb_slot + * __flush_tlb_slot - Flushes TLB slot @slot. * * @slot: Address of TLB slot. - * - * Flushes TLB slot @slot. */ static inline void __flush_tlb_slot(unsigned long long slot) { diff --git a/arch/sh/include/cpu-sh2/cpu/cache.h b/arch/sh/include/cpu-sh2/cpu/cache.h index 4e0b16500686..673515bc4135 100644 --- a/arch/sh/include/cpu-sh2/cpu/cache.h +++ b/arch/sh/include/cpu-sh2/cpu/cache.h @@ -21,11 +21,11 @@ #define CCR 0xffffffec #define CCR_CACHE_CE 0x01 /* Cache enable */ -#define CCR_CACHE_WT 0x06 /* CCR[bit1=1,bit2=1] */ +#define CCR_CACHE_WT 0x02 /* CCR[bit1=1,bit2=1] */ /* 0x00000000-0x7fffffff: Write-through */ /* 0x80000000-0x9fffffff: Write-back */ /* 0xc0000000-0xdfffffff: Write-through */ -#define CCR_CACHE_CB 0x00 /* CCR[bit1=0,bit2=0] */ +#define CCR_CACHE_CB 0x04 /* CCR[bit1=0,bit2=0] */ /* 0x00000000-0x7fffffff: Write-back */ /* 0x80000000-0x9fffffff: Write-through */ /* 0xc0000000-0xdfffffff: Write-back */ @@ -36,6 +36,8 @@ #define CCR_CACHE_ENABLE CCR_CACHE_CE #define CCR_CACHE_INVALIDATE CCR_CACHE_CF +#define CACHE_PHYSADDR_MASK 0x1ffffc00 + #endif #endif /* __ASM_CPU_SH2_CACHE_H */ diff --git a/arch/sh/include/cpu-sh2a/cpu/addrspace.h b/arch/sh/include/cpu-sh2a/cpu/addrspace.h new file mode 100644 index 000000000000..31eb4b58aa6d --- /dev/null +++ b/arch/sh/include/cpu-sh2a/cpu/addrspace.h @@ -0,0 +1,10 @@ +#ifndef __ASM_SH_CPU_SH2A_ADDRSPACE_H +#define __ASM_SH_CPU_SH2A_ADDRSPACE_H + +#define P0SEG 0x00000000 +#define P1SEG 0x00000000 +#define P2SEG 0x20000000 +#define P3SEG 0x40000000 +#define P4SEG 0x60000000 + +#endif /* __ASM_SH_CPU_SH2A_ADDRSPACE_H */ diff --git a/arch/sh/include/cpu-sh2a/cpu/cache.h b/arch/sh/include/cpu-sh2a/cpu/cache.h index afe228b3f493..defb0baa5a06 100644 --- a/arch/sh/include/cpu-sh2a/cpu/cache.h +++ b/arch/sh/include/cpu-sh2a/cpu/cache.h @@ -36,5 +36,8 @@ #define CCR_CACHE_ENABLE (CCR_CACHE_OCE | CCR_CACHE_ICE) #define CCR_CACHE_INVALIDATE (CCR_CACHE_OCI | CCR_CACHE_ICI) +#define CCR_ICACHE_INVALIDATE CCR_CACHE_ICI +#define CCR_OCACHE_INVALIDATE CCR_CACHE_OCI +#define CACHE_PHYSADDR_MASK 0x1ffffc00 #endif /* __ASM_CPU_SH2A_CACHE_H */ diff --git a/arch/sh/include/cpu-sh2a/cpu/cacheflush.h b/arch/sh/include/cpu-sh2a/cpu/cacheflush.h new file mode 100644 index 000000000000..3d3b9205d2ac --- /dev/null +++ b/arch/sh/include/cpu-sh2a/cpu/cacheflush.h @@ -0,0 +1,34 @@ +#ifndef __ASM_CPU_SH2A_CACHEFLUSH_H +#define __ASM_CPU_SH2A_CACHEFLUSH_H + +/* + * Cache flushing: + * + * - flush_cache_all() flushes entire cache + * - flush_cache_mm(mm) flushes the specified mm context's cache lines + * - flush_cache_dup mm(mm) handles cache flushing when forking + * - flush_cache_page(mm, vmaddr, pfn) flushes a single page + * - flush_cache_range(vma, start, end) flushes a range of pages + * + * - flush_dcache_page(pg) flushes(wback&invalidates) a page for dcache + * - flush_icache_range(start, end) flushes(invalidates) a range for icache + * - flush_icache_page(vma, pg) flushes(invalidates) a page for icache + * + * Caches are indexed (effectively) by physical address on SH-2, so + * we don't need them. + */ +#define flush_cache_all() do { } while (0) +#define flush_cache_mm(mm) do { } while (0) +#define flush_cache_dup_mm(mm) do { } while (0) +#define flush_cache_range(vma, start, end) do { } while (0) +#define flush_cache_page(vma, vmaddr, pfn) do { } while (0) +#define flush_dcache_page(page) do { } while (0) +#define flush_dcache_mmap_lock(mapping) do { } while (0) +#define flush_dcache_mmap_unlock(mapping) do { } while (0) +void flush_icache_range(unsigned long start, unsigned long end); +#define flush_icache_page(vma,pg) do { } while (0) +#define flush_icache_user_range(vma,pg,adr,len) do { } while (0) +#define flush_cache_sigtramp(vaddr) do { } while (0) + +#define p3_cache_init() do { } while (0) +#endif /* __ASM_CPU_SH2A_CACHEFLUSH_H */ diff --git a/arch/sh/kernel/cpu/sh4/sq.c b/arch/sh/kernel/cpu/sh4/sq.c index dcdf959a3d44..8a8a993f55ea 100644 --- a/arch/sh/kernel/cpu/sh4/sq.c +++ b/arch/sh/kernel/cpu/sh4/sq.c @@ -199,7 +199,7 @@ EXPORT_SYMBOL(sq_remap); /** * sq_unmap - Unmap a Store Queue allocation - * @map: Pre-allocated Store Queue mapping. + * @vaddr: Pre-allocated Store Queue mapping. * * Unmaps the store queue allocation @map that was previously created by * sq_remap(). Also frees up the pte that was previously inserted into diff --git a/arch/sh/kernel/cpu/sh5/entry.S b/arch/sh/kernel/cpu/sh5/entry.S index ca08e7f26a3a..04c7da968146 100644 --- a/arch/sh/kernel/cpu/sh5/entry.S +++ b/arch/sh/kernel/cpu/sh5/entry.S @@ -987,11 +987,11 @@ work_resched: work_notifysig: gettr tr1, LINK - movi do_signal, r6 + movi do_notify_resume, r6 ptabs r6, tr0 or SP, ZERO, r2 - or ZERO, ZERO, r3 - blink tr0, LINK /* Call do_signal(regs, 0), return here */ + or r7, ZERO, r3 + blink tr0, LINK /* Call do_notify_resume(regs, current_thread_info->flags), return here */ restore_all: /* Do prefetches */ @@ -1300,18 +1300,20 @@ syscall_allowed: getcon KCR0, r2 ld.l r2, TI_FLAGS, r4 - movi (_TIF_SYSCALL_TRACE | _TIF_SINGLESTEP | _TIF_SYSCALL_AUDIT), r6 + movi _TIF_WORK_SYSCALL_MASK, r6 and r6, r4, r6 beq/l r6, ZERO, tr0 /* Trace it by calling syscall_trace before and after */ - movi syscall_trace, r4 + movi do_syscall_trace_enter, r4 or SP, ZERO, r2 - or ZERO, ZERO, r3 ptabs r4, tr0 blink tr0, LINK - /* Reload syscall number as r5 is trashed by syscall_trace */ + /* Save the retval */ + st.q SP, FRAME_R(2), r2 + + /* Reload syscall number as r5 is trashed by do_syscall_trace_enter */ ld.q SP, FRAME_S(FSYSCALL_ID), r5 andi r5, 0x1ff, r5 @@ -1343,9 +1345,8 @@ syscall_ret_trace: /* We get back here only if under trace */ st.q SP, FRAME_R(9), r2 /* Save return value */ - movi syscall_trace, LINK + movi do_syscall_trace_leave, LINK or SP, ZERO, r2 - movi 1, r3 ptabs LINK, tr0 blink tr0, LINK diff --git a/arch/sh/kernel/entry-common.S b/arch/sh/kernel/entry-common.S index 5e0dd1933847..0bc17def55a7 100644 --- a/arch/sh/kernel/entry-common.S +++ b/arch/sh/kernel/entry-common.S @@ -202,7 +202,7 @@ work_resched: syscall_exit_work: ! r0: current_thread_info->flags ! r8: current_thread_info - tst #_TIF_SYSCALL_TRACE | _TIF_SINGLESTEP | _TIF_SYSCALL_AUDIT, r0 + tst #_TIF_WORK_SYSCALL_MASK, r0 bt/s work_pending tst #_TIF_NEED_RESCHED, r0 #ifdef CONFIG_TRACE_IRQFLAGS @@ -211,10 +211,8 @@ syscall_exit_work: nop #endif sti - ! XXX setup arguments... mov r15, r4 - mov #1, r5 - mov.l 4f, r0 ! do_syscall_trace + mov.l 8f, r0 ! do_syscall_trace_leave jsr @r0 nop bra resume_userspace @@ -223,12 +221,11 @@ syscall_exit_work: .align 2 syscall_trace_entry: ! Yes it is traced. - ! XXX setup arguments... mov r15, r4 - mov #0, r5 - mov.l 4f, r11 ! Call do_syscall_trace which notifies + mov.l 7f, r11 ! Call do_syscall_trace_enter which notifies jsr @r11 ! superior (will chomp R[0-7]) nop + mov.l r0, @(OFF_R0,r15) ! Save return value ! Reload R0-R4 from kernel stack, where the ! parent may have modified them using ! ptrace(POKEUSR). (Note that R0-R2 are @@ -351,7 +348,7 @@ ENTRY(system_call) ! get_current_thread_info r8, r10 mov.l @(TI_FLAGS,r8), r8 - mov #(_TIF_SYSCALL_TRACE | _TIF_SYSCALL_AUDIT), r10 + mov #_TIF_WORK_SYSCALL_MASK, r10 tst r10, r8 bf syscall_trace_entry ! @@ -389,8 +386,9 @@ syscall_exit: #endif 2: .long NR_syscalls 3: .long sys_call_table -4: .long do_syscall_trace #ifdef CONFIG_TRACE_IRQFLAGS 5: .long trace_hardirqs_on 6: .long trace_hardirqs_off #endif +7: .long do_syscall_trace_enter +8: .long do_syscall_trace_leave diff --git a/arch/sh/kernel/machine_kexec.c b/arch/sh/kernel/machine_kexec.c index ec1eadce4aaa..4703dff174d5 100644 --- a/arch/sh/kernel/machine_kexec.c +++ b/arch/sh/kernel/machine_kexec.c @@ -13,6 +13,7 @@ #include <linux/kexec.h> #include <linux/delay.h> #include <linux/reboot.h> +#include <linux/numa.h> #include <asm/pgtable.h> #include <asm/pgalloc.h> #include <asm/mmu_context.h> @@ -104,3 +105,10 @@ void machine_kexec(struct kimage *image) (*rnk)(page_list, reboot_code_buffer, image->start, vbr_reg); } +void arch_crash_save_vmcoreinfo(void) +{ +#ifdef CONFIG_NUMA + VMCOREINFO_SYMBOL(node_data); + VMCOREINFO_LENGTH(node_data, MAX_NUMNODES); +#endif +} diff --git a/arch/sh/kernel/module.c b/arch/sh/kernel/module.c index 5482e65375a9..c43081039dd5 100644 --- a/arch/sh/kernel/module.c +++ b/arch/sh/kernel/module.c @@ -27,6 +27,7 @@ #include <linux/moduleloader.h> #include <linux/elf.h> #include <linux/vmalloc.h> +#include <linux/bug.h> #include <linux/fs.h> #include <linux/string.h> #include <linux/kernel.h> @@ -36,7 +37,8 @@ void *module_alloc(unsigned long size) { if (size == 0) return NULL; - return vmalloc(size); + + return vmalloc_exec(size); } @@ -145,9 +147,10 @@ int module_finalize(const Elf_Ehdr *hdr, const Elf_Shdr *sechdrs, struct module *me) { - return 0; + return module_bug_finalize(hdr, sechdrs, me); } void module_arch_cleanup(struct module *mod) { + module_bug_cleanup(mod); } diff --git a/arch/sh/kernel/ptrace_32.c b/arch/sh/kernel/ptrace_32.c index 2bc72def5cf8..035cb300d3dc 100644 --- a/arch/sh/kernel/ptrace_32.c +++ b/arch/sh/kernel/ptrace_32.c @@ -20,6 +20,8 @@ #include <linux/signal.h> #include <linux/io.h> #include <linux/audit.h> +#include <linux/seccomp.h> +#include <linux/tracehook.h> #include <asm/uaccess.h> #include <asm/pgtable.h> #include <asm/system.h> @@ -57,7 +59,23 @@ static inline int put_stack_long(struct task_struct *task, int offset, return 0; } -static void ptrace_disable_singlestep(struct task_struct *child) +void user_enable_single_step(struct task_struct *child) +{ + struct pt_regs *regs = task_pt_regs(child); + long pc; + + pc = get_stack_long(child, (long)®s->pc); + + /* Next scheduling will set up UBC */ + if (child->thread.ubc_pc == 0) + ubc_usercnt += 1; + + child->thread.ubc_pc = pc; + + set_tsk_thread_flag(child, TIF_SINGLESTEP); +} + +void user_disable_single_step(struct task_struct *child) { clear_tsk_thread_flag(child, TIF_SINGLESTEP); @@ -81,7 +99,7 @@ static void ptrace_disable_singlestep(struct task_struct *child) */ void ptrace_disable(struct task_struct *child) { - ptrace_disable_singlestep(child); + user_disable_single_step(child); } long arch_ptrace(struct task_struct *child, long request, long addr, long data) @@ -90,12 +108,6 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) int ret; switch (request) { - /* when I and D space are separate, these will need to be fixed. */ - case PTRACE_PEEKTEXT: /* read word at location addr. */ - case PTRACE_PEEKDATA: - ret = generic_ptrace_peekdata(child, addr, data); - break; - /* read the word at location addr in the USER area. */ case PTRACE_PEEKUSR: { unsigned long tmp; @@ -125,12 +137,6 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) break; } - /* when I and D space are separate, this will have to be fixed. */ - case PTRACE_POKETEXT: /* write the word at location addr. */ - case PTRACE_POKEDATA: - ret = generic_ptrace_pokedata(child, addr, data); - break; - case PTRACE_POKEUSR: /* write the word at location addr in the USER area */ ret = -EIO; if ((addr & 3) || addr < 0 || @@ -151,67 +157,6 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) } break; - case PTRACE_SYSCALL: /* continue and stop at next (return from) syscall */ - case PTRACE_CONT: { /* restart after signal. */ - ret = -EIO; - if (!valid_signal(data)) - break; - if (request == PTRACE_SYSCALL) - set_tsk_thread_flag(child, TIF_SYSCALL_TRACE); - else - clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); - - ptrace_disable_singlestep(child); - - child->exit_code = data; - wake_up_process(child); - ret = 0; - break; - } - -/* - * make the child exit. Best I can do is send it a sigkill. - * perhaps it should be put in the status that it wants to - * exit. - */ - case PTRACE_KILL: { - ret = 0; - if (child->exit_state == EXIT_ZOMBIE) /* already dead */ - break; - ptrace_disable_singlestep(child); - child->exit_code = SIGKILL; - wake_up_process(child); - break; - } - - case PTRACE_SINGLESTEP: { /* set the trap flag. */ - long pc; - struct pt_regs *regs = NULL; - - ret = -EIO; - if (!valid_signal(data)) - break; - clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); - if ((child->ptrace & PT_DTRACE) == 0) { - /* Spurious delayed TF traps may occur */ - child->ptrace |= PT_DTRACE; - } - - pc = get_stack_long(child, (long)®s->pc); - - /* Next scheduling will set up UBC */ - if (child->thread.ubc_pc == 0) - ubc_usercnt += 1; - child->thread.ubc_pc = pc; - - set_tsk_thread_flag(child, TIF_SINGLESTEP); - child->exit_code = data; - /* give it a chance to run. */ - wake_up_process(child); - ret = 0; - break; - } - #ifdef CONFIG_SH_DSP case PTRACE_GETDSPREGS: { unsigned long dp; @@ -272,39 +217,49 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) return ret; } -asmlinkage void do_syscall_trace(struct pt_regs *regs, int entryexit) +static inline int audit_arch(void) { - struct task_struct *tsk = current; + int arch = EM_SH; - if (unlikely(current->audit_context) && entryexit) - audit_syscall_exit(AUDITSC_RESULT(regs->regs[0]), - regs->regs[0]); +#ifdef CONFIG_CPU_LITTLE_ENDIAN + arch |= __AUDIT_ARCH_LE; +#endif - if (!test_thread_flag(TIF_SYSCALL_TRACE) && - !test_thread_flag(TIF_SINGLESTEP)) - goto out; - if (!(tsk->ptrace & PT_PTRACED)) - goto out; + return arch; +} - /* the 0x80 provides a way for the tracing parent to distinguish - between a syscall stop and SIGTRAP delivery */ - ptrace_notify(SIGTRAP | ((current->ptrace & PT_TRACESYSGOOD) && - !test_thread_flag(TIF_SINGLESTEP) ? 0x80 : 0)); +asmlinkage long do_syscall_trace_enter(struct pt_regs *regs) +{ + long ret = 0; - /* - * this isn't the same as continuing with a signal, but it will do - * for normal use. strace only continues with a signal if the - * stopping signal is not SIGTRAP. -brl - */ - if (tsk->exit_code) { - send_sig(tsk->exit_code, tsk, 1); - tsk->exit_code = 0; - } + secure_computing(regs->regs[0]); + + if (test_thread_flag(TIF_SYSCALL_TRACE) && + tracehook_report_syscall_entry(regs)) + /* + * Tracing decided this syscall should not happen. + * We'll return a bogus call number to get an ENOSYS + * error, but leave the original number in regs->regs[0]. + */ + ret = -1L; -out: - if (unlikely(current->audit_context) && !entryexit) - audit_syscall_entry(AUDIT_ARCH_SH, regs->regs[3], + if (unlikely(current->audit_context)) + audit_syscall_entry(audit_arch(), regs->regs[3], regs->regs[4], regs->regs[5], regs->regs[6], regs->regs[7]); + return ret ?: regs->regs[0]; +} + +asmlinkage void do_syscall_trace_leave(struct pt_regs *regs) +{ + int step; + + if (unlikely(current->audit_context)) + audit_syscall_exit(AUDITSC_RESULT(regs->regs[0]), + regs->regs[0]); + + step = test_thread_flag(TIF_SINGLESTEP); + if (step || test_thread_flag(TIF_SYSCALL_TRACE)) + tracehook_report_syscall_exit(regs, step); } diff --git a/arch/sh/kernel/ptrace_64.c b/arch/sh/kernel/ptrace_64.c index d453c47dc522..5922edd416db 100644 --- a/arch/sh/kernel/ptrace_64.c +++ b/arch/sh/kernel/ptrace_64.c @@ -27,6 +27,8 @@ #include <linux/signal.h> #include <linux/syscalls.h> #include <linux/audit.h> +#include <linux/seccomp.h> +#include <linux/tracehook.h> #include <asm/io.h> #include <asm/uaccess.h> #include <asm/pgtable.h> @@ -120,18 +122,23 @@ put_fpu_long(struct task_struct *task, unsigned long addr, unsigned long data) return 0; } +void user_enable_single_step(struct task_struct *child) +{ + struct pt_regs *regs = child->thread.uregs; + + regs->sr |= SR_SSTEP; /* auto-resetting upon exception */ +} + +void user_disable_single_step(struct task_struct *child) +{ + regs->sr &= ~SR_SSTEP; +} long arch_ptrace(struct task_struct *child, long request, long addr, long data) { int ret; switch (request) { - /* when I and D space are separate, these will need to be fixed. */ - case PTRACE_PEEKTEXT: /* read word at location addr. */ - case PTRACE_PEEKDATA: - ret = generic_ptrace_peekdata(child, addr, data); - break; - /* read the word at location addr in the USER area. */ case PTRACE_PEEKUSR: { unsigned long tmp; @@ -154,12 +161,6 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) break; } - /* when I and D space are separate, this will have to be fixed. */ - case PTRACE_POKETEXT: /* write the word at location addr. */ - case PTRACE_POKEDATA: - ret = generic_ptrace_pokedata(child, addr, data); - break; - case PTRACE_POKEUSR: /* write the word at location addr in the USER area. We must disallow any changes to certain SR bits or u_fpvalid, since @@ -191,58 +192,6 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) } break; - case PTRACE_SYSCALL: /* continue and stop at next (return from) syscall */ - case PTRACE_CONT: { /* restart after signal. */ - ret = -EIO; - if (!valid_signal(data)) - break; - if (request == PTRACE_SYSCALL) - set_tsk_thread_flag(child, TIF_SYSCALL_TRACE); - else - clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); - child->exit_code = data; - wake_up_process(child); - ret = 0; - break; - } - -/* - * make the child exit. Best I can do is send it a sigkill. - * perhaps it should be put in the status that it wants to - * exit. - */ - case PTRACE_KILL: { - ret = 0; - if (child->exit_state == EXIT_ZOMBIE) /* already dead */ - break; - child->exit_code = SIGKILL; - wake_up_process(child); - break; - } - - case PTRACE_SINGLESTEP: { /* set the trap flag. */ - struct pt_regs *regs; - - ret = -EIO; - if (!valid_signal(data)) - break; - clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); - if ((child->ptrace & PT_DTRACE) == 0) { - /* Spurious delayed TF traps may occur */ - child->ptrace |= PT_DTRACE; - } - - regs = child->thread.uregs; - - regs->sr |= SR_SSTEP; /* auto-resetting upon exception */ - - child->exit_code = data; - /* give it a chance to run. */ - wake_up_process(child); - ret = 0; - break; - } - default: ret = ptrace_request(child, request, addr, data); break; @@ -273,38 +222,51 @@ asmlinkage int sh64_ptrace(long request, long pid, long addr, long data) return sys_ptrace(request, pid, addr, data); } -asmlinkage void syscall_trace(struct pt_regs *regs, int entryexit) +static inline int audit_arch(void) { - struct task_struct *tsk = current; + int arch = EM_SH; - if (unlikely(current->audit_context) && entryexit) - audit_syscall_exit(AUDITSC_RESULT(regs->regs[9]), - regs->regs[9]); +#ifdef CONFIG_64BIT + arch |= __AUDIT_ARCH_64BIT; +#endif +#ifdef CONFIG_CPU_LITTLE_ENDIAN + arch |= __AUDIT_ARCH_LE; +#endif - if (!test_thread_flag(TIF_SYSCALL_TRACE) && - !test_thread_flag(TIF_SINGLESTEP)) - goto out; - if (!(tsk->ptrace & PT_PTRACED)) - goto out; - - ptrace_notify(SIGTRAP | ((current->ptrace & PT_TRACESYSGOOD) && - !test_thread_flag(TIF_SINGLESTEP) ? 0x80 : 0)); - - /* - * this isn't the same as continuing with a signal, but it will do - * for normal use. strace only continues with a signal if the - * stopping signal is not SIGTRAP. -brl - */ - if (tsk->exit_code) { - send_sig(tsk->exit_code, tsk, 1); - tsk->exit_code = 0; - } + return arch; +} -out: - if (unlikely(current->audit_context) && !entryexit) - audit_syscall_entry(AUDIT_ARCH_SH, regs->regs[1], +asmlinkage long long do_syscall_trace_enter(struct pt_regs *regs) +{ + long long ret = 0; + + secure_computing(regs->regs[9]); + + if (test_thread_flag(TIF_SYSCALL_TRACE) && + tracehook_report_syscall_entry(regs)) + /* + * Tracing decided this syscall should not happen. + * We'll return a bogus call number to get an ENOSYS + * error, but leave the original number in regs->regs[0]. + */ + ret = -1LL; + + if (unlikely(current->audit_context)) + audit_syscall_entry(audit_arch(), regs->regs[1], regs->regs[2], regs->regs[3], regs->regs[4], regs->regs[5]); + + return ret ?: regs->regs[9]; +} + +asmlinkage void do_syscall_trace_leave(struct pt_regs *regs) +{ + if (unlikely(current->audit_context)) + audit_syscall_exit(AUDITSC_RESULT(regs->regs[9]), + regs->regs[9]); + + if (test_thread_flag(TIF_SYSCALL_TRACE)) + tracehook_report_syscall_exit(regs, 0); } /* Called with interrupts disabled */ @@ -338,5 +300,5 @@ asmlinkage void do_software_break_point(unsigned long long vec, */ void ptrace_disable(struct task_struct *child) { - /* nothing to do.. */ + user_disable_single_step(child); } diff --git a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c index 6339d0c95715..a35207655e7b 100644 --- a/arch/sh/kernel/setup.c +++ b/arch/sh/kernel/setup.c @@ -25,6 +25,7 @@ #include <linux/smp.h> #include <linux/err.h> #include <linux/debugfs.h> +#include <linux/crash_dump.h> #include <asm/uaccess.h> #include <asm/io.h> #include <asm/page.h> @@ -286,6 +287,25 @@ static void __init setup_memory(void) extern void __init setup_memory(void); #endif +/* + * Note: elfcorehdr_addr is not just limited to vmcore. It is also used by + * is_kdump_kernel() to determine if we are booting after a panic. Hence + * ifdef it under CONFIG_CRASH_DUMP and not CONFIG_PROC_VMCORE. + */ +#ifdef CONFIG_CRASH_DUMP +/* elfcorehdr= specifies the location of elf core header + * stored by the crashed kernel. + */ +static int __init parse_elfcorehdr(char *arg) +{ + if (!arg) + return -EINVAL; + elfcorehdr_addr = memparse(arg, &arg); + return 0; +} +early_param("elfcorehdr", parse_elfcorehdr); +#endif + void __init setup_arch(char **cmdline_p) { enable_mmu(); diff --git a/arch/sh/kernel/signal_32.c b/arch/sh/kernel/signal_32.c index 4bbbde895a53..51689d29ad45 100644 --- a/arch/sh/kernel/signal_32.c +++ b/arch/sh/kernel/signal_32.c @@ -24,6 +24,7 @@ #include <linux/binfmts.h> #include <linux/freezer.h> #include <linux/io.h> +#include <linux/tracehook.h> #include <asm/system.h> #include <asm/ucontext.h> #include <asm/uaccess.h> @@ -507,14 +508,13 @@ handle_signal(unsigned long sig, struct k_sigaction *ka, siginfo_t *info, switch (regs->regs[0]) { case -ERESTART_RESTARTBLOCK: case -ERESTARTNOHAND: + no_system_call_restart: regs->regs[0] = -EINTR; break; case -ERESTARTSYS: - if (!(ka->sa.sa_flags & SA_RESTART)) { - regs->regs[0] = -EINTR; - break; - } + if (!(ka->sa.sa_flags & SA_RESTART)) + goto no_system_call_restart; /* fallthrough */ case -ERESTARTNOINTR: regs->regs[0] = save_r0; @@ -589,12 +589,15 @@ static void do_signal(struct pt_regs *regs, unsigned int save_r0) * clear the TIF_RESTORE_SIGMASK flag */ if (test_thread_flag(TIF_RESTORE_SIGMASK)) clear_thread_flag(TIF_RESTORE_SIGMASK); + + tracehook_signal_handler(signr, &info, &ka, regs, + test_thread_flag(TIF_SINGLESTEP)); } return; } - no_signal: +no_signal: /* Did we come from a system call? */ if (regs->tra >= 0) { /* Restart the system call - no handlers present */ @@ -618,9 +621,14 @@ static void do_signal(struct pt_regs *regs, unsigned int save_r0) } asmlinkage void do_notify_resume(struct pt_regs *regs, unsigned int save_r0, - __u32 thread_info_flags) + unsigned long thread_info_flags) { /* deal with pending signal delivery */ - if (thread_info_flags & (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK)) + if (thread_info_flags & _TIF_SIGPENDING) do_signal(regs, save_r0); + + if (thread_info_flags & _TIF_NOTIFY_RESUME) { + clear_thread_flag(TIF_NOTIFY_RESUME); + tracehook_notify_resume(regs); + } } diff --git a/arch/sh/kernel/signal_64.c b/arch/sh/kernel/signal_64.c index 552eb810cd85..1d62dfef77f1 100644 --- a/arch/sh/kernel/signal_64.c +++ b/arch/sh/kernel/signal_64.c @@ -22,6 +22,7 @@ #include <linux/ptrace.h> #include <linux/unistd.h> #include <linux/stddef.h> +#include <linux/tracehook.h> #include <asm/ucontext.h> #include <asm/uaccess.h> #include <asm/pgtable.h> @@ -42,7 +43,84 @@ #define _BLOCKABLE (~(sigmask(SIGKILL) | sigmask(SIGSTOP))) -asmlinkage int do_signal(struct pt_regs *regs, sigset_t *oldset); +/* + * Note that 'init' is a special process: it doesn't get signals it doesn't + * want to handle. Thus you cannot kill init even with a SIGKILL even by + * mistake. + * + * Note that we go through the signals twice: once to check the signals that + * the kernel can handle, and then we build all the user-level signal handling + * stack-frames in one go after that. + */ +static int do_signal(struct pt_regs *regs, sigset_t *oldset) +{ + siginfo_t info; + int signr; + struct k_sigaction ka; + + /* + * We want the common case to go fast, which + * is why we may in certain cases get here from + * kernel mode. Just return without doing anything + * if so. + */ + if (!user_mode(regs)) + return 1; + + if (try_to_freeze()) + goto no_signal; + + if (test_thread_flag(TIF_RESTORE_SIGMASK)) + oldset = ¤t->saved_sigmask; + else if (!oldset) + oldset = ¤t->blocked; + + signr = get_signal_to_deliver(&info, &ka, regs, 0); + + if (signr > 0) { + /* Whee! Actually deliver the signal. */ + handle_signal(signr, &info, &ka, oldset, regs); + + /* + * If a signal was successfully delivered, the saved sigmask + * is in its frame, and we can clear the TIF_RESTORE_SIGMASK + * flag. + */ + if (test_thread_flag(TIF_RESTORE_SIGMASK)) + clear_thread_flag(TIF_RESTORE_SIGMASK); + + tracehook_signal_handler(signr, &info, &ka, regs, 0); + return 1; + } + +no_signal: + /* Did we come from a system call? */ + if (regs->syscall_nr >= 0) { + /* Restart the system call - no handlers present */ + switch (regs->regs[REG_RET]) { + case -ERESTARTNOHAND: + case -ERESTARTSYS: + case -ERESTARTNOINTR: + /* Decode Syscall # */ + regs->regs[REG_RET] = regs->syscall_nr; + regs->pc -= 4; + break; + + case -ERESTART_RESTARTBLOCK: + regs->regs[REG_RET] = __NR_restart_syscall; + regs->pc -= 4; + break; + } + } + + /* No signal to deliver -- put the saved sigmask back */ + if (test_thread_flag(TIF_RESTORE_SIGMASK)) { + clear_thread_flag(TIF_RESTORE_SIGMASK); + sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); + } + + return 0; +} /* * Atomically swap in the new signal mask, and wait for a signal. @@ -643,14 +721,13 @@ handle_signal(unsigned long sig, siginfo_t *info, struct k_sigaction *ka, switch (regs->regs[REG_RET]) { case -ERESTART_RESTARTBLOCK: case -ERESTARTNOHAND: + no_system_call_restart: regs->regs[REG_RET] = -EINTR; break; case -ERESTARTSYS: - if (!(ka->sa.sa_flags & SA_RESTART)) { - regs->regs[REG_RET] = -EINTR; - break; - } + if (!(ka->sa.sa_flags & SA_RESTART)) + goto no_system_call_restart; /* fallthrough */ case -ERESTARTNOINTR: /* Decode syscall # */ @@ -673,80 +750,13 @@ handle_signal(unsigned long sig, siginfo_t *info, struct k_sigaction *ka, spin_unlock_irq(¤t->sighand->siglock); } -/* - * Note that 'init' is a special process: it doesn't get signals it doesn't - * want to handle. Thus you cannot kill init even with a SIGKILL even by - * mistake. - * - * Note that we go through the signals twice: once to check the signals that - * the kernel can handle, and then we build all the user-level signal handling - * stack-frames in one go after that. - */ -int do_signal(struct pt_regs *regs, sigset_t *oldset) +asmlinkage void do_notify_resume(struct pt_regs *regs, unsigned long thread_info_flags) { - siginfo_t info; - int signr; - struct k_sigaction ka; - - /* - * We want the common case to go fast, which - * is why we may in certain cases get here from - * kernel mode. Just return without doing anything - * if so. - */ - if (!user_mode(regs)) - return 1; - - if (try_to_freeze()) - goto no_signal; - - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - oldset = ¤t->saved_sigmask; - else if (!oldset) - oldset = ¤t->blocked; - - signr = get_signal_to_deliver(&info, &ka, regs, 0); - - if (signr > 0) { - /* Whee! Actually deliver the signal. */ - handle_signal(signr, &info, &ka, oldset, regs); + if (thread_info_flags & _TIF_SIGPENDING) + do_signal(regs, 0); - /* - * If a signal was successfully delivered, the saved sigmask - * is in its frame, and we can clear the TIF_RESTORE_SIGMASK - * flag. - */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - clear_thread_flag(TIF_RESTORE_SIGMASK); - - return 1; + if (thread_info_flags & _TIF_NOTIFY_RESUME) { + clear_thread_flag(TIF_NOTIFY_RESUME); + tracehook_notify_resume(regs); } - -no_signal: - /* Did we come from a system call? */ - if (regs->syscall_nr >= 0) { - /* Restart the system call - no handlers present */ - switch (regs->regs[REG_RET]) { - case -ERESTARTNOHAND: - case -ERESTARTSYS: - case -ERESTARTNOINTR: - /* Decode Syscall # */ - regs->regs[REG_RET] = regs->syscall_nr; - regs->pc -= 4; - break; - - case -ERESTART_RESTARTBLOCK: - regs->regs[REG_RET] = __NR_restart_syscall; - regs->pc -= 4; - break; - } - } - - /* No signal to deliver -- put the saved sigmask back */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) { - clear_thread_flag(TIF_RESTORE_SIGMASK); - sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); - } - - return 0; } diff --git a/arch/sh/mm/Kconfig b/arch/sh/mm/Kconfig index 56d0a7daa34b..9c131cac91a4 100644 --- a/arch/sh/mm/Kconfig +++ b/arch/sh/mm/Kconfig @@ -237,7 +237,6 @@ choice config CACHE_WRITEBACK bool "Write-back" - depends on CPU_SH2A || CPU_SH3 || CPU_SH4 || CPU_SH5 config CACHE_WRITETHROUGH bool "Write-through" diff --git a/arch/sh/mm/Makefile_32 b/arch/sh/mm/Makefile_32 index e295db60b91b..70e0906023cc 100644 --- a/arch/sh/mm/Makefile_32 +++ b/arch/sh/mm/Makefile_32 @@ -5,12 +5,15 @@ obj-y := init.o extable_32.o consistent.o ifndef CONFIG_CACHE_OFF -obj-$(CONFIG_CPU_SH2) += cache-sh2.o -obj-$(CONFIG_CPU_SH3) += cache-sh3.o -obj-$(CONFIG_CPU_SH4) += cache-sh4.o -obj-$(CONFIG_SH7705_CACHE_32KB) += cache-sh7705.o +cache-$(CONFIG_CPU_SH2) := cache-sh2.o +cache-$(CONFIG_CPU_SH2A) := cache-sh2a.o +cache-$(CONFIG_CPU_SH3) := cache-sh3.o +cache-$(CONFIG_CPU_SH4) := cache-sh4.o +cache-$(CONFIG_SH7705_CACHE_32KB) += cache-sh7705.o endif +obj-y += $(cache-y) + mmu-y := tlb-nommu.o pg-nommu.o mmu-$(CONFIG_MMU) := fault_32.o tlbflush_32.o ioremap_32.o diff --git a/arch/sh/mm/cache-sh2.c b/arch/sh/mm/cache-sh2.c index 6614033f6be9..c4e80d2b764b 100644 --- a/arch/sh/mm/cache-sh2.c +++ b/arch/sh/mm/cache-sh2.c @@ -2,6 +2,7 @@ * arch/sh/mm/cache-sh2.c * * Copyright (C) 2002 Paul Mundt + * Copyright (C) 2008 Yoshinori Sato * * Released under the terms of the GNU GPL v2.0. */ @@ -24,8 +25,15 @@ void __flush_wback_region(void *start, int size) end = ((unsigned long)start + size + L1_CACHE_BYTES-1) & ~(L1_CACHE_BYTES-1); for (v = begin; v < end; v+=L1_CACHE_BYTES) { - /* FIXME cache purge */ - ctrl_outl((v & 0x1ffffc00), (v & 0x00000ff0) | 0x00000008); + unsigned long addr = CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0); + int way; + for (way = 0; way < 4; way++) { + unsigned long data = ctrl_inl(addr | (way << 12)); + if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { + data &= ~SH_CACHE_UPDATED; + ctrl_outl(data, addr | (way << 12)); + } + } } } @@ -37,21 +45,40 @@ void __flush_purge_region(void *start, int size) begin = (unsigned long)start & ~(L1_CACHE_BYTES-1); end = ((unsigned long)start + size + L1_CACHE_BYTES-1) & ~(L1_CACHE_BYTES-1); - for (v = begin; v < end; v+=L1_CACHE_BYTES) { - ctrl_outl((v & 0x1ffffc00), (v & 0x00000ff0) | 0x00000008); - } + + for (v = begin; v < end; v+=L1_CACHE_BYTES) + ctrl_outl((v & CACHE_PHYSADDR_MASK), + CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0) | 0x00000008); } void __flush_invalidate_region(void *start, int size) { +#ifdef CONFIG_CACHE_WRITEBACK + /* + * SH-2 does not support individual line invalidation, only a + * global invalidate. + */ + unsigned long ccr; + unsigned long flags; + local_irq_save(flags); + jump_to_uncached(); + + ccr = ctrl_inl(CCR); + ccr |= CCR_CACHE_INVALIDATE; + ctrl_outl(ccr, CCR); + + back_to_cached(); + local_irq_restore(flags); +#else unsigned long v; unsigned long begin, end; begin = (unsigned long)start & ~(L1_CACHE_BYTES-1); end = ((unsigned long)start + size + L1_CACHE_BYTES-1) & ~(L1_CACHE_BYTES-1); - for (v = begin; v < end; v+=L1_CACHE_BYTES) { - ctrl_outl((v & 0x1ffffc00), (v & 0x00000ff0) | 0x00000008); - } -} + for (v = begin; v < end; v+=L1_CACHE_BYTES) + ctrl_outl((v & CACHE_PHYSADDR_MASK), + CACHE_OC_ADDRESS_ARRAY | (v & 0x00000ff0) | 0x00000008); +#endif +} diff --git a/arch/sh/mm/cache-sh2a.c b/arch/sh/mm/cache-sh2a.c new file mode 100644 index 000000000000..62c0c5f35120 --- /dev/null +++ b/arch/sh/mm/cache-sh2a.c @@ -0,0 +1,129 @@ +/* + * arch/sh/mm/cache-sh2a.c + * + * Copyright (C) 2008 Yoshinori Sato + * + * Released under the terms of the GNU GPL v2.0. + */ + +#include <linux/init.h> +#include <linux/mm.h> + +#include <asm/cache.h> +#include <asm/addrspace.h> +#include <asm/processor.h> +#include <asm/cacheflush.h> +#include <asm/io.h> + +void __flush_wback_region(void *start, int size) +{ + unsigned long v; + unsigned long begin, end; + unsigned long flags; + + begin = (unsigned long)start & ~(L1_CACHE_BYTES-1); + end = ((unsigned long)start + size + L1_CACHE_BYTES-1) + & ~(L1_CACHE_BYTES-1); + + local_irq_save(flags); + jump_to_uncached(); + + for (v = begin; v < end; v+=L1_CACHE_BYTES) { + unsigned long addr = CACHE_OC_ADDRESS_ARRAY | (v & 0x000007f0); + int way; + for (way = 0; way < 4; way++) { + unsigned long data = ctrl_inl(addr | (way << 11)); + if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { + data &= ~SH_CACHE_UPDATED; + ctrl_outl(data, addr | (way << 11)); + } + } + } + + back_to_cached(); + local_irq_restore(flags); +} + +void __flush_purge_region(void *start, int size) +{ + unsigned long v; + unsigned long begin, end; + unsigned long flags; + + begin = (unsigned long)start & ~(L1_CACHE_BYTES-1); + end = ((unsigned long)start + size + L1_CACHE_BYTES-1) + & ~(L1_CACHE_BYTES-1); + + local_irq_save(flags); + jump_to_uncached(); + + for (v = begin; v < end; v+=L1_CACHE_BYTES) { + ctrl_outl((v & CACHE_PHYSADDR_MASK), + CACHE_OC_ADDRESS_ARRAY | (v & 0x000003f0) | 0x00000008); + } + back_to_cached(); + local_irq_restore(flags); +} + +void __flush_invalidate_region(void *start, int size) +{ + unsigned long v; + unsigned long begin, end; + unsigned long flags; + + begin = (unsigned long)start & ~(L1_CACHE_BYTES-1); + end = ((unsigned long)start + size + L1_CACHE_BYTES-1) + & ~(L1_CACHE_BYTES-1); + local_irq_save(flags); + jump_to_uncached(); + +#ifdef CONFIG_CACHE_WRITEBACK + ctrl_outl(ctrl_inl(CCR) | CCR_OCACHE_INVALIDATE, CCR); + /* I-cache invalidate */ + for (v = begin; v < end; v+=L1_CACHE_BYTES) { + ctrl_outl((v & CACHE_PHYSADDR_MASK), + CACHE_IC_ADDRESS_ARRAY | (v & 0x000003f0) | 0x00000008); + } +#else + for (v = begin; v < end; v+=L1_CACHE_BYTES) { + ctrl_outl((v & CACHE_PHYSADDR_MASK), + CACHE_IC_ADDRESS_ARRAY | (v & 0x000003f0) | 0x00000008); + ctrl_outl((v & CACHE_PHYSADDR_MASK), + CACHE_OC_ADDRESS_ARRAY | (v & 0x000003f0) | 0x00000008); + } +#endif + back_to_cached(); + local_irq_restore(flags); +} + +/* WBack O-Cache and flush I-Cache */ +void flush_icache_range(unsigned long start, unsigned long end) +{ + unsigned long v; + unsigned long flags; + + start = start & ~(L1_CACHE_BYTES-1); + end = (end + L1_CACHE_BYTES-1) & ~(L1_CACHE_BYTES-1); + + local_irq_save(flags); + jump_to_uncached(); + + for (v = start; v < end; v+=L1_CACHE_BYTES) { + unsigned long addr = (v & 0x000007f0); + int way; + /* O-Cache writeback */ + for (way = 0; way < 4; way++) { + unsigned long data = ctrl_inl(CACHE_OC_ADDRESS_ARRAY | addr | (way << 11)); + if ((data & CACHE_PHYSADDR_MASK) == (v & CACHE_PHYSADDR_MASK)) { + data &= ~SH_CACHE_UPDATED; + ctrl_outl(data, CACHE_OC_ADDRESS_ARRAY | addr | (way << 11)); + } + } + /* I-Cache invalidate */ + ctrl_outl(addr, + CACHE_IC_ADDRESS_ARRAY | addr | 0x00000008); + } + + back_to_cached(); + local_irq_restore(flags); +} diff --git a/arch/sh/mm/tlb-sh5.c b/arch/sh/mm/tlb-sh5.c index f34274a1ded3..dae131243bcc 100644 --- a/arch/sh/mm/tlb-sh5.c +++ b/arch/sh/mm/tlb-sh5.c @@ -15,9 +15,7 @@ #include <asm/mmu_context.h> /** - * sh64_tlb_init - * - * Perform initial setup for the DTLB and ITLB. + * sh64_tlb_init - Perform initial setup for the DTLB and ITLB. */ int __init sh64_tlb_init(void) { @@ -46,9 +44,7 @@ int __init sh64_tlb_init(void) } /** - * sh64_next_free_dtlb_entry - * - * Find the next available DTLB entry + * sh64_next_free_dtlb_entry - Find the next available DTLB entry */ unsigned long long sh64_next_free_dtlb_entry(void) { @@ -56,9 +52,7 @@ unsigned long long sh64_next_free_dtlb_entry(void) } /** - * sh64_get_wired_dtlb_entry - * - * Allocate a wired (locked-in) entry in the DTLB + * sh64_get_wired_dtlb_entry - Allocate a wired (locked-in) entry in the DTLB */ unsigned long long sh64_get_wired_dtlb_entry(void) { @@ -71,12 +65,10 @@ unsigned long long sh64_get_wired_dtlb_entry(void) } /** - * sh64_put_wired_dtlb_entry + * sh64_put_wired_dtlb_entry - Free a wired (locked-in) entry in the DTLB. * * @entry: Address of TLB slot. * - * Free a wired (locked-in) entry in the DTLB. - * * Works like a stack, last one to allocate must be first one to free. */ int sh64_put_wired_dtlb_entry(unsigned long long entry) @@ -115,7 +107,7 @@ int sh64_put_wired_dtlb_entry(unsigned long long entry) } /** - * sh64_setup_tlb_slot + * sh64_setup_tlb_slot - Load up a translation in a wired slot. * * @config_addr: Address of TLB slot. * @eaddr: Virtual address. @@ -154,7 +146,7 @@ inline void sh64_setup_tlb_slot(unsigned long long config_addr, } /** - * sh64_teardown_tlb_slot + * sh64_teardown_tlb_slot - Teardown a translation. * * @config_addr: Address of TLB slot. * diff --git a/arch/sh/tools/Makefile b/arch/sh/tools/Makefile index b5d202be8206..567516b58acc 100644 --- a/arch/sh/tools/Makefile +++ b/arch/sh/tools/Makefile @@ -10,7 +10,7 @@ # Shamelessly cloned from ARM. # -arch/sh/include/asm/machtypes.h: $(src)/gen-mach-types $(src)/mach-types +include/asm-sh/machtypes.h: $(src)/gen-mach-types $(src)/mach-types @echo ' Generating $@' - $(Q)if [ ! -d arch/sh/include/asm ]; then mkdir -p arch/sh/include/asm; fi + $(Q)if [ ! -d include/asm-sh ]; then mkdir -p include/asm-sh; fi $(Q)$(AWK) -f $^ > $@ || { rm -f $@; /bin/false; } diff --git a/block/scsi_ioctl.c b/block/scsi_ioctl.c index c5b9bcfc0a6d..12a5182173f6 100644 --- a/block/scsi_ioctl.c +++ b/block/scsi_ioctl.c @@ -518,7 +518,7 @@ int scsi_cmd_ioctl(struct file *file, struct request_queue *q, hdr.sbp = cgc.sense; if (hdr.sbp) hdr.mx_sb_len = sizeof(struct request_sense); - hdr.timeout = cgc.timeout; + hdr.timeout = jiffies_to_msecs(cgc.timeout); hdr.cmdp = ((struct cdrom_generic_command __user*) arg)->cmd; hdr.cmd_len = sizeof(cgc.cmd); diff --git a/drivers/char/efirtc.c b/drivers/char/efirtc.c index 67fbd7aab5db..34d15d548236 100644 --- a/drivers/char/efirtc.c +++ b/drivers/char/efirtc.c @@ -37,7 +37,6 @@ #include <linux/rtc.h> #include <linux/proc_fs.h> #include <linux/efi.h> -#include <linux/smp_lock.h> #include <linux/uaccess.h> #include <asm/system.h> diff --git a/drivers/char/hvc_console.h b/drivers/char/hvc_console.h index d9ce10915625..9790201718ae 100644 --- a/drivers/char/hvc_console.h +++ b/drivers/char/hvc_console.h @@ -6,7 +6,7 @@ * Ryan S. Arnold <rsa@us.ibm.com> * * hvc_console header information: - * moved here from include/asm-powerpc/hvconsole.h + * moved here from arch/powerpc/include/asm/hvconsole.h * and drivers/char/hvc_console.c * * This program is free software; you can redistribute it and/or modify diff --git a/drivers/char/hvcs.c b/drivers/char/hvcs.c index 786d518e9477..473d9b14439a 100644 --- a/drivers/char/hvcs.c +++ b/drivers/char/hvcs.c @@ -114,7 +114,7 @@ * the hvcs_final_close() function in order to get it out of the spinlock. * Rearranged hvcs_close(). Cleaned up some printks and did some housekeeping * on the changelog. Removed local CLC_LENGTH and used HVCS_CLC_LENGTH from - * include/asm-powerpc/hvcserver.h + * arch/powerepc/include/asm/hvcserver.h * * 1.3.2 -> 1.3.3 Replaced yield() in hvcs_close() with tty_wait_until_sent() to * prevent possible lockup with realtime scheduling as similarily pointed out by diff --git a/drivers/char/vt.c b/drivers/char/vt.c index 82a51f38a546..1bc00c9d860d 100644 --- a/drivers/char/vt.c +++ b/drivers/char/vt.c @@ -916,7 +916,6 @@ int vc_resize(struct vc_data *vc, unsigned int cols, unsigned int lines) ws.ws_col = vc->vc_cols; ws.ws_ypixel = vc->vc_scan_lines; - mutex_lock(&vc->vc_tty->termios_mutex); spin_lock_irq(&vc->vc_tty->ctrl_lock); if ((ws.ws_row != cws->ws_row || ws.ws_col != cws->ws_col)) pgrp = get_pid(vc->vc_tty->pgrp); @@ -926,7 +925,6 @@ int vc_resize(struct vc_data *vc, unsigned int cols, unsigned int lines) put_pid(pgrp); } *cws = ws; - mutex_unlock(&vc->vc_tty->termios_mutex); } if (CON_IS_VISIBLE(vc)) diff --git a/drivers/infiniband/hw/ehca/ehca_reqs.c b/drivers/infiniband/hw/ehca/ehca_reqs.c index dd9bc68f1c7b..898c8b5c38dd 100644 --- a/drivers/infiniband/hw/ehca/ehca_reqs.c +++ b/drivers/infiniband/hw/ehca/ehca_reqs.c @@ -42,7 +42,7 @@ */ -#include <asm-powerpc/system.h> +#include <asm/system.h> #include "ehca_classes.h" #include "ehca_tools.h" #include "ehca_qes.h" diff --git a/drivers/input/keyboard/maple_keyb.c b/drivers/input/keyboard/maple_keyb.c index 7797ef6e5e64..22f17a593be7 100644 --- a/drivers/input/keyboard/maple_keyb.c +++ b/drivers/input/keyboard/maple_keyb.c @@ -2,7 +2,7 @@ * SEGA Dreamcast keyboard driver * Based on drivers/usb/usbkbd.c * Copyright YAEGASHI Takeshi, 2001 - * Porting to 2.6 Copyright Adrian McMenamin, 2007 + * Porting to 2.6 Copyright Adrian McMenamin, 2007, 2008 * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -45,39 +45,51 @@ struct dc_kbd { }; static const unsigned short dc_kbd_keycode[NR_SCANCODES] = { - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_A, KEY_B, KEY_C, KEY_D, - KEY_E, KEY_F, KEY_G, KEY_H, KEY_I, KEY_J, KEY_K, KEY_L, - KEY_M, KEY_N, KEY_O, KEY_P, KEY_Q, KEY_R, KEY_S, KEY_T, - KEY_U, KEY_V, KEY_W, KEY_X, KEY_Y, KEY_Z, KEY_1, KEY_2, - KEY_3, KEY_4, KEY_5, KEY_6, KEY_7, KEY_8, KEY_9, KEY_0, - KEY_ENTER, KEY_ESC, KEY_BACKSPACE, KEY_TAB, KEY_SPACE, KEY_MINUS, KEY_EQUAL, KEY_LEFTBRACE, - KEY_RIGHTBRACE, KEY_BACKSLASH, KEY_BACKSLASH, KEY_SEMICOLON, KEY_APOSTROPHE, KEY_GRAVE, KEY_COMMA, - KEY_DOT, KEY_SLASH, KEY_CAPSLOCK, KEY_F1, KEY_F2, KEY_F3, KEY_F4, KEY_F5, KEY_F6, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_A, KEY_B, + KEY_C, KEY_D, KEY_E, KEY_F, KEY_G, KEY_H, KEY_I, KEY_J, KEY_K, KEY_L, + KEY_M, KEY_N, KEY_O, KEY_P, KEY_Q, KEY_R, KEY_S, KEY_T, KEY_U, KEY_V, + KEY_W, KEY_X, KEY_Y, KEY_Z, KEY_1, KEY_2, KEY_3, KEY_4, KEY_5, KEY_6, + KEY_7, KEY_8, KEY_9, KEY_0, KEY_ENTER, KEY_ESC, KEY_BACKSPACE, + KEY_TAB, KEY_SPACE, KEY_MINUS, KEY_EQUAL, KEY_LEFTBRACE, + KEY_RIGHTBRACE, KEY_BACKSLASH, KEY_BACKSLASH, KEY_SEMICOLON, + KEY_APOSTROPHE, KEY_GRAVE, KEY_COMMA, KEY_DOT, KEY_SLASH, + KEY_CAPSLOCK, KEY_F1, KEY_F2, KEY_F3, KEY_F4, KEY_F5, KEY_F6, KEY_F7, KEY_F8, KEY_F9, KEY_F10, KEY_F11, KEY_F12, KEY_SYSRQ, - KEY_SCROLLLOCK, KEY_PAUSE, KEY_INSERT, KEY_HOME, KEY_PAGEUP, KEY_DELETE, - KEY_END, KEY_PAGEDOWN, KEY_RIGHT, KEY_LEFT, KEY_DOWN, KEY_UP, - KEY_NUMLOCK, KEY_KPSLASH, KEY_KPASTERISK, KEY_KPMINUS, KEY_KPPLUS, KEY_KPENTER, KEY_KP1, KEY_KP2, - KEY_KP3, KEY_KP4, KEY_KP5, KEY_KP6, KEY_KP7, KEY_KP8, KEY_KP9, KEY_KP0, KEY_KPDOT, - KEY_102ND, KEY_COMPOSE, KEY_POWER, KEY_KPEQUAL, KEY_F13, KEY_F14, KEY_F15, - KEY_F16, KEY_F17, KEY_F18, KEY_F19, KEY_F20, - KEY_F21, KEY_F22, KEY_F23, KEY_F24, KEY_OPEN, KEY_HELP, KEY_PROPS, KEY_FRONT, - KEY_STOP, KEY_AGAIN, KEY_UNDO, KEY_CUT, KEY_COPY, KEY_PASTE, KEY_FIND, KEY_MUTE, - KEY_VOLUMEUP, KEY_VOLUMEDOWN, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_KPCOMMA, KEY_RESERVED, KEY_RO, KEY_KATAKANAHIRAGANA , KEY_YEN, - KEY_HENKAN, KEY_MUHENKAN, KEY_KPJPCOMMA, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_HANGEUL, KEY_HANJA, KEY_KATAKANA, KEY_HIRAGANA, KEY_ZENKAKUHANKAKU, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, - KEY_LEFTCTRL, KEY_LEFTSHIFT, KEY_LEFTALT, KEY_LEFTMETA, KEY_RIGHTCTRL, KEY_RIGHTSHIFT, KEY_RIGHTALT, KEY_RIGHTMETA, - KEY_PLAYPAUSE, KEY_STOPCD, KEY_PREVIOUSSONG, KEY_NEXTSONG, KEY_EJECTCD, KEY_VOLUMEUP, KEY_VOLUMEDOWN, KEY_MUTE, - KEY_WWW, KEY_BACK, KEY_FORWARD, KEY_STOP, KEY_FIND, KEY_SCROLLUP, KEY_SCROLLDOWN, KEY_EDIT, KEY_SLEEP, - KEY_SCREENLOCK, KEY_REFRESH, KEY_CALC, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED + KEY_SCROLLLOCK, KEY_PAUSE, KEY_INSERT, KEY_HOME, KEY_PAGEUP, + KEY_DELETE, KEY_END, KEY_PAGEDOWN, KEY_RIGHT, KEY_LEFT, KEY_DOWN, + KEY_UP, KEY_NUMLOCK, KEY_KPSLASH, KEY_KPASTERISK, KEY_KPMINUS, + KEY_KPPLUS, KEY_KPENTER, KEY_KP1, KEY_KP2, KEY_KP3, KEY_KP4, KEY_KP5, + KEY_KP6, KEY_KP7, KEY_KP8, KEY_KP9, KEY_KP0, KEY_KPDOT, KEY_102ND, + KEY_COMPOSE, KEY_POWER, KEY_KPEQUAL, KEY_F13, KEY_F14, KEY_F15, + KEY_F16, KEY_F17, KEY_F18, KEY_F19, KEY_F20, KEY_F21, KEY_F22, + KEY_F23, KEY_F24, KEY_OPEN, KEY_HELP, KEY_PROPS, KEY_FRONT, KEY_STOP, + KEY_AGAIN, KEY_UNDO, KEY_CUT, KEY_COPY, KEY_PASTE, KEY_FIND, KEY_MUTE, + KEY_VOLUMEUP, KEY_VOLUMEDOWN, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_KPCOMMA, KEY_RESERVED, KEY_RO, KEY_KATAKANAHIRAGANA , KEY_YEN, + KEY_HENKAN, KEY_MUHENKAN, KEY_KPJPCOMMA, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_HANGEUL, KEY_HANJA, KEY_KATAKANA, KEY_HIRAGANA, + KEY_ZENKAKUHANKAKU, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, + KEY_RESERVED, KEY_RESERVED, KEY_LEFTCTRL, KEY_LEFTSHIFT, KEY_LEFTALT, + KEY_LEFTMETA, KEY_RIGHTCTRL, KEY_RIGHTSHIFT, KEY_RIGHTALT, + KEY_RIGHTMETA, KEY_PLAYPAUSE, KEY_STOPCD, KEY_PREVIOUSSONG, + KEY_NEXTSONG, KEY_EJECTCD, KEY_VOLUMEUP, KEY_VOLUMEDOWN, KEY_MUTE, + KEY_WWW, KEY_BACK, KEY_FORWARD, KEY_STOP, KEY_FIND, KEY_SCROLLUP, + KEY_SCROLLDOWN, KEY_EDIT, KEY_SLEEP, KEY_SCREENLOCK, KEY_REFRESH, + KEY_CALC, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED, KEY_RESERVED }; static void dc_scan_kbd(struct dc_kbd *kbd) @@ -127,12 +139,12 @@ static void dc_scan_kbd(struct dc_kbd *kbd) static void dc_kbd_callback(struct mapleq *mq) { struct maple_device *mapledev = mq->dev; - struct dc_kbd *kbd = mapledev->private_data; + struct dc_kbd *kbd = maple_get_drvdata(mapledev); unsigned long *buf = mq->recvbuf; /* - * We should always be getting the lock because the only - * time it may be locked if driver is in cleanup phase. + * We should always get the lock because the only + * time it may be locked is if the driver is in the cleanup phase. */ if (likely(mutex_trylock(&maple_keyb_mutex))) { @@ -145,106 +157,96 @@ static void dc_kbd_callback(struct mapleq *mq) } } -static int dc_kbd_connect(struct maple_device *mdev) +static int probe_maple_kbd(struct device *dev) { + struct maple_device *mdev = to_maple_dev(dev); + struct maple_driver *mdrv = to_maple_driver(dev->driver); int i, error; struct dc_kbd *kbd; - struct input_dev *dev; + struct input_dev *idev; if (!(mdev->function & MAPLE_FUNC_KEYBOARD)) return -EINVAL; kbd = kzalloc(sizeof(struct dc_kbd), GFP_KERNEL); - dev = input_allocate_device(); - if (!kbd || !dev) { + idev = input_allocate_device(); + if (!kbd || !idev) { error = -ENOMEM; goto fail; } - mdev->private_data = kbd; - - kbd->dev = dev; + kbd->dev = idev; memcpy(kbd->keycode, dc_kbd_keycode, sizeof(kbd->keycode)); - dev->name = mdev->product_name; - dev->evbit[0] = BIT(EV_KEY) | BIT(EV_REP); - dev->keycode = kbd->keycode; - dev->keycodesize = sizeof (unsigned short); - dev->keycodemax = ARRAY_SIZE(kbd->keycode); - dev->id.bustype = BUS_HOST; - dev->dev.parent = &mdev->dev; + idev->name = mdev->product_name; + idev->evbit[0] = BIT(EV_KEY) | BIT(EV_REP); + idev->keycode = kbd->keycode; + idev->keycodesize = sizeof(unsigned short); + idev->keycodemax = ARRAY_SIZE(kbd->keycode); + idev->id.bustype = BUS_HOST; + idev->dev.parent = &mdev->dev; for (i = 0; i < NR_SCANCODES; i++) - __set_bit(dc_kbd_keycode[i], dev->keybit); - __clear_bit(KEY_RESERVED, dev->keybit); + __set_bit(dc_kbd_keycode[i], idev->keybit); + __clear_bit(KEY_RESERVED, idev->keybit); - input_set_capability(dev, EV_MSC, MSC_SCAN); - input_set_drvdata(dev, kbd); + input_set_capability(idev, EV_MSC, MSC_SCAN); + input_set_drvdata(idev, kbd); - error = input_register_device(dev); + error = input_register_device(idev); if (error) goto fail; /* Maple polling is locked to VBLANK - which may be just 50/s */ - maple_getcond_callback(mdev, dc_kbd_callback, HZ/50, MAPLE_FUNC_KEYBOARD); - return 0; + maple_getcond_callback(mdev, dc_kbd_callback, HZ/50, + MAPLE_FUNC_KEYBOARD); - fail: - input_free_device(dev); + mdev->driver = mdrv; + + maple_set_drvdata(mdev, kbd); + + return error; + +fail: + input_free_device(idev); kfree(kbd); - mdev->private_data = NULL; + maple_set_drvdata(mdev, NULL); return error; } -static void dc_kbd_disconnect(struct maple_device *mdev) +static int remove_maple_kbd(struct device *dev) { - struct dc_kbd *kbd; + struct maple_device *mdev = to_maple_dev(dev); + struct dc_kbd *kbd = maple_get_drvdata(mdev); mutex_lock(&maple_keyb_mutex); - kbd = mdev->private_data; - mdev->private_data = NULL; input_unregister_device(kbd->dev); kfree(kbd); - mutex_unlock(&maple_keyb_mutex); -} - -/* allow the keyboard to be used */ -static int probe_maple_kbd(struct device *dev) -{ - struct maple_device *mdev = to_maple_dev(dev); - struct maple_driver *mdrv = to_maple_driver(dev->driver); - int error; - - error = dc_kbd_connect(mdev); - if (error) - return error; - - mdev->driver = mdrv; - mdev->registered = 1; + maple_set_drvdata(mdev, NULL); + mutex_unlock(&maple_keyb_mutex); return 0; } static struct maple_driver dc_kbd_driver = { .function = MAPLE_FUNC_KEYBOARD, - .connect = dc_kbd_connect, - .disconnect = dc_kbd_disconnect, .drv = { .name = "Dreamcast_keyboard", .probe = probe_maple_kbd, - }, + .remove = remove_maple_kbd, + }, }; static int __init dc_kbd_init(void) { - return maple_driver_register(&dc_kbd_driver.drv); + return maple_driver_register(&dc_kbd_driver); } static void __exit dc_kbd_exit(void) { - driver_unregister(&dc_kbd_driver.drv); + maple_driver_unregister(&dc_kbd_driver); } module_init(dc_kbd_init); diff --git a/drivers/isdn/Makefile b/drivers/isdn/Makefile index 8380a4568d11..f1f777570e8e 100644 --- a/drivers/isdn/Makefile +++ b/drivers/isdn/Makefile @@ -5,7 +5,7 @@ obj-$(CONFIG_ISDN_I4L) += i4l/ obj-$(CONFIG_ISDN_CAPI) += capi/ obj-$(CONFIG_MISDN) += mISDN/ -obj-$(CONFIG_ISDN_CAPI) += hardware/ +obj-$(CONFIG_ISDN) += hardware/ obj-$(CONFIG_ISDN_DIVERSION) += divert/ obj-$(CONFIG_ISDN_DRV_HISAX) += hisax/ obj-$(CONFIG_ISDN_DRV_ICN) += icn/ diff --git a/drivers/isdn/hardware/mISDN/hfcmulti.c b/drivers/isdn/hardware/mISDN/hfcmulti.c index 2649ea55a9e8..1eac03f39d00 100644 --- a/drivers/isdn/hardware/mISDN/hfcmulti.c +++ b/drivers/isdn/hardware/mISDN/hfcmulti.c @@ -140,7 +140,7 @@ * #define HFC_REGISTER_DEBUG */ -static const char *hfcmulti_revision = "2.00"; +static const char *hfcmulti_revision = "2.02"; #include <linux/module.h> #include <linux/pci.h> @@ -427,12 +427,12 @@ write_fifo_regio(struct hfc_multi *hc, u_char *data, int len) { outb(A_FIFO_DATA0, (hc->pci_iobase)+4); while (len>>2) { - outl(*(u32 *)data, hc->pci_iobase); + outl(cpu_to_le32(*(u32 *)data), hc->pci_iobase); data += 4; len -= 4; } while (len>>1) { - outw(*(u16 *)data, hc->pci_iobase); + outw(cpu_to_le16(*(u16 *)data), hc->pci_iobase); data += 2; len -= 2; } @@ -447,17 +447,19 @@ void write_fifo_pcimem(struct hfc_multi *hc, u_char *data, int len) { while (len>>2) { - writel(*(u32 *)data, (hc->pci_membase)+A_FIFO_DATA0); + writel(cpu_to_le32(*(u32 *)data), + hc->pci_membase + A_FIFO_DATA0); data += 4; len -= 4; } while (len>>1) { - writew(*(u16 *)data, (hc->pci_membase)+A_FIFO_DATA0); + writew(cpu_to_le16(*(u16 *)data), + hc->pci_membase + A_FIFO_DATA0); data += 2; len -= 2; } while (len) { - writeb(*data, (hc->pci_membase)+A_FIFO_DATA0); + writeb(*data, hc->pci_membase + A_FIFO_DATA0); data++; len--; } @@ -468,12 +470,12 @@ read_fifo_regio(struct hfc_multi *hc, u_char *data, int len) { outb(A_FIFO_DATA0, (hc->pci_iobase)+4); while (len>>2) { - *(u32 *)data = inl(hc->pci_iobase); + *(u32 *)data = le32_to_cpu(inl(hc->pci_iobase)); data += 4; len -= 4; } while (len>>1) { - *(u16 *)data = inw(hc->pci_iobase); + *(u16 *)data = le16_to_cpu(inw(hc->pci_iobase)); data += 2; len -= 2; } @@ -490,18 +492,18 @@ read_fifo_pcimem(struct hfc_multi *hc, u_char *data, int len) { while (len>>2) { *(u32 *)data = - readl((hc->pci_membase)+A_FIFO_DATA0); + le32_to_cpu(readl(hc->pci_membase + A_FIFO_DATA0)); data += 4; len -= 4; } while (len>>1) { *(u16 *)data = - readw((hc->pci_membase)+A_FIFO_DATA0); + le16_to_cpu(readw(hc->pci_membase + A_FIFO_DATA0)); data += 2; len -= 2; } while (len) { - *data = readb((hc->pci_membase)+A_FIFO_DATA0); + *data = readb(hc->pci_membase + A_FIFO_DATA0); data++; len--; } @@ -3971,7 +3973,7 @@ open_bchannel(struct hfc_multi *hc, struct dchannel *dch, struct bchannel *bch; int ch; - if (!test_bit(rq->adr.channel, &dch->dev.channelmap[0])) + if (!test_channelmap(rq->adr.channel, dch->dev.channelmap)) return -EINVAL; if (rq->protocol == ISDN_P_NONE) return -EINVAL; @@ -4587,7 +4589,7 @@ init_e1_port(struct hfc_multi *hc, struct hm_map *m) list_add(&bch->ch.list, &dch->dev.bchannels); hc->chan[ch].bch = bch; hc->chan[ch].port = 0; - test_and_set_bit(bch->nr, &dch->dev.channelmap[0]); + set_channelmap(bch->nr, dch->dev.channelmap); } /* set optical line type */ if (port[Port_cnt] & 0x001) { @@ -4755,7 +4757,7 @@ init_multi_port(struct hfc_multi *hc, int pt) list_add(&bch->ch.list, &dch->dev.bchannels); hc->chan[i + ch].bch = bch; hc->chan[i + ch].port = pt; - test_and_set_bit(bch->nr, &dch->dev.channelmap[0]); + set_channelmap(bch->nr, dch->dev.channelmap); } /* set master clock */ if (port[Port_cnt] & 0x001) { @@ -5050,12 +5052,12 @@ static void __devexit hfc_remove_pci(struct pci_dev *pdev) static const struct hm_map hfcm_map[] = { /*0*/ {VENDOR_BN, "HFC-1S Card (mini PCI)", 4, 1, 1, 3, 0, DIP_4S, 0}, -/*1*/ {VENDOR_BN, "HFC-2S Card", 4, 2, 1, 3, 0, DIP_4S}, +/*1*/ {VENDOR_BN, "HFC-2S Card", 4, 2, 1, 3, 0, DIP_4S, 0}, /*2*/ {VENDOR_BN, "HFC-2S Card (mini PCI)", 4, 2, 1, 3, 0, DIP_4S, 0}, /*3*/ {VENDOR_BN, "HFC-4S Card", 4, 4, 1, 2, 0, DIP_4S, 0}, /*4*/ {VENDOR_BN, "HFC-4S Card (mini PCI)", 4, 4, 1, 2, 0, 0, 0}, /*5*/ {VENDOR_CCD, "HFC-4S Eval (old)", 4, 4, 0, 0, 0, 0, 0}, -/*6*/ {VENDOR_CCD, "HFC-4S IOB4ST", 4, 4, 1, 2, 0, 0, 0}, +/*6*/ {VENDOR_CCD, "HFC-4S IOB4ST", 4, 4, 1, 2, 0, DIP_4S, 0}, /*7*/ {VENDOR_CCD, "HFC-4S", 4, 4, 1, 2, 0, 0, 0}, /*8*/ {VENDOR_DIG, "HFC-4S Card", 4, 4, 0, 2, 0, 0, HFC_IO_MODE_REGIO}, /*9*/ {VENDOR_CCD, "HFC-4S Swyx 4xS0 SX2 QuadBri", 4, 4, 1, 2, 0, 0, 0}, @@ -5251,9 +5253,6 @@ HFCmulti_init(void) if (debug & DEBUG_HFCMULTI_INIT) printk(KERN_DEBUG "%s: init entered\n", __func__); -#ifdef __BIG_ENDIAN -#error "not running on big endian machines now" -#endif hfc_interrupt = symbol_get(ztdummy_extern_interrupt); register_interrupt = symbol_get(ztdummy_register_interrupt); unregister_interrupt = symbol_get(ztdummy_unregister_interrupt); diff --git a/drivers/isdn/hardware/mISDN/hfcpci.c b/drivers/isdn/hardware/mISDN/hfcpci.c index 3231814e7efa..9cf5edbb1a9b 100644 --- a/drivers/isdn/hardware/mISDN/hfcpci.c +++ b/drivers/isdn/hardware/mISDN/hfcpci.c @@ -2056,7 +2056,7 @@ setup_card(struct hfc_pci *card) card->dch.dev.nrbchan = 2; for (i = 0; i < 2; i++) { card->bch[i].nr = i + 1; - test_and_set_bit(i + 1, &card->dch.dev.channelmap[0]); + set_channelmap(i + 1, card->dch.dev.channelmap); card->bch[i].debug = debug; mISDN_initbchannel(&card->bch[i], MAX_DATA_MEM); card->bch[i].hw = card; diff --git a/drivers/isdn/mISDN/l1oip_core.c b/drivers/isdn/mISDN/l1oip_core.c index 155b99780c4f..e42150a57780 100644 --- a/drivers/isdn/mISDN/l1oip_core.c +++ b/drivers/isdn/mISDN/l1oip_core.c @@ -1006,8 +1006,7 @@ open_bchannel(struct l1oip *hc, struct dchannel *dch, struct channel_req *rq) struct bchannel *bch; int ch; - if (!test_bit(rq->adr.channel & 0x1f, - &dch->dev.channelmap[rq->adr.channel >> 5])) + if (!test_channelmap(rq->adr.channel, dch->dev.channelmap)) return -EINVAL; if (rq->protocol == ISDN_P_NONE) return -EINVAL; @@ -1412,8 +1411,7 @@ init_card(struct l1oip *hc, int pri, int bundle) bch->ch.nr = i + ch; list_add(&bch->ch.list, &dch->dev.bchannels); hc->chan[i + ch].bch = bch; - test_and_set_bit(bch->nr & 0x1f, - &dch->dev.channelmap[bch->nr >> 5]); + set_channelmap(bch->nr, dch->dev.channelmap); } ret = mISDN_register_device(&dch->dev, hc->name); if (ret) diff --git a/drivers/isdn/mISDN/socket.c b/drivers/isdn/mISDN/socket.c index 4ba4cc364c9e..e5a20f9542d1 100644 --- a/drivers/isdn/mISDN/socket.c +++ b/drivers/isdn/mISDN/socket.c @@ -379,7 +379,7 @@ data_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg) di.Bprotocols = dev->Bprotocols | get_all_Bprotocols(); di.protocol = dev->D.protocol; memcpy(di.channelmap, dev->channelmap, - MISDN_CHMAP_SIZE * 4); + sizeof(di.channelmap)); di.nrbchan = dev->nrbchan; strcpy(di.name, dev->name); if (copy_to_user((void __user *)arg, &di, sizeof(di))) @@ -637,7 +637,7 @@ base_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg) di.Bprotocols = dev->Bprotocols | get_all_Bprotocols(); di.protocol = dev->D.protocol; memcpy(di.channelmap, dev->channelmap, - MISDN_CHMAP_SIZE * 4); + sizeof(di.channelmap)); di.nrbchan = dev->nrbchan; strcpy(di.name, dev->name); if (copy_to_user((void __user *)arg, &di, sizeof(di))) diff --git a/drivers/net/stnic.c b/drivers/net/stnic.c index b65be5d70fec..2ed0bd596815 100644 --- a/drivers/net/stnic.c +++ b/drivers/net/stnic.c @@ -19,7 +19,7 @@ #include <asm/system.h> #include <asm/io.h> -#include <asm/se.h> +#include <mach-se/mach/se.h> #include <asm/machvec.h> #ifdef CONFIG_SH_STANDARD_BIOS #include <asm/sh_bios.h> diff --git a/drivers/pcmcia/rsrc_nonstatic.c b/drivers/pcmcia/rsrc_nonstatic.c index d0c1d63d1891..203e579ebbd2 100644 --- a/drivers/pcmcia/rsrc_nonstatic.c +++ b/drivers/pcmcia/rsrc_nonstatic.c @@ -275,7 +275,7 @@ static int readable(struct pcmcia_socket *s, struct resource *res, destroy_cis_cache(s); } s->cis_mem.res = NULL; - if ((ret != 0) || (count == 0)) + if ((ret != 0) || (*count == 0)) return 0; return 1; } diff --git a/drivers/scsi/hptiop.c b/drivers/scsi/hptiop.c index da876d3924be..74d12b58a263 100644 --- a/drivers/scsi/hptiop.c +++ b/drivers/scsi/hptiop.c @@ -1249,6 +1249,13 @@ static struct pci_device_id hptiop_id_table[] = { { PCI_VDEVICE(TTI, 0x3522), (kernel_ulong_t)&hptiop_itl_ops }, { PCI_VDEVICE(TTI, 0x3410), (kernel_ulong_t)&hptiop_itl_ops }, { PCI_VDEVICE(TTI, 0x3540), (kernel_ulong_t)&hptiop_itl_ops }, + { PCI_VDEVICE(TTI, 0x3530), (kernel_ulong_t)&hptiop_itl_ops }, + { PCI_VDEVICE(TTI, 0x3560), (kernel_ulong_t)&hptiop_itl_ops }, + { PCI_VDEVICE(TTI, 0x4322), (kernel_ulong_t)&hptiop_itl_ops }, + { PCI_VDEVICE(TTI, 0x4210), (kernel_ulong_t)&hptiop_itl_ops }, + { PCI_VDEVICE(TTI, 0x4211), (kernel_ulong_t)&hptiop_itl_ops }, + { PCI_VDEVICE(TTI, 0x4310), (kernel_ulong_t)&hptiop_itl_ops }, + { PCI_VDEVICE(TTI, 0x4311), (kernel_ulong_t)&hptiop_itl_ops }, { PCI_VDEVICE(TTI, 0x3120), (kernel_ulong_t)&hptiop_mv_ops }, { PCI_VDEVICE(TTI, 0x3122), (kernel_ulong_t)&hptiop_mv_ops }, { PCI_VDEVICE(TTI, 0x3020), (kernel_ulong_t)&hptiop_mv_ops }, diff --git a/drivers/scsi/scsi_transport_spi.c b/drivers/scsi/scsi_transport_spi.c index 75a64a6cae8c..b29360ed0bdc 100644 --- a/drivers/scsi/scsi_transport_spi.c +++ b/drivers/scsi/scsi_transport_spi.c @@ -366,12 +366,14 @@ spi_transport_rd_attr(rti, "%d\n"); spi_transport_rd_attr(pcomp_en, "%d\n"); spi_transport_rd_attr(hold_mcs, "%d\n"); -/* we only care about the first child device so we return 1 */ +/* we only care about the first child device that's a real SCSI device + * so we return 1 to terminate the iteration when we find it */ static int child_iter(struct device *dev, void *data) { - struct scsi_device *sdev = to_scsi_device(dev); + if (!scsi_is_sdev_device(dev)) + return 0; - spi_dv_device(sdev); + spi_dv_device(to_scsi_device(dev)); return 1; } diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index e5e7d7856454..8e08d51a0f05 100644 --- a/drivers/scsi/sd.c +++ b/drivers/scsi/sd.c @@ -375,7 +375,6 @@ static int sd_prep_fn(struct request_queue *q, struct request *rq) struct gendisk *disk = rq->rq_disk; struct scsi_disk *sdkp; sector_t block = rq->sector; - sector_t threshold; unsigned int this_count = rq->nr_sectors; unsigned int timeout = sdp->timeout; int ret; @@ -423,21 +422,13 @@ static int sd_prep_fn(struct request_queue *q, struct request *rq) } /* - * Some SD card readers can't handle multi-sector accesses which touch - * the last one or two hardware sectors. Split accesses as needed. + * Some devices (some sdcards for one) don't like it if the + * last sector gets read in a larger then 1 sector read. */ - threshold = get_capacity(disk) - SD_LAST_BUGGY_SECTORS * - (sdp->sector_size / 512); - - if (unlikely(sdp->last_sector_bug && block + this_count > threshold)) { - if (block < threshold) { - /* Access up to the threshold but not beyond */ - this_count = threshold - block; - } else { - /* Access only a single hardware sector */ - this_count = sdp->sector_size / 512; - } - } + if (unlikely(sdp->last_sector_bug && + rq->nr_sectors > sdp->sector_size / 512 && + block + this_count == get_capacity(disk))) + this_count -= sdp->sector_size / 512; SCSI_LOG_HLQUEUE(2, scmd_printk(KERN_INFO, SCpnt, "block=%llu\n", (unsigned long long)block)); diff --git a/drivers/scsi/sd.h b/drivers/scsi/sd.h index 95b9f06534d5..550b2f70a1f8 100644 --- a/drivers/scsi/sd.h +++ b/drivers/scsi/sd.h @@ -31,12 +31,6 @@ */ #define SD_BUF_SIZE 512 -/* - * Number of sectors at the end of the device to avoid multi-sector - * accesses to in the case of last_sector_bug - */ -#define SD_LAST_BUGGY_SECTORS 8 - struct scsi_disk { struct scsi_driver *driver; /* always &sd_template */ struct scsi_device *device; diff --git a/drivers/scsi/ses.c b/drivers/scsi/ses.c index 0fe031f003e7..1bcf3c33d7ff 100644 --- a/drivers/scsi/ses.c +++ b/drivers/scsi/ses.c @@ -345,14 +345,14 @@ static int ses_enclosure_find_by_addr(struct enclosure_device *edev, return 0; } -#define VPD_INQUIRY_SIZE 512 +#define VPD_INQUIRY_SIZE 36 static void ses_match_to_enclosure(struct enclosure_device *edev, struct scsi_device *sdev) { unsigned char *buf = kmalloc(VPD_INQUIRY_SIZE, GFP_KERNEL); unsigned char *desc; - int len; + u16 vpd_len; struct efd efd = { .addr = 0, }; @@ -372,9 +372,19 @@ static void ses_match_to_enclosure(struct enclosure_device *edev, VPD_INQUIRY_SIZE, NULL, SES_TIMEOUT, SES_RETRIES)) goto free; - len = (buf[2] << 8) + buf[3]; + vpd_len = (buf[2] << 8) + buf[3]; + kfree(buf); + buf = kmalloc(vpd_len, GFP_KERNEL); + if (!buf) + return; + cmd[3] = vpd_len >> 8; + cmd[4] = vpd_len & 0xff; + if (scsi_execute_req(sdev, cmd, DMA_FROM_DEVICE, buf, + vpd_len, NULL, SES_TIMEOUT, SES_RETRIES)) + goto free; + desc = buf + 4; - while (desc < buf + len) { + while (desc < buf + vpd_len) { enum scsi_protocol proto = desc[0] >> 4; u8 code_set = desc[0] & 0x0f; u8 piv = desc[1] & 0x80; diff --git a/drivers/serial/bfin_5xx.c b/drivers/serial/bfin_5xx.c index 9d8543762a30..efcd44344fb1 100644 --- a/drivers/serial/bfin_5xx.c +++ b/drivers/serial/bfin_5xx.c @@ -817,7 +817,7 @@ static void bfin_serial_set_ldisc(struct uart_port *port) if (line >= port->info->port.tty->driver->num) return; - switch (port->info->port.tty->ldisc.num) { + switch (port->info->port.tty->termios->c_line) { case N_IRDA: val = UART_GET_GCTL(&bfin_serial_ports[line]); val |= (IREN | RPOLC); diff --git a/drivers/serial/crisv10.c b/drivers/serial/crisv10.c index 8249ac490559..bf94a770bb44 100644 --- a/drivers/serial/crisv10.c +++ b/drivers/serial/crisv10.c @@ -234,7 +234,7 @@ unsigned long r_alt_ser_baudrate_shadow = 0; static struct e100_serial rs_table[] = { { .baud = DEF_BAUD, - .port = (unsigned char *)R_SERIAL0_CTRL, + .ioport = (unsigned char *)R_SERIAL0_CTRL, .irq = 1U << 12, /* uses DMA 6 and 7 */ .oclrintradr = R_DMA_CH6_CLR_INTR, .ofirstadr = R_DMA_CH6_FIRST, @@ -288,7 +288,7 @@ static struct e100_serial rs_table[] = { }, /* ttyS0 */ #ifndef CONFIG_SVINTO_SIM { .baud = DEF_BAUD, - .port = (unsigned char *)R_SERIAL1_CTRL, + .ioport = (unsigned char *)R_SERIAL1_CTRL, .irq = 1U << 16, /* uses DMA 8 and 9 */ .oclrintradr = R_DMA_CH8_CLR_INTR, .ofirstadr = R_DMA_CH8_FIRST, @@ -344,7 +344,7 @@ static struct e100_serial rs_table[] = { }, /* ttyS1 */ { .baud = DEF_BAUD, - .port = (unsigned char *)R_SERIAL2_CTRL, + .ioport = (unsigned char *)R_SERIAL2_CTRL, .irq = 1U << 4, /* uses DMA 2 and 3 */ .oclrintradr = R_DMA_CH2_CLR_INTR, .ofirstadr = R_DMA_CH2_FIRST, @@ -398,7 +398,7 @@ static struct e100_serial rs_table[] = { }, /* ttyS2 */ { .baud = DEF_BAUD, - .port = (unsigned char *)R_SERIAL3_CTRL, + .ioport = (unsigned char *)R_SERIAL3_CTRL, .irq = 1U << 8, /* uses DMA 4 and 5 */ .oclrintradr = R_DMA_CH4_CLR_INTR, .ofirstadr = R_DMA_CH4_FIRST, @@ -939,7 +939,7 @@ static const struct control_pins e100_modem_pins[NR_PORTS] = /* Output */ #define E100_RTS_GET(info) ((info)->rx_ctrl & E100_RTS_MASK) /* Input */ -#define E100_CTS_GET(info) ((info)->port[REG_STATUS] & E100_CTS_MASK) +#define E100_CTS_GET(info) ((info)->ioport[REG_STATUS] & E100_CTS_MASK) /* These are typically PA or PB and 0 means 0V, 1 means 3.3V */ /* Is an output */ @@ -1092,7 +1092,7 @@ e100_rts(struct e100_serial *info, int set) local_irq_save(flags); info->rx_ctrl &= ~E100_RTS_MASK; info->rx_ctrl |= (set ? 0 : E100_RTS_MASK); /* RTS is active low */ - info->port[REG_REC_CTRL] = info->rx_ctrl; + info->ioport[REG_REC_CTRL] = info->rx_ctrl; local_irq_restore(flags); #ifdef SERIAL_DEBUG_IO printk("ser%i rts %i\n", info->line, set); @@ -1142,7 +1142,7 @@ e100_disable_rx(struct e100_serial *info) { #ifndef CONFIG_SVINTO_SIM /* disable the receiver */ - info->port[REG_REC_CTRL] = + info->ioport[REG_REC_CTRL] = (info->rx_ctrl &= ~IO_MASK(R_SERIAL0_REC_CTRL, rec_enable)); #endif } @@ -1152,7 +1152,7 @@ e100_enable_rx(struct e100_serial *info) { #ifndef CONFIG_SVINTO_SIM /* enable the receiver */ - info->port[REG_REC_CTRL] = + info->ioport[REG_REC_CTRL] = (info->rx_ctrl |= IO_MASK(R_SERIAL0_REC_CTRL, rec_enable)); #endif } @@ -1490,7 +1490,7 @@ rs_stop(struct tty_struct *tty) xoff |= IO_STATE(R_SERIAL0_XOFF, auto_xoff, enable); } - *((unsigned long *)&info->port[REG_XOFF]) = xoff; + *((unsigned long *)&info->ioport[REG_XOFF]) = xoff; local_irq_restore(flags); } } @@ -1513,7 +1513,7 @@ rs_start(struct tty_struct *tty) xoff |= IO_STATE(R_SERIAL0_XOFF, auto_xoff, enable); } - *((unsigned long *)&info->port[REG_XOFF]) = xoff; + *((unsigned long *)&info->ioport[REG_XOFF]) = xoff; if (!info->uses_dma_out && info->xmit.head != info->xmit.tail && info->xmit.buf) e100_enable_serial_tx_ready_irq(info); @@ -1888,7 +1888,7 @@ static void receive_chars_dma(struct e100_serial *info) handle_all_descr_data(info); /* Read the status register to detect errors */ - rstat = info->port[REG_STATUS]; + rstat = info->ioport[REG_STATUS]; if (rstat & IO_MASK(R_SERIAL0_STATUS, xoff_detect) ) { DFLOW(DEBUG_LOG(info->line, "XOFF detect stat %x\n", rstat)); } @@ -1897,7 +1897,7 @@ static void receive_chars_dma(struct e100_serial *info) /* If we got an error, we must reset it by reading the * data_in field */ - unsigned char data = info->port[REG_DATA]; + unsigned char data = info->ioport[REG_DATA]; PROCSTAT(ser_stat[info->line].errors_cnt++); DEBUG_LOG(info->line, "#dERR: s d 0x%04X\n", @@ -2077,7 +2077,7 @@ static int force_eop_if_needed(struct e100_serial *info) /* We check data_avail bit to determine if data has * arrived since last time */ - unsigned char rstat = info->port[REG_STATUS]; + unsigned char rstat = info->ioport[REG_STATUS]; /* error or datavail? */ if (rstat & SER_ERROR_MASK) { @@ -2096,7 +2096,7 @@ static int force_eop_if_needed(struct e100_serial *info) TIMERD(DEBUG_LOG(info->line, "timeout: rstat 0x%03X\n", rstat | (info->line << 8))); /* Read data to clear status flags */ - (void)info->port[REG_DATA]; + (void)info->ioport[REG_DATA]; info->forced_eop = 0; START_FLUSH_FAST_TIMER(info, "magic"); @@ -2296,7 +2296,7 @@ struct e100_serial * handle_ser_rx_interrupt_no_dma(struct e100_serial *info) } /* Read data and status at the same time */ - data_read = *((unsigned long *)&info->port[REG_DATA_STATUS32]); + data_read = *((unsigned long *)&info->ioport[REG_DATA_STATUS32]); more_data: if (data_read & IO_MASK(R_SERIAL0_READ, xoff_detect) ) { DFLOW(DEBUG_LOG(info->line, "XOFF detect\n", 0)); @@ -2391,7 +2391,7 @@ more_data: info->icount.rx++; - data_read = *((unsigned long *)&info->port[REG_DATA_STATUS32]); + data_read = *((unsigned long *)&info->ioport[REG_DATA_STATUS32]); if (data_read & IO_MASK(R_SERIAL0_READ, data_avail)) { DEBUG_LOG(info->line, "ser_rx %c in loop\n", IO_EXTRACT(R_SERIAL0_READ, data_in, data_read)); goto more_data; @@ -2413,7 +2413,7 @@ static struct e100_serial* handle_ser_rx_interrupt(struct e100_serial *info) return handle_ser_rx_interrupt_no_dma(info); } /* DMA is used */ - rstat = info->port[REG_STATUS]; + rstat = info->ioport[REG_STATUS]; if (rstat & IO_MASK(R_SERIAL0_STATUS, xoff_detect) ) { DFLOW(DEBUG_LOG(info->line, "XOFF detect\n", 0)); } @@ -2426,7 +2426,7 @@ static struct e100_serial* handle_ser_rx_interrupt(struct e100_serial *info) /* If we got an error, we must reset it by reading the * data_in field */ - data = info->port[REG_DATA]; + data = info->ioport[REG_DATA]; DINTR1(DEBUG_LOG(info->line, "ser_rx! %c\n", data)); DINTR1(DEBUG_LOG(info->line, "ser_rx err stat %02X\n", rstat)); if (!data && (rstat & SER_FRAMING_ERR_MASK)) { @@ -2528,10 +2528,10 @@ static void handle_ser_tx_interrupt(struct e100_serial *info) unsigned char rstat; DFLOW(DEBUG_LOG(info->line, "tx_int: xchar 0x%02X\n", info->x_char)); local_irq_save(flags); - rstat = info->port[REG_STATUS]; + rstat = info->ioport[REG_STATUS]; DFLOW(DEBUG_LOG(info->line, "stat %x\n", rstat)); - info->port[REG_TR_DATA] = info->x_char; + info->ioport[REG_TR_DATA] = info->x_char; info->icount.tx++; info->x_char = 0; /* We must enable since it is disabled in ser_interrupt */ @@ -2545,7 +2545,7 @@ static void handle_ser_tx_interrupt(struct e100_serial *info) /* We only use normal tx interrupt when sending x_char */ DFLOW(DEBUG_LOG(info->line, "tx_int: xchar sent\n", 0)); local_irq_save(flags); - rstat = info->port[REG_STATUS]; + rstat = info->ioport[REG_STATUS]; DFLOW(DEBUG_LOG(info->line, "stat %x\n", rstat)); e100_disable_serial_tx_ready_irq(info); if (info->port.tty->stopped) @@ -2573,7 +2573,7 @@ static void handle_ser_tx_interrupt(struct e100_serial *info) DINTR2(DEBUG_LOG(info->line, "tx_int %c\n", info->xmit.buf[info->xmit.tail])); /* Send a byte, rs485 timing is critical so turn of ints */ local_irq_save(flags); - info->port[REG_TR_DATA] = info->xmit.buf[info->xmit.tail]; + info->ioport[REG_TR_DATA] = info->xmit.buf[info->xmit.tail]; info->xmit.tail = (info->xmit.tail + 1) & (SERIAL_XMIT_SIZE-1); info->icount.tx++; if (info->xmit.head == info->xmit.tail) { @@ -2848,7 +2848,7 @@ startup(struct e100_serial * info) /* dummy read to reset any serial errors */ - (void)info->port[REG_DATA]; + (void)info->ioport[REG_DATA]; /* enable the interrupts */ if (info->uses_dma_out) @@ -2897,7 +2897,7 @@ shutdown(struct e100_serial * info) /* shut down the transmitter and receiver */ DFLOW(DEBUG_LOG(info->line, "shutdown %i\n", info->line)); e100_disable_rx(info); - info->port[REG_TR_CTRL] = (info->tx_ctrl &= ~0x40); + info->ioport[REG_TR_CTRL] = (info->tx_ctrl &= ~0x40); /* disable interrupts, reset dma channels */ if (info->uses_dma_in) { @@ -2968,7 +2968,7 @@ change_speed(struct e100_serial *info) if (!info->port.tty || !info->port.tty->termios) return; - if (!info->port) + if (!info->ioport) return; cflag = info->port.tty->termios->c_cflag; @@ -3037,7 +3037,7 @@ change_speed(struct e100_serial *info) info->baud = cflag_to_baud(cflag); #ifndef CONFIG_SVINTO_SIM - info->port[REG_BAUD] = cflag_to_etrax_baud(cflag); + info->ioport[REG_BAUD] = cflag_to_etrax_baud(cflag); #endif /* CONFIG_SVINTO_SIM */ } @@ -3097,8 +3097,8 @@ change_speed(struct e100_serial *info) /* actually write the control regs to the hardware */ - info->port[REG_TR_CTRL] = info->tx_ctrl; - info->port[REG_REC_CTRL] = info->rx_ctrl; + info->ioport[REG_TR_CTRL] = info->tx_ctrl; + info->ioport[REG_REC_CTRL] = info->rx_ctrl; xoff = IO_FIELD(R_SERIAL0_XOFF, xoff_char, STOP_CHAR(info->port.tty)); xoff |= IO_STATE(R_SERIAL0_XOFF, tx_stop, enable); if (info->port.tty->termios->c_iflag & IXON ) { @@ -3107,7 +3107,7 @@ change_speed(struct e100_serial *info) xoff |= IO_STATE(R_SERIAL0_XOFF, auto_xoff, enable); } - *((unsigned long *)&info->port[REG_XOFF]) = xoff; + *((unsigned long *)&info->ioport[REG_XOFF]) = xoff; local_irq_restore(flags); #endif /* !CONFIG_SVINTO_SIM */ @@ -3156,7 +3156,7 @@ static int rs_raw_write(struct tty_struct *tty, #ifdef SERIAL_DEBUG_DATA if (info->line == SERIAL_DEBUG_LINE) printk("rs_raw_write (%d), status %d\n", - count, info->port[REG_STATUS]); + count, info->ioport[REG_STATUS]); #endif #ifdef CONFIG_SVINTO_SIM @@ -3427,7 +3427,7 @@ get_serial_info(struct e100_serial * info, memset(&tmp, 0, sizeof(tmp)); tmp.type = info->type; tmp.line = info->line; - tmp.port = (int)info->port; + tmp.port = (int)info->ioport; tmp.irq = info->irq; tmp.flags = info->flags; tmp.baud_base = info->baud_base; @@ -3557,14 +3557,14 @@ char *get_control_state_str(int MLines, char *s) } #endif -static void +static int rs_break(struct tty_struct *tty, int break_state) { struct e100_serial *info = (struct e100_serial *)tty->driver_data; unsigned long flags; - if (!info->port) - return; + if (!info->ioport) + return -EIO; local_irq_save(flags); if (break_state == -1) { @@ -3575,8 +3575,9 @@ rs_break(struct tty_struct *tty, int break_state) /* Set bit 7 (txd) and 6 (tr_enable) */ info->tx_ctrl |= (0x80 | 0x40); } - info->port[REG_TR_CTRL] = info->tx_ctrl; + info->ioport[REG_TR_CTRL] = info->tx_ctrl; local_irq_restore(flags); + return 0; } static int @@ -4231,9 +4232,9 @@ static int line_info(char *buf, struct e100_serial *info) unsigned long tmp; ret = sprintf(buf, "%d: uart:E100 port:%lX irq:%d", - info->line, (unsigned long)info->port, info->irq); + info->line, (unsigned long)info->ioport, info->irq); - if (!info->port || (info->type == PORT_UNKNOWN)) { + if (!info->ioport || (info->type == PORT_UNKNOWN)) { ret += sprintf(buf+ret, "\n"); return ret; } @@ -4281,7 +4282,7 @@ static int line_info(char *buf, struct e100_serial *info) } { - unsigned char rstat = info->port[REG_STATUS]; + unsigned char rstat = info->ioport[REG_STATUS]; if (rstat & IO_MASK(R_SERIAL0_STATUS, xoff_detect) ) ret += sprintf(buf+ret, " xoff_detect:1"); } @@ -4502,7 +4503,7 @@ rs_init(void) if (info->enabled) { printk(KERN_INFO "%s%d at 0x%x is a builtin UART with DMA\n", - serial_driver->name, info->line, (unsigned int)info->port); + serial_driver->name, info->line, (unsigned int)info->ioport); } } #ifdef CONFIG_ETRAX_FAST_TIMER diff --git a/drivers/serial/crisv10.h b/drivers/serial/crisv10.h index ccd0f32b7372..e3c5c8c3c09b 100644 --- a/drivers/serial/crisv10.h +++ b/drivers/serial/crisv10.h @@ -36,8 +36,9 @@ struct etrax_recv_buffer { }; struct e100_serial { + struct tty_port port; int baud; - volatile u8 *port; /* R_SERIALx_CTRL */ + volatile u8 *ioport; /* R_SERIALx_CTRL */ u32 irq; /* bitnr in R_IRQ_MASK2 for dmaX_descr */ /* Output registers */ diff --git a/drivers/sh/maple/maple.c b/drivers/sh/maple/maple.c index be97789fa5fd..d1812d32f47d 100644 --- a/drivers/sh/maple/maple.c +++ b/drivers/sh/maple/maple.c @@ -2,6 +2,7 @@ * Core maple bus functionality * * Copyright (C) 2007, 2008 Adrian McMenamin + * Copyright (C) 2001 - 2008 Paul Mundt * * Based on 2.4 code by: * @@ -31,7 +32,7 @@ #include <mach/dma.h> #include <mach/sysasic.h> -MODULE_AUTHOR("Yaegshi Takeshi, Paul Mundt, M.R. Brown, Adrian McMenamin"); +MODULE_AUTHOR("Yaegashi Takeshi, Paul Mundt, M. R. Brown, Adrian McMenamin"); MODULE_DESCRIPTION("Maple bus driver for Dreamcast"); MODULE_LICENSE("GPL v2"); MODULE_SUPPORTED_DEVICE("{{SEGA, Dreamcast/Maple}}"); @@ -65,19 +66,36 @@ static bool checked[4]; static struct maple_device *baseunits[4]; /** - * maple_driver_register - register a device driver - * automatically makes the driver bus a maple bus - * @drv: the driver to be registered + * maple_driver_register - register a maple driver + * @drv: maple driver to be registered. + * + * Registers the passed in @drv, while updating the bus type. + * Devices with matching function IDs will be automatically probed. */ -int maple_driver_register(struct device_driver *drv) +int maple_driver_register(struct maple_driver *drv) { if (!drv) return -EINVAL; - drv->bus = &maple_bus_type; - return driver_register(drv); + + drv->drv.bus = &maple_bus_type; + + return driver_register(&drv->drv); } EXPORT_SYMBOL_GPL(maple_driver_register); +/** + * maple_driver_unregister - unregister a maple driver. + * @drv: maple driver to unregister. + * + * Cleans up after maple_driver_register(). To be invoked in the exit + * path of any module drivers. + */ +void maple_driver_unregister(struct maple_driver *drv) +{ + driver_unregister(&drv->drv); +} +EXPORT_SYMBOL_GPL(maple_driver_unregister); + /* set hardware registers to enable next round of dma */ static void maplebus_dma_reset(void) { @@ -129,13 +147,13 @@ static void maple_release_device(struct device *dev) kfree(mdev); } -/* +/** * maple_add_packet - add a single instruction to the queue - * @mdev - maple device - * @function - function on device being queried - * @command - maple command to add - * @length - length of command string (in 32 bit words) - * @data - remainder of command string + * @mdev: maple device + * @function: function on device being queried + * @command: maple command to add + * @length: length of command string (in 32 bit words) + * @data: remainder of command string */ int maple_add_packet(struct maple_device *mdev, u32 function, u32 command, size_t length, void *data) @@ -176,14 +194,15 @@ out: } EXPORT_SYMBOL_GPL(maple_add_packet); -/* +/** * maple_add_packet_sleeps - add a single instruction to the queue - * - waits for lock to be free - * @mdev - maple device - * @function - function on device being queried - * @command - maple command to add - * @length - length of command string (in 32 bit words) - * @data - remainder of command string + * @mdev: maple device + * @function: function on device being queried + * @command: maple command to add + * @length: length of command string (in 32 bit words) + * @data: remainder of command string + * + * Same as maple_add_packet(), but waits for the lock to become free. */ int maple_add_packet_sleeps(struct maple_device *mdev, u32 function, u32 command, size_t length, void *data) @@ -724,11 +743,9 @@ static int maple_get_dma_buffer(void) static int match_maple_bus_driver(struct device *devptr, struct device_driver *drvptr) { - struct maple_driver *maple_drv; - struct maple_device *maple_dev; + struct maple_driver *maple_drv = to_maple_driver(drvptr); + struct maple_device *maple_dev = to_maple_dev(devptr); - maple_drv = container_of(drvptr, struct maple_driver, drv); - maple_dev = container_of(devptr, struct maple_device, dev); /* Trap empty port case */ if (maple_dev->devinfo.function == 0xFFFFFFFF) return 0; diff --git a/drivers/spi/atmel_spi.c b/drivers/spi/atmel_spi.c index 0c7165660853..95190c619c10 100644 --- a/drivers/spi/atmel_spi.c +++ b/drivers/spi/atmel_spi.c @@ -184,7 +184,8 @@ static void atmel_spi_next_xfer(struct spi_master *master, { struct atmel_spi *as = spi_master_get_devdata(master); struct spi_transfer *xfer; - u32 len, remaining, total; + u32 len, remaining; + u32 ieval; dma_addr_t tx_dma, rx_dma; if (!as->current_transfer) @@ -197,6 +198,8 @@ static void atmel_spi_next_xfer(struct spi_master *master, xfer = NULL; if (xfer) { + spi_writel(as, PTCR, SPI_BIT(RXTDIS) | SPI_BIT(TXTDIS)); + len = xfer->len; atmel_spi_next_xfer_data(master, xfer, &tx_dma, &rx_dma, &len); remaining = xfer->len - len; @@ -234,6 +237,8 @@ static void atmel_spi_next_xfer(struct spi_master *master, as->next_transfer = xfer; if (xfer) { + u32 total; + total = len; atmel_spi_next_xfer_data(master, xfer, &tx_dma, &rx_dma, &len); as->next_remaining_bytes = total - len; @@ -250,9 +255,11 @@ static void atmel_spi_next_xfer(struct spi_master *master, " next xfer %p: len %u tx %p/%08x rx %p/%08x\n", xfer, xfer->len, xfer->tx_buf, xfer->tx_dma, xfer->rx_buf, xfer->rx_dma); + ieval = SPI_BIT(ENDRX) | SPI_BIT(OVRES); } else { spi_writel(as, RNCR, 0); spi_writel(as, TNCR, 0); + ieval = SPI_BIT(RXBUFF) | SPI_BIT(ENDRX) | SPI_BIT(OVRES); } /* REVISIT: We're waiting for ENDRX before we start the next @@ -265,7 +272,7 @@ static void atmel_spi_next_xfer(struct spi_master *master, * * It should be doable, though. Just not now... */ - spi_writel(as, IER, SPI_BIT(ENDRX) | SPI_BIT(OVRES)); + spi_writel(as, IER, ieval); spi_writel(as, PTCR, SPI_BIT(TXTEN) | SPI_BIT(RXTEN)); } @@ -396,7 +403,7 @@ atmel_spi_interrupt(int irq, void *dev_id) ret = IRQ_HANDLED; - spi_writel(as, IDR, (SPI_BIT(ENDTX) | SPI_BIT(ENDRX) + spi_writel(as, IDR, (SPI_BIT(RXBUFF) | SPI_BIT(ENDRX) | SPI_BIT(OVRES))); /* @@ -418,7 +425,7 @@ atmel_spi_interrupt(int irq, void *dev_id) if (xfer->delay_usecs) udelay(xfer->delay_usecs); - dev_warn(master->dev.parent, "fifo overrun (%u/%u remaining)\n", + dev_warn(master->dev.parent, "overrun (%u/%u remaining)\n", spi_readl(as, TCR), spi_readl(as, RCR)); /* @@ -442,7 +449,7 @@ atmel_spi_interrupt(int irq, void *dev_id) spi_readl(as, SR); atmel_spi_msg_done(master, as, msg, -EIO, 0); - } else if (pending & SPI_BIT(ENDRX)) { + } else if (pending & (SPI_BIT(RXBUFF) | SPI_BIT(ENDRX))) { ret = IRQ_HANDLED; spi_writel(as, IDR, pending); diff --git a/drivers/spi/spi_s3c24xx.c b/drivers/spi/spi_s3c24xx.c index 1c643c9e1f15..21661c7959c8 100644 --- a/drivers/spi/spi_s3c24xx.c +++ b/drivers/spi/spi_s3c24xx.c @@ -236,6 +236,19 @@ static irqreturn_t s3c24xx_spi_irq(int irq, void *dev) return IRQ_HANDLED; } +static void s3c24xx_spi_initialsetup(struct s3c24xx_spi *hw) +{ + /* for the moment, permanently enable the clock */ + + clk_enable(hw->clk); + + /* program defaults into the registers */ + + writeb(0xff, hw->regs + S3C2410_SPPRE); + writeb(SPPIN_DEFAULT, hw->regs + S3C2410_SPPIN); + writeb(SPCON_DEFAULT, hw->regs + S3C2410_SPCON); +} + static int __init s3c24xx_spi_probe(struct platform_device *pdev) { struct s3c2410_spi_info *pdata; @@ -327,15 +340,7 @@ static int __init s3c24xx_spi_probe(struct platform_device *pdev) goto err_no_clk; } - /* for the moment, permanently enable the clock */ - - clk_enable(hw->clk); - - /* program defaults into the registers */ - - writeb(0xff, hw->regs + S3C2410_SPPRE); - writeb(SPPIN_DEFAULT, hw->regs + S3C2410_SPPIN); - writeb(SPCON_DEFAULT, hw->regs + S3C2410_SPCON); + s3c24xx_spi_initialsetup(hw); /* setup any gpio we can */ @@ -415,7 +420,7 @@ static int s3c24xx_spi_resume(struct platform_device *pdev) { struct s3c24xx_spi *hw = platform_get_drvdata(pdev); - clk_enable(hw->clk); + s3c24xx_spi_initialsetup(hw); return 0; } diff --git a/drivers/watchdog/ar7_wdt.c b/drivers/watchdog/ar7_wdt.c index 2eb48c0df32c..ef7b0d67095e 100644 --- a/drivers/watchdog/ar7_wdt.c +++ b/drivers/watchdog/ar7_wdt.c @@ -69,7 +69,8 @@ struct ar7_wdt { u32 prescale; }; -static struct semaphore open_semaphore; +static unsigned long wdt_is_open; +static spinlock_t wdt_lock; static unsigned expect_close; /* XXX currently fixed, allows max margin ~68.72 secs */ @@ -154,8 +155,10 @@ static void ar7_wdt_update_margin(int new_margin) u32 change; change = new_margin * (ar7_vbus_freq() / prescale_value); - if (change < 1) change = 1; - if (change > 0xffff) change = 0xffff; + if (change < 1) + change = 1; + if (change > 0xffff) + change = 0xffff; ar7_wdt_change(change); margin = change * prescale_value / ar7_vbus_freq(); printk(KERN_INFO DRVNAME @@ -179,7 +182,7 @@ static void ar7_wdt_disable_wdt(void) static int ar7_wdt_open(struct inode *inode, struct file *file) { /* only allow one at a time */ - if (down_trylock(&open_semaphore)) + if (test_and_set_bit(0, &wdt_is_open)) return -EBUSY; ar7_wdt_enable_wdt(); expect_close = 0; @@ -195,9 +198,7 @@ static int ar7_wdt_release(struct inode *inode, struct file *file) "will not disable the watchdog timer\n"); else if (!nowayout) ar7_wdt_disable_wdt(); - - up(&open_semaphore); - + clear_bit(0, &wdt_is_open); return 0; } @@ -222,7 +223,9 @@ static ssize_t ar7_wdt_write(struct file *file, const char *data, if (len) { size_t i; + spin_lock(&wdt_lock); ar7_wdt_kick(1); + spin_unlock(&wdt_lock); expect_close = 0; for (i = 0; i < len; ++i) { @@ -237,8 +240,8 @@ static ssize_t ar7_wdt_write(struct file *file, const char *data, return len; } -static int ar7_wdt_ioctl(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg) +static long ar7_wdt_ioctl(struct file *file, + unsigned int cmd, unsigned long arg) { static struct watchdog_info ident = { .identity = LONGNAME, @@ -269,8 +272,10 @@ static int ar7_wdt_ioctl(struct inode *inode, struct file *file, if (new_margin < 1) return -EINVAL; + spin_lock(&wdt_lock); ar7_wdt_update_margin(new_margin); ar7_wdt_kick(1); + spin_unlock(&wdt_lock); case WDIOC_GETTIMEOUT: if (put_user(margin, (int *)arg)) @@ -282,7 +287,7 @@ static int ar7_wdt_ioctl(struct inode *inode, struct file *file, static const struct file_operations ar7_wdt_fops = { .owner = THIS_MODULE, .write = ar7_wdt_write, - .ioctl = ar7_wdt_ioctl, + .unlocked_ioctl = ar7_wdt_ioctl, .open = ar7_wdt_open, .release = ar7_wdt_release, }; @@ -297,6 +302,8 @@ static int __init ar7_wdt_init(void) { int rc; + spin_lock_init(&wdt_lock); + ar7_wdt_get_regs(); if (!request_mem_region(ar7_regs_wdt, sizeof(struct ar7_wdt), @@ -312,8 +319,6 @@ static int __init ar7_wdt_init(void) ar7_wdt_prescale(prescale_value); ar7_wdt_update_margin(margin); - sema_init(&open_semaphore, 1); - rc = register_reboot_notifier(&ar7_wdt_notifier); if (rc) { printk(KERN_ERR DRVNAME diff --git a/drivers/watchdog/it8712f_wdt.c b/drivers/watchdog/it8712f_wdt.c index 445b7e812112..51bfd5721833 100644 --- a/drivers/watchdog/it8712f_wdt.c +++ b/drivers/watchdog/it8712f_wdt.c @@ -30,9 +30,8 @@ #include <linux/fs.h> #include <linux/pci.h> #include <linux/spinlock.h> - -#include <asm/uaccess.h> -#include <asm/io.h> +#include <linux/uaccess.h> +#include <linux/io.h> #define NAME "it8712f_wdt" @@ -50,7 +49,7 @@ static int nowayout = WATCHDOG_NOWAYOUT; module_param(nowayout, int, 0); MODULE_PARM_DESC(nowayout, "Disable watchdog shutdown on close"); -static struct semaphore it8712f_wdt_sem; +static unsigned long wdt_open; static unsigned expect_close; static spinlock_t io_lock; static unsigned char revision; @@ -86,22 +85,19 @@ static unsigned short address; #define WDT_OUT_PWROK 0x10 #define WDT_OUT_KRST 0x40 -static int -superio_inb(int reg) +static int superio_inb(int reg) { outb(reg, REG); return inb(VAL); } -static void -superio_outb(int val, int reg) +static void superio_outb(int val, int reg) { outb(reg, REG); outb(val, VAL); } -static int -superio_inw(int reg) +static int superio_inw(int reg) { int val; outb(reg++, REG); @@ -111,15 +107,13 @@ superio_inw(int reg) return val; } -static inline void -superio_select(int ldn) +static inline void superio_select(int ldn) { outb(LDN, REG); outb(ldn, VAL); } -static inline void -superio_enter(void) +static inline void superio_enter(void) { spin_lock(&io_lock); outb(0x87, REG); @@ -128,22 +122,19 @@ superio_enter(void) outb(0x55, REG); } -static inline void -superio_exit(void) +static inline void superio_exit(void) { outb(0x02, REG); outb(0x02, VAL); spin_unlock(&io_lock); } -static inline void -it8712f_wdt_ping(void) +static inline void it8712f_wdt_ping(void) { inb(address); } -static void -it8712f_wdt_update_margin(void) +static void it8712f_wdt_update_margin(void) { int config = WDT_OUT_KRST | WDT_OUT_PWROK; int units = margin; @@ -165,8 +156,7 @@ it8712f_wdt_update_margin(void) superio_outb(units, WDT_TIMEOUT); } -static int -it8712f_wdt_get_status(void) +static int it8712f_wdt_get_status(void) { if (superio_inb(WDT_CONTROL) & 0x01) return WDIOF_CARDRESET; @@ -174,8 +164,7 @@ it8712f_wdt_get_status(void) return 0; } -static void -it8712f_wdt_enable(void) +static void it8712f_wdt_enable(void) { printk(KERN_DEBUG NAME ": enabling watchdog timer\n"); superio_enter(); @@ -190,8 +179,7 @@ it8712f_wdt_enable(void) it8712f_wdt_ping(); } -static void -it8712f_wdt_disable(void) +static void it8712f_wdt_disable(void) { printk(KERN_DEBUG NAME ": disabling watchdog timer\n"); @@ -207,8 +195,7 @@ it8712f_wdt_disable(void) superio_exit(); } -static int -it8712f_wdt_notify(struct notifier_block *this, +static int it8712f_wdt_notify(struct notifier_block *this, unsigned long code, void *unused) { if (code == SYS_HALT || code == SYS_POWER_OFF) @@ -222,9 +209,8 @@ static struct notifier_block it8712f_wdt_notifier = { .notifier_call = it8712f_wdt_notify, }; -static ssize_t -it8712f_wdt_write(struct file *file, const char __user *data, - size_t len, loff_t *ppos) +static ssize_t it8712f_wdt_write(struct file *file, const char __user *data, + size_t len, loff_t *ppos) { /* check for a magic close character */ if (len) { @@ -245,9 +231,8 @@ it8712f_wdt_write(struct file *file, const char __user *data, return len; } -static int -it8712f_wdt_ioctl(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg) +static long it8712f_wdt_ioctl(struct file *file, unsigned int cmd, + unsigned long arg) { void __user *argp = (void __user *)arg; int __user *p = argp; @@ -302,19 +287,16 @@ it8712f_wdt_ioctl(struct inode *inode, struct file *file, } } -static int -it8712f_wdt_open(struct inode *inode, struct file *file) +static int it8712f_wdt_open(struct inode *inode, struct file *file) { /* only allow one at a time */ - if (down_trylock(&it8712f_wdt_sem)) + if (test_and_set_bit(0, &wdt_open)) return -EBUSY; it8712f_wdt_enable(); - return nonseekable_open(inode, file); } -static int -it8712f_wdt_release(struct inode *inode, struct file *file) +static int it8712f_wdt_release(struct inode *inode, struct file *file) { if (expect_close != 42) { printk(KERN_WARNING NAME @@ -324,7 +306,7 @@ it8712f_wdt_release(struct inode *inode, struct file *file) it8712f_wdt_disable(); } expect_close = 0; - up(&it8712f_wdt_sem); + clear_bit(0, &wdt_open); return 0; } @@ -333,7 +315,7 @@ static const struct file_operations it8712f_wdt_fops = { .owner = THIS_MODULE, .llseek = no_llseek, .write = it8712f_wdt_write, - .ioctl = it8712f_wdt_ioctl, + .unlocked_ioctl = it8712f_wdt_ioctl, .open = it8712f_wdt_open, .release = it8712f_wdt_release, }; @@ -344,8 +326,7 @@ static struct miscdevice it8712f_wdt_miscdev = { .fops = &it8712f_wdt_fops, }; -static int __init -it8712f_wdt_find(unsigned short *address) +static int __init it8712f_wdt_find(unsigned short *address) { int err = -ENODEV; int chip_type; @@ -387,8 +368,7 @@ exit: return err; } -static int __init -it8712f_wdt_init(void) +static int __init it8712f_wdt_init(void) { int err = 0; @@ -404,8 +384,6 @@ it8712f_wdt_init(void) it8712f_wdt_disable(); - sema_init(&it8712f_wdt_sem, 1); - err = register_reboot_notifier(&it8712f_wdt_notifier); if (err) { printk(KERN_ERR NAME ": unable to register reboot notifier\n"); @@ -430,8 +408,7 @@ out: return err; } -static void __exit -it8712f_wdt_exit(void) +static void __exit it8712f_wdt_exit(void) { misc_deregister(&it8712f_wdt_miscdev); unregister_reboot_notifier(&it8712f_wdt_notifier); diff --git a/drivers/watchdog/s3c2410_wdt.c b/drivers/watchdog/s3c2410_wdt.c index 98532c0e0689..97b4a2e8eb09 100644 --- a/drivers/watchdog/s3c2410_wdt.c +++ b/drivers/watchdog/s3c2410_wdt.c @@ -46,9 +46,8 @@ #include <linux/platform_device.h> #include <linux/interrupt.h> #include <linux/clk.h> - -#include <asm/uaccess.h> -#include <asm/io.h> +#include <linux/uaccess.h> +#include <linux/io.h> #include <asm/arch/map.h> @@ -65,8 +64,8 @@ static int nowayout = WATCHDOG_NOWAYOUT; static int tmr_margin = CONFIG_S3C2410_WATCHDOG_DEFAULT_TIME; static int tmr_atboot = CONFIG_S3C2410_WATCHDOG_ATBOOT; -static int soft_noboot = 0; -static int debug = 0; +static int soft_noboot; +static int debug; module_param(tmr_margin, int, 0); module_param(tmr_atboot, int, 0); @@ -74,24 +73,23 @@ module_param(nowayout, int, 0); module_param(soft_noboot, int, 0); module_param(debug, int, 0); -MODULE_PARM_DESC(tmr_margin, "Watchdog tmr_margin in seconds. default=" __MODULE_STRING(CONFIG_S3C2410_WATCHDOG_DEFAULT_TIME) ")"); - -MODULE_PARM_DESC(tmr_atboot, "Watchdog is started at boot time if set to 1, default=" __MODULE_STRING(CONFIG_S3C2410_WATCHDOG_ATBOOT)); - -MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=" __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); - +MODULE_PARM_DESC(tmr_margin, "Watchdog tmr_margin in seconds. default=" + __MODULE_STRING(CONFIG_S3C2410_WATCHDOG_DEFAULT_TIME) ")"); +MODULE_PARM_DESC(tmr_atboot, + "Watchdog is started at boot time if set to 1, default=" + __MODULE_STRING(CONFIG_S3C2410_WATCHDOG_ATBOOT)); +MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=" + __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); MODULE_PARM_DESC(soft_noboot, "Watchdog action, set to 1 to ignore reboots, 0 to reboot (default depends on ONLY_TESTING)"); - MODULE_PARM_DESC(debug, "Watchdog debug, set to >1 for debug, (default 0)"); typedef enum close_state { CLOSE_STATE_NOT, - CLOSE_STATE_ALLOW=0x4021 + CLOSE_STATE_ALLOW = 0x4021 } close_state_t; -static DECLARE_MUTEX(open_lock); - +static unsigned long open_lock; static struct device *wdt_dev; /* platform device attached to */ static struct resource *wdt_mem; static struct resource *wdt_irq; @@ -99,38 +97,58 @@ static struct clk *wdt_clock; static void __iomem *wdt_base; static unsigned int wdt_count; static close_state_t allow_close; +static DEFINE_SPINLOCK(wdt_lock); /* watchdog control routines */ #define DBG(msg...) do { \ if (debug) \ printk(KERN_INFO msg); \ - } while(0) + } while (0) /* functions */ -static int s3c2410wdt_keepalive(void) +static void s3c2410wdt_keepalive(void) { + spin_lock(&wdt_lock); writel(wdt_count, wdt_base + S3C2410_WTCNT); - return 0; + spin_unlock(&wdt_lock); } -static int s3c2410wdt_stop(void) +static void __s3c2410wdt_stop(void) { unsigned long wtcon; + spin_lock(&wdt_lock); wtcon = readl(wdt_base + S3C2410_WTCON); wtcon &= ~(S3C2410_WTCON_ENABLE | S3C2410_WTCON_RSTEN); writel(wtcon, wdt_base + S3C2410_WTCON); + spin_unlock(&wdt_lock); +} - return 0; +static void __s3c2410wdt_stop(void) +{ + unsigned long wtcon; + + wtcon = readl(wdt_base + S3C2410_WTCON); + wtcon &= ~(S3C2410_WTCON_ENABLE | S3C2410_WTCON_RSTEN); + writel(wtcon, wdt_base + S3C2410_WTCON); +} + +static void s3c2410wdt_stop(void) +{ + spin_lock(&wdt_lock); + __s3c2410wdt_stop(); + spin_unlock(&wdt_lock); } -static int s3c2410wdt_start(void) +static void s3c2410wdt_start(void) { unsigned long wtcon; - s3c2410wdt_stop(); + spin_lock(&wdt_lock); + + __s3c2410wdt_stop(); wtcon = readl(wdt_base + S3C2410_WTCON); wtcon |= S3C2410_WTCON_ENABLE | S3C2410_WTCON_DIV128; @@ -149,6 +167,7 @@ static int s3c2410wdt_start(void) writel(wdt_count, wdt_base + S3C2410_WTDAT); writel(wdt_count, wdt_base + S3C2410_WTCNT); writel(wtcon, wdt_base + S3C2410_WTCON); + spin_unlock(&wdt_lock); return 0; } @@ -211,7 +230,7 @@ static int s3c2410wdt_set_heartbeat(int timeout) static int s3c2410wdt_open(struct inode *inode, struct file *file) { - if(down_trylock(&open_lock)) + if (test_and_set_bit(0, &open_lock)) return -EBUSY; if (nowayout) @@ -231,15 +250,14 @@ static int s3c2410wdt_release(struct inode *inode, struct file *file) * Lock it in if it's a module and we set nowayout */ - if (allow_close == CLOSE_STATE_ALLOW) { + if (allow_close == CLOSE_STATE_ALLOW) s3c2410wdt_stop(); - } else { + else { dev_err(wdt_dev, "Unexpected close, not stopping watchdog\n"); s3c2410wdt_keepalive(); } - allow_close = CLOSE_STATE_NOT; - up(&open_lock); + clear_bit(0, &open_lock); return 0; } @@ -249,7 +267,7 @@ static ssize_t s3c2410wdt_write(struct file *file, const char __user *data, /* * Refresh the timer. */ - if(len) { + if (len) { if (!nowayout) { size_t i; @@ -265,7 +283,6 @@ static ssize_t s3c2410wdt_write(struct file *file, const char __user *data, allow_close = CLOSE_STATE_ALLOW; } } - s3c2410wdt_keepalive(); } return len; @@ -273,48 +290,41 @@ static ssize_t s3c2410wdt_write(struct file *file, const char __user *data, #define OPTIONS WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING | WDIOF_MAGICCLOSE -static struct watchdog_info s3c2410_wdt_ident = { +static const struct watchdog_info s3c2410_wdt_ident = { .options = OPTIONS, .firmware_version = 0, .identity = "S3C2410 Watchdog", }; -static int s3c2410wdt_ioctl(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg) +static long s3c2410wdt_ioctl(struct file *file, unsigned int cmd, + unsigned long arg) { void __user *argp = (void __user *)arg; int __user *p = argp; int new_margin; switch (cmd) { - default: - return -ENOTTY; - - case WDIOC_GETSUPPORT: - return copy_to_user(argp, &s3c2410_wdt_ident, - sizeof(s3c2410_wdt_ident)) ? -EFAULT : 0; - - case WDIOC_GETSTATUS: - case WDIOC_GETBOOTSTATUS: - return put_user(0, p); - - case WDIOC_KEEPALIVE: - s3c2410wdt_keepalive(); - return 0; - - case WDIOC_SETTIMEOUT: - if (get_user(new_margin, p)) - return -EFAULT; - - if (s3c2410wdt_set_heartbeat(new_margin)) - return -EINVAL; - - s3c2410wdt_keepalive(); - return put_user(tmr_margin, p); - - case WDIOC_GETTIMEOUT: - return put_user(tmr_margin, p); + default: + return -ENOTTY; + case WDIOC_GETSUPPORT: + return copy_to_user(argp, &s3c2410_wdt_ident, + sizeof(s3c2410_wdt_ident)) ? -EFAULT : 0; + case WDIOC_GETSTATUS: + case WDIOC_GETBOOTSTATUS: + return put_user(0, p); + case WDIOC_KEEPALIVE: + s3c2410wdt_keepalive(); + return 0; + case WDIOC_SETTIMEOUT: + if (get_user(new_margin, p)) + return -EFAULT; + if (s3c2410wdt_set_heartbeat(new_margin)) + return -EINVAL; + s3c2410wdt_keepalive(); + return put_user(tmr_margin, p); + case WDIOC_GETTIMEOUT: + return put_user(tmr_margin, p); } } @@ -324,7 +334,7 @@ static const struct file_operations s3c2410wdt_fops = { .owner = THIS_MODULE, .llseek = no_llseek, .write = s3c2410wdt_write, - .ioctl = s3c2410wdt_ioctl, + .unlocked_ioctl = s3c2410wdt_ioctl, .open = s3c2410wdt_open, .release = s3c2410wdt_release, }; @@ -411,14 +421,15 @@ static int s3c2410wdt_probe(struct platform_device *pdev) * not, try the default value */ if (s3c2410wdt_set_heartbeat(tmr_margin)) { - started = s3c2410wdt_set_heartbeat(CONFIG_S3C2410_WATCHDOG_DEFAULT_TIME); + started = s3c2410wdt_set_heartbeat( + CONFIG_S3C2410_WATCHDOG_DEFAULT_TIME); - if (started == 0) { - dev_info(dev,"tmr_margin value out of range, default %d used\n", + if (started == 0) + dev_info(dev, + "tmr_margin value out of range, default %d used\n", CONFIG_S3C2410_WATCHDOG_DEFAULT_TIME); - } else { + else dev_info(dev, "default timer value is out of range, cannot start\n"); - } } ret = misc_register(&s3c2410wdt_miscdev); @@ -447,7 +458,7 @@ static int s3c2410wdt_probe(struct platform_device *pdev) (wtcon & S3C2410_WTCON_ENABLE) ? "" : "in", (wtcon & S3C2410_WTCON_RSTEN) ? "" : "dis", (wtcon & S3C2410_WTCON_INTEN) ? "" : "en"); - + return 0; err_clk: @@ -487,7 +498,7 @@ static int s3c2410wdt_remove(struct platform_device *dev) static void s3c2410wdt_shutdown(struct platform_device *dev) { - s3c2410wdt_stop(); + s3c2410wdt_stop(); } #ifdef CONFIG_PM @@ -540,7 +551,8 @@ static struct platform_driver s3c2410wdt_driver = { }; -static char banner[] __initdata = KERN_INFO "S3C2410 Watchdog Timer, (c) 2004 Simtec Electronics\n"; +static char banner[] __initdata = + KERN_INFO "S3C2410 Watchdog Timer, (c) 2004 Simtec Electronics\n"; static int __init watchdog_init(void) { diff --git a/drivers/watchdog/sc1200wdt.c b/drivers/watchdog/sc1200wdt.c index 35cddff7020f..621ebad56d86 100644 --- a/drivers/watchdog/sc1200wdt.c +++ b/drivers/watchdog/sc1200wdt.c @@ -15,14 +15,18 @@ * * Changelog: * 20020220 Zwane Mwaikambo Code based on datasheet, no hardware. - * 20020221 Zwane Mwaikambo Cleanups as suggested by Jeff Garzik and Alan Cox. + * 20020221 Zwane Mwaikambo Cleanups as suggested by Jeff Garzik + * and Alan Cox. * 20020222 Zwane Mwaikambo Added probing. * 20020225 Zwane Mwaikambo Added ISAPNP support. * 20020412 Rob Radez Broke out start/stop functions - * <rob@osinvestor.com> Return proper status instead of temperature warning - * Add WDIOC_GETBOOTSTATUS and WDIOC_SETOPTIONS ioctls + * <rob@osinvestor.com> Return proper status instead of + * temperature warning + * Add WDIOC_GETBOOTSTATUS and + * WDIOC_SETOPTIONS ioctls * Fix CONFIG_WATCHDOG_NOWAYOUT - * 20020530 Joel Becker Add Matt Domsch's nowayout module option + * 20020530 Joel Becker Add Matt Domsch's nowayout module + * option * 20030116 Adam Belay Updated to the latest pnp code * */ @@ -39,9 +43,8 @@ #include <linux/pnp.h> #include <linux/fs.h> #include <linux/semaphore.h> - -#include <asm/io.h> -#include <asm/uaccess.h> +#include <linux/io.h> +#include <linux/uaccess.h> #define SC1200_MODULE_VER "build 20020303" #define SC1200_MODULE_NAME "sc1200wdt" @@ -72,7 +75,7 @@ static char banner[] __initdata = KERN_INFO PFX SC1200_MODULE_VER; static int timeout = 1; static int io = -1; static int io_len = 2; /* for non plug and play */ -static struct semaphore open_sem; +static unsigned long open_flag; static char expect_close; static DEFINE_SPINLOCK(sc1200wdt_lock); /* io port access serialisation */ @@ -81,7 +84,8 @@ static int isapnp = 1; static struct pnp_dev *wdt_dev; module_param(isapnp, int, 0); -MODULE_PARM_DESC(isapnp, "When set to 0 driver ISA PnP support will be disabled"); +MODULE_PARM_DESC(isapnp, + "When set to 0 driver ISA PnP support will be disabled"); #endif module_param(io, int, 0); @@ -91,26 +95,40 @@ MODULE_PARM_DESC(timeout, "range is 0-255 minutes, default is 1"); static int nowayout = WATCHDOG_NOWAYOUT; module_param(nowayout, int, 0); -MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=" __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); +MODULE_PARM_DESC(nowayout, + "Watchdog cannot be stopped once started (default=" + __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); /* Read from Data Register */ -static inline void sc1200wdt_read_data(unsigned char index, unsigned char *data) +static inline void __sc1200wdt_read_data(unsigned char index, + unsigned char *data) { - spin_lock(&sc1200wdt_lock); outb_p(index, PMIR); *data = inb(PMDR); - spin_unlock(&sc1200wdt_lock); } +static void sc1200wdt_read_data(unsigned char index, unsigned char *data) +{ + spin_lock(&sc1200wdt_lock); + __sc1200wdt_read_data(index, data); + spin_unlock(&sc1200wdt_lock); +} /* Write to Data Register */ -static inline void sc1200wdt_write_data(unsigned char index, unsigned char data) +static inline void __sc1200wdt_write_data(unsigned char index, + unsigned char data) { - spin_lock(&sc1200wdt_lock); outb_p(index, PMIR); outb(data, PMDR); +} + +static inline void sc1200wdt_write_data(unsigned char index, + unsigned char data) +{ + spin_lock(&sc1200wdt_lock); + __sc1200wdt_write_data(index, data); spin_unlock(&sc1200wdt_lock); } @@ -118,22 +136,23 @@ static inline void sc1200wdt_write_data(unsigned char index, unsigned char data) static void sc1200wdt_start(void) { unsigned char reg; + spin_lock(&sc1200wdt_lock); - sc1200wdt_read_data(WDCF, ®); + __sc1200wdt_read_data(WDCF, ®); /* assert WDO when any of the following interrupts are triggered too */ reg |= (KBC_IRQ | MSE_IRQ | UART1_IRQ | UART2_IRQ); - sc1200wdt_write_data(WDCF, reg); + __sc1200wdt_write_data(WDCF, reg); /* set the timeout and get the ball rolling */ - sc1200wdt_write_data(WDTO, timeout); -} + __sc1200wdt_write_data(WDTO, timeout); + spin_unlock(&sc1200wdt_lock); +} static void sc1200wdt_stop(void) { sc1200wdt_write_data(WDTO, 0); } - /* This returns the status of the WDO signal, inactive high. */ static inline int sc1200wdt_status(void) { @@ -144,14 +163,13 @@ static inline int sc1200wdt_status(void) * KEEPALIVEPING which is a bit of a kludge because there's nothing * else for enabled/disabled status */ - return (ret & 0x01) ? 0 : WDIOF_KEEPALIVEPING; /* bits 1 - 7 are undefined */ + return (ret & 0x01) ? 0 : WDIOF_KEEPALIVEPING; } - static int sc1200wdt_open(struct inode *inode, struct file *file) { /* allow one at a time */ - if (down_trylock(&open_sem)) + if (test_and_set_bit(0, &open_flag)) return -EBUSY; if (timeout > MAX_TIMEOUT) @@ -164,71 +182,71 @@ static int sc1200wdt_open(struct inode *inode, struct file *file) } -static int sc1200wdt_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg) +static long sc1200wdt_ioctl(struct file *file, unsigned int cmd, + unsigned long arg) { int new_timeout; void __user *argp = (void __user *)arg; int __user *p = argp; - static struct watchdog_info ident = { - .options = WDIOF_KEEPALIVEPING | WDIOF_SETTIMEOUT | WDIOF_MAGICCLOSE, + static const struct watchdog_info ident = { + .options = WDIOF_KEEPALIVEPING | WDIOF_SETTIMEOUT | + WDIOF_MAGICCLOSE, .firmware_version = 0, .identity = "PC87307/PC97307", }; switch (cmd) { - default: - return -ENOTTY; - - case WDIOC_GETSUPPORT: - if (copy_to_user(argp, &ident, sizeof ident)) - return -EFAULT; - return 0; - - case WDIOC_GETSTATUS: - return put_user(sc1200wdt_status(), p); - - case WDIOC_GETBOOTSTATUS: - return put_user(0, p); - - case WDIOC_KEEPALIVE: - sc1200wdt_write_data(WDTO, timeout); - return 0; - case WDIOC_SETTIMEOUT: - if (get_user(new_timeout, p)) - return -EFAULT; + case WDIOC_GETSUPPORT: + if (copy_to_user(argp, &ident, sizeof ident)) + return -EFAULT; + return 0; - /* the API states this is given in secs */ - new_timeout /= 60; - if (new_timeout < 0 || new_timeout > MAX_TIMEOUT) - return -EINVAL; + case WDIOC_GETSTATUS: + return put_user(sc1200wdt_status(), p); - timeout = new_timeout; - sc1200wdt_write_data(WDTO, timeout); - /* fall through and return the new timeout */ + case WDIOC_GETBOOTSTATUS: + return put_user(0, p); - case WDIOC_GETTIMEOUT: - return put_user(timeout * 60, p); + case WDIOC_KEEPALIVE: + sc1200wdt_write_data(WDTO, timeout); + return 0; + + case WDIOC_SETTIMEOUT: + if (get_user(new_timeout, p)) + return -EFAULT; + /* the API states this is given in secs */ + new_timeout /= 60; + if (new_timeout < 0 || new_timeout > MAX_TIMEOUT) + return -EINVAL; + timeout = new_timeout; + sc1200wdt_write_data(WDTO, timeout); + /* fall through and return the new timeout */ - case WDIOC_SETOPTIONS: - { - int options, retval = -EINVAL; + case WDIOC_GETTIMEOUT: + return put_user(timeout * 60, p); - if (get_user(options, p)) - return -EFAULT; + case WDIOC_SETOPTIONS: + { + int options, retval = -EINVAL; - if (options & WDIOS_DISABLECARD) { - sc1200wdt_stop(); - retval = 0; - } + if (get_user(options, p)) + return -EFAULT; - if (options & WDIOS_ENABLECARD) { - sc1200wdt_start(); - retval = 0; - } + if (options & WDIOS_DISABLECARD) { + sc1200wdt_stop(); + retval = 0; + } - return retval; + if (options & WDIOS_ENABLECARD) { + sc1200wdt_start(); + retval = 0; } + + return retval; + } + default: + return -ENOTTY; } } @@ -240,16 +258,18 @@ static int sc1200wdt_release(struct inode *inode, struct file *file) printk(KERN_INFO PFX "Watchdog disabled\n"); } else { sc1200wdt_write_data(WDTO, timeout); - printk(KERN_CRIT PFX "Unexpected close!, timeout = %d min(s)\n", timeout); + printk(KERN_CRIT PFX + "Unexpected close!, timeout = %d min(s)\n", timeout); } - up(&open_sem); + clear_bit(0, &open_flag); expect_close = 0; return 0; } -static ssize_t sc1200wdt_write(struct file *file, const char __user *data, size_t len, loff_t *ppos) +static ssize_t sc1200wdt_write(struct file *file, const char __user *data, + size_t len, loff_t *ppos) { if (len) { if (!nowayout) { @@ -275,7 +295,8 @@ static ssize_t sc1200wdt_write(struct file *file, const char __user *data, size_ } -static int sc1200wdt_notify_sys(struct notifier_block *this, unsigned long code, void *unused) +static int sc1200wdt_notify_sys(struct notifier_block *this, + unsigned long code, void *unused) { if (code == SYS_DOWN || code == SYS_HALT) sc1200wdt_stop(); @@ -284,23 +305,20 @@ static int sc1200wdt_notify_sys(struct notifier_block *this, unsigned long code, } -static struct notifier_block sc1200wdt_notifier = -{ +static struct notifier_block sc1200wdt_notifier = { .notifier_call = sc1200wdt_notify_sys, }; -static const struct file_operations sc1200wdt_fops = -{ +static const struct file_operations sc1200wdt_fops = { .owner = THIS_MODULE, .llseek = no_llseek, .write = sc1200wdt_write, - .ioctl = sc1200wdt_ioctl, + .unlocked_ioctl = sc1200wdt_ioctl, .open = sc1200wdt_open, .release = sc1200wdt_release, }; -static struct miscdevice sc1200wdt_miscdev = -{ +static struct miscdevice sc1200wdt_miscdev = { .minor = WATCHDOG_MINOR, .name = "watchdog", .fops = &sc1200wdt_fops, @@ -312,14 +330,14 @@ static int __init sc1200wdt_probe(void) /* The probe works by reading the PMC3 register's default value of 0x0e * there is one caveat, if the device disables the parallel port or any * of the UARTs we won't be able to detect it. - * Nb. This could be done with accuracy by reading the SID registers, but - * we don't have access to those io regions. + * NB. This could be done with accuracy by reading the SID registers, + * but we don't have access to those io regions. */ unsigned char reg; sc1200wdt_read_data(PMC3, ®); - reg &= 0x0f; /* we don't want the UART busy bits */ + reg &= 0x0f; /* we don't want the UART busy bits */ return (reg == 0x0e) ? 0 : -ENODEV; } @@ -332,7 +350,8 @@ static struct pnp_device_id scl200wdt_pnp_devices[] = { {.id = ""}, }; -static int scl200wdt_pnp_probe(struct pnp_dev * dev, const struct pnp_device_id *dev_id) +static int scl200wdt_pnp_probe(struct pnp_dev *dev, + const struct pnp_device_id *dev_id) { /* this driver only supports one card at a time */ if (wdt_dev || !isapnp) @@ -347,13 +366,14 @@ static int scl200wdt_pnp_probe(struct pnp_dev * dev, const struct pnp_device_id return -EBUSY; } - printk(KERN_INFO "scl200wdt: PnP device found at io port %#x/%d\n", io, io_len); + printk(KERN_INFO "scl200wdt: PnP device found at io port %#x/%d\n", + io, io_len); return 0; } -static void scl200wdt_pnp_remove(struct pnp_dev * dev) +static void scl200wdt_pnp_remove(struct pnp_dev *dev) { - if (wdt_dev){ + if (wdt_dev) { release_region(io, io_len); wdt_dev = NULL; } @@ -375,8 +395,6 @@ static int __init sc1200wdt_init(void) printk("%s\n", banner); - sema_init(&open_sem, 1); - #if defined CONFIG_PNP if (isapnp) { ret = pnp_register_driver(&scl200wdt_pnp_driver); @@ -410,13 +428,16 @@ static int __init sc1200wdt_init(void) ret = register_reboot_notifier(&sc1200wdt_notifier); if (ret) { - printk(KERN_ERR PFX "Unable to register reboot notifier err = %d\n", ret); + printk(KERN_ERR PFX + "Unable to register reboot notifier err = %d\n", ret); goto out_io; } ret = misc_register(&sc1200wdt_miscdev); if (ret) { - printk(KERN_ERR PFX "Unable to register miscdev on minor %d\n", WATCHDOG_MINOR); + printk(KERN_ERR PFX + "Unable to register miscdev on minor %d\n", + WATCHDOG_MINOR); goto out_rbt; } @@ -446,7 +467,7 @@ static void __exit sc1200wdt_exit(void) unregister_reboot_notifier(&sc1200wdt_notifier); #if defined CONFIG_PNP - if(isapnp) + if (isapnp) pnp_unregister_driver(&scl200wdt_pnp_driver); else #endif diff --git a/drivers/watchdog/wdt.c b/drivers/watchdog/wdt.c index 756fb15fdce7..53a6b18bcb9a 100644 --- a/drivers/watchdog/wdt.c +++ b/drivers/watchdog/wdt.c @@ -24,9 +24,10 @@ * Matt Crocker). * Alan Cox : Added wdt= boot option * Alan Cox : Cleaned up copy/user stuff - * Tim Hockin : Added insmod parameters, comment cleanup - * Parameterized timeout - * Tigran Aivazian : Restructured wdt_init() to handle failures + * Tim Hockin : Added insmod parameters, comment + * cleanup, parameterized timeout + * Tigran Aivazian : Restructured wdt_init() to handle + * failures * Joel Becker : Added WDIOC_GET/SETTIMEOUT * Matt Domsch : Added nowayout module option */ @@ -42,9 +43,9 @@ #include <linux/notifier.h> #include <linux/reboot.h> #include <linux/init.h> +#include <linux/io.h> +#include <linux/uaccess.h> -#include <asm/io.h> -#include <asm/uaccess.h> #include <asm/system.h> #include "wd501p.h" @@ -60,15 +61,19 @@ static char expect_close; static int heartbeat = WD_TIMO; static int wd_heartbeat; module_param(heartbeat, int, 0); -MODULE_PARM_DESC(heartbeat, "Watchdog heartbeat in seconds. (0<heartbeat<65536, default=" __MODULE_STRING(WD_TIMO) ")"); +MODULE_PARM_DESC(heartbeat, + "Watchdog heartbeat in seconds. (0 < heartbeat < 65536, default=" + __MODULE_STRING(WD_TIMO) ")"); static int nowayout = WATCHDOG_NOWAYOUT; module_param(nowayout, int, 0); -MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=" __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); +MODULE_PARM_DESC(nowayout, + "Watchdog cannot be stopped once started (default=" + __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); /* You must set these - there is no sane way to probe for this board. */ -static int io=0x240; -static int irq=11; +static int io = 0x240; +static int irq = 11; static DEFINE_SPINLOCK(wdt_lock); @@ -82,7 +87,8 @@ MODULE_PARM_DESC(irq, "WDT irq (default=11)"); static int tachometer; module_param(tachometer, int, 0); -MODULE_PARM_DESC(tachometer, "WDT501-P Fan Tachometer support (0=disable, default=0)"); +MODULE_PARM_DESC(tachometer, + "WDT501-P Fan Tachometer support (0=disable, default=0)"); #endif /* CONFIG_WDT_501 */ /* @@ -91,9 +97,9 @@ MODULE_PARM_DESC(tachometer, "WDT501-P Fan Tachometer support (0=disable, defaul static void wdt_ctr_mode(int ctr, int mode) { - ctr<<=6; - ctr|=0x30; - ctr|=(mode<<1); + ctr <<= 6; + ctr |= 0x30; + ctr |= (mode << 1); outb_p(ctr, WDT_CR); } @@ -114,12 +120,15 @@ static int wdt_start(void) unsigned long flags; spin_lock_irqsave(&wdt_lock, flags); inb_p(WDT_DC); /* Disable watchdog */ - wdt_ctr_mode(0,3); /* Program CTR0 for Mode 3: Square Wave Generator */ - wdt_ctr_mode(1,2); /* Program CTR1 for Mode 2: Rate Generator */ - wdt_ctr_mode(2,0); /* Program CTR2 for Mode 0: Pulse on Terminal Count */ + wdt_ctr_mode(0, 3); /* Program CTR0 for Mode 3: + Square Wave Generator */ + wdt_ctr_mode(1, 2); /* Program CTR1 for Mode 2: + Rate Generator */ + wdt_ctr_mode(2, 0); /* Program CTR2 for Mode 0: + Pulse on Terminal Count */ wdt_ctr_load(0, 8948); /* Count at 100Hz */ - wdt_ctr_load(1,wd_heartbeat); /* Heartbeat */ - wdt_ctr_load(2,65535); /* Length of reset pulse */ + wdt_ctr_load(1, wd_heartbeat); /* Heartbeat */ + wdt_ctr_load(2, 65535); /* Length of reset pulse */ outb_p(0, WDT_DC); /* Enable watchdog */ spin_unlock_irqrestore(&wdt_lock, flags); return 0; @@ -131,13 +140,13 @@ static int wdt_start(void) * Stop the watchdog driver. */ -static int wdt_stop (void) +static int wdt_stop(void) { unsigned long flags; spin_lock_irqsave(&wdt_lock, flags); /* Turn the card off */ inb_p(WDT_DC); /* Disable watchdog */ - wdt_ctr_load(2,0); /* 0 length reset pulses now */ + wdt_ctr_load(2, 0); /* 0 length reset pulses now */ spin_unlock_irqrestore(&wdt_lock, flags); return 0; } @@ -145,8 +154,8 @@ static int wdt_stop (void) /** * wdt_ping: * - * Reload counter one with the watchdog heartbeat. We don't bother reloading - * the cascade counter. + * Reload counter one with the watchdog heartbeat. We don't bother + * reloading the cascade counter. */ static int wdt_ping(void) @@ -155,8 +164,9 @@ static int wdt_ping(void) spin_lock_irqsave(&wdt_lock, flags); /* Write a watchdog value */ inb_p(WDT_DC); /* Disable watchdog */ - wdt_ctr_mode(1,2); /* Re-Program CTR1 for Mode 2: Rate Generator */ - wdt_ctr_load(1,wd_heartbeat); /* Heartbeat */ + wdt_ctr_mode(1, 2); /* Re-Program CTR1 for Mode 2: + Rate Generator */ + wdt_ctr_load(1, wd_heartbeat); /* Heartbeat */ outb_p(0, WDT_DC); /* Enable watchdog */ spin_unlock_irqrestore(&wdt_lock, flags); return 0; @@ -166,13 +176,14 @@ static int wdt_ping(void) * wdt_set_heartbeat: * @t: the new heartbeat value that needs to be set. * - * Set a new heartbeat value for the watchdog device. If the heartbeat value is - * incorrect we keep the old value and return -EINVAL. If successfull we - * return 0. + * Set a new heartbeat value for the watchdog device. If the heartbeat + * value is incorrect we keep the old value and return -EINVAL. If + * successful we return 0. */ + static int wdt_set_heartbeat(int t) { - if ((t < 1) || (t > 65535)) + if (t < 1 || t > 65535) return -EINVAL; heartbeat = t; @@ -200,7 +211,7 @@ static int wdt_get_status(int *status) new_status = inb_p(WDT_SR); spin_unlock_irqrestore(&wdt_lock, flags); - *status=0; + *status = 0; if (new_status & WDC_SR_ISOI0) *status |= WDIOF_EXTERN1; if (new_status & WDC_SR_ISII1) @@ -266,7 +277,7 @@ static irqreturn_t wdt_interrupt(int irq, void *dev_id) #ifdef CONFIG_WDT_501 if (!(status & WDC_SR_TGOOD)) - printk(KERN_CRIT "Overheat alarm.(%d)\n",inb_p(WDT_RT)); + printk(KERN_CRIT "Overheat alarm.(%d)\n", inb_p(WDT_RT)); if (!(status & WDC_SR_PSUOVER)) printk(KERN_CRIT "PSU over voltage.\n"); if (!(status & WDC_SR_PSUUNDR)) @@ -304,9 +315,10 @@ static irqreturn_t wdt_interrupt(int irq, void *dev_id) * write of data will do, as we we don't define content meaning. */ -static ssize_t wdt_write(struct file *file, const char __user *buf, size_t count, loff_t *ppos) +static ssize_t wdt_write(struct file *file, const char __user *buf, + size_t count, loff_t *ppos) { - if(count) { + if (count) { if (!nowayout) { size_t i; @@ -328,7 +340,6 @@ static ssize_t wdt_write(struct file *file, const char __user *buf, size_t count /** * wdt_ioctl: - * @inode: inode of the device * @file: file handle to the device * @cmd: watchdog command * @arg: argument pointer @@ -338,8 +349,7 @@ static ssize_t wdt_write(struct file *file, const char __user *buf, size_t count * querying capabilities and current status. */ -static int wdt_ioctl(struct inode *inode, struct file *file, unsigned int cmd, - unsigned long arg) +static long wdt_ioctl(struct file *file, unsigned int cmd, unsigned long arg) { void __user *argp = (void __user *)arg; int __user *p = argp; @@ -362,32 +372,28 @@ static int wdt_ioctl(struct inode *inode, struct file *file, unsigned int cmd, ident.options |= WDIOF_FANFAULT; #endif /* CONFIG_WDT_501 */ - switch(cmd) - { - default: - return -ENOTTY; - case WDIOC_GETSUPPORT: - return copy_to_user(argp, &ident, sizeof(ident))?-EFAULT:0; - - case WDIOC_GETSTATUS: - wdt_get_status(&status); - return put_user(status, p); - case WDIOC_GETBOOTSTATUS: - return put_user(0, p); - case WDIOC_KEEPALIVE: - wdt_ping(); - return 0; - case WDIOC_SETTIMEOUT: - if (get_user(new_heartbeat, p)) - return -EFAULT; - - if (wdt_set_heartbeat(new_heartbeat)) - return -EINVAL; - - wdt_ping(); - /* Fall */ - case WDIOC_GETTIMEOUT: - return put_user(heartbeat, p); + switch (cmd) { + default: + return -ENOTTY; + case WDIOC_GETSUPPORT: + return copy_to_user(argp, &ident, sizeof(ident)) ? -EFAULT : 0; + case WDIOC_GETSTATUS: + wdt_get_status(&status); + return put_user(status, p); + case WDIOC_GETBOOTSTATUS: + return put_user(0, p); + case WDIOC_KEEPALIVE: + wdt_ping(); + return 0; + case WDIOC_SETTIMEOUT: + if (get_user(new_heartbeat, p)) + return -EFAULT; + if (wdt_set_heartbeat(new_heartbeat)) + return -EINVAL; + wdt_ping(); + /* Fall */ + case WDIOC_GETTIMEOUT: + return put_user(heartbeat, p); } } @@ -405,7 +411,7 @@ static int wdt_ioctl(struct inode *inode, struct file *file, unsigned int cmd, static int wdt_open(struct inode *inode, struct file *file) { - if(test_and_set_bit(0, &wdt_is_open)) + if (test_and_set_bit(0, &wdt_is_open)) return -EBUSY; /* * Activate @@ -432,7 +438,8 @@ static int wdt_release(struct inode *inode, struct file *file) wdt_stop(); clear_bit(0, &wdt_is_open); } else { - printk(KERN_CRIT "wdt: WDT device closed unexpectedly. WDT will not stop!\n"); + printk(KERN_CRIT + "wdt: WDT device closed unexpectedly. WDT will not stop!\n"); wdt_ping(); } expect_close = 0; @@ -451,14 +458,15 @@ static int wdt_release(struct inode *inode, struct file *file) * farenheit. It was designed by an imperial measurement luddite. */ -static ssize_t wdt_temp_read(struct file *file, char __user *buf, size_t count, loff_t *ptr) +static ssize_t wdt_temp_read(struct file *file, char __user *buf, + size_t count, loff_t *ptr) { int temperature; if (wdt_get_temperature(&temperature)) return -EFAULT; - if (copy_to_user (buf, &temperature, 1)) + if (copy_to_user(buf, &temperature, 1)) return -EFAULT; return 1; @@ -506,10 +514,8 @@ static int wdt_temp_release(struct inode *inode, struct file *file) static int wdt_notify_sys(struct notifier_block *this, unsigned long code, void *unused) { - if(code==SYS_DOWN || code==SYS_HALT) { - /* Turn the card off */ + if (code == SYS_DOWN || code == SYS_HALT) wdt_stop(); - } return NOTIFY_DONE; } @@ -522,7 +528,7 @@ static const struct file_operations wdt_fops = { .owner = THIS_MODULE, .llseek = no_llseek, .write = wdt_write, - .ioctl = wdt_ioctl, + .unlocked_ioctl = wdt_ioctl, .open = wdt_open, .release = wdt_release, }; @@ -576,7 +582,7 @@ static void __exit wdt_exit(void) #endif /* CONFIG_WDT_501 */ unregister_reboot_notifier(&wdt_notifier); free_irq(irq, NULL); - release_region(io,8); + release_region(io, 8); } /** @@ -591,44 +597,49 @@ static int __init wdt_init(void) { int ret; - /* Check that the heartbeat value is within it's range ; if not reset to the default */ + /* Check that the heartbeat value is within it's range; + if not reset to the default */ if (wdt_set_heartbeat(heartbeat)) { wdt_set_heartbeat(WD_TIMO); - printk(KERN_INFO "wdt: heartbeat value must be 0<heartbeat<65536, using %d\n", + printk(KERN_INFO "wdt: heartbeat value must be 0 < heartbeat < 65536, using %d\n", WD_TIMO); } if (!request_region(io, 8, "wdt501p")) { - printk(KERN_ERR "wdt: I/O address 0x%04x already in use\n", io); + printk(KERN_ERR + "wdt: I/O address 0x%04x already in use\n", io); ret = -EBUSY; goto out; } ret = request_irq(irq, wdt_interrupt, IRQF_DISABLED, "wdt501p", NULL); - if(ret) { + if (ret) { printk(KERN_ERR "wdt: IRQ %d is not free.\n", irq); goto outreg; } ret = register_reboot_notifier(&wdt_notifier); - if(ret) { - printk(KERN_ERR "wdt: cannot register reboot notifier (err=%d)\n", ret); + if (ret) { + printk(KERN_ERR + "wdt: cannot register reboot notifier (err=%d)\n", ret); goto outirq; } #ifdef CONFIG_WDT_501 ret = misc_register(&temp_miscdev); if (ret) { - printk(KERN_ERR "wdt: cannot register miscdev on minor=%d (err=%d)\n", - TEMP_MINOR, ret); + printk(KERN_ERR + "wdt: cannot register miscdev on minor=%d (err=%d)\n", + TEMP_MINOR, ret); goto outrbt; } #endif /* CONFIG_WDT_501 */ ret = misc_register(&wdt_miscdev); if (ret) { - printk(KERN_ERR "wdt: cannot register miscdev on minor=%d (err=%d)\n", - WATCHDOG_MINOR, ret); + printk(KERN_ERR + "wdt: cannot register miscdev on minor=%d (err=%d)\n", + WATCHDOG_MINOR, ret); goto outmisc; } @@ -636,7 +647,8 @@ static int __init wdt_init(void) printk(KERN_INFO "WDT500/501-P driver 0.10 at 0x%04x (Interrupt %d). heartbeat=%d sec (nowayout=%d)\n", io, irq, heartbeat, nowayout); #ifdef CONFIG_WDT_501 - printk(KERN_INFO "wdt: Fan Tachometer is %s\n", (tachometer ? "Enabled" : "Disabled")); + printk(KERN_INFO "wdt: Fan Tachometer is %s\n", + (tachometer ? "Enabled" : "Disabled")); #endif /* CONFIG_WDT_501 */ out: @@ -651,7 +663,7 @@ outrbt: outirq: free_irq(irq, NULL); outreg: - release_region(io,8); + release_region(io, 8); goto out; } diff --git a/drivers/watchdog/wdt_pci.c b/drivers/watchdog/wdt_pci.c index 1355608683e4..5d922fd6eafc 100644 --- a/drivers/watchdog/wdt_pci.c +++ b/drivers/watchdog/wdt_pci.c @@ -29,9 +29,11 @@ * JP Nollmann : Added support for PCI wdt501p * Alan Cox : Split ISA and PCI cards into two drivers * Jeff Garzik : PCI cleanups - * Tigran Aivazian : Restructured wdtpci_init_one() to handle failures + * Tigran Aivazian : Restructured wdtpci_init_one() to handle + * failures * Joel Becker : Added WDIOC_GET/SETTIMEOUT - * Zwane Mwaikambo : Magic char closing, locking changes, cleanups + * Zwane Mwaikambo : Magic char closing, locking changes, + * cleanups * Matt Domsch : nowayout module option */ @@ -42,14 +44,15 @@ #include <linux/miscdevice.h> #include <linux/watchdog.h> #include <linux/ioport.h> +#include <linux/delay.h> #include <linux/notifier.h> #include <linux/reboot.h> #include <linux/init.h> #include <linux/fs.h> #include <linux/pci.h> +#include <linux/io.h> +#include <linux/uaccess.h> -#include <asm/io.h> -#include <asm/uaccess.h> #include <asm/system.h> #define WDT_IS_PCI @@ -73,7 +76,7 @@ /* We can only use 1 card due to the /dev/watchdog restriction */ static int dev_count; -static struct semaphore open_sem; +static unsigned long open_lock; static DEFINE_SPINLOCK(wdtpci_lock); static char expect_close; @@ -86,18 +89,23 @@ static int irq; static int heartbeat = WD_TIMO; static int wd_heartbeat; module_param(heartbeat, int, 0); -MODULE_PARM_DESC(heartbeat, "Watchdog heartbeat in seconds. (0<heartbeat<65536, default=" __MODULE_STRING(WD_TIMO) ")"); +MODULE_PARM_DESC(heartbeat, + "Watchdog heartbeat in seconds. (0<heartbeat<65536, default=" + __MODULE_STRING(WD_TIMO) ")"); static int nowayout = WATCHDOG_NOWAYOUT; module_param(nowayout, int, 0); -MODULE_PARM_DESC(nowayout, "Watchdog cannot be stopped once started (default=" __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); +MODULE_PARM_DESC(nowayout, + "Watchdog cannot be stopped once started (default=" + __MODULE_STRING(WATCHDOG_NOWAYOUT) ")"); #ifdef CONFIG_WDT_501_PCI /* Support for the Fan Tachometer on the PCI-WDT501 */ static int tachometer; module_param(tachometer, int, 0); -MODULE_PARM_DESC(tachometer, "PCI-WDT501 Fan Tachometer support (0=disable, default=0)"); +MODULE_PARM_DESC(tachometer, + "PCI-WDT501 Fan Tachometer support (0=disable, default=0)"); #endif /* CONFIG_WDT_501_PCI */ /* @@ -106,16 +114,19 @@ MODULE_PARM_DESC(tachometer, "PCI-WDT501 Fan Tachometer support (0=disable, defa static void wdtpci_ctr_mode(int ctr, int mode) { - ctr<<=6; - ctr|=0x30; - ctr|=(mode<<1); - outb_p(ctr, WDT_CR); + ctr <<= 6; + ctr |= 0x30; + ctr |= (mode << 1); + outb(ctr, WDT_CR); + udelay(8); } static void wdtpci_ctr_load(int ctr, int val) { - outb_p(val&0xFF, WDT_COUNT0+ctr); - outb_p(val>>8, WDT_COUNT0+ctr); + outb(val & 0xFF, WDT_COUNT0 + ctr); + udelay(8); + outb(val >> 8, WDT_COUNT0 + ctr); + udelay(8); } /** @@ -134,23 +145,35 @@ static int wdtpci_start(void) * "pet" the watchdog, as Access says. * This resets the clock outputs. */ - inb_p(WDT_DC); /* Disable watchdog */ - wdtpci_ctr_mode(2,0); /* Program CTR2 for Mode 0: Pulse on Terminal Count */ - outb_p(0, WDT_DC); /* Enable watchdog */ - - inb_p(WDT_DC); /* Disable watchdog */ - outb_p(0, WDT_CLOCK); /* 2.0833MHz clock */ - inb_p(WDT_BUZZER); /* disable */ - inb_p(WDT_OPTONOTRST); /* disable */ - inb_p(WDT_OPTORST); /* disable */ - inb_p(WDT_PROGOUT); /* disable */ - wdtpci_ctr_mode(0,3); /* Program CTR0 for Mode 3: Square Wave Generator */ - wdtpci_ctr_mode(1,2); /* Program CTR1 for Mode 2: Rate Generator */ - wdtpci_ctr_mode(2,1); /* Program CTR2 for Mode 1: Retriggerable One-Shot */ - wdtpci_ctr_load(0,20833); /* count at 100Hz */ - wdtpci_ctr_load(1,wd_heartbeat);/* Heartbeat */ + inb(WDT_DC); /* Disable watchdog */ + udelay(8); + wdtpci_ctr_mode(2, 0); /* Program CTR2 for Mode 0: + Pulse on Terminal Count */ + outb(0, WDT_DC); /* Enable watchdog */ + udelay(8); + inb(WDT_DC); /* Disable watchdog */ + udelay(8); + outb(0, WDT_CLOCK); /* 2.0833MHz clock */ + udelay(8); + inb(WDT_BUZZER); /* disable */ + udelay(8); + inb(WDT_OPTONOTRST); /* disable */ + udelay(8); + inb(WDT_OPTORST); /* disable */ + udelay(8); + inb(WDT_PROGOUT); /* disable */ + udelay(8); + wdtpci_ctr_mode(0, 3); /* Program CTR0 for Mode 3: + Square Wave Generator */ + wdtpci_ctr_mode(1, 2); /* Program CTR1 for Mode 2: + Rate Generator */ + wdtpci_ctr_mode(2, 1); /* Program CTR2 for Mode 1: + Retriggerable One-Shot */ + wdtpci_ctr_load(0, 20833); /* count at 100Hz */ + wdtpci_ctr_load(1, wd_heartbeat);/* Heartbeat */ /* DO NOT LOAD CTR2 on PCI card! -- JPN */ - outb_p(0, WDT_DC); /* Enable watchdog */ + outb(0, WDT_DC); /* Enable watchdog */ + udelay(8); spin_unlock_irqrestore(&wdtpci_lock, flags); return 0; @@ -162,14 +185,15 @@ static int wdtpci_start(void) * Stop the watchdog driver. */ -static int wdtpci_stop (void) +static int wdtpci_stop(void) { unsigned long flags; /* Turn the card off */ spin_lock_irqsave(&wdtpci_lock, flags); - inb_p(WDT_DC); /* Disable watchdog */ - wdtpci_ctr_load(2,0); /* 0 length reset pulses now */ + inb(WDT_DC); /* Disable watchdog */ + udelay(8); + wdtpci_ctr_load(2, 0); /* 0 length reset pulses now */ spin_unlock_irqrestore(&wdtpci_lock, flags); return 0; } @@ -177,20 +201,23 @@ static int wdtpci_stop (void) /** * wdtpci_ping: * - * Reload counter one with the watchdog heartbeat. We don't bother reloading - * the cascade counter. + * Reload counter one with the watchdog heartbeat. We don't bother + * reloading the cascade counter. */ static int wdtpci_ping(void) { unsigned long flags; - /* Write a watchdog value */ spin_lock_irqsave(&wdtpci_lock, flags); - inb_p(WDT_DC); /* Disable watchdog */ - wdtpci_ctr_mode(1,2); /* Re-Program CTR1 for Mode 2: Rate Generator */ - wdtpci_ctr_load(1,wd_heartbeat);/* Heartbeat */ - outb_p(0, WDT_DC); /* Enable watchdog */ + /* Write a watchdog value */ + inb(WDT_DC); /* Disable watchdog */ + udelay(8); + wdtpci_ctr_mode(1, 2); /* Re-Program CTR1 for Mode 2: + Rate Generator */ + wdtpci_ctr_load(1, wd_heartbeat);/* Heartbeat */ + outb(0, WDT_DC); /* Enable watchdog */ + udelay(8); spin_unlock_irqrestore(&wdtpci_lock, flags); return 0; } @@ -199,14 +226,14 @@ static int wdtpci_ping(void) * wdtpci_set_heartbeat: * @t: the new heartbeat value that needs to be set. * - * Set a new heartbeat value for the watchdog device. If the heartbeat value is - * incorrect we keep the old value and return -EINVAL. If successfull we - * return 0. + * Set a new heartbeat value for the watchdog device. If the heartbeat + * value is incorrect we keep the old value and return -EINVAL. + * If successful we return 0. */ static int wdtpci_set_heartbeat(int t) { /* Arbitrary, can't find the card's limits */ - if ((t < 1) || (t > 65535)) + if (t < 1 || t > 65535) return -EINVAL; heartbeat = t; @@ -227,9 +254,14 @@ static int wdtpci_set_heartbeat(int t) static int wdtpci_get_status(int *status) { - unsigned char new_status=inb_p(WDT_SR); + unsigned char new_status; + unsigned long flags; + + spin_lock_irqsave(&wdtpci_lock, flags); + new_status = inb(WDT_SR); + spin_unlock_irqrestore(&wdtpci_lock, flags); - *status=0; + *status = 0; if (new_status & WDC_SR_ISOI0) *status |= WDIOF_EXTERN1; if (new_status & WDC_SR_ISII1) @@ -259,8 +291,12 @@ static int wdtpci_get_status(int *status) static int wdtpci_get_temperature(int *temperature) { - unsigned short c=inb_p(WDT_RT); - + unsigned short c; + unsigned long flags; + spin_lock_irqsave(&wdtpci_lock, flags); + c = inb(WDT_RT); + udelay(8); + spin_unlock_irqrestore(&wdtpci_lock, flags); *temperature = (c * 11 / 15) + 7; return 0; } @@ -282,17 +318,25 @@ static irqreturn_t wdtpci_interrupt(int irq, void *dev_id) * Read the status register see what is up and * then printk it. */ - unsigned char status=inb_p(WDT_SR); + unsigned char status; + + spin_lock(&wdtpci_lock); + + status = inb(WDT_SR); + udelay(8); printk(KERN_CRIT PFX "status %d\n", status); #ifdef CONFIG_WDT_501_PCI - if (!(status & WDC_SR_TGOOD)) - printk(KERN_CRIT PFX "Overheat alarm.(%d)\n",inb_p(WDT_RT)); + if (!(status & WDC_SR_TGOOD)) { + u8 alarm = inb(WDT_RT); + printk(KERN_CRIT PFX "Overheat alarm.(%d)\n", alarm); + udelay(8); + } if (!(status & WDC_SR_PSUOVER)) - printk(KERN_CRIT PFX "PSU over voltage.\n"); + printk(KERN_CRIT PFX "PSU over voltage.\n"); if (!(status & WDC_SR_PSUUNDR)) - printk(KERN_CRIT PFX "PSU under voltage.\n"); + printk(KERN_CRIT PFX "PSU under voltage.\n"); if (tachometer) { if (!(status & WDC_SR_FANGOOD)) printk(KERN_CRIT PFX "Possible fan fault.\n"); @@ -310,6 +354,7 @@ static irqreturn_t wdtpci_interrupt(int irq, void *dev_id) printk(KERN_CRIT PFX "Reset in 5ms.\n"); #endif } + spin_unlock(&wdtpci_lock); return IRQ_HANDLED; } @@ -325,7 +370,8 @@ static irqreturn_t wdtpci_interrupt(int irq, void *dev_id) * write of data will do, as we we don't define content meaning. */ -static ssize_t wdtpci_write(struct file *file, const char __user *buf, size_t count, loff_t *ppos) +static ssize_t wdtpci_write(struct file *file, const char __user *buf, + size_t count, loff_t *ppos) { if (count) { if (!nowayout) { @@ -335,7 +381,7 @@ static ssize_t wdtpci_write(struct file *file, const char __user *buf, size_t co for (i = 0; i != count; i++) { char c; - if(get_user(c, buf+i)) + if (get_user(c, buf+i)) return -EFAULT; if (c == 'V') expect_close = 42; @@ -343,13 +389,11 @@ static ssize_t wdtpci_write(struct file *file, const char __user *buf, size_t co } wdtpci_ping(); } - return count; } /** * wdtpci_ioctl: - * @inode: inode of the device * @file: file handle to the device * @cmd: watchdog command * @arg: argument pointer @@ -359,8 +403,8 @@ static ssize_t wdtpci_write(struct file *file, const char __user *buf, size_t co * querying capabilities and current status. */ -static int wdtpci_ioctl(struct inode *inode, struct file *file, unsigned int cmd, - unsigned long arg) +static long wdtpci_ioctl(struct file *file, unsigned int cmd, + unsigned long arg) { int new_heartbeat; int status; @@ -383,33 +427,29 @@ static int wdtpci_ioctl(struct inode *inode, struct file *file, unsigned int cmd ident.options |= WDIOF_FANFAULT; #endif /* CONFIG_WDT_501_PCI */ - switch(cmd) - { - default: - return -ENOTTY; - case WDIOC_GETSUPPORT: - return copy_to_user(argp, &ident, sizeof(ident))?-EFAULT:0; - - case WDIOC_GETSTATUS: - wdtpci_get_status(&status); - return put_user(status, p); - case WDIOC_GETBOOTSTATUS: - return put_user(0, p); - case WDIOC_KEEPALIVE: - wdtpci_ping(); - return 0; - case WDIOC_SETTIMEOUT: - if (get_user(new_heartbeat, p)) - return -EFAULT; - - if (wdtpci_set_heartbeat(new_heartbeat)) - return -EINVAL; - - wdtpci_ping(); - /* Fall */ - case WDIOC_GETTIMEOUT: - return put_user(heartbeat, p); - } + switch (cmd) { + default: + return -ENOTTY; + case WDIOC_GETSUPPORT: + return copy_to_user(argp, &ident, sizeof(ident)) ? -EFAULT : 0; + case WDIOC_GETSTATUS: + wdtpci_get_status(&status); + return put_user(status, p); + case WDIOC_GETBOOTSTATUS: + return put_user(0, p); + case WDIOC_KEEPALIVE: + wdtpci_ping(); + return 0; + case WDIOC_SETTIMEOUT: + if (get_user(new_heartbeat, p)) + return -EFAULT; + if (wdtpci_set_heartbeat(new_heartbeat)) + return -EINVAL; + wdtpci_ping(); + /* Fall */ + case WDIOC_GETTIMEOUT: + return put_user(heartbeat, p); + } } /** @@ -426,12 +466,11 @@ static int wdtpci_ioctl(struct inode *inode, struct file *file, unsigned int cmd static int wdtpci_open(struct inode *inode, struct file *file) { - if (down_trylock(&open_sem)) + if (test_and_set_bit(0, &open_lock)) return -EBUSY; - if (nowayout) { + if (nowayout) __module_get(THIS_MODULE); - } /* * Activate */ @@ -460,7 +499,7 @@ static int wdtpci_release(struct inode *inode, struct file *file) wdtpci_ping(); } expect_close = 0; - up(&open_sem); + clear_bit(0, &open_lock); return 0; } @@ -476,14 +515,15 @@ static int wdtpci_release(struct inode *inode, struct file *file) * fahrenheit. It was designed by an imperial measurement luddite. */ -static ssize_t wdtpci_temp_read(struct file *file, char __user *buf, size_t count, loff_t *ptr) +static ssize_t wdtpci_temp_read(struct file *file, char __user *buf, + size_t count, loff_t *ptr) { int temperature; if (wdtpci_get_temperature(&temperature)) return -EFAULT; - if (copy_to_user (buf, &temperature, 1)) + if (copy_to_user(buf, &temperature, 1)) return -EFAULT; return 1; @@ -529,12 +569,10 @@ static int wdtpci_temp_release(struct inode *inode, struct file *file) */ static int wdtpci_notify_sys(struct notifier_block *this, unsigned long code, - void *unused) + void *unused) { - if (code==SYS_DOWN || code==SYS_HALT) { - /* Turn the card off */ + if (code == SYS_DOWN || code == SYS_HALT) wdtpci_stop(); - } return NOTIFY_DONE; } @@ -547,7 +585,7 @@ static const struct file_operations wdtpci_fops = { .owner = THIS_MODULE, .llseek = no_llseek, .write = wdtpci_write, - .ioctl = wdtpci_ioctl, + .unlocked_ioctl = wdtpci_ioctl, .open = wdtpci_open, .release = wdtpci_release, }; @@ -584,80 +622,85 @@ static struct notifier_block wdtpci_notifier = { }; -static int __devinit wdtpci_init_one (struct pci_dev *dev, - const struct pci_device_id *ent) +static int __devinit wdtpci_init_one(struct pci_dev *dev, + const struct pci_device_id *ent) { int ret = -EIO; dev_count++; if (dev_count > 1) { - printk (KERN_ERR PFX "this driver only supports 1 device\n"); + printk(KERN_ERR PFX "This driver only supports one device\n"); return -ENODEV; } - if (pci_enable_device (dev)) { - printk (KERN_ERR PFX "Not possible to enable PCI Device\n"); + if (pci_enable_device(dev)) { + printk(KERN_ERR PFX "Not possible to enable PCI Device\n"); return -ENODEV; } - if (pci_resource_start (dev, 2) == 0x0000) { - printk (KERN_ERR PFX "No I/O-Address for card detected\n"); + if (pci_resource_start(dev, 2) == 0x0000) { + printk(KERN_ERR PFX "No I/O-Address for card detected\n"); ret = -ENODEV; goto out_pci; } - sema_init(&open_sem, 1); - irq = dev->irq; - io = pci_resource_start (dev, 2); + io = pci_resource_start(dev, 2); - if (request_region (io, 16, "wdt_pci") == NULL) { - printk (KERN_ERR PFX "I/O address 0x%04x already in use\n", io); + if (request_region(io, 16, "wdt_pci") == NULL) { + printk(KERN_ERR PFX "I/O address 0x%04x already in use\n", io); goto out_pci; } - if (request_irq (irq, wdtpci_interrupt, IRQF_DISABLED | IRQF_SHARED, + if (request_irq(irq, wdtpci_interrupt, IRQF_DISABLED | IRQF_SHARED, "wdt_pci", &wdtpci_miscdev)) { - printk (KERN_ERR PFX "IRQ %d is not free\n", irq); + printk(KERN_ERR PFX "IRQ %d is not free\n", irq); goto out_reg; } - printk ("PCI-WDT500/501 (PCI-WDG-CSM) driver 0.10 at 0x%04x (Interrupt %d)\n", - io, irq); + printk(KERN_INFO + "PCI-WDT500/501 (PCI-WDG-CSM) driver 0.10 at 0x%04x (Interrupt %d)\n", + io, irq); - /* Check that the heartbeat value is within it's range ; if not reset to the default */ + /* Check that the heartbeat value is within its range; + if not reset to the default */ if (wdtpci_set_heartbeat(heartbeat)) { wdtpci_set_heartbeat(WD_TIMO); - printk(KERN_INFO PFX "heartbeat value must be 0<heartbeat<65536, using %d\n", - WD_TIMO); + printk(KERN_INFO PFX + "heartbeat value must be 0 < heartbeat < 65536, using %d\n", + WD_TIMO); } - ret = register_reboot_notifier (&wdtpci_notifier); + ret = register_reboot_notifier(&wdtpci_notifier); if (ret) { - printk (KERN_ERR PFX "cannot register reboot notifier (err=%d)\n", ret); + printk(KERN_ERR PFX + "cannot register reboot notifier (err=%d)\n", ret); goto out_irq; } #ifdef CONFIG_WDT_501_PCI - ret = misc_register (&temp_miscdev); + ret = misc_register(&temp_miscdev); if (ret) { - printk (KERN_ERR PFX "cannot register miscdev on minor=%d (err=%d)\n", - TEMP_MINOR, ret); + printk(KERN_ERR PFX + "cannot register miscdev on minor=%d (err=%d)\n", + TEMP_MINOR, ret); goto out_rbt; } #endif /* CONFIG_WDT_501_PCI */ - ret = misc_register (&wdtpci_miscdev); + ret = misc_register(&wdtpci_miscdev); if (ret) { - printk (KERN_ERR PFX "cannot register miscdev on minor=%d (err=%d)\n", - WATCHDOG_MINOR, ret); + printk(KERN_ERR PFX + "cannot register miscdev on minor=%d (err=%d)\n", + WATCHDOG_MINOR, ret); goto out_misc; } printk(KERN_INFO PFX "initialized. heartbeat=%d sec (nowayout=%d)\n", heartbeat, nowayout); #ifdef CONFIG_WDT_501_PCI - printk(KERN_INFO "wdt: Fan Tachometer is %s\n", (tachometer ? "Enabled" : "Disabled")); + printk(KERN_INFO "wdt: Fan Tachometer is %s\n", + (tachometer ? "Enabled" : "Disabled")); #endif /* CONFIG_WDT_501_PCI */ ret = 0; @@ -673,14 +716,14 @@ out_rbt: out_irq: free_irq(irq, &wdtpci_miscdev); out_reg: - release_region (io, 16); + release_region(io, 16); out_pci: pci_disable_device(dev); goto out; } -static void __devexit wdtpci_remove_one (struct pci_dev *pdev) +static void __devexit wdtpci_remove_one(struct pci_dev *pdev) { /* here we assume only one device will ever have * been picked up and registered by probe function */ @@ -728,7 +771,7 @@ static struct pci_driver wdtpci_driver = { static void __exit wdtpci_cleanup(void) { - pci_unregister_driver (&wdtpci_driver); + pci_unregister_driver(&wdtpci_driver); } @@ -742,7 +785,7 @@ static void __exit wdtpci_cleanup(void) static int __init wdtpci_init(void) { - return pci_register_driver (&wdtpci_driver); + return pci_register_driver(&wdtpci_driver); } diff --git a/firmware/ihex2fw.c b/firmware/ihex2fw.c index 660b191ed75e..8f7fdaa9e010 100644 --- a/firmware/ihex2fw.c +++ b/firmware/ihex2fw.c @@ -250,19 +250,19 @@ static void file_record(struct ihex_binrec *record) static int output_records(int outfd) { - unsigned char zeroes[5] = {0, 0, 0, 0, 0}; + unsigned char zeroes[6] = {0, 0, 0, 0, 0, 0}; struct ihex_binrec *p = records; while (p) { uint16_t writelen = (p->len + 9) & ~3; p->addr = htonl(p->addr); - p->len = htonl(p->len); + p->len = htons(p->len); write(outfd, &p->addr, writelen); p = p->next; } /* EOF record is zero length, since we don't bother to represent the type field in the binary version */ - write(outfd, zeroes, 5); + write(outfd, zeroes, 6); return 0; } diff --git a/fs/nfs/nfsroot.c b/fs/nfs/nfsroot.c index 8478fc25daee..46763d1cd397 100644 --- a/fs/nfs/nfsroot.c +++ b/fs/nfs/nfsroot.c @@ -127,7 +127,7 @@ enum { Opt_err }; -static match_table_t __initconst tokens = { +static match_table_t __initdata tokens = { {Opt_port, "port=%u"}, {Opt_rsize, "rsize=%u"}, {Opt_wsize, "wsize=%u"}, diff --git a/fs/ufs/super.c b/fs/ufs/super.c index 3e30e40aa24d..3141969b456d 100644 --- a/fs/ufs/super.c +++ b/fs/ufs/super.c @@ -1233,7 +1233,7 @@ static int ufs_show_options(struct seq_file *seq, struct vfsmount *vfs) { struct ufs_sb_info *sbi = UFS_SB(vfs->mnt_sb); unsigned mval = sbi->s_mount_opt & UFS_MOUNT_UFSTYPE; - const struct match_token *tp = tokens; + struct match_token *tp = tokens; while (tp->token != Opt_onerror_panic && tp->token != mval) ++tp; diff --git a/include/asm-m68k/contregs.h b/include/asm-m68k/contregs.h index 1e233e7d191e..d1ea750bddfe 100644 --- a/include/asm-m68k/contregs.h +++ b/include/asm-m68k/contregs.h @@ -1,4 +1,53 @@ #ifndef _M68K_CONTREGS_H #define _M68K_CONTREGS_H -#include <asm-sparc/contregs.h> + +/* contregs.h: Addresses of registers in the ASI_CONTROL alternate address + * space. These are for the mmu's context register, etc. + * + * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu) + */ + +/* 3=sun3 + 4=sun4 (as in sun4 sysmaint student book) + c=sun4c (according to davem) */ + +#define AC_IDPROM 0x00000000 /* 34 ID PROM, R/O, byte, 32 bytes */ +#define AC_PAGEMAP 0x10000000 /* 3 Pagemap R/W, long */ +#define AC_SEGMAP 0x20000000 /* 3 Segment map, byte */ +#define AC_CONTEXT 0x30000000 /* 34c current mmu-context */ +#define AC_SENABLE 0x40000000 /* 34c system dvma/cache/reset enable reg*/ +#define AC_UDVMA_ENB 0x50000000 /* 34 Not used on Sun boards, byte */ +#define AC_BUS_ERROR 0x60000000 /* 34 Not cleared on read, byte. */ +#define AC_SYNC_ERR 0x60000000 /* c fault type */ +#define AC_SYNC_VA 0x60000004 /* c fault virtual address */ +#define AC_ASYNC_ERR 0x60000008 /* c asynchronous fault type */ +#define AC_ASYNC_VA 0x6000000c /* c async fault virtual address */ +#define AC_LEDS 0x70000000 /* 34 Zero turns on LEDs, byte */ +#define AC_CACHETAGS 0x80000000 /* 34c direct access to the VAC tags */ +#define AC_CACHEDDATA 0x90000000 /* 3 c direct access to the VAC data */ +#define AC_UDVMA_MAP 0xD0000000 /* 4 Not used on Sun boards, byte */ +#define AC_VME_VECTOR 0xE0000000 /* 4 For non-Autovector VME, byte */ +#define AC_BOOT_SCC 0xF0000000 /* 34 bypass to access Zilog 8530. byte.*/ + +/* s=Swift, h=Ross_HyperSPARC, v=TI_Viking, t=Tsunami, r=Ross_Cypress */ +#define AC_M_PCR 0x0000 /* shv Processor Control Reg */ +#define AC_M_CTPR 0x0100 /* shv Context Table Pointer Reg */ +#define AC_M_CXR 0x0200 /* shv Context Register */ +#define AC_M_SFSR 0x0300 /* shv Synchronous Fault Status Reg */ +#define AC_M_SFAR 0x0400 /* shv Synchronous Fault Address Reg */ +#define AC_M_AFSR 0x0500 /* hv Asynchronous Fault Status Reg */ +#define AC_M_AFAR 0x0600 /* hv Asynchronous Fault Address Reg */ +#define AC_M_RESET 0x0700 /* hv Reset Reg */ +#define AC_M_RPR 0x1000 /* hv Root Pointer Reg */ +#define AC_M_TSUTRCR 0x1000 /* s TLB Replacement Ctrl Reg */ +#define AC_M_IAPTP 0x1100 /* hv Instruction Access PTP */ +#define AC_M_DAPTP 0x1200 /* hv Data Access PTP */ +#define AC_M_ITR 0x1300 /* hv Index Tag Register */ +#define AC_M_TRCR 0x1400 /* hv TLB Replacement Control Reg */ +#define AC_M_SFSRX 0x1300 /* s Synch Fault Status Reg prim */ +#define AC_M_SFARX 0x1400 /* s Synch Fault Address Reg prim */ +#define AC_M_RPR1 0x1500 /* h Root Pointer Reg (entry 2) */ +#define AC_M_IAPTP1 0x1600 /* h Instruction Access PTP (entry 2) */ +#define AC_M_DAPTP1 0x1700 /* h Data Access PTP (entry 2) */ + #endif /* _M68K_CONTREGS_H */ diff --git a/include/asm-m68k/fbio.h b/include/asm-m68k/fbio.h index c17edf8c7bc4..b9215a0907d3 100644 --- a/include/asm-m68k/fbio.h +++ b/include/asm-m68k/fbio.h @@ -1 +1,330 @@ -#include <asm-sparc/fbio.h> +#ifndef __LINUX_FBIO_H +#define __LINUX_FBIO_H + +#include <linux/compiler.h> +#include <linux/types.h> + +/* Constants used for fbio SunOS compatibility */ +/* (C) 1996 Miguel de Icaza */ + +/* Frame buffer types */ +#define FBTYPE_NOTYPE -1 +#define FBTYPE_SUN1BW 0 /* mono */ +#define FBTYPE_SUN1COLOR 1 +#define FBTYPE_SUN2BW 2 +#define FBTYPE_SUN2COLOR 3 +#define FBTYPE_SUN2GP 4 +#define FBTYPE_SUN5COLOR 5 +#define FBTYPE_SUN3COLOR 6 +#define FBTYPE_MEMCOLOR 7 +#define FBTYPE_SUN4COLOR 8 + +#define FBTYPE_NOTSUN1 9 +#define FBTYPE_NOTSUN2 10 +#define FBTYPE_NOTSUN3 11 + +#define FBTYPE_SUNFAST_COLOR 12 /* cg6 */ +#define FBTYPE_SUNROP_COLOR 13 +#define FBTYPE_SUNFB_VIDEO 14 +#define FBTYPE_SUNGIFB 15 +#define FBTYPE_SUNGPLAS 16 +#define FBTYPE_SUNGP3 17 +#define FBTYPE_SUNGT 18 +#define FBTYPE_SUNLEO 19 /* zx Leo card */ +#define FBTYPE_MDICOLOR 20 /* cg14 */ +#define FBTYPE_TCXCOLOR 21 /* SUNW,tcx card */ + +#define FBTYPE_LASTPLUSONE 21 /* This is not last + 1 in fact... */ + +/* Does not seem to be listed in the Sun file either */ +#define FBTYPE_CREATOR 22 +#define FBTYPE_PCI_IGA1682 23 +#define FBTYPE_P9100COLOR 24 + +#define FBTYPE_PCI_GENERIC 1000 +#define FBTYPE_PCI_MACH64 1001 + +/* fbio ioctls */ +/* Returned by FBIOGTYPE */ +struct fbtype { + int fb_type; /* fb type, see above */ + int fb_height; /* pixels */ + int fb_width; /* pixels */ + int fb_depth; + int fb_cmsize; /* color map entries */ + int fb_size; /* fb size in bytes */ +}; +#define FBIOGTYPE _IOR('F', 0, struct fbtype) + +struct fbcmap { + int index; /* first element (0 origin) */ + int count; + unsigned char __user *red; + unsigned char __user *green; + unsigned char __user *blue; +}; + +#ifdef __KERNEL__ +#define FBIOPUTCMAP_SPARC _IOW('F', 3, struct fbcmap) +#define FBIOGETCMAP_SPARC _IOW('F', 4, struct fbcmap) +#else +#define FBIOPUTCMAP _IOW('F', 3, struct fbcmap) +#define FBIOGETCMAP _IOW('F', 4, struct fbcmap) +#endif + +/* # of device specific values */ +#define FB_ATTR_NDEVSPECIFIC 8 +/* # of possible emulations */ +#define FB_ATTR_NEMUTYPES 4 + +struct fbsattr { + int flags; + int emu_type; /* -1 if none */ + int dev_specific[FB_ATTR_NDEVSPECIFIC]; +}; + +struct fbgattr { + int real_type; /* real frame buffer type */ + int owner; /* unknown */ + struct fbtype fbtype; /* real frame buffer fbtype */ + struct fbsattr sattr; + int emu_types[FB_ATTR_NEMUTYPES]; /* supported emulations */ +}; +#define FBIOSATTR _IOW('F', 5, struct fbgattr) /* Unsupported: */ +#define FBIOGATTR _IOR('F', 6, struct fbgattr) /* supported */ + +#define FBIOSVIDEO _IOW('F', 7, int) +#define FBIOGVIDEO _IOR('F', 8, int) + +struct fbcursor { + short set; /* what to set, choose from the list above */ + short enable; /* cursor on/off */ + struct fbcurpos pos; /* cursor position */ + struct fbcurpos hot; /* cursor hot spot */ + struct fbcmap cmap; /* color map info */ + struct fbcurpos size; /* cursor bit map size */ + char __user *image; /* cursor image bits */ + char __user *mask; /* cursor mask bits */ +}; + +/* set/get cursor attributes/shape */ +#define FBIOSCURSOR _IOW('F', 24, struct fbcursor) +#define FBIOGCURSOR _IOWR('F', 25, struct fbcursor) + +/* set/get cursor position */ +#define FBIOSCURPOS _IOW('F', 26, struct fbcurpos) +#define FBIOGCURPOS _IOW('F', 27, struct fbcurpos) + +/* get max cursor size */ +#define FBIOGCURMAX _IOR('F', 28, struct fbcurpos) + +/* wid manipulation */ +struct fb_wid_alloc { +#define FB_WID_SHARED_8 0 +#define FB_WID_SHARED_24 1 +#define FB_WID_DBL_8 2 +#define FB_WID_DBL_24 3 + __u32 wa_type; + __s32 wa_index; /* Set on return */ + __u32 wa_count; +}; +struct fb_wid_item { + __u32 wi_type; + __s32 wi_index; + __u32 wi_attrs; + __u32 wi_values[32]; +}; +struct fb_wid_list { + __u32 wl_flags; + __u32 wl_count; + struct fb_wid_item *wl_list; +}; + +#define FBIO_WID_ALLOC _IOWR('F', 30, struct fb_wid_alloc) +#define FBIO_WID_FREE _IOW('F', 31, struct fb_wid_alloc) +#define FBIO_WID_PUT _IOW('F', 32, struct fb_wid_list) +#define FBIO_WID_GET _IOWR('F', 33, struct fb_wid_list) + +/* Creator ioctls */ +#define FFB_IOCTL ('F'<<8) +#define FFB_SYS_INFO (FFB_IOCTL|80) +#define FFB_CLUTREAD (FFB_IOCTL|81) +#define FFB_CLUTPOST (FFB_IOCTL|82) +#define FFB_SETDIAGMODE (FFB_IOCTL|83) +#define FFB_GETMONITORID (FFB_IOCTL|84) +#define FFB_GETVIDEOMODE (FFB_IOCTL|85) +#define FFB_SETVIDEOMODE (FFB_IOCTL|86) +#define FFB_SETSERVER (FFB_IOCTL|87) +#define FFB_SETOVCTL (FFB_IOCTL|88) +#define FFB_GETOVCTL (FFB_IOCTL|89) +#define FFB_GETSAXNUM (FFB_IOCTL|90) +#define FFB_FBDEBUG (FFB_IOCTL|91) + +/* Cg14 ioctls */ +#define MDI_IOCTL ('M'<<8) +#define MDI_RESET (MDI_IOCTL|1) +#define MDI_GET_CFGINFO (MDI_IOCTL|2) +#define MDI_SET_PIXELMODE (MDI_IOCTL|3) +# define MDI_32_PIX 32 +# define MDI_16_PIX 16 +# define MDI_8_PIX 8 + +struct mdi_cfginfo { + int mdi_ncluts; /* Number of implemented CLUTs in this MDI */ + int mdi_type; /* FBTYPE name */ + int mdi_height; /* height */ + int mdi_width; /* widht */ + int mdi_size; /* available ram */ + int mdi_mode; /* 8bpp, 16bpp or 32bpp */ + int mdi_pixfreq; /* pixel clock (from PROM) */ +}; + +/* SparcLinux specific ioctl for the MDI, should be replaced for + * the SET_XLUT/SET_CLUTn ioctls instead + */ +#define MDI_CLEAR_XLUT (MDI_IOCTL|9) + +/* leo & ffb ioctls */ +struct fb_clut_alloc { + __u32 clutid; /* Set on return */ + __u32 flag; + __u32 index; +}; + +struct fb_clut { +#define FB_CLUT_WAIT 0x00000001 /* Not yet implemented */ + __u32 flag; + __u32 clutid; + __u32 offset; + __u32 count; + char * red; + char * green; + char * blue; +}; + +struct fb_clut32 { + __u32 flag; + __u32 clutid; + __u32 offset; + __u32 count; + __u32 red; + __u32 green; + __u32 blue; +}; + +#define LEO_CLUTALLOC _IOWR('L', 53, struct fb_clut_alloc) +#define LEO_CLUTFREE _IOW('L', 54, struct fb_clut_alloc) +#define LEO_CLUTREAD _IOW('L', 55, struct fb_clut) +#define LEO_CLUTPOST _IOW('L', 56, struct fb_clut) +#define LEO_SETGAMMA _IOW('L', 68, int) /* Not yet implemented */ +#define LEO_GETGAMMA _IOR('L', 69, int) /* Not yet implemented */ + +#ifdef __KERNEL__ +/* Addresses on the fd of a cgsix that are mappable */ +#define CG6_FBC 0x70000000 +#define CG6_TEC 0x70001000 +#define CG6_BTREGS 0x70002000 +#define CG6_FHC 0x70004000 +#define CG6_THC 0x70005000 +#define CG6_ROM 0x70006000 +#define CG6_RAM 0x70016000 +#define CG6_DHC 0x80000000 + +#define CG3_MMAP_OFFSET 0x4000000 + +/* Addresses on the fd of a tcx that are mappable */ +#define TCX_RAM8BIT 0x00000000 +#define TCX_RAM24BIT 0x01000000 +#define TCX_UNK3 0x10000000 +#define TCX_UNK4 0x20000000 +#define TCX_CONTROLPLANE 0x28000000 +#define TCX_UNK6 0x30000000 +#define TCX_UNK7 0x38000000 +#define TCX_TEC 0x70000000 +#define TCX_BTREGS 0x70002000 +#define TCX_THC 0x70004000 +#define TCX_DHC 0x70008000 +#define TCX_ALT 0x7000a000 +#define TCX_SYNC 0x7000e000 +#define TCX_UNK2 0x70010000 + +/* CG14 definitions */ + +/* Offsets into the OBIO space: */ +#define CG14_REGS 0 /* registers */ +#define CG14_CURSORREGS 0x1000 /* cursor registers */ +#define CG14_DACREGS 0x2000 /* DAC registers */ +#define CG14_XLUT 0x3000 /* X Look Up Table -- ??? */ +#define CG14_CLUT1 0x4000 /* Color Look Up Table */ +#define CG14_CLUT2 0x5000 /* Color Look Up Table */ +#define CG14_CLUT3 0x6000 /* Color Look Up Table */ +#define CG14_AUTO 0xf000 + +#endif /* KERNEL */ + +/* These are exported to userland for applications to use */ +/* Mappable offsets for the cg14: control registers */ +#define MDI_DIRECT_MAP 0x10000000 +#define MDI_CTLREG_MAP 0x20000000 +#define MDI_CURSOR_MAP 0x30000000 +#define MDI_SHDW_VRT_MAP 0x40000000 + +/* Mappable offsets for the cg14: frame buffer resolutions */ +/* 32 bits */ +#define MDI_CHUNKY_XBGR_MAP 0x50000000 +#define MDI_CHUNKY_BGR_MAP 0x60000000 + +/* 16 bits */ +#define MDI_PLANAR_X16_MAP 0x70000000 +#define MDI_PLANAR_C16_MAP 0x80000000 + +/* 8 bit is done as CG3 MMAP offset */ +/* 32 bits, planar */ +#define MDI_PLANAR_X32_MAP 0x90000000 +#define MDI_PLANAR_B32_MAP 0xa0000000 +#define MDI_PLANAR_G32_MAP 0xb0000000 +#define MDI_PLANAR_R32_MAP 0xc0000000 + +/* Mappable offsets on leo */ +#define LEO_SS0_MAP 0x00000000 +#define LEO_LC_SS0_USR_MAP 0x00800000 +#define LEO_LD_SS0_MAP 0x00801000 +#define LEO_LX_CURSOR_MAP 0x00802000 +#define LEO_SS1_MAP 0x00803000 +#define LEO_LC_SS1_USR_MAP 0x01003000 +#define LEO_LD_SS1_MAP 0x01004000 +#define LEO_UNK_MAP 0x01005000 +#define LEO_LX_KRN_MAP 0x01006000 +#define LEO_LC_SS0_KRN_MAP 0x01007000 +#define LEO_LC_SS1_KRN_MAP 0x01008000 +#define LEO_LD_GBL_MAP 0x01009000 +#define LEO_UNK2_MAP 0x0100a000 + +#ifdef __KERNEL__ +struct fbcmap32 { + int index; /* first element (0 origin) */ + int count; + u32 red; + u32 green; + u32 blue; +}; + +#define FBIOPUTCMAP32 _IOW('F', 3, struct fbcmap32) +#define FBIOGETCMAP32 _IOW('F', 4, struct fbcmap32) + +struct fbcursor32 { + short set; /* what to set, choose from the list above */ + short enable; /* cursor on/off */ + struct fbcurpos pos; /* cursor position */ + struct fbcurpos hot; /* cursor hot spot */ + struct fbcmap32 cmap; /* color map info */ + struct fbcurpos size; /* cursor bit map size */ + u32 image; /* cursor image bits */ + u32 mask; /* cursor mask bits */ +}; + +#define FBIOSCURSOR32 _IOW('F', 24, struct fbcursor32) +#define FBIOGCURSOR32 _IOW('F', 25, struct fbcursor32) +#endif + +#endif /* __LINUX_FBIO_H */ diff --git a/include/asm-m68k/idprom.h b/include/asm-m68k/idprom.h index 4349eaf3cfe4..160616a89e05 100644 --- a/include/asm-m68k/idprom.h +++ b/include/asm-m68k/idprom.h @@ -1,6 +1,25 @@ #ifndef _M68K_IDPROM_H #define _M68K_IDPROM_H -#include <asm-sparc/idprom.h> +/* + * idprom.h: Macros and defines for idprom routines + * + * Copyright (C) 1995,1996 David S. Miller (davem@caip.rutgers.edu) + */ + +#include <linux/types.h> + +struct idprom { + u8 id_format; /* Format identifier (always 0x01) */ + u8 id_machtype; /* Machine type */ + u8 id_ethaddr[6]; /* Hardware ethernet address */ + s32 id_date; /* Date of manufacture */ + u32 id_sernum:24; /* Unique serial number */ + u8 id_cksum; /* Checksum - xor of the data bytes */ + u8 reserved[16]; +}; + +extern struct idprom *idprom; +extern void idprom_init(void); /* Sun3: in control space */ #define SUN3_IDPROM_BASE 0x00000000 diff --git a/include/linux/ihex.h b/include/linux/ihex.h index 2baace2788a7..31d8629e75a1 100644 --- a/include/linux/ihex.h +++ b/include/linux/ihex.h @@ -18,7 +18,7 @@ struct ihex_binrec { __be32 addr; __be16 len; uint8_t data[0]; -} __attribute__((aligned(4))); +} __attribute__((packed)); /* Find the next record, taking into account the 4-byte alignment */ static inline const struct ihex_binrec * diff --git a/include/linux/mISDNif.h b/include/linux/mISDNif.h index 5c948f337817..8f2d60da04e7 100644 --- a/include/linux/mISDNif.h +++ b/include/linux/mISDNif.h @@ -37,7 +37,7 @@ */ #define MISDN_MAJOR_VERSION 1 #define MISDN_MINOR_VERSION 0 -#define MISDN_RELEASE 18 +#define MISDN_RELEASE 19 /* primitives for information exchange * generell format @@ -242,7 +242,8 @@ struct mISDNhead { #define TEI_SAPI 63 #define CTRL_SAPI 0 -#define MISDN_CHMAP_SIZE 4 +#define MISDN_MAX_CHANNEL 127 +#define MISDN_CHMAP_SIZE ((MISDN_MAX_CHANNEL + 1) >> 3) #define SOL_MISDN 0 @@ -275,11 +276,32 @@ struct mISDN_devinfo { u_int Dprotocols; u_int Bprotocols; u_int protocol; - u_long channelmap[MISDN_CHMAP_SIZE]; + u_char channelmap[MISDN_CHMAP_SIZE]; u_int nrbchan; char name[MISDN_MAX_IDLEN]; }; +static inline int +test_channelmap(u_int nr, u_char *map) +{ + if (nr <= MISDN_MAX_CHANNEL) + return map[nr >> 3] & (1 << (nr & 7)); + else + return 0; +} + +static inline void +set_channelmap(u_int nr, u_char *map) +{ + map[nr >> 3] |= (1 << (nr & 7)); +} + +static inline void +clear_channelmap(u_int nr, u_char *map) +{ + map[nr >> 3] &= ~(1 << (nr & 7)); +} + /* CONTROL_CHANNEL parameters */ #define MISDN_CTRL_GETOP 0x0000 #define MISDN_CTRL_LOOP 0x0001 @@ -405,7 +427,7 @@ struct mISDNdevice { u_int Dprotocols; u_int Bprotocols; u_int nrbchan; - u_long channelmap[MISDN_CHMAP_SIZE]; + u_char channelmap[MISDN_CHMAP_SIZE]; struct list_head bchannels; struct mISDNchannel *teimgr; struct device dev; @@ -430,7 +452,7 @@ struct mISDNstack { #endif }; -/* global alloc/queue dunctions */ +/* global alloc/queue functions */ static inline struct sk_buff * mI_alloc_skb(unsigned int len, gfp_t gfp_mask) diff --git a/include/linux/maple.h b/include/linux/maple.h index c853b1066018..c23d3f51ba40 100644 --- a/include/linux/maple.h +++ b/include/linux/maple.h @@ -51,7 +51,6 @@ struct maple_devinfo { struct maple_device { struct maple_driver *driver; struct mapleq *mq; - void *private_data; void (*callback) (struct mapleq * mq); unsigned long when, interval, function; struct maple_devinfo devinfo; @@ -70,7 +69,9 @@ void maple_getcond_callback(struct maple_device *dev, void (*callback) (struct mapleq * mq), unsigned long interval, unsigned long function); -int maple_driver_register(struct device_driver *drv); +int maple_driver_register(struct maple_driver *); +void maple_driver_unregister(struct maple_driver *); + int maple_add_packet_sleeps(struct maple_device *mdev, u32 function, u32 command, u32 length, void *data); void maple_clear_dev(struct maple_device *mdev); @@ -78,4 +79,7 @@ void maple_clear_dev(struct maple_device *mdev); #define to_maple_dev(n) container_of(n, struct maple_device, dev) #define to_maple_driver(n) container_of(n, struct maple_driver, drv) +#define maple_get_drvdata(d) dev_get_drvdata(&(d)->dev) +#define maple_set_drvdata(d,p) dev_set_drvdata(&(d)->dev, (p)) + #endif /* __LINUX_MAPLE_H */ diff --git a/include/linux/parser.h b/include/linux/parser.h index cc554ca8bc78..7dcd05075756 100644 --- a/include/linux/parser.h +++ b/include/linux/parser.h @@ -14,7 +14,7 @@ struct match_token { const char *pattern; }; -typedef const struct match_token match_table_t[]; +typedef struct match_token match_table_t[]; /* Maximum number of arguments that match_token will find in a pattern */ enum {MAX_OPT_ARGS = 3}; diff --git a/include/linux/tracehook.h b/include/linux/tracehook.h index 12532839f508..ab3ef7aefa95 100644 --- a/include/linux/tracehook.h +++ b/include/linux/tracehook.h @@ -487,6 +487,9 @@ static inline int tracehook_notify_jctl(int notify, int why) return notify || (current->ptrace & PT_PTRACED); } +#define DEATH_REAP -1 +#define DEATH_DELAYED_GROUP_LEADER -2 + /** * tracehook_notify_death - task is dead, ready to notify parent * @task: @current task now exiting @@ -501,8 +504,6 @@ static inline int tracehook_notify_jctl(int notify, int why) * * Called with write_lock_irq(&tasklist_lock) held. */ -#define DEATH_REAP -1 -#define DEATH_DELAYED_GROUP_LEADER -2 static inline int tracehook_notify_death(struct task_struct *task, void **death_cookie, int group_dead) { diff --git a/include/linux/vt_kern.h b/include/linux/vt_kern.h index 8c8119ffee12..1c78d56c57e5 100644 --- a/include/linux/vt_kern.h +++ b/include/linux/vt_kern.h @@ -86,6 +86,7 @@ int con_copy_unimap(struct vc_data *dst_vc, struct vc_data *src_vc); #define con_copy_unimap(d, s) (0) #define con_get_unimap(vc, ct, uct, list) (-EINVAL) #define con_free_unimap(vc) do { ; } while (0) +#define con_protect_unimap(vc, rdonly) do { ; } while (0) #define vc_translate(vc, c) (c) #endif diff --git a/include/scsi/scsi_device.h b/include/scsi/scsi_device.h index 291d56a19167..9cecc409f0f8 100644 --- a/include/scsi/scsi_device.h +++ b/include/scsi/scsi_device.h @@ -140,8 +140,7 @@ struct scsi_device { unsigned fix_capacity:1; /* READ_CAPACITY is too high by 1 */ unsigned guess_capacity:1; /* READ_CAPACITY might be too high by 1 */ unsigned retry_hwerror:1; /* Retry HARDWARE_ERROR */ - unsigned last_sector_bug:1; /* do not use multisector accesses on - SD_LAST_BUGGY_SECTORS */ + unsigned last_sector_bug:1; /* Always read last sector in a 1 sector read */ DECLARE_BITMAP(supported_events, SDEV_EVT_MAXBITS); /* supported events */ struct list_head event_list; /* asserted events */ diff --git a/kernel/auditsc.c b/kernel/auditsc.c index 496c3dd37276..972f8e61d36a 100644 --- a/kernel/auditsc.c +++ b/kernel/auditsc.c @@ -243,6 +243,9 @@ static inline int open_arg(int flags, int mask) static int audit_match_perm(struct audit_context *ctx, int mask) { + if (unlikely(!ctx)) + return 0; + unsigned n = ctx->major; switch (audit_classify_syscall(ctx->arch, n)) { case 0: /* native */ @@ -284,6 +287,10 @@ static int audit_match_filetype(struct audit_context *ctx, int which) { unsigned index = which & ~S_IFMT; mode_t mode = which & S_IFMT; + + if (unlikely(!ctx)) + return 0; + if (index >= ctx->name_count) return 0; if (ctx->names[index].ino == -1) diff --git a/kernel/sched.c b/kernel/sched.c index 21f7da94662e..04160d277e7a 100644 --- a/kernel/sched.c +++ b/kernel/sched.c @@ -5004,19 +5004,21 @@ recheck: return -EPERM; } + if (user) { #ifdef CONFIG_RT_GROUP_SCHED - /* - * Do not allow realtime tasks into groups that have no runtime - * assigned. - */ - if (user - && rt_policy(policy) && task_group(p)->rt_bandwidth.rt_runtime == 0) - return -EPERM; + /* + * Do not allow realtime tasks into groups that have no runtime + * assigned. + */ + if (rt_policy(policy) && task_group(p)->rt_bandwidth.rt_runtime == 0) + return -EPERM; #endif - retval = security_task_setscheduler(p, policy, param); - if (retval) - return retval; + retval = security_task_setscheduler(p, policy, param); + if (retval) + return retval; + } + /* * make sure no PI-waiters arrive (or leave) while we are * changing the priority of the task: diff --git a/mm/memory.c b/mm/memory.c index 6793b9c68107..a472bcd4b061 100644 --- a/mm/memory.c +++ b/mm/memory.c @@ -2765,16 +2765,26 @@ int make_pages_present(unsigned long addr, unsigned long end) vma = find_vma(current->mm, addr); if (!vma) - return -1; + return -ENOMEM; write = (vma->vm_flags & VM_WRITE) != 0; BUG_ON(addr >= end); BUG_ON(end > vma->vm_end); len = DIV_ROUND_UP(end, PAGE_SIZE) - addr/PAGE_SIZE; ret = get_user_pages(current, current->mm, addr, len, write, 0, NULL, NULL); - if (ret < 0) + if (ret < 0) { + /* + SUS require strange return value to mlock + - invalid addr generate to ENOMEM. + - out of memory should generate EAGAIN. + */ + if (ret == -EFAULT) + ret = -ENOMEM; + else if (ret == -ENOMEM) + ret = -EAGAIN; return ret; - return ret == len ? 0 : -1; + } + return ret == len ? 0 : -ENOMEM; } #if !defined(__HAVE_ARCH_GATE_AREA) diff --git a/mm/mlock.c b/mm/mlock.c index 7b2656055d6a..01fbe93eff5c 100644 --- a/mm/mlock.c +++ b/mm/mlock.c @@ -78,8 +78,6 @@ success: mm->locked_vm -= pages; out: - if (ret == -ENOMEM) - ret = -EAGAIN; return ret; } diff --git a/mm/nommu.c b/mm/nommu.c index 5edccd9c9218..ed75bc962fbe 100644 --- a/mm/nommu.c +++ b/mm/nommu.c @@ -266,6 +266,27 @@ void *vmalloc_node(unsigned long size, int node) } EXPORT_SYMBOL(vmalloc_node); +#ifndef PAGE_KERNEL_EXEC +# define PAGE_KERNEL_EXEC PAGE_KERNEL +#endif + +/** + * vmalloc_exec - allocate virtually contiguous, executable memory + * @size: allocation size + * + * Kernel-internal function to allocate enough pages to cover @size + * the page level allocator and map them into contiguous and + * executable kernel virtual space. + * + * For tight control over page level allocator and protection flags + * use __vmalloc() instead. + */ + +void *vmalloc_exec(unsigned long size) +{ + return __vmalloc(size, GFP_KERNEL | __GFP_HIGHMEM, PAGE_KERNEL_EXEC); +} + /** * vmalloc_32 - allocate virtually contiguous memory (32bit addressable) * @size: allocation size diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c index 9fba838c7069..36b5eedcdc75 100644 --- a/scripts/kconfig/conf.c +++ b/scripts/kconfig/conf.c @@ -596,7 +596,7 @@ int main(int ac, char **av) break; } - if (conf_get_changed() && conf_write(NULL)) { + if (conf_write(NULL)) { fprintf(stderr, _("\n*** Error during writing of the kernel configuration.\n\n")); exit(1); } diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c index 07597611cc50..df6a188b9930 100644 --- a/scripts/kconfig/confdata.c +++ b/scripts/kconfig/confdata.c @@ -222,10 +222,8 @@ load: continue; if (def == S_DEF_USER) { sym = sym_find(line + 9); - if (!sym) { - conf_warning("trying to assign nonexistent symbol %s", line + 9); + if (!sym) break; - } } else { sym = sym_lookup(line + 9, 0); if (sym->type == S_UNKNOWN) @@ -261,10 +259,8 @@ load: } if (def == S_DEF_USER) { sym = sym_find(line + 7); - if (!sym) { - conf_warning("trying to assign nonexistent symbol %s", line + 7); + if (!sym) break; - } } else { sym = sym_lookup(line + 7, 0); if (sym->type == S_UNKNOWN) diff --git a/sound/core/seq/oss/seq_oss_synth.c b/sound/core/seq/oss/seq_oss_synth.c index 558dadbf45f1..e024e4588b82 100644 --- a/sound/core/seq/oss/seq_oss_synth.c +++ b/sound/core/seq/oss/seq_oss_synth.c @@ -604,6 +604,9 @@ snd_seq_oss_synth_make_info(struct seq_oss_devinfo *dp, int dev, struct synth_in { struct seq_oss_synth *rec; + if (dev < 0 || dev >= dp->max_synthdev) + return -ENXIO; + if (dp->synths[dev].is_midi) { struct midi_info minf; snd_seq_oss_midi_make_info(dp, dp->synths[dev].midi_mapped, &minf); |