]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
Merge branch 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6
authorLinus Torvalds <torvalds@g5.osdl.org>
Thu, 29 Jun 2006 18:01:17 +0000 (11:01 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Thu, 29 Jun 2006 18:01:17 +0000 (11:01 -0700)
* 'for-linus' of git://git390.osdl.marist.edu/pub/scm/linux-2.6: (28 commits)
  [S390] rework of channel measurement facility.
  [S390] appldata enhancements.
  [S390] Add vmpanic parameter.
  [S390] add PAV support to the dasd driver.
  [S390] remove export of sys_call_table
  [S390] remove unused macros from binfmt_elf32.c
  [S390] fix duplicate export of overflow{ug}id
  [S390] cio chpid offline.
  [S390] avenrun export in appdata_base.c
  Convert s390_collect_crw_info() in s390mach.c from being started
  [S390] dasd eer data format.
  [S390] preempt_count initialization.
  [S390] head.S code moving.
  [S390] dasd whitespace and other cosmetics.
  [S390] virtual cpu accounting vs. machine checks.
  [S390] add __cpuinit to appldata cpu hotplug notifier.
  [S390] dasd_eckd_dump_sense bug.
  [S390] missing check in dasd_eer_open.
  [S390] modular 3270 driver.
  [S390] console_unblank woes.
  ...

321 files changed:
Documentation/DocBook/Makefile
Documentation/DocBook/genericirq.tmpl [new file with mode: 0644]
Documentation/IRQ.txt [new file with mode: 0644]
Documentation/keys-request-key.txt
Documentation/keys.txt
arch/alpha/kernel/irq.c
arch/alpha/kernel/irq_alpha.c
arch/alpha/kernel/irq_i8259.c
arch/alpha/kernel/irq_pyxis.c
arch/alpha/kernel/irq_srm.c
arch/alpha/kernel/pci.c
arch/alpha/kernel/sys_alcor.c
arch/alpha/kernel/sys_cabriolet.c
arch/alpha/kernel/sys_dp264.c
arch/alpha/kernel/sys_eb64p.c
arch/alpha/kernel/sys_eiger.c
arch/alpha/kernel/sys_jensen.c
arch/alpha/kernel/sys_marvel.c
arch/alpha/kernel/sys_mikasa.c
arch/alpha/kernel/sys_noritake.c
arch/alpha/kernel/sys_rawhide.c
arch/alpha/kernel/sys_rx164.c
arch/alpha/kernel/sys_sable.c
arch/alpha/kernel/sys_takara.c
arch/alpha/kernel/sys_titan.c
arch/alpha/kernel/sys_wildfire.c
arch/arm/kernel/bios32.c
arch/arm/kernel/setup.c
arch/cris/Kconfig
arch/cris/arch-v10/kernel/irq.c
arch/cris/arch-v32/drivers/pci/bios.c
arch/cris/arch-v32/kernel/irq.c
arch/cris/kernel/irq.c
arch/frv/mb93090-mb00/pci-frv.c
arch/i386/Kconfig
arch/i386/kernel/efi.c
arch/i386/kernel/i8259.c
arch/i386/kernel/io_apic.c
arch/i386/kernel/irq.c
arch/i386/kernel/setup.c
arch/i386/mach-visws/setup.c
arch/i386/mach-visws/visws_apic.c
arch/i386/mach-voyager/voyager_smp.c
arch/i386/pci/i386.c
arch/ia64/Kconfig
arch/ia64/hp/sim/hpsim_irq.c
arch/ia64/kernel/iosapic.c
arch/ia64/kernel/irq.c
arch/ia64/kernel/irq_ia64.c
arch/ia64/kernel/irq_lsapic.c
arch/ia64/kernel/mca.c
arch/ia64/kernel/perfmon.c
arch/ia64/kernel/smpboot.c
arch/ia64/pci/pci.c
arch/ia64/sn/kernel/irq.c
arch/m32r/kernel/irq.c
arch/m32r/kernel/setup_m32104ut.c
arch/m32r/kernel/setup_m32700ut.c
arch/m32r/kernel/setup_mappi.c
arch/m32r/kernel/setup_mappi2.c
arch/m32r/kernel/setup_mappi3.c
arch/m32r/kernel/setup_oaks32r.c
arch/m32r/kernel/setup_opsput.c
arch/m32r/kernel/setup_usrv.c
arch/m68knommu/kernel/comempci.c
arch/mips/Kconfig
arch/mips/au1000/common/irq.c
arch/mips/au1000/pb1200/irqmap.c
arch/mips/ddb5xxx/ddb5477/irq_5477.c
arch/mips/dec/ioasic-irq.c
arch/mips/dec/kn02-irq.c
arch/mips/gt64120/ev64120/irq.c
arch/mips/ite-boards/generic/irq.c
arch/mips/jazz/irq.c
arch/mips/jmr3927/rbhma3100/irq.c
arch/mips/kernel/i8259.c
arch/mips/kernel/irq-msc01.c
arch/mips/kernel/irq-mv6434x.c
arch/mips/kernel/irq-rm7000.c
arch/mips/kernel/irq-rm9000.c
arch/mips/kernel/irq.c
arch/mips/kernel/irq_cpu.c
arch/mips/lasat/interrupt.c
arch/mips/mips-boards/atlas/atlas_int.c
arch/mips/momentum/ocelot_c/cpci-irq.c
arch/mips/momentum/ocelot_c/uart-irq.c
arch/mips/pci/pci.c
arch/mips/philips/pnx8550/common/int.c
arch/mips/pmc-sierra/yosemite/ht.c
arch/mips/sgi-ip22/ip22-eisa.c
arch/mips/sgi-ip22/ip22-int.c
arch/mips/sgi-ip27/ip27-irq.c
arch/mips/sgi-ip32/ip32-irq.c
arch/mips/sibyte/bcm1480/irq.c
arch/mips/sibyte/sb1250/irq.c
arch/mips/sni/irq.c
arch/mips/tx4927/common/tx4927_irq.c
arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_irq.c
arch/mips/tx4938/common/irq.c
arch/mips/tx4938/toshiba_rbtx4938/irq.c
arch/mips/vr41xx/common/icu.c
arch/mips/vr41xx/common/irq.c
arch/mips/vr41xx/common/vrc4173.c
arch/mips/vr41xx/nec-cmbvr4133/irq.c
arch/parisc/Kconfig
arch/parisc/kernel/irq.c
arch/parisc/kernel/pci.c
arch/powerpc/Kconfig
arch/powerpc/kernel/crash.c
arch/powerpc/kernel/irq.c
arch/powerpc/kernel/pci_32.c
arch/powerpc/kernel/pci_64.c
arch/powerpc/platforms/83xx/pci.c
arch/powerpc/platforms/85xx/pci.c
arch/powerpc/platforms/cell/interrupt.c
arch/powerpc/platforms/cell/spider-pic.c
arch/powerpc/platforms/chrp/pci.c
arch/powerpc/platforms/iseries/irq.c
arch/powerpc/platforms/maple/pci.c
arch/powerpc/platforms/powermac/pci.c
arch/powerpc/platforms/powermac/pic.c
arch/powerpc/platforms/pseries/xics.c
arch/powerpc/sysdev/i8259.c
arch/powerpc/sysdev/ipic.c
arch/powerpc/sysdev/mpic.c
arch/ppc/8xx_io/commproc.c
arch/ppc/kernel/pci.c
arch/ppc/platforms/apus_setup.c
arch/ppc/platforms/sbc82xx.c
arch/ppc/syslib/cpc700_pic.c
arch/ppc/syslib/cpm2_pic.c
arch/ppc/syslib/gt64260_pic.c
arch/ppc/syslib/m82xx_pci.c
arch/ppc/syslib/m8xx_setup.c
arch/ppc/syslib/mpc52xx_pic.c
arch/ppc/syslib/mv64360_pic.c
arch/ppc/syslib/open_pic.c
arch/ppc/syslib/open_pic2.c
arch/ppc/syslib/ppc403_pic.c
arch/ppc/syslib/ppc4xx_pic.c
arch/ppc/syslib/xilinx_pic.c
arch/sh/boards/adx/irq_maskreg.c
arch/sh/boards/bigsur/irq.c
arch/sh/boards/cqreek/irq.c
arch/sh/boards/dreamcast/setup.c
arch/sh/boards/ec3104/setup.c
arch/sh/boards/harp/irq.c
arch/sh/boards/mpc1211/pci.c
arch/sh/boards/mpc1211/setup.c
arch/sh/boards/overdrive/galileo.c
arch/sh/boards/overdrive/irq.c
arch/sh/boards/renesas/hs7751rvoip/irq.c
arch/sh/boards/renesas/rts7751r2d/irq.c
arch/sh/boards/renesas/systemh/irq.c
arch/sh/boards/se/73180/irq.c
arch/sh/boards/superh/microdev/irq.c
arch/sh/cchips/hd6446x/hd64461/setup.c
arch/sh/cchips/hd6446x/hd64465/setup.c
arch/sh/cchips/voyagergx/irq.c
arch/sh/drivers/pci/pci.c
arch/sh/kernel/cpu/irq/imask.c
arch/sh/kernel/cpu/irq/intc2.c
arch/sh/kernel/cpu/irq/ipr.c
arch/sh/kernel/cpu/irq/pint.c
arch/sh/kernel/irq.c
arch/sh64/kernel/irq.c
arch/sh64/kernel/irq_intc.c
arch/sh64/kernel/pcibios.c
arch/sh64/mach-cayman/irq.c
arch/sparc/kernel/ioport.c
arch/sparc/kernel/pcic.c
arch/sparc/kernel/setup.c
arch/sparc64/kernel/irq.c
arch/sparc64/kernel/pci.c
arch/um/kernel/irq.c
arch/v850/kernel/irq.c
arch/v850/kernel/rte_mb_a_pci.c
arch/x86_64/Kconfig
arch/x86_64/kernel/i8259.c
arch/x86_64/kernel/io_apic.c
arch/x86_64/kernel/irq.c
arch/xtensa/kernel/irq.c
arch/xtensa/kernel/pci.c
drivers/amba/bus.c
drivers/atm/ambassador.c
drivers/atm/firestream.c
drivers/block/paride/pf.c
drivers/block/sx8.c
drivers/char/Kconfig
drivers/char/applicom.c
drivers/char/vr41xx_giu.c
drivers/ide/pci/aec62xx.c
drivers/ide/pci/hpt34x.c
drivers/ide/pci/pdc202xx_new.c
drivers/ide/pci/pdc202xx_old.c
drivers/ieee1394/ohci1394.c
drivers/infiniband/hw/ipath/ipath_driver.c
drivers/infiniband/hw/mthca/mthca_main.c
drivers/input/serio/ct82c710.c
drivers/isdn/hisax/hfc_pci.c
drivers/isdn/hisax/telespci.c
drivers/isdn/i4l/isdn_x25iface.c
drivers/macintosh/macio_asic.c
drivers/md/raid5.c
drivers/media/video/bt8xx/bttv-driver.c
drivers/media/video/cx88/cx88-alsa.c
drivers/media/video/cx88/cx88-core.c
drivers/media/video/cx88/cx88-mpeg.c
drivers/media/video/cx88/cx88-video.c
drivers/media/video/saa7134/saa7134-core.c
drivers/message/i2o/iop.c
drivers/mmc/mmci.c
drivers/mtd/devices/pmc551.c
drivers/mtd/maps/amd76xrom.c
drivers/mtd/maps/ichxrom.c
drivers/mtd/maps/scx200_docflash.c
drivers/mtd/maps/sun_uflash.c
drivers/net/3c59x.c
drivers/net/8139cp.c
drivers/net/8139too.c
drivers/net/e100.c
drivers/net/skge.c
drivers/net/sky2.c
drivers/net/tulip/de2104x.c
drivers/net/tulip/tulip_core.c
drivers/net/typhoon.c
drivers/net/wan/dscc4.c
drivers/net/wan/pc300_drv.c
drivers/parisc/dino.c
drivers/parisc/eisa.c
drivers/parisc/gsc.c
drivers/parisc/iosapic.c
drivers/parisc/superio.c
drivers/pci/bus.c
drivers/pci/hotplug/cpcihp_zt5550.c
drivers/pci/hotplug/cpqphp_core.c
drivers/pci/hotplug/pciehp_hpc.c
drivers/pci/hotplug/shpchp_sysfs.c
drivers/pci/msi.c
drivers/pci/pci-sysfs.c
drivers/pci/pci.c
drivers/pci/pci.h
drivers/pci/proc.c
drivers/pci/rom.c
drivers/pci/setup-bus.c
drivers/pci/setup-res.c
drivers/pcmcia/hd64465_ss.c
drivers/pcmcia/i82365.c
drivers/pcmcia/pd6729.c
drivers/pcmcia/rsrc_nonstatic.c
drivers/pcmcia/tcic.c
drivers/pnp/interface.c
drivers/pnp/manager.c
drivers/pnp/resource.c
drivers/scsi/sata_via.c
drivers/serial/8250_pci.c
drivers/sn/ioc4.c
drivers/usb/host/sl811-hcd.c
drivers/video/console/vgacon.c
drivers/video/sgivwfb.c
fs/ufs/inode.c
include/asm-alpha/hw_irq.h
include/asm-arm/mach/pci.h
include/asm-cris/hw_irq.h
include/asm-cris/irq.h
include/asm-i386/hw_irq.h
include/asm-i386/mach-visws/setup_arch.h
include/asm-ia64/hw_irq.h
include/asm-ia64/irq.h
include/asm-m32r/hw_irq.h
include/asm-mips/hw_irq.h
include/asm-mips/mach-mips/irq.h
include/asm-parisc/hw_irq.h
include/asm-parisc/irq.h
include/asm-powerpc/hw_irq.h
include/asm-powerpc/irq.h
include/asm-powerpc/pci.h
include/asm-ppc/pci.h
include/asm-sh/hw_irq.h
include/asm-sh64/hw_irq.h
include/asm-um/hw_irq.h
include/asm-v850/hw_irq.h
include/asm-x86_64/hw_irq.h
include/asm-xtensa/hw_irq.h
include/linux/interrupt.h
include/linux/ioport.h
include/linux/irq.h
include/linux/isdn/tpam.h [deleted file]
include/linux/key.h
include/linux/pci.h
include/linux/pnp.h
include/linux/types.h
kernel/irq/Makefile
kernel/irq/autoprobe.c
kernel/irq/chip.c [new file with mode: 0644]
kernel/irq/handle.c
kernel/irq/internals.h
kernel/irq/manage.c
kernel/irq/migration.c
kernel/irq/proc.c
kernel/irq/resend.c [new file with mode: 0644]
kernel/irq/spurious.c
kernel/resource.c
mm/Kconfig
mm/filemap.c
mm/filemap.h
security/keys/internal.h
security/keys/keyctl.c
security/keys/request_key.c
sound/arm/aaci.c
sound/drivers/mpu401/mpu401.c
sound/isa/es18xx.c
sound/isa/gus/interwave.c
sound/isa/sb/sb16.c
sound/oss/Kconfig
sound/oss/forte.c
sound/pci/bt87x.c
sound/pci/sonicvibes.c
sound/ppc/pmac.c
sound/sparc/cs4231.c
sound/sparc/dbri.c

index 5a2882d275ba5b3beabb305c62a22f38aa5cff44..66e1cf733571ccc4122dcc745bf9c713ee6559b6 100644 (file)
@@ -10,7 +10,8 @@ DOCBOOKS := wanbook.xml z8530book.xml mcabook.xml videobook.xml \
            kernel-hacking.xml kernel-locking.xml deviceiobook.xml \
            procfs-guide.xml writing_usb_driver.xml \
            kernel-api.xml journal-api.xml lsm.xml usb.xml \
-           gadget.xml libata.xml mtdnand.xml librs.xml rapidio.xml
+           gadget.xml libata.xml mtdnand.xml librs.xml rapidio.xml \
+           genericirq.xml
 
 ###
 # The build process is as follows (targets):
diff --git a/Documentation/DocBook/genericirq.tmpl b/Documentation/DocBook/genericirq.tmpl
new file mode 100644 (file)
index 0000000..0f4a4b6
--- /dev/null
@@ -0,0 +1,474 @@
+<?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="Generic-IRQ-Guide">
+ <bookinfo>
+  <title>Linux generic IRQ handling</title>
+
+  <authorgroup>
+   <author>
+    <firstname>Thomas</firstname>
+    <surname>Gleixner</surname>
+    <affiliation>
+     <address>
+      <email>tglx@linutronix.de</email>
+     </address>
+    </affiliation>
+   </author>
+   <author>
+    <firstname>Ingo</firstname>
+    <surname>Molnar</surname>
+    <affiliation>
+     <address>
+      <email>mingo@elte.hu</email>
+     </address>
+    </affiliation>
+   </author>
+  </authorgroup>
+
+  <copyright>
+   <year>2005-2006</year>
+   <holder>Thomas Gleixner</holder>
+  </copyright>
+  <copyright>
+   <year>2005-2006</year>
+   <holder>Ingo Molnar</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="intro">
+    <title>Introduction</title>
+    <para>
+       The generic interrupt handling layer is designed to provide a
+       complete abstraction of interrupt handling for device drivers.
+       It is able to handle all the different types of interrupt controller
+       hardware. Device drivers use generic API functions to request, enable,
+       disable and free interrupts. The drivers do not have to know anything
+       about interrupt hardware details, so they can be used on different
+       platforms without code changes.
+    </para>
+    <para>
+       This documentation is provided to developers who want to implement
+       an interrupt subsystem based for their architecture, with the help
+       of the generic IRQ handling layer.
+    </para>
+  </chapter>
+
+  <chapter id="rationale">
+    <title>Rationale</title>
+       <para>
+       The original implementation of interrupt handling in Linux is using
+       the __do_IRQ() super-handler, which is able to deal with every
+       type of interrupt logic.
+       </para>
+       <para>
+       Originally, Russell King identified different types of handlers to
+       build a quite universal set for the ARM interrupt handler
+       implementation in Linux 2.5/2.6. He distinguished between:
+       <itemizedlist>
+         <listitem><para>Level type</para></listitem>
+         <listitem><para>Edge type</para></listitem>
+         <listitem><para>Simple type</para></listitem>
+       </itemizedlist>
+       In the SMP world of the __do_IRQ() super-handler another type
+       was identified:
+       <itemizedlist>
+         <listitem><para>Per CPU type</para></listitem>
+       </itemizedlist>
+       </para>
+       <para>
+       This split implementation of highlevel IRQ handlers allows us to
+       optimize the flow of the interrupt handling for each specific
+       interrupt type. This reduces complexity in that particular codepath
+       and allows the optimized handling of a given type.
+       </para>
+       <para>
+       The original general IRQ implementation used hw_interrupt_type
+       structures and their ->ack(), ->end() [etc.] callbacks to
+       differentiate the flow control in the super-handler. This leads to
+       a mix of flow logic and lowlevel hardware logic, and it also leads
+       to unnecessary code duplication: for example in i386, there is a
+       ioapic_level_irq and a ioapic_edge_irq irq-type which share many
+       of the lowlevel details but have different flow handling.
+       </para>
+       <para>
+       A more natural abstraction is the clean separation of the
+       'irq flow' and the 'chip details'.
+       </para>
+       <para>
+       Analysing a couple of architecture's IRQ subsystem implementations
+       reveals that most of them can use a generic set of 'irq flow'
+       methods and only need to add the chip level specific code.
+       The separation is also valuable for (sub)architectures
+       which need specific quirks in the irq flow itself but not in the
+       chip-details - and thus provides a more transparent IRQ subsystem
+       design.
+       </para>
+       <para>
+       Each interrupt descriptor is assigned its own highlevel flow
+       handler, which is normally one of the generic
+       implementations. (This highlevel flow handler implementation also
+       makes it simple to provide demultiplexing handlers which can be
+       found in embedded platforms on various architectures.)
+       </para>
+       <para>
+       The separation makes the generic interrupt handling layer more
+       flexible and extensible. For example, an (sub)architecture can
+       use a generic irq-flow implementation for 'level type' interrupts
+       and add a (sub)architecture specific 'edge type' implementation.
+       </para>
+       <para>
+       To make the transition to the new model easier and prevent the
+       breakage of existing implementations, the __do_IRQ() super-handler
+       is still available. This leads to a kind of duality for the time
+       being. Over time the new model should be used in more and more
+       architectures, as it enables smaller and cleaner IRQ subsystems.
+       </para>
+  </chapter>
+  <chapter id="bugs">
+    <title>Known Bugs And Assumptions</title>
+    <para>
+       None (knock on wood).
+    </para>
+  </chapter>
+
+  <chapter id="Abstraction">
+    <title>Abstraction layers</title>
+    <para>
+       There are three main levels of abstraction in the interrupt code:
+       <orderedlist>
+         <listitem><para>Highlevel driver API</para></listitem>
+         <listitem><para>Highlevel IRQ flow handlers</para></listitem>
+         <listitem><para>Chiplevel hardware encapsulation</para></listitem>
+       </orderedlist>
+    </para>
+    <sect1>
+       <title>Interrupt control flow</title>
+       <para>
+       Each interrupt is described by an interrupt descriptor structure
+       irq_desc. The interrupt is referenced by an 'unsigned int' numeric
+       value which selects the corresponding interrupt decription structure
+       in the descriptor structures array.
+       The descriptor structure contains status information and pointers
+       to the interrupt flow method and the interrupt chip structure
+       which are assigned to this interrupt.
+       </para>
+       <para>
+       Whenever an interrupt triggers, the lowlevel arch code calls into
+       the generic interrupt code by calling desc->handle_irq().
+       This highlevel IRQ handling function only uses desc->chip primitives
+       referenced by the assigned chip descriptor structure.
+       </para>
+    </sect1>
+    <sect1>
+       <title>Highlevel Driver API</title>
+       <para>
+         The highlevel Driver API consists of following functions:
+         <itemizedlist>
+         <listitem><para>request_irq()</para></listitem>
+         <listitem><para>free_irq()</para></listitem>
+         <listitem><para>disable_irq()</para></listitem>
+         <listitem><para>enable_irq()</para></listitem>
+         <listitem><para>disable_irq_nosync() (SMP only)</para></listitem>
+         <listitem><para>synchronize_irq() (SMP only)</para></listitem>
+         <listitem><para>set_irq_type()</para></listitem>
+         <listitem><para>set_irq_wake()</para></listitem>
+         <listitem><para>set_irq_data()</para></listitem>
+         <listitem><para>set_irq_chip()</para></listitem>
+         <listitem><para>set_irq_chip_data()</para></listitem>
+          </itemizedlist>
+         See the autogenerated function documentation for details.
+       </para>
+    </sect1>
+    <sect1>
+       <title>Highlevel IRQ flow handlers</title>
+       <para>
+         The generic layer provides a set of pre-defined irq-flow methods:
+         <itemizedlist>
+         <listitem><para>handle_level_irq</para></listitem>
+         <listitem><para>handle_edge_irq</para></listitem>
+         <listitem><para>handle_simple_irq</para></listitem>
+         <listitem><para>handle_percpu_irq</para></listitem>
+         </itemizedlist>
+         The interrupt flow handlers (either predefined or architecture
+         specific) are assigned to specific interrupts by the architecture
+         either during bootup or during device initialization.
+       </para>
+       <sect2>
+       <title>Default flow implementations</title>
+           <sect3>
+               <title>Helper functions</title>
+               <para>
+               The helper functions call the chip primitives and
+               are used by the default flow implementations.
+               The following helper functions are implemented (simplified excerpt):
+               <programlisting>
+default_enable(irq)
+{
+       desc->chip->unmask(irq);
+}
+
+default_disable(irq)
+{
+       if (!delay_disable(irq))
+               desc->chip->mask(irq);
+}
+
+default_ack(irq)
+{
+       chip->ack(irq);
+}
+
+default_mask_ack(irq)
+{
+       if (chip->mask_ack) {
+               chip->mask_ack(irq);
+       } else {
+               chip->mask(irq);
+               chip->ack(irq);
+       }
+}
+
+noop(irq)
+{
+}
+
+               </programlisting>
+               </para>
+           </sect3>
+       </sect2>
+       <sect2>
+       <title>Default flow handler implementations</title>
+           <sect3>
+               <title>Default Level IRQ flow handler</title>
+               <para>
+               handle_level_irq provides a generic implementation
+               for level-triggered interrupts.
+               </para>
+               <para>
+               The following control flow is implemented (simplified excerpt):
+               <programlisting>
+desc->chip->start();
+handle_IRQ_event(desc->action);
+desc->chip->end();
+               </programlisting>
+               </para>
+           </sect3>
+           <sect3>
+               <title>Default Edge IRQ flow handler</title>
+               <para>
+               handle_edge_irq provides a generic implementation
+               for edge-triggered interrupts.
+               </para>
+               <para>
+               The following control flow is implemented (simplified excerpt):
+               <programlisting>
+if (desc->status &amp; running) {
+       desc->chip->hold();
+       desc->status |= pending | masked;
+       return;
+}
+desc->chip->start();
+desc->status |= running;
+do {
+       if (desc->status &amp; masked)
+               desc->chip->enable();
+       desc-status &amp;= ~pending;
+       handle_IRQ_event(desc->action);
+} while (status &amp; pending);
+desc-status &amp;= ~running;
+desc->chip->end();
+               </programlisting>
+               </para>
+           </sect3>
+           <sect3>
+               <title>Default simple IRQ flow handler</title>
+               <para>
+               handle_simple_irq provides a generic implementation
+               for simple interrupts.
+               </para>
+               <para>
+               Note: The simple flow handler does not call any
+               handler/chip primitives.
+               </para>
+               <para>
+               The following control flow is implemented (simplified excerpt):
+               <programlisting>
+handle_IRQ_event(desc->action);
+               </programlisting>
+               </para>
+           </sect3>
+           <sect3>
+               <title>Default per CPU flow handler</title>
+               <para>
+               handle_percpu_irq provides a generic implementation
+               for per CPU interrupts.
+               </para>
+               <para>
+               Per CPU interrupts are only available on SMP and
+               the handler provides a simplified version without
+               locking.
+               </para>
+               <para>
+               The following control flow is implemented (simplified excerpt):
+               <programlisting>
+desc->chip->start();
+handle_IRQ_event(desc->action);
+desc->chip->end();
+               </programlisting>
+               </para>
+           </sect3>
+       </sect2>
+       <sect2>
+       <title>Quirks and optimizations</title>
+       <para>
+       The generic functions are intended for 'clean' architectures and chips,
+       which have no platform-specific IRQ handling quirks. If an architecture
+       needs to implement quirks on the 'flow' level then it can do so by
+       overriding the highlevel irq-flow handler.
+       </para>
+       </sect2>
+       <sect2>
+       <title>Delayed interrupt disable</title>
+       <para>
+       This per interrupt selectable feature, which was introduced by Russell
+       King in the ARM interrupt implementation, does not mask an interrupt
+       at the hardware level when disable_irq() is called. The interrupt is
+       kept enabled and is masked in the flow handler when an interrupt event
+       happens. This prevents losing edge interrupts on hardware which does
+       not store an edge interrupt event while the interrupt is disabled at
+       the hardware level. When an interrupt arrives while the IRQ_DISABLED
+       flag is set, then the interrupt is masked at the hardware level and
+       the IRQ_PENDING bit is set. When the interrupt is re-enabled by
+       enable_irq() the pending bit is checked and if it is set, the
+       interrupt is resent either via hardware or by a software resend
+       mechanism. (It's necessary to enable CONFIG_HARDIRQS_SW_RESEND when
+       you want to use the delayed interrupt disable feature and your
+       hardware is not capable of retriggering an interrupt.)
+       The delayed interrupt disable can be runtime enabled, per interrupt,
+       by setting the IRQ_DELAYED_DISABLE flag in the irq_desc status field.
+       </para>
+       </sect2>
+    </sect1>
+    <sect1>
+       <title>Chiplevel hardware encapsulation</title>
+       <para>
+       The chip level hardware descriptor structure irq_chip
+       contains all the direct chip relevant functions, which
+       can be utilized by the irq flow implementations.
+         <itemizedlist>
+         <listitem><para>ack()</para></listitem>
+         <listitem><para>mask_ack() - Optional, recommended for performance</para></listitem>
+         <listitem><para>mask()</para></listitem>
+         <listitem><para>unmask()</para></listitem>
+         <listitem><para>retrigger() - Optional</para></listitem>
+         <listitem><para>set_type() - Optional</para></listitem>
+         <listitem><para>set_wake() - Optional</para></listitem>
+         </itemizedlist>
+       These primitives are strictly intended to mean what they say: ack means
+       ACK, masking means masking of an IRQ line, etc. It is up to the flow
+       handler(s) to use these basic units of lowlevel functionality.
+       </para>
+    </sect1>
+  </chapter>
+
+  <chapter id="doirq">
+     <title>__do_IRQ entry point</title>
+     <para>
+       The original implementation __do_IRQ() is an alternative entry
+       point for all types of interrupts.
+     </para>
+     <para>
+       This handler turned out to be not suitable for all
+       interrupt hardware and was therefore reimplemented with split
+       functionality for egde/level/simple/percpu interrupts. This is not
+       only a functional optimization. It also shortens code paths for
+       interrupts.
+      </para>
+      <para>
+       To make use of the split implementation, replace the call to
+       __do_IRQ by a call to desc->chip->handle_irq() and associate
+        the appropriate handler function to desc->chip->handle_irq().
+       In most cases the generic handler implementations should
+       be sufficient.
+     </para>
+  </chapter>
+
+  <chapter id="locking">
+     <title>Locking on SMP</title>
+     <para>
+       The locking of chip registers is up to the architecture that
+       defines the chip primitives. There is a chip->lock field that can be used
+       for serialization, but the generic layer does not touch it. The per-irq
+       structure is protected via desc->lock, by the generic layer.
+     </para>
+  </chapter>
+  <chapter id="structs">
+     <title>Structures</title>
+     <para>
+     This chapter contains the autogenerated documentation of the structures which are
+     used in the generic IRQ layer.
+     </para>
+!Iinclude/linux/irq.h
+  </chapter>
+
+  <chapter id="pubfunctions">
+     <title>Public Functions Provided</title>
+     <para>
+     This chapter contains the autogenerated documentation of the kernel API functions
+      which are exported.
+     </para>
+!Ekernel/irq/manage.c
+!Ekernel/irq/chip.c
+  </chapter>
+
+  <chapter id="intfunctions">
+     <title>Internal Functions Provided</title>
+     <para>
+     This chapter contains the autogenerated documentation of the internal functions.
+     </para>
+!Ikernel/irq/handle.c
+!Ikernel/irq/chip.c
+  </chapter>
+
+  <chapter id="credits">
+     <title>Credits</title>
+       <para>
+               The following people have contributed to this document:
+               <orderedlist>
+                       <listitem><para>Thomas Gleixner<email>tglx@linutronix.de</email></para></listitem>
+                       <listitem><para>Ingo Molnar<email>mingo@elte.hu</email></para></listitem>
+               </orderedlist>
+       </para>
+  </chapter>
+</book>
diff --git a/Documentation/IRQ.txt b/Documentation/IRQ.txt
new file mode 100644 (file)
index 0000000..1011e71
--- /dev/null
@@ -0,0 +1,22 @@
+What is an IRQ?
+
+An IRQ is an interrupt request from a device.
+Currently they can come in over a pin, or over a packet.
+Several devices may be connected to the same pin thus
+sharing an IRQ.
+
+An IRQ number is a kernel identifier used to talk about a hardware
+interrupt source.  Typically this is an index into the global irq_desc
+array, but except for what linux/interrupt.h implements the details
+are architecture specific.
+
+An IRQ number is an enumeration of the possible interrupt sources on a
+machine.  Typically what is enumerated is the number of input pins on
+all of the interrupt controller in the system.  In the case of ISA
+what is enumerated are the 16 input pins on the two i8259 interrupt
+controllers.
+
+Architectures can assign additional meaning to the IRQ numbers, and
+are encouraged to in the case  where there is any manual configuration
+of the hardware involved.  The ISA IRQs are a classic example of
+assigning this kind of additional meaning.
index 22488d7911681e8b40cf43a93439f550fa0f93dc..c1f64fdf84cba2ba6a9f04fc1d5315da7a732ecc 100644 (file)
@@ -3,16 +3,23 @@
                              ===================
 
 The key request service is part of the key retention service (refer to
-Documentation/keys.txt). This document explains more fully how that the
-requesting algorithm works.
+Documentation/keys.txt).  This document explains more fully how the requesting
+algorithm works.
 
 The process starts by either the kernel requesting a service by calling
-request_key():
+request_key*():
 
        struct key *request_key(const struct key_type *type,
                                const char *description,
                                const char *callout_string);
 
+or:
+
+       struct key *request_key_with_auxdata(const struct key_type *type,
+                                            const char *description,
+                                            const char *callout_string,
+                                            void *aux);
+
 Or by userspace invoking the request_key system call:
 
        key_serial_t request_key(const char *type,
@@ -20,16 +27,26 @@ Or by userspace invoking the request_key system call:
                                 const char *callout_info,
                                 key_serial_t dest_keyring);
 
-The main difference between the two access points is that the in-kernel
-interface does not need to link the key to a keyring to prevent it from being
-immediately destroyed. The kernel interface returns a pointer directly to the
-key, and it's up to the caller to destroy the key.
+The main difference between the access points is that the in-kernel interface
+does not need to link the key to a keyring to prevent it from being immediately
+destroyed.  The kernel interface returns a pointer directly to the key, and
+it's up to the caller to destroy the key.
+
+The request_key_with_auxdata() call is like the in-kernel request_key() call,
+except that it permits auxiliary data to be passed to the upcaller (the default
+is NULL).  This is only useful for those key types that define their own upcall
+mechanism rather than using /sbin/request-key.
 
 The userspace interface links the key to a keyring associated with the process
 to prevent the key from going away, and returns the serial number of the key to
 the caller.
 
 
+The following example assumes that the key types involved don't define their
+own upcall mechanisms.  If they do, then those should be substituted for the
+forking and execution of /sbin/request-key.
+
+
 ===========
 THE PROCESS
 ===========
@@ -40,8 +57,8 @@ A request proceeds in the following manner:
      interface].
 
  (2) request_key() searches the process's subscribed keyrings to see if there's
-     a suitable key there. If there is, it returns the key. If there isn't, and
-     callout_info is not set, an error is returned. Otherwise the process
+     a suitable key there.  If there is, it returns the key.  If there isn't,
+     and callout_info is not set, an error is returned.  Otherwise the process
      proceeds to the next step.
 
  (3) request_key() sees that A doesn't have the desired key yet, so it creates
@@ -62,7 +79,7 @@ A request proceeds in the following manner:
      instantiation.
 
  (7) The program may want to access another key from A's context (say a
-     Kerberos TGT key). It just requests the appropriate key, and the keyring
+     Kerberos TGT key).  It just requests the appropriate key, and the keyring
      search notes that the session keyring has auth key V in its bottom level.
 
      This will permit it to then search the keyrings of process A with the
@@ -79,10 +96,11 @@ A request proceeds in the following manner:
 (10) The program then exits 0 and request_key() deletes key V and returns key
      U to the caller.
 
-This also extends further. If key W (step 7 above) didn't exist, key W would be
-created uninstantiated, another auth key (X) would be created (as per step 3)
-and another copy of /sbin/request-key spawned (as per step 4); but the context
-specified by auth key X will still be process A, as it was in auth key V.
+This also extends further.  If key W (step 7 above) didn't exist, key W would
+be created uninstantiated, another auth key (X) would be created (as per step
+3) and another copy of /sbin/request-key spawned (as per step 4); but the
+context specified by auth key X will still be process A, as it was in auth key
+V.
 
 This is because process A's keyrings can't simply be attached to
 /sbin/request-key at the appropriate places because (a) execve will discard two
@@ -118,17 +136,17 @@ A search of any particular keyring proceeds in the following fashion:
 
  (2) It considers all the non-keyring keys within that keyring and, if any key
      matches the criteria specified, calls key_permission(SEARCH) on it to see
-     if the key is allowed to be found. If it is, that key is returned; if
+     if the key is allowed to be found.  If it is, that key is returned; if
      not, the search continues, and the error code is retained if of higher
      priority than the one currently set.
 
  (3) It then considers all the keyring-type keys in the keyring it's currently
-     searching. It calls key_permission(SEARCH) on each keyring, and if this
+     searching.  It calls key_permission(SEARCH) on each keyring, and if this
      grants permission, it recurses, executing steps (2) and (3) on that
      keyring.
 
 The process stops immediately a valid key is found with permission granted to
-use it. Any error from a previous match attempt is discarded and the key is
+use it.  Any error from a previous match attempt is discarded and the key is
 returned.
 
 When search_process_keyrings() is invoked, it performs the following searches
@@ -153,7 +171,7 @@ The moment one succeeds, all pending errors are discarded and the found key is
 returned.
 
 Only if all these fail does the whole thing fail with the highest priority
-error. Note that several errors may have come from LSM.
+error.  Note that several errors may have come from LSM.
 
 The error priority is:
 
index 61c0fad2fe2fa01ca14b14d218b56282940bafa6..e373f02128434277bc53098185b393df0a7c36d5 100644 (file)
@@ -780,6 +780,17 @@ payload contents" for more information.
     See also Documentation/keys-request-key.txt.
 
 
+(*) To search for a key, passing auxiliary data to the upcaller, call:
+
+       struct key *request_key_with_auxdata(const struct key_type *type,
+                                            const char *description,
+                                            const char *callout_string,
+                                            void *aux);
+
+    This is identical to request_key(), except that the auxiliary data is
+    passed to the key_type->request_key() op if it exists.
+
+
 (*) When it is no longer required, the key should be released using:
 
        void key_put(struct key *key);
@@ -1031,6 +1042,24 @@ The structure has a number of fields, some of which are mandatory:
      as might happen when the userspace buffer is accessed.
 
 
+ (*) int (*request_key)(struct key *key, struct key *authkey, const char *op,
+                       void *aux);
+
+     This method is optional.  If provided, request_key() and
+     request_key_with_auxdata() will invoke this function rather than
+     upcalling to /sbin/request-key to operate upon a key of this type.
+
+     The aux parameter is as passed to request_key_with_auxdata() or is NULL
+     otherwise.  Also passed are the key to be operated upon, the
+     authorisation key for this operation and the operation type (currently
+     only "create").
+
+     This function should return only when the upcall is complete.  Upon return
+     the authorisation key will be revoked, and the target key will be
+     negatively instantiated if it is still uninstantiated.  The error will be
+     returned to the caller of request_key*().
+
+
 ============================
 REQUEST-KEY CALLBACK SERVICE
 ============================
index da677f829f7689966bf09aeda6d89fc4b6a876d1..63af36cf7f6e356fc917b1ac86f6e879be5bc0fd 100644 (file)
@@ -49,15 +49,15 @@ select_smp_affinity(unsigned int irq)
        static int last_cpu;
        int cpu = last_cpu + 1;
 
-       if (!irq_desc[irq].handler->set_affinity || irq_user_affinity[irq])
+       if (!irq_desc[irq].chip->set_affinity || irq_user_affinity[irq])
                return 1;
 
        while (!cpu_possible(cpu))
                cpu = (cpu < (NR_CPUS-1) ? cpu + 1 : 0);
        last_cpu = cpu;
 
-       irq_affinity[irq] = cpumask_of_cpu(cpu);
-       irq_desc[irq].handler->set_affinity(irq, cpumask_of_cpu(cpu));
+       irq_desc[irq].affinity = cpumask_of_cpu(cpu);
+       irq_desc[irq].chip->set_affinity(irq, cpumask_of_cpu(cpu));
        return 0;
 }
 #endif /* CONFIG_SMP */
@@ -93,7 +93,7 @@ show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[irq]);
 #endif
-               seq_printf(p, " %14s", irq_desc[irq].handler->typename);
+               seq_printf(p, " %14s", irq_desc[irq].chip->typename);
                seq_printf(p, "  %c%s",
                        (action->flags & SA_INTERRUPT)?'+':' ',
                        action->name);
index 9d34ce26e5efc9231eb3581de7b158438818944d..f20f2dff9c438599c6e182eaf9222bf34450b45a 100644 (file)
@@ -233,7 +233,7 @@ void __init
 init_rtc_irq(void)
 {
        irq_desc[RTC_IRQ].status = IRQ_DISABLED;
-       irq_desc[RTC_IRQ].handler = &rtc_irq_type;
+       irq_desc[RTC_IRQ].chip = &rtc_irq_type;
        setup_irq(RTC_IRQ, &timer_irqaction);
 }
 
index b188683b83fd04a4ec8265e4bf1c5c06da8c1694..ac893bd48036cf6cf613d82a042eb6860b690830 100644 (file)
@@ -109,7 +109,7 @@ init_i8259a_irqs(void)
 
        for (i = 0; i < 16; i++) {
                irq_desc[i].status = IRQ_DISABLED;
-               irq_desc[i].handler = &i8259a_irq_type;
+               irq_desc[i].chip = &i8259a_irq_type;
        }
 
        setup_irq(2, &cascade);
index 146a20b9e3d563208715c5033214e0e16d1d7f8e..3b581415bab0bdaa5e9607cb14faf4dc7debed10 100644 (file)
@@ -120,7 +120,7 @@ init_pyxis_irqs(unsigned long ignore_mask)
                if ((ignore_mask >> i) & 1)
                        continue;
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &pyxis_irq_type;
+               irq_desc[i].chip = &pyxis_irq_type;
        }
 
        setup_irq(16+7, &isa_cascade_irqaction);
index 0a87e466918c2e72fb59e4a5f087a1e5fa268007..8e4d121f84ccf87745aa6149e0a1a26e53649211 100644 (file)
@@ -67,7 +67,7 @@ init_srm_irqs(long max, unsigned long ignore_mask)
                if (i < 64 && ((ignore_mask >> i) & 1))
                        continue;
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &srm_irq_type;
+               irq_desc[i].chip = &srm_irq_type;
        }
 }
 
index 2a8b364c822e9f0e17c9ead5352ab84ad9f1ace6..4ea6711e55aa5263812ba401a84dbae7ff5d4dbf 100644 (file)
@@ -124,12 +124,12 @@ DECLARE_PCI_FIXUP_FINAL(PCI_ANY_ID, PCI_ANY_ID, pcibios_fixup_final);
 
 void
 pcibios_align_resource(void *data, struct resource *res,
-                      unsigned long size, unsigned long align)
+                      resource_size_t size, resource_size_t align)
 {
        struct pci_dev *dev = data;
        struct pci_controller *hose = dev->sysdata;
        unsigned long alignto;
-       unsigned long start = res->start;
+       resource_size_t start = res->start;
 
        if (res->flags & IORESOURCE_IO) {
                /* Make sure we start at our min on all hoses */
index d7f0e97fe56fbeed9a93f102116de960de9c40ec..1a1a2c7a3d944190c8699339c5f38086b434ee83 100644 (file)
@@ -144,7 +144,7 @@ alcor_init_irq(void)
                if (i >= 16+20 && i <= 16+30)
                        continue;
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &alcor_irq_type;
+               irq_desc[i].chip = &alcor_irq_type;
        }
        i8259a_irq_type.ack = alcor_isa_mask_and_ack_irq;
 
index 8e3374d34c95bf2782a34ae7ce2ca749c56b8590..8c9e443d93ad6298b312e424ee48db22fd23ebe6 100644 (file)
@@ -124,7 +124,7 @@ common_init_irq(void (*srm_dev_int)(unsigned long v, struct pt_regs *r))
 
                for (i = 16; i < 35; ++i) {
                        irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-                       irq_desc[i].handler = &cabriolet_irq_type;
+                       irq_desc[i].chip = &cabriolet_irq_type;
                }
        }
 
index d5da6b1b28eec6cd557942ff1684f371a9ccc22a..b28c8f1c6e10b078fb0b1173ce64ad538bc23dda 100644 (file)
@@ -300,7 +300,7 @@ init_tsunami_irqs(struct hw_interrupt_type * ops, int imin, int imax)
        long i;
        for (i = imin; i <= imax; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = ops;
+               irq_desc[i].chip = ops;
        }
 }
 
index 61a79c354f0bdece82ed231db04aae15706fc226..aeb8e0277905660275943dd0b0678c3ba08a19b6 100644 (file)
@@ -137,7 +137,7 @@ eb64p_init_irq(void)
 
        for (i = 16; i < 32; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &eb64p_irq_type;
+               irq_desc[i].chip = &eb64p_irq_type;
        }               
 
        common_init_isa_dma();
index bd6e5f0e43c7e443b1d23dd6935df6d26d2e2e61..64a785baf53a0f1ffac8ebfcb904a4ec4c01c0d6 100644 (file)
@@ -154,7 +154,7 @@ eiger_init_irq(void)
 
        for (i = 16; i < 128; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &eiger_irq_type;
+               irq_desc[i].chip = &eiger_irq_type;
        }
 }
 
index fcabb7c96a16588f7367eb554d7b3ad8b9ee3047..0148e095638f8c6d40183ca098f49746f2f5d9f8 100644 (file)
@@ -206,11 +206,11 @@ jensen_init_irq(void)
 {
        init_i8259a_irqs();
 
-       irq_desc[1].handler = &jensen_local_irq_type;
-       irq_desc[4].handler = &jensen_local_irq_type;
-       irq_desc[3].handler = &jensen_local_irq_type;
-       irq_desc[7].handler = &jensen_local_irq_type;
-       irq_desc[9].handler = &jensen_local_irq_type;
+       irq_desc[1].chip = &jensen_local_irq_type;
+       irq_desc[4].chip = &jensen_local_irq_type;
+       irq_desc[3].chip = &jensen_local_irq_type;
+       irq_desc[7].chip = &jensen_local_irq_type;
+       irq_desc[9].chip = &jensen_local_irq_type;
 
        common_init_isa_dma();
 }
index e32fee50522076c7cfaf685d80690e2c0846c135..36d2159543769758904fe8125b7c037b4984efcc 100644 (file)
@@ -303,7 +303,7 @@ init_io7_irqs(struct io7 *io7,
        /* Set up the lsi irqs.  */
        for (i = 0; i < 128; ++i) {
                irq_desc[base + i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[base + i].handler = lsi_ops;
+               irq_desc[base + i].chip = lsi_ops;
        }
 
        /* Disable the implemented irqs in hardware.  */
@@ -317,7 +317,7 @@ init_io7_irqs(struct io7 *io7,
        /* Set up the msi irqs.  */
        for (i = 128; i < (128 + 512); ++i) {
                irq_desc[base + i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[base + i].handler = msi_ops;
+               irq_desc[base + i].chip = msi_ops;
        }
 
        for (i = 0; i < 16; ++i)
@@ -335,7 +335,7 @@ marvel_init_irq(void)
        /* Reserve the legacy irqs.  */
        for (i = 0; i < 16; ++i) {
                irq_desc[i].status = IRQ_DISABLED;
-               irq_desc[i].handler = &marvel_legacy_irq_type;
+               irq_desc[i].chip = &marvel_legacy_irq_type;
        }
 
        /* Init the io7 irqs.  */
index d78a0daa6168e3c3216b82f2f8bc514bd94ded74..b741600e3761a794450d07b278b6ffd2afe2b0ff 100644 (file)
@@ -117,7 +117,7 @@ mikasa_init_irq(void)
 
        for (i = 16; i < 32; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &mikasa_irq_type;
+               irq_desc[i].chip = &mikasa_irq_type;
        }
 
        init_i8259a_irqs();
index 65061f5d741062e01ed1487a7bb389ec770245b2..55db02d318d74172804f5ee67ae1ebd25e046b7d 100644 (file)
@@ -139,7 +139,7 @@ noritake_init_irq(void)
 
        for (i = 16; i < 48; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &noritake_irq_type;
+               irq_desc[i].chip = &noritake_irq_type;
        }
 
        init_i8259a_irqs();
index 05888a02a6049415e53b5ac0c84022eb39d5a605..949607e3d6fbe82395c641b1f94ecb3d99ef1b12 100644 (file)
@@ -180,7 +180,7 @@ rawhide_init_irq(void)
 
        for (i = 16; i < 128; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &rawhide_irq_type;
+               irq_desc[i].chip = &rawhide_irq_type;
        }
 
        init_i8259a_irqs();
index 58404243057b65711300cf786175f62597122f04..6ae50605263592061869345ecfe1856a1c33467e 100644 (file)
@@ -117,7 +117,7 @@ rx164_init_irq(void)
        rx164_update_irq_hw(0);
        for (i = 16; i < 40; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &rx164_irq_type;
+               irq_desc[i].chip = &rx164_irq_type;
        }
 
        init_i8259a_irqs();
index a7ff84474aceebc7603455ec09b8180471d09798..24dea40c9bfe823feea687efcea7677bb42bae12 100644 (file)
@@ -537,7 +537,7 @@ sable_lynx_init_irq(int nr_irqs)
 
        for (i = 0; i < nr_irqs; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &sable_lynx_irq_type;
+               irq_desc[i].chip = &sable_lynx_irq_type;
        }
 
        common_init_isa_dma();
index 7955bdfc2db0e2fabd4b44da9eed48ecc947ead2..2c75cd1fd81aab537e6b93615011baba52b98e2c 100644 (file)
@@ -154,7 +154,7 @@ takara_init_irq(void)
 
        for (i = 16; i < 128; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = &takara_irq_type;
+               irq_desc[i].chip = &takara_irq_type;
        }
 
        common_init_isa_dma();
index 2551fb49ae099150561407adc726e410b8e03c9f..13f3ed8ed7ac2f1c166d6d9392a0785bccbb71fd 100644 (file)
@@ -189,7 +189,7 @@ init_titan_irqs(struct hw_interrupt_type * ops, int imin, int imax)
        long i;
        for (i = imin; i <= imax; ++i) {
                irq_desc[i].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i].handler = ops;
+               irq_desc[i].chip = ops;
        }
 }
 
index 1553f470246e6b74eecb0ba9630982d3a0cf5c97..22c5798fe083ba03cf16e88ec6fe4088fce61ce3 100644 (file)
@@ -199,14 +199,14 @@ wildfire_init_irq_per_pca(int qbbno, int pcano)
                if (i == 2)
                        continue;
                irq_desc[i+irq_bias].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i+irq_bias].handler = &wildfire_irq_type;
+               irq_desc[i+irq_bias].chip = &wildfire_irq_type;
        }
 
        irq_desc[36+irq_bias].status = IRQ_DISABLED | IRQ_LEVEL;
-       irq_desc[36+irq_bias].handler = &wildfire_irq_type;
+       irq_desc[36+irq_bias].chip = &wildfire_irq_type;
        for (i = 40; i < 64; ++i) {
                irq_desc[i+irq_bias].status = IRQ_DISABLED | IRQ_LEVEL;
-               irq_desc[i+irq_bias].handler = &wildfire_irq_type;
+               irq_desc[i+irq_bias].chip = &wildfire_irq_type;
        }
 
        setup_irq(32+irq_bias, &isa_enable);    
index 302fc140154797e8d2d59045a40a940cad69092a..45da06fc1ba1a1481f66e102e0fc582aaa2096f5 100644 (file)
@@ -304,7 +304,7 @@ static inline int pdev_bad_for_parity(struct pci_dev *dev)
 static void __devinit
 pdev_fixup_device_resources(struct pci_sys_data *root, struct pci_dev *dev)
 {
-       unsigned long offset;
+       resource_size_t offset;
        int i;
 
        for (i = 0; i < PCI_NUM_RESOURCES; i++) {
@@ -634,9 +634,9 @@ char * __init pcibios_setup(char *str)
  * which might be mirrored at 0x0100-0x03ff..
  */
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size, unsigned long align)
+                           resource_size_t size, resource_size_t align)
 {
-       unsigned long start = res->start;
+       resource_size_t start = res->start;
 
        if (res->flags & IORESOURCE_IO && start & 0x300)
                start = (start + 0x3ff) & ~0x3ff;
index 093ccba0503c9a1885bbddc3fa6f3c2e8a67e5eb..6bdf70def01f0c22390aeeba31db56cbd05be7e8 100644 (file)
@@ -119,9 +119,24 @@ DEFINE_PER_CPU(struct cpuinfo_arm, cpu_data);
  * Standard memory resources
  */
 static struct resource mem_res[] = {
-       { "Video RAM",   0,     0,     IORESOURCE_MEM                   },
-       { "Kernel text", 0,     0,     IORESOURCE_MEM                   },
-       { "Kernel data", 0,     0,     IORESOURCE_MEM                   }
+       {
+               .name = "Video RAM",
+               .start = 0,
+               .end = 0,
+               .flags = IORESOURCE_MEM
+       },
+       {
+               .name = "Kernel text",
+               .start = 0,
+               .end = 0,
+               .flags = IORESOURCE_MEM
+       },
+       {
+               .name = "Kernel data",
+               .start = 0,
+               .end = 0,
+               .flags = IORESOURCE_MEM
+       }
 };
 
 #define video_ram   mem_res[0]
@@ -129,9 +144,24 @@ static struct resource mem_res[] = {
 #define kernel_data mem_res[2]
 
 static struct resource io_res[] = {
-       { "reserved",    0x3bc, 0x3be, IORESOURCE_IO | IORESOURCE_BUSY },
-       { "reserved",    0x378, 0x37f, IORESOURCE_IO | IORESOURCE_BUSY },
-       { "reserved",    0x278, 0x27f, IORESOURCE_IO | IORESOURCE_BUSY }
+       {
+               .name = "reserved",
+               .start = 0x3bc,
+               .end = 0x3be,
+               .flags = IORESOURCE_IO | IORESOURCE_BUSY
+       },
+       {
+               .name = "reserved",
+               .start = 0x378,
+               .end = 0x37f,
+               .flags = IORESOURCE_IO | IORESOURCE_BUSY
+       },
+       {
+               .name = "reserved",
+               .start = 0x278,
+               .end = 0x27f,
+               .flags = IORESOURCE_IO | IORESOURCE_BUSY
+       }
 };
 
 #define lp0 io_res[0]
index 856b665020e770d8a464e40a74cd91a7f5649b7e..6a1238a29d6c4d98d46156a1863e4a342478d7db 100644 (file)
@@ -28,6 +28,10 @@ config GENERIC_CALIBRATE_DELAY
        bool
        default y
 
+config IRQ_PER_CPU
+       bool
+       default y
+
 config CRIS
        bool
        default y
index 4b368a122015288dc1b04b9248f19ca8eefbb106..2d5be93b5197c202d37d41d0a4d6334fa0a271a0 100644 (file)
@@ -172,7 +172,7 @@ init_IRQ(void)
 
        /* Initialize IRQ handler descriptiors. */
        for(i = 2; i < NR_IRQS; i++) {
-               irq_desc[i].handler = &crisv10_irq_type;
+               irq_desc[i].chip = &crisv10_irq_type;
                set_int_vector(i, interrupt[i]);
        }
 
index 1e9d062103aec24a993c8c0e4263e4e9778df9a3..a2b9c60c2777e6cf39b94b0789fccf15307ced19 100644 (file)
@@ -43,10 +43,10 @@ int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma,
 
 void
 pcibios_align_resource(void *data, struct resource *res,
-                      unsigned long size, unsigned long align)
+                      resource_size_t size, resource_size_t align)
 {
        if (res->flags & IORESOURCE_IO) {
-               unsigned long start = res->start;
+               resource_size_t start = res->start;
 
                if (start & 0x300) {
                        start = (start + 0x3ff) & ~0x3ff;
index c78cc2685133727f32bc3e6d514b08caf79f2aca..06260874f018f4ff7d5a9d1f8d07cf8ba2e6ca11 100644 (file)
@@ -369,7 +369,7 @@ init_IRQ(void)
 
        /* Point all IRQ's to bad handlers. */
        for (i = FIRST_IRQ, j = 0; j < NR_IRQS; i++, j++) {
-               irq_desc[j].handler = &crisv32_irq_type;
+               irq_desc[j].chip = &crisv32_irq_type;
                set_exception_vector(i, interrupt[j]);
        }
 
index b504def3e346944cc65fad1a5b55cc391f145eb1..6547bb64636419de268dadcccea8d7b89c84c425 100644 (file)
@@ -69,7 +69,7 @@ int show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
 #endif
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
index 0a26bf6f1cd4280ecd682d6de6a6f0c3c2ddd97c..4f165c93be424545ebcad65ee1d2b10be477f7fe 100644 (file)
@@ -64,10 +64,10 @@ pcibios_update_resource(struct pci_dev *dev, struct resource *root,
  */
 void
 pcibios_align_resource(void *data, struct resource *res,
-                      unsigned long size, unsigned long align)
+                      resource_size_t size, resource_size_t align)
 {
        if (res->flags & IORESOURCE_IO) {
-               unsigned long start = res->start;
+               resource_size_t start = res->start;
 
                if (start & 0x300) {
                        start = (start + 0x3ff) & ~0x3ff;
index 3bb221db164a65c0425fdb5b01e299e331ccd99a..0463f63359051f90bbf4b0c86a9d984ac3d36d1f 100644 (file)
@@ -529,6 +529,7 @@ config X86_PAE
        bool
        depends on HIGHMEM64G
        default y
+       select RESOURCES_64BIT
 
 # Common NUMA Features
 config NUMA
@@ -794,6 +795,9 @@ config COMPAT_VDSO
 
 endmenu
 
+config ARCH_ENABLE_MEMORY_HOTPLUG
+       def_bool y
+       depends on HIGHMEM
 
 menu "Power management options (ACPI, APM)"
        depends on !X86_VOYAGER
index 9202b67c4b2e5cc925b0670d0b3e804dc719abbc..8beb0f07d99966b00206880fb3113db77333edd5 100644 (file)
@@ -601,8 +601,10 @@ efi_initialize_iomem_resources(struct resource *code_resource,
                res->end = res->start + ((md->num_pages << EFI_PAGE_SHIFT) - 1);
                res->flags = IORESOURCE_MEM | IORESOURCE_BUSY;
                if (request_resource(&iomem_resource, res) < 0)
-                       printk(KERN_ERR PFX "Failed to allocate res %s : 0x%lx-0x%lx\n",
-                               res->name, res->start, res->end);
+                       printk(KERN_ERR PFX "Failed to allocate res %s : "
+                               "0x%llx-0x%llx\n", res->name,
+                               (unsigned long long)res->start,
+                               (unsigned long long)res->end);
                /*
                 * We don't know which region contains kernel data so we try
                 * it repeatedly and let the resource manager test it.
index c1a42feba28667cd8e0b7662aafe0fdb79607a23..3c6063671a9f94b4beabb137539880acdc105054 100644 (file)
@@ -132,7 +132,7 @@ void make_8259A_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
        io_apic_irqs &= ~(1<<irq);
-       irq_desc[irq].handler = &i8259A_irq_type;
+       irq_desc[irq].chip = &i8259A_irq_type;
        enable_irq(irq);
 }
 
@@ -386,12 +386,12 @@ void __init init_ISA_irqs (void)
                        /*
                         * 16 old-style INTA-cycle interrupts:
                         */
-                       irq_desc[i].handler = &i8259A_irq_type;
+                       irq_desc[i].chip = &i8259A_irq_type;
                } else {
                        /*
                         * 'high' PCI IRQs filled in on demand
                         */
-                       irq_desc[i].handler = &no_irq_type;
+                       irq_desc[i].chip = &no_irq_type;
                }
        }
 }
index 72ae414e4d4976437fefa8a01e1b38d97fdc0395..ec9ea0269d367fb8c346b883f809ba40d7621b0d 100644 (file)
@@ -581,7 +581,7 @@ static int balanced_irq(void *unused)
        
        /* push everything to CPU 0 to give us a starting point.  */
        for (i = 0 ; i < NR_IRQS ; i++) {
-               pending_irq_cpumask[i] = cpumask_of_cpu(0);
+               irq_desc[i].pending_mask = cpumask_of_cpu(0);
                set_pending_irq(i, cpumask_of_cpu(0));
        }
 
@@ -1205,15 +1205,17 @@ static struct hw_interrupt_type ioapic_edge_type;
 #define IOAPIC_EDGE    0
 #define IOAPIC_LEVEL   1
 
-static inline void ioapic_register_intr(int irq, int vector, unsigned long trigger)
+static void ioapic_register_intr(int irq, int vector, unsigned long trigger)
 {
-       unsigned idx = use_pci_vector() && !platform_legacy_irq(irq) ? vector : irq;
+       unsigned idx;
+
+       idx = use_pci_vector() && !platform_legacy_irq(irq) ? vector : irq;
 
        if ((trigger == IOAPIC_AUTO && IO_APIC_irq_trigger(irq)) ||
                        trigger == IOAPIC_LEVEL)
-               irq_desc[idx].handler = &ioapic_level_type;
+               irq_desc[idx].chip = &ioapic_level_type;
        else
-               irq_desc[idx].handler = &ioapic_edge_type;
+               irq_desc[idx].chip = &ioapic_edge_type;
        set_intr_gate(vector, interrupt[idx]);
 }
 
@@ -1325,7 +1327,7 @@ static void __init setup_ExtINT_IRQ0_pin(unsigned int apic, unsigned int pin, in
         * The timer IRQ doesn't have to know that behind the
         * scene we have a 8259A-master in AEOI mode ...
         */
-       irq_desc[0].handler = &ioapic_edge_type;
+       irq_desc[0].chip = &ioapic_edge_type;
 
        /*
         * Add it to the IO-APIC irq-routing table:
@@ -2069,6 +2071,13 @@ static void set_ioapic_affinity_vector (unsigned int vector,
 #endif
 #endif
 
+static int ioapic_retrigger(unsigned int irq)
+{
+       send_IPI_self(IO_APIC_VECTOR(irq));
+
+       return 1;
+}
+
 /*
  * Level and edge triggered IO-APIC interrupts need different handling,
  * so we use two separate IRQ descriptors. Edge triggered IRQs can be
@@ -2088,6 +2097,7 @@ static struct hw_interrupt_type ioapic_edge_type __read_mostly = {
 #ifdef CONFIG_SMP
        .set_affinity   = set_ioapic_affinity,
 #endif
+       .retrigger      = ioapic_retrigger,
 };
 
 static struct hw_interrupt_type ioapic_level_type __read_mostly = {
@@ -2101,6 +2111,7 @@ static struct hw_interrupt_type ioapic_level_type __read_mostly = {
 #ifdef CONFIG_SMP
        .set_affinity   = set_ioapic_affinity,
 #endif
+       .retrigger      = ioapic_retrigger,
 };
 
 static inline void init_IO_APIC_traps(void)
@@ -2135,7 +2146,7 @@ static inline void init_IO_APIC_traps(void)
                                make_8259A_irq(irq);
                        else
                                /* Strange. Oh, well.. */
-                               irq_desc[irq].handler = &no_irq_type;
+                               irq_desc[irq].chip = &no_irq_type;
                }
        }
 }
@@ -2351,7 +2362,7 @@ static inline void check_timer(void)
        printk(KERN_INFO "...trying to set up timer as Virtual Wire IRQ...");
 
        disable_8259A_irq(0);
-       irq_desc[0].handler = &lapic_irq_type;
+       irq_desc[0].chip = &lapic_irq_type;
        apic_write_around(APIC_LVT0, APIC_DM_FIXED | vector);   /* Fixed mode */
        enable_8259A_irq(0);
 
index 9eec9435318ea4053f80a1f097edcff6bce0184a..16b4917039672bb3200e82c0325ef2f85134fbd9 100644 (file)
@@ -82,6 +82,10 @@ fastcall unsigned int do_IRQ(struct pt_regs *regs)
        }
 #endif
 
+       if (!irq_desc[irq].handle_irq) {
+               __do_IRQ(irq, regs);
+               goto out_exit;
+       }
 #ifdef CONFIG_4KSTACKS
 
        curctx = (union irq_ctx *) current_thread_info();
@@ -121,6 +125,7 @@ fastcall unsigned int do_IRQ(struct pt_regs *regs)
 #endif
                __do_IRQ(irq, regs);
 
+out_exit:
        irq_exit();
 
        return 1;
@@ -249,7 +254,7 @@ int show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
 #endif
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
@@ -291,13 +296,13 @@ void fixup_irqs(cpumask_t map)
                if (irq == 2)
                        continue;
 
-               cpus_and(mask, irq_affinity[irq], map);
+               cpus_and(mask, irq_desc[irq].affinity, map);
                if (any_online_cpu(mask) == NR_CPUS) {
                        printk("Breaking affinity for irq %i\n", irq);
                        mask = map;
                }
-               if (irq_desc[irq].handler->set_affinity)
-                       irq_desc[irq].handler->set_affinity(irq, mask);
+               if (irq_desc[irq].chip->set_affinity)
+                       irq_desc[irq].chip->set_affinity(irq, mask);
                else if (irq_desc[irq].action && !(warned++))
                        printk("Cannot set affinity for irq %i\n", irq);
        }
index 4a65040cc624b06bf1de3ca678f66cd9527b36a9..6712f0d2eb37372aa040ce352ef68a9ebd8c09d7 100644 (file)
@@ -1314,8 +1314,10 @@ legacy_init_iomem_resources(struct resource *code_resource, struct resource *dat
        probe_roms();
        for (i = 0; i < e820.nr_map; i++) {
                struct resource *res;
+#ifndef CONFIG_RESOURCES_64BIT
                if (e820.map[i].addr + e820.map[i].size > 0x100000000ULL)
                        continue;
+#endif
                res = kzalloc(sizeof(struct resource), GFP_ATOMIC);
                switch (e820.map[i].type) {
                case E820_RAM:  res->name = "System RAM"; break;
index 8a9e1a6f745de17f9d28e9acfaf2e3f3d205994a..1f84cdb24779179b77da4b80d711ae6f276f5d5f 100644 (file)
@@ -140,8 +140,8 @@ void __init time_init_hook(void)
 
 #define MB (1024 * 1024)
 
-static unsigned long sgivwfb_mem_phys;
-static unsigned long sgivwfb_mem_size;
+unsigned long sgivwfb_mem_phys;
+unsigned long sgivwfb_mem_size;
 
 long long mem_size __initdata = 0;
 
@@ -177,8 +177,4 @@ char * __init machine_specific_memory_setup(void)
        add_memory_region(sgivwfb_mem_phys, sgivwfb_mem_size, E820_RESERVED);
 
        return "PROM";
-
-       /* Remove gcc warnings */
-       (void) sanitize_e820_map(NULL, NULL);
-       (void) copy_e820_map(NULL, 0);
 }
index 3e64fb7212911bc4db9fe8db9f67ab75a40ecd36..c418521dd5547073cf78bfbf0e9bb710366cb3b0 100644 (file)
@@ -278,22 +278,22 @@ void init_VISWS_APIC_irqs(void)
                irq_desc[i].depth = 1;
 
                if (i == 0) {
-                       irq_desc[i].handler = &cobalt_irq_type;
+                       irq_desc[i].chip = &cobalt_irq_type;
                }
                else if (i == CO_IRQ_IDE0) {
-                       irq_desc[i].handler = &cobalt_irq_type;
+                       irq_desc[i].chip = &cobalt_irq_type;
                }
                else if (i == CO_IRQ_IDE1) {
-                       irq_desc[i].handler = &cobalt_irq_type;
+                       irq_desc[i].chip = &cobalt_irq_type;
                }
                else if (i == CO_IRQ_8259) {
-                       irq_desc[i].handler = &piix4_master_irq_type;
+                       irq_desc[i].chip = &piix4_master_irq_type;
                }
                else if (i < CO_IRQ_APIC0) {
-                       irq_desc[i].handler = &piix4_virtual_irq_type;
+                       irq_desc[i].chip = &piix4_virtual_irq_type;
                }
                else if (IS_CO_APIC(i)) {
-                       irq_desc[i].handler = &cobalt_irq_type;
+                       irq_desc[i].chip = &cobalt_irq_type;
                }
        }
 
index 8242af9ebc6f99b4fb0e24dfff4f3d4b68d393c4..5b8b579a079fa8a7afdc52e4871aef91b3a94665 100644 (file)
@@ -1419,7 +1419,7 @@ smp_intr_init(void)
         * This is for later: first 16 correspond to PC IRQs; next 16
         * are Primary MC IRQs and final 16 are Secondary MC IRQs */
        for(i = 0; i < 48; i++)
-               irq_desc[i].handler = &vic_irq_type;
+               irq_desc[i].chip = &vic_irq_type;
 }
 
 /* send a CPI at level cpi to a set of cpus in cpuset (set 1 bit per
index a151f7a99f5e8010a7f9875cede3f9aceb81ed61..10154a2cac6895d6073973f3e12ef95d18bee247 100644 (file)
  */
 void
 pcibios_align_resource(void *data, struct resource *res,
-                      unsigned long size, unsigned long align)
+                       resource_size_t size, resource_size_t align)
 {
        if (res->flags & IORESOURCE_IO) {
-               unsigned long start = res->start;
+               resource_size_t start = res->start;
 
                if (start & 0x300) {
                        start = (start + 0x3ff) & ~0x3ff;
index a56df7bf022da153c2efe0035526e296df419d0a..b487e227a1f7a3e6b17dd48d57a81d1319e0e376 100644 (file)
@@ -271,6 +271,9 @@ config HOTPLUG_CPU
          can be controlled through /sys/devices/system/cpu/cpu#.
          Say N if you want to disable CPU hotplug.
 
+config ARCH_ENABLE_MEMORY_HOTPLUG
+       def_bool y
+
 config SCHED_SMT
        bool "SMT scheduler support"
        depends on SMP
@@ -489,6 +492,10 @@ config GENERIC_PENDING_IRQ
        depends on GENERIC_HARDIRQS && SMP
        default y
 
+config IRQ_PER_CPU
+       bool
+       default y
+
 source "arch/ia64/hp/sim/Kconfig"
 
 menu "Instrumentation Support"
index c0d25a2a3e9caf1ddbf7eb396b23027347024856..8145547bb52daf891199affd969a5dd9cb8cee9a 100644 (file)
@@ -44,8 +44,8 @@ hpsim_irq_init (void)
        int i;
 
        for (i = 0; i < NR_IRQS; ++i) {
-               idesc = irq_descp(i);
-               if (idesc->handler == &no_irq_type)
-                       idesc->handler = &irq_type_hp_sim;
+               idesc = irq_desc + i;
+               if (idesc->chip == &no_irq_type)
+                       idesc->chip = &irq_type_hp_sim;
        }
 }
index d58c1c5c903a9cfdae0981411ae53604fce020f1..efc7df4b0fd251a126b29a263546bb4ef2181f07 100644 (file)
@@ -456,7 +456,7 @@ iosapic_startup_edge_irq (unsigned int irq)
 static void
 iosapic_ack_edge_irq (unsigned int irq)
 {
-       irq_desc_t *idesc = irq_descp(irq);
+       irq_desc_t *idesc = irq_desc + irq;
 
        move_native_irq(irq);
        /*
@@ -659,14 +659,14 @@ register_intr (unsigned int gsi, int vector, unsigned char delivery,
        else
                irq_type = &irq_type_iosapic_level;
 
-       idesc = irq_descp(vector);
-       if (idesc->handler != irq_type) {
-               if (idesc->handler != &no_irq_type)
+       idesc = irq_desc + vector;
+       if (idesc->chip != irq_type) {
+               if (idesc->chip != &no_irq_type)
                        printk(KERN_WARNING
                               "%s: changing vector %d from %s to %s\n",
                               __FUNCTION__, vector,
-                              idesc->handler->typename, irq_type->typename);
-               idesc->handler = irq_type;
+                              idesc->chip->typename, irq_type->typename);
+               idesc->chip = irq_type;
        }
        return 0;
 }
@@ -793,14 +793,14 @@ again:
                        return -ENOSPC;
        }
 
-       spin_lock_irqsave(&irq_descp(vector)->lock, flags);
+       spin_lock_irqsave(&irq_desc[vector].lock, flags);
        spin_lock(&iosapic_lock);
        {
                if (gsi_to_vector(gsi) > 0) {
                        if (list_empty(&iosapic_intr_info[vector].rtes))
                                free_irq_vector(vector);
                        spin_unlock(&iosapic_lock);
-                       spin_unlock_irqrestore(&irq_descp(vector)->lock,
+                       spin_unlock_irqrestore(&irq_desc[vector].lock,
                                               flags);
                        goto again;
                }
@@ -810,7 +810,7 @@ again:
                              polarity, trigger);
                if (err < 0) {
                        spin_unlock(&iosapic_lock);
-                       spin_unlock_irqrestore(&irq_descp(vector)->lock,
+                       spin_unlock_irqrestore(&irq_desc[vector].lock,
                                               flags);
                        return err;
                }
@@ -825,7 +825,7 @@ again:
                set_rte(gsi, vector, dest, mask);
        }
        spin_unlock(&iosapic_lock);
-       spin_unlock_irqrestore(&irq_descp(vector)->lock, flags);
+       spin_unlock_irqrestore(&irq_desc[vector].lock, flags);
 
        printk(KERN_INFO "GSI %u (%s, %s) -> CPU %d (0x%04x) vector %d\n",
               gsi, (trigger == IOSAPIC_EDGE ? "edge" : "level"),
@@ -860,7 +860,7 @@ iosapic_unregister_intr (unsigned int gsi)
        }
        vector = irq_to_vector(irq);
 
-       idesc = irq_descp(irq);
+       idesc = irq_desc + irq;
        spin_lock_irqsave(&idesc->lock, flags);
        spin_lock(&iosapic_lock);
        {
@@ -903,7 +903,7 @@ iosapic_unregister_intr (unsigned int gsi)
                        BUG_ON(iosapic_intr_info[vector].count);
 
                        /* Clear the interrupt controller descriptor */
-                       idesc->handler = &no_irq_type;
+                       idesc->chip = &no_irq_type;
 
                        /* Clear the interrupt information */
                        memset(&iosapic_intr_info[vector], 0,
index 9c72ea3f6432d115ca32090d0c8bd9c8365d5c07..7852382de2fa6666a67383086f0014c93ddce43a 100644 (file)
@@ -76,7 +76,7 @@ int show_interrupts(struct seq_file *p, void *v)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
                }
 #endif
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
@@ -100,7 +100,7 @@ void set_irq_affinity_info (unsigned int irq, int hwid, int redir)
        cpu_set(cpu_logical_id(hwid), mask);
 
        if (irq < NR_IRQS) {
-               irq_affinity[irq] = mask;
+               irq_desc[irq].affinity = mask;
                irq_redir[irq] = (char) (redir & 0xff);
        }
 }
@@ -120,7 +120,7 @@ static void migrate_irqs(void)
        int             irq, new_cpu;
 
        for (irq=0; irq < NR_IRQS; irq++) {
-               desc = irq_descp(irq);
+               desc = irq_desc + irq;
 
                /*
                 * No handling for now.
@@ -131,7 +131,7 @@ static void migrate_irqs(void)
                if (desc->status == IRQ_PER_CPU)
                        continue;
 
-               cpus_and(mask, irq_affinity[irq], cpu_online_map);
+               cpus_and(mask, irq_desc[irq].affinity, cpu_online_map);
                if (any_online_cpu(mask) == NR_CPUS) {
                        /*
                         * Save it for phase 2 processing
@@ -144,15 +144,15 @@ static void migrate_irqs(void)
                        /*
                         * Al three are essential, currently WARN_ON.. maybe panic?
                         */
-                       if (desc->handler && desc->handler->disable &&
-                               desc->handler->enable && desc->handler->set_affinity) {
-                               desc->handler->disable(irq);
-                               desc->handler->set_affinity(irq, mask);
-                               desc->handler->enable(irq);
+                       if (desc->chip && desc->chip->disable &&
+                               desc->chip->enable && desc->chip->set_affinity) {
+                               desc->chip->disable(irq);
+                               desc->chip->set_affinity(irq, mask);
+                               desc->chip->enable(irq);
                        } else {
-                               WARN_ON((!(desc->handler) || !(desc->handler->disable) ||
-                                               !(desc->handler->enable) ||
-                                               !(desc->handler->set_affinity)));
+                               WARN_ON((!(desc->chip) || !(desc->chip->disable) ||
+                                               !(desc->chip->enable) ||
+                                               !(desc->chip->set_affinity)));
                        }
                }
        }
index ef9a2b49307ae756ac58a8fb7f8c360aa2aca53a..f5035304594e5af977d6b432a3f82e45b9320d93 100644 (file)
@@ -249,9 +249,9 @@ register_percpu_irq (ia64_vector vec, struct irqaction *action)
 
        for (irq = 0; irq < NR_IRQS; ++irq)
                if (irq_to_vector(irq) == vec) {
-                       desc = irq_descp(irq);
+                       desc = irq_desc + irq;
                        desc->status |= IRQ_PER_CPU;
-                       desc->handler = &irq_type_ia64_lsapic;
+                       desc->chip = &irq_type_ia64_lsapic;
                        if (action)
                                setup_irq(irq, action);
                }
index ea14e6a04409636c62813048504cf77e3ef57949..1ab58b09f3d7163df640f5765efd7d8d3a020c02 100644 (file)
@@ -26,6 +26,13 @@ lsapic_noop (unsigned int irq)
        /* nuthing to do... */
 }
 
+static int lsapic_retrigger(unsigned int irq)
+{
+       ia64_resend_irq(irq);
+
+       return 1;
+}
+
 struct hw_interrupt_type irq_type_ia64_lsapic = {
        .typename =     "LSAPIC",
        .startup =      lsapic_noop_startup,
@@ -33,5 +40,6 @@ struct hw_interrupt_type irq_type_ia64_lsapic = {
        .enable =       lsapic_noop,
        .disable =      lsapic_noop,
        .ack =          lsapic_noop,
-       .end =          lsapic_noop
+       .end =          lsapic_noop,
+       .retrigger =    lsapic_retrigger,
 };
index 6a0880639bc9396208c30a9f9ccd4b3ae93aa835..d7dc5e63de63c2bc29b9a1fc19b98c663517de5f 100644 (file)
@@ -1788,7 +1788,7 @@ ia64_mca_late_init(void)
                        cpe_poll_enabled = 0;
                        for (irq = 0; irq < NR_IRQS; ++irq)
                                if (irq_to_vector(irq) == cpe_vector) {
-                                       desc = irq_descp(irq);
+                                       desc = irq_desc + irq;
                                        desc->status |= IRQ_PER_CPU;
                                        setup_irq(irq, &mca_cpe_irqaction);
                                        ia64_cpe_irq = irq;
index 6d7bc8ff7b3afff19b3781cdaa91a18d27268772..a0055d3d695c81d2ba042dcbe54d831ffd82a42b 100644 (file)
@@ -6165,7 +6165,7 @@ pfm_load_regs (struct task_struct *task)
                /*
                 * will replay the PMU interrupt
                 */
-               if (need_irq_resend) hw_resend_irq(NULL, IA64_PERFMON_VECTOR);
+               if (need_irq_resend) ia64_resend_irq(IA64_PERFMON_VECTOR);
 
                pfm_stats[smp_processor_id()].pfm_replay_ovfl_intr_count++;
        }
@@ -6305,7 +6305,7 @@ pfm_load_regs (struct task_struct *task)
                /*
                 * will replay the PMU interrupt
                 */
-               if (need_irq_resend) hw_resend_irq(NULL, IA64_PERFMON_VECTOR);
+               if (need_irq_resend) ia64_resend_irq(IA64_PERFMON_VECTOR);
 
                pfm_stats[smp_processor_id()].pfm_replay_ovfl_intr_count++;
        }
index 44e9547878ac7310b6f11502d1a709fd5805bd66..5203df78f150cd1d9cf35c5b888a958f4dd10cdd 100644 (file)
@@ -677,16 +677,16 @@ int migrate_platform_irqs(unsigned int cpu)
                        new_cpei_cpu = any_online_cpu(cpu_online_map);
                        mask = cpumask_of_cpu(new_cpei_cpu);
                        set_cpei_target_cpu(new_cpei_cpu);
-                       desc = irq_descp(ia64_cpe_irq);
+                       desc = irq_desc + ia64_cpe_irq;
                        /*
                         * Switch for now, immediatly, we need to do fake intr
                         * as other interrupts, but need to study CPEI behaviour with
                         * polling before making changes.
                         */
                        if (desc) {
-                               desc->handler->disable(ia64_cpe_irq);
-                               desc->handler->set_affinity(ia64_cpe_irq, mask);
-                               desc->handler->enable(ia64_cpe_irq);
+                               desc->chip->disable(ia64_cpe_irq);
+                               desc->chip->set_affinity(ia64_cpe_irq, mask);
+                               desc->chip->enable(ia64_cpe_irq);
                                printk ("Re-targetting CPEI to cpu %d\n", new_cpei_cpu);
                        }
                }
index 77375a55da312fd7b4ac5ddcb68933aadc381e83..5bef0e3603f2a44e19169a5957bb6a0bf201150a 100644 (file)
@@ -568,7 +568,7 @@ pcibios_disable_device (struct pci_dev *dev)
 
 void
 pcibios_align_resource (void *data, struct resource *res,
-                       unsigned long size, unsigned long align)
+                       resource_size_t size, resource_size_t align)
 {
 }
 
index 677c6c0fd66188b69e8df0194c2f3654360f00f4..7bb6ad188ba39855f1516465e4fee89f5b4ef145 100644 (file)
@@ -225,8 +225,8 @@ void sn_irq_init(void)
        ia64_last_device_vector = IA64_SN2_LAST_DEVICE_VECTOR;
 
        for (i = 0; i < NR_IRQS; i++) {
-               if (base_desc[i].handler == &no_irq_type) {
-                       base_desc[i].handler = &irq_type_sn;
+               if (base_desc[i].chip == &no_irq_type) {
+                       base_desc[i].chip = &irq_type_sn;
                }
        }
 }
index a4634b06f67554ffeb3f9c84f33bb213ca493b7b..3841861df6a2a0565fc19aad6b59e8a5fa0490ee 100644 (file)
@@ -54,7 +54,7 @@ int show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
 #endif
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
index 6328e1357a80637c324421ffed54af28e223f804..f9f56c2701951c10f0c44883c57a8f89fa3ddf2b 100644 (file)
@@ -87,7 +87,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_SMC91X)
        /* INT#0: LAN controller on M32104UT-LAN (SMC91C111)*/
        irq_desc[M32R_IRQ_INT0].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT0].handler = &m32104ut_irq_type;
+       irq_desc[M32R_IRQ_INT0].chip = &m32104ut_irq_type;
        irq_desc[M32R_IRQ_INT0].action = 0;
        irq_desc[M32R_IRQ_INT0].depth = 1;
        icu_data[M32R_IRQ_INT0].icucr = M32R_ICUCR_IEN | M32R_ICUCR_ISMOD11; /* "H" level sense */
@@ -96,7 +96,7 @@ void __init init_IRQ(void)
 
        /* MFT2 : system timer */
        irq_desc[M32R_IRQ_MFT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_MFT2].handler = &m32104ut_irq_type;
+       irq_desc[M32R_IRQ_MFT2].chip = &m32104ut_irq_type;
        irq_desc[M32R_IRQ_MFT2].action = 0;
        irq_desc[M32R_IRQ_MFT2].depth = 1;
        icu_data[M32R_IRQ_MFT2].icucr = M32R_ICUCR_IEN;
@@ -105,7 +105,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_SERIAL_M32R_SIO
        /* SIO0_R : uart receive data */
        irq_desc[M32R_IRQ_SIO0_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_R].handler = &m32104ut_irq_type;
+       irq_desc[M32R_IRQ_SIO0_R].chip = &m32104ut_irq_type;
        irq_desc[M32R_IRQ_SIO0_R].action = 0;
        irq_desc[M32R_IRQ_SIO0_R].depth = 1;
        icu_data[M32R_IRQ_SIO0_R].icucr = M32R_ICUCR_IEN;
@@ -113,7 +113,7 @@ void __init init_IRQ(void)
 
        /* SIO0_S : uart send data */
        irq_desc[M32R_IRQ_SIO0_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_S].handler = &m32104ut_irq_type;
+       irq_desc[M32R_IRQ_SIO0_S].chip = &m32104ut_irq_type;
        irq_desc[M32R_IRQ_SIO0_S].action = 0;
        irq_desc[M32R_IRQ_SIO0_S].depth = 1;
        icu_data[M32R_IRQ_SIO0_S].icucr = M32R_ICUCR_IEN;
index fad1fc99bb272d8b4d485bc9346de58f027c2468..b6ab00eff58057db820edf51c06cfdc08a4b5017 100644 (file)
@@ -301,7 +301,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_SMC91X)
        /* INT#0: LAN controller on M32700UT-LAN (SMC91C111)*/
        irq_desc[M32700UT_LAN_IRQ_LAN].status = IRQ_DISABLED;
-       irq_desc[M32700UT_LAN_IRQ_LAN].handler = &m32700ut_lanpld_irq_type;
+       irq_desc[M32700UT_LAN_IRQ_LAN].chip = &m32700ut_lanpld_irq_type;
        irq_desc[M32700UT_LAN_IRQ_LAN].action = 0;
        irq_desc[M32700UT_LAN_IRQ_LAN].depth = 1;       /* disable nested irq */
        lanpld_icu_data[irq2lanpldirq(M32700UT_LAN_IRQ_LAN)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD02;   /* "H" edge sense */
@@ -310,7 +310,7 @@ void __init init_IRQ(void)
 
        /* MFT2 : system timer */
        irq_desc[M32R_IRQ_MFT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_MFT2].handler = &m32700ut_irq_type;
+       irq_desc[M32R_IRQ_MFT2].chip = &m32700ut_irq_type;
        irq_desc[M32R_IRQ_MFT2].action = 0;
        irq_desc[M32R_IRQ_MFT2].depth = 1;
        icu_data[M32R_IRQ_MFT2].icucr = M32R_ICUCR_IEN;
@@ -318,7 +318,7 @@ void __init init_IRQ(void)
 
        /* SIO0 : receive */
        irq_desc[M32R_IRQ_SIO0_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_R].handler = &m32700ut_irq_type;
+       irq_desc[M32R_IRQ_SIO0_R].chip = &m32700ut_irq_type;
        irq_desc[M32R_IRQ_SIO0_R].action = 0;
        irq_desc[M32R_IRQ_SIO0_R].depth = 1;
        icu_data[M32R_IRQ_SIO0_R].icucr = 0;
@@ -326,7 +326,7 @@ void __init init_IRQ(void)
 
        /* SIO0 : send */
        irq_desc[M32R_IRQ_SIO0_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_S].handler = &m32700ut_irq_type;
+       irq_desc[M32R_IRQ_SIO0_S].chip = &m32700ut_irq_type;
        irq_desc[M32R_IRQ_SIO0_S].action = 0;
        irq_desc[M32R_IRQ_SIO0_S].depth = 1;
        icu_data[M32R_IRQ_SIO0_S].icucr = 0;
@@ -334,7 +334,7 @@ void __init init_IRQ(void)
 
        /* SIO1 : receive */
        irq_desc[M32R_IRQ_SIO1_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_R].handler = &m32700ut_irq_type;
+       irq_desc[M32R_IRQ_SIO1_R].chip = &m32700ut_irq_type;
        irq_desc[M32R_IRQ_SIO1_R].action = 0;
        irq_desc[M32R_IRQ_SIO1_R].depth = 1;
        icu_data[M32R_IRQ_SIO1_R].icucr = 0;
@@ -342,7 +342,7 @@ void __init init_IRQ(void)
 
        /* SIO1 : send */
        irq_desc[M32R_IRQ_SIO1_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_S].handler = &m32700ut_irq_type;
+       irq_desc[M32R_IRQ_SIO1_S].chip = &m32700ut_irq_type;
        irq_desc[M32R_IRQ_SIO1_S].action = 0;
        irq_desc[M32R_IRQ_SIO1_S].depth = 1;
        icu_data[M32R_IRQ_SIO1_S].icucr = 0;
@@ -350,7 +350,7 @@ void __init init_IRQ(void)
 
        /* DMA1 : */
        irq_desc[M32R_IRQ_DMA1].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_DMA1].handler = &m32700ut_irq_type;
+       irq_desc[M32R_IRQ_DMA1].chip = &m32700ut_irq_type;
        irq_desc[M32R_IRQ_DMA1].action = 0;
        irq_desc[M32R_IRQ_DMA1].depth = 1;
        icu_data[M32R_IRQ_DMA1].icucr = 0;
@@ -359,7 +359,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_SERIAL_M32R_PLDSIO
        /* INT#1: SIO0 Receive on PLD */
        irq_desc[PLD_IRQ_SIO0_RCV].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_SIO0_RCV].handler = &m32700ut_pld_irq_type;
+       irq_desc[PLD_IRQ_SIO0_RCV].chip = &m32700ut_pld_irq_type;
        irq_desc[PLD_IRQ_SIO0_RCV].action = 0;
        irq_desc[PLD_IRQ_SIO0_RCV].depth = 1;   /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_SIO0_RCV)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD03;
@@ -367,7 +367,7 @@ void __init init_IRQ(void)
 
        /* INT#1: SIO0 Send on PLD */
        irq_desc[PLD_IRQ_SIO0_SND].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_SIO0_SND].handler = &m32700ut_pld_irq_type;
+       irq_desc[PLD_IRQ_SIO0_SND].chip = &m32700ut_pld_irq_type;
        irq_desc[PLD_IRQ_SIO0_SND].action = 0;
        irq_desc[PLD_IRQ_SIO0_SND].depth = 1;   /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_SIO0_SND)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD03;
@@ -376,7 +376,7 @@ void __init init_IRQ(void)
 
        /* INT#1: CFC IREQ on PLD */
        irq_desc[PLD_IRQ_CFIREQ].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFIREQ].handler = &m32700ut_pld_irq_type;
+       irq_desc[PLD_IRQ_CFIREQ].chip = &m32700ut_pld_irq_type;
        irq_desc[PLD_IRQ_CFIREQ].action = 0;
        irq_desc[PLD_IRQ_CFIREQ].depth = 1;     /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_CFIREQ)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD01;       /* 'L' level sense */
@@ -384,7 +384,7 @@ void __init init_IRQ(void)
 
        /* INT#1: CFC Insert on PLD */
        irq_desc[PLD_IRQ_CFC_INSERT].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFC_INSERT].handler = &m32700ut_pld_irq_type;
+       irq_desc[PLD_IRQ_CFC_INSERT].chip = &m32700ut_pld_irq_type;
        irq_desc[PLD_IRQ_CFC_INSERT].action = 0;
        irq_desc[PLD_IRQ_CFC_INSERT].depth = 1; /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_CFC_INSERT)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD00;   /* 'L' edge sense */
@@ -392,7 +392,7 @@ void __init init_IRQ(void)
 
        /* INT#1: CFC Eject on PLD */
        irq_desc[PLD_IRQ_CFC_EJECT].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFC_EJECT].handler = &m32700ut_pld_irq_type;
+       irq_desc[PLD_IRQ_CFC_EJECT].chip = &m32700ut_pld_irq_type;
        irq_desc[PLD_IRQ_CFC_EJECT].action = 0;
        irq_desc[PLD_IRQ_CFC_EJECT].depth = 1;  /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_CFC_EJECT)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD02;    /* 'H' edge sense */
@@ -416,7 +416,7 @@ void __init init_IRQ(void)
        outw(USBCR_OTGS, USBCR);        /* USBCR: non-OTG */
 
     irq_desc[M32700UT_LCD_IRQ_USB_INT1].status = IRQ_DISABLED;
-    irq_desc[M32700UT_LCD_IRQ_USB_INT1].handler = &m32700ut_lcdpld_irq_type;
+    irq_desc[M32700UT_LCD_IRQ_USB_INT1].chip = &m32700ut_lcdpld_irq_type;
     irq_desc[M32700UT_LCD_IRQ_USB_INT1].action = 0;
     irq_desc[M32700UT_LCD_IRQ_USB_INT1].depth = 1;
     lcdpld_icu_data[irq2lcdpldirq(M32700UT_LCD_IRQ_USB_INT1)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD01; /* "L" level sense */
@@ -434,7 +434,7 @@ void __init init_IRQ(void)
         * INT3# is used for AR
         */
        irq_desc[M32R_IRQ_INT3].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT3].handler = &m32700ut_irq_type;
+       irq_desc[M32R_IRQ_INT3].chip = &m32700ut_irq_type;
        irq_desc[M32R_IRQ_INT3].action = 0;
        irq_desc[M32R_IRQ_INT3].depth = 1;
        icu_data[M32R_IRQ_INT3].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD10;
index 00f253209cb36a0fd8db56407ed88c9d75a5cde0..c268044185f543ed4ffd936996fb29e01c6f1e29 100644 (file)
@@ -86,7 +86,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_NE2000
        /* INT0 : LAN controller (RTL8019AS) */
        irq_desc[M32R_IRQ_INT0].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT0].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_INT0].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_INT0].action = 0;
        irq_desc[M32R_IRQ_INT0].depth = 1;
        icu_data[M32R_IRQ_INT0].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD10;
@@ -95,7 +95,7 @@ void __init init_IRQ(void)
 
        /* MFT2 : system timer */
        irq_desc[M32R_IRQ_MFT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_MFT2].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_MFT2].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_MFT2].action = 0;
        irq_desc[M32R_IRQ_MFT2].depth = 1;
        icu_data[M32R_IRQ_MFT2].icucr = M32R_ICUCR_IEN;
@@ -104,7 +104,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_SERIAL_M32R_SIO
        /* SIO0_R : uart receive data */
        irq_desc[M32R_IRQ_SIO0_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_R].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_SIO0_R].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_SIO0_R].action = 0;
        irq_desc[M32R_IRQ_SIO0_R].depth = 1;
        icu_data[M32R_IRQ_SIO0_R].icucr = 0;
@@ -112,7 +112,7 @@ void __init init_IRQ(void)
 
        /* SIO0_S : uart send data */
        irq_desc[M32R_IRQ_SIO0_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_S].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_SIO0_S].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_SIO0_S].action = 0;
        irq_desc[M32R_IRQ_SIO0_S].depth = 1;
        icu_data[M32R_IRQ_SIO0_S].icucr = 0;
@@ -120,7 +120,7 @@ void __init init_IRQ(void)
 
        /* SIO1_R : uart receive data */
        irq_desc[M32R_IRQ_SIO1_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_R].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_SIO1_R].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_SIO1_R].action = 0;
        irq_desc[M32R_IRQ_SIO1_R].depth = 1;
        icu_data[M32R_IRQ_SIO1_R].icucr = 0;
@@ -128,7 +128,7 @@ void __init init_IRQ(void)
 
        /* SIO1_S : uart send data */
        irq_desc[M32R_IRQ_SIO1_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_S].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_SIO1_S].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_SIO1_S].action = 0;
        irq_desc[M32R_IRQ_SIO1_S].depth = 1;
        icu_data[M32R_IRQ_SIO1_S].icucr = 0;
@@ -138,7 +138,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_M32R_PCC)
        /* INT1 : pccard0 interrupt */
        irq_desc[M32R_IRQ_INT1].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT1].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_INT1].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_INT1].action = 0;
        irq_desc[M32R_IRQ_INT1].depth = 1;
        icu_data[M32R_IRQ_INT1].icucr = M32R_ICUCR_IEN | M32R_ICUCR_ISMOD00;
@@ -146,7 +146,7 @@ void __init init_IRQ(void)
 
        /* INT2 : pccard1 interrupt */
        irq_desc[M32R_IRQ_INT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT2].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_INT2].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_INT2].action = 0;
        irq_desc[M32R_IRQ_INT2].depth = 1;
        icu_data[M32R_IRQ_INT2].icucr = M32R_ICUCR_IEN | M32R_ICUCR_ISMOD00;
index eebc9d8b4e72be56fc49df85fe84fca54def62ec..bd2327d5cca28a1528a8f0ae1fec9b83231a7fec 100644 (file)
@@ -87,7 +87,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_SMC91X)
        /* INT0 : LAN controller (SMC91111) */
        irq_desc[M32R_IRQ_INT0].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT0].handler = &mappi2_irq_type;
+       irq_desc[M32R_IRQ_INT0].chip = &mappi2_irq_type;
        irq_desc[M32R_IRQ_INT0].action = 0;
        irq_desc[M32R_IRQ_INT0].depth = 1;
        icu_data[M32R_IRQ_INT0].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD10;
@@ -96,7 +96,7 @@ void __init init_IRQ(void)
 
        /* MFT2 : system timer */
        irq_desc[M32R_IRQ_MFT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_MFT2].handler = &mappi2_irq_type;
+       irq_desc[M32R_IRQ_MFT2].chip = &mappi2_irq_type;
        irq_desc[M32R_IRQ_MFT2].action = 0;
        irq_desc[M32R_IRQ_MFT2].depth = 1;
        icu_data[M32R_IRQ_MFT2].icucr = M32R_ICUCR_IEN;
@@ -105,7 +105,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_SERIAL_M32R_SIO
        /* SIO0_R : uart receive data */
        irq_desc[M32R_IRQ_SIO0_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_R].handler = &mappi2_irq_type;
+       irq_desc[M32R_IRQ_SIO0_R].chip = &mappi2_irq_type;
        irq_desc[M32R_IRQ_SIO0_R].action = 0;
        irq_desc[M32R_IRQ_SIO0_R].depth = 1;
        icu_data[M32R_IRQ_SIO0_R].icucr = 0;
@@ -113,14 +113,14 @@ void __init init_IRQ(void)
 
        /* SIO0_S : uart send data */
        irq_desc[M32R_IRQ_SIO0_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_S].handler = &mappi2_irq_type;
+       irq_desc[M32R_IRQ_SIO0_S].chip = &mappi2_irq_type;
        irq_desc[M32R_IRQ_SIO0_S].action = 0;
        irq_desc[M32R_IRQ_SIO0_S].depth = 1;
        icu_data[M32R_IRQ_SIO0_S].icucr = 0;
        disable_mappi2_irq(M32R_IRQ_SIO0_S);
        /* SIO1_R : uart receive data */
        irq_desc[M32R_IRQ_SIO1_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_R].handler = &mappi2_irq_type;
+       irq_desc[M32R_IRQ_SIO1_R].chip = &mappi2_irq_type;
        irq_desc[M32R_IRQ_SIO1_R].action = 0;
        irq_desc[M32R_IRQ_SIO1_R].depth = 1;
        icu_data[M32R_IRQ_SIO1_R].icucr = 0;
@@ -128,7 +128,7 @@ void __init init_IRQ(void)
 
        /* SIO1_S : uart send data */
        irq_desc[M32R_IRQ_SIO1_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_S].handler = &mappi2_irq_type;
+       irq_desc[M32R_IRQ_SIO1_S].chip = &mappi2_irq_type;
        irq_desc[M32R_IRQ_SIO1_S].action = 0;
        irq_desc[M32R_IRQ_SIO1_S].depth = 1;
        icu_data[M32R_IRQ_SIO1_S].icucr = 0;
@@ -138,7 +138,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_USB)
        /* INT1 : USB Host controller interrupt */
        irq_desc[M32R_IRQ_INT1].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT1].handler = &mappi2_irq_type;
+       irq_desc[M32R_IRQ_INT1].chip = &mappi2_irq_type;
        irq_desc[M32R_IRQ_INT1].action = 0;
        irq_desc[M32R_IRQ_INT1].depth = 1;
        icu_data[M32R_IRQ_INT1].icucr = M32R_ICUCR_ISMOD01;
@@ -147,7 +147,7 @@ void __init init_IRQ(void)
 
        /* ICUCR40: CFC IREQ */
        irq_desc[PLD_IRQ_CFIREQ].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFIREQ].handler = &mappi2_irq_type;
+       irq_desc[PLD_IRQ_CFIREQ].chip = &mappi2_irq_type;
        irq_desc[PLD_IRQ_CFIREQ].action = 0;
        irq_desc[PLD_IRQ_CFIREQ].depth = 1;     /* disable nested irq */
        icu_data[PLD_IRQ_CFIREQ].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD01;
@@ -156,7 +156,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_M32R_CFC)
        /* ICUCR41: CFC Insert */
        irq_desc[PLD_IRQ_CFC_INSERT].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFC_INSERT].handler = &mappi2_irq_type;
+       irq_desc[PLD_IRQ_CFC_INSERT].chip = &mappi2_irq_type;
        irq_desc[PLD_IRQ_CFC_INSERT].action = 0;
        irq_desc[PLD_IRQ_CFC_INSERT].depth = 1; /* disable nested irq */
        icu_data[PLD_IRQ_CFC_INSERT].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD00;
@@ -164,7 +164,7 @@ void __init init_IRQ(void)
 
        /* ICUCR42: CFC Eject */
        irq_desc[PLD_IRQ_CFC_EJECT].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFC_EJECT].handler = &mappi2_irq_type;
+       irq_desc[PLD_IRQ_CFC_EJECT].chip = &mappi2_irq_type;
        irq_desc[PLD_IRQ_CFC_EJECT].action = 0;
        irq_desc[PLD_IRQ_CFC_EJECT].depth = 1;  /* disable nested irq */
        icu_data[PLD_IRQ_CFC_EJECT].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD10;
index d2ff021e2d3dc7d1acf2c7f2be0b77601210b1a4..014b51d17505a3e9fd047f79b82f20508d813d9d 100644 (file)
@@ -87,7 +87,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_SMC91X)
        /* INT0 : LAN controller (SMC91111) */
        irq_desc[M32R_IRQ_INT0].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT0].handler = &mappi3_irq_type;
+       irq_desc[M32R_IRQ_INT0].chip = &mappi3_irq_type;
        irq_desc[M32R_IRQ_INT0].action = 0;
        irq_desc[M32R_IRQ_INT0].depth = 1;
        icu_data[M32R_IRQ_INT0].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD10;
@@ -96,7 +96,7 @@ void __init init_IRQ(void)
 
        /* MFT2 : system timer */
        irq_desc[M32R_IRQ_MFT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_MFT2].handler = &mappi3_irq_type;
+       irq_desc[M32R_IRQ_MFT2].chip = &mappi3_irq_type;
        irq_desc[M32R_IRQ_MFT2].action = 0;
        irq_desc[M32R_IRQ_MFT2].depth = 1;
        icu_data[M32R_IRQ_MFT2].icucr = M32R_ICUCR_IEN;
@@ -105,7 +105,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_SERIAL_M32R_SIO
        /* SIO0_R : uart receive data */
        irq_desc[M32R_IRQ_SIO0_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_R].handler = &mappi3_irq_type;
+       irq_desc[M32R_IRQ_SIO0_R].chip = &mappi3_irq_type;
        irq_desc[M32R_IRQ_SIO0_R].action = 0;
        irq_desc[M32R_IRQ_SIO0_R].depth = 1;
        icu_data[M32R_IRQ_SIO0_R].icucr = 0;
@@ -113,14 +113,14 @@ void __init init_IRQ(void)
 
        /* SIO0_S : uart send data */
        irq_desc[M32R_IRQ_SIO0_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_S].handler = &mappi3_irq_type;
+       irq_desc[M32R_IRQ_SIO0_S].chip = &mappi3_irq_type;
        irq_desc[M32R_IRQ_SIO0_S].action = 0;
        irq_desc[M32R_IRQ_SIO0_S].depth = 1;
        icu_data[M32R_IRQ_SIO0_S].icucr = 0;
        disable_mappi3_irq(M32R_IRQ_SIO0_S);
        /* SIO1_R : uart receive data */
        irq_desc[M32R_IRQ_SIO1_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_R].handler = &mappi3_irq_type;
+       irq_desc[M32R_IRQ_SIO1_R].chip = &mappi3_irq_type;
        irq_desc[M32R_IRQ_SIO1_R].action = 0;
        irq_desc[M32R_IRQ_SIO1_R].depth = 1;
        icu_data[M32R_IRQ_SIO1_R].icucr = 0;
@@ -128,7 +128,7 @@ void __init init_IRQ(void)
 
        /* SIO1_S : uart send data */
        irq_desc[M32R_IRQ_SIO1_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_S].handler = &mappi3_irq_type;
+       irq_desc[M32R_IRQ_SIO1_S].chip = &mappi3_irq_type;
        irq_desc[M32R_IRQ_SIO1_S].action = 0;
        irq_desc[M32R_IRQ_SIO1_S].depth = 1;
        icu_data[M32R_IRQ_SIO1_S].icucr = 0;
@@ -138,7 +138,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_USB)
        /* INT1 : USB Host controller interrupt */
        irq_desc[M32R_IRQ_INT1].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT1].handler = &mappi3_irq_type;
+       irq_desc[M32R_IRQ_INT1].chip = &mappi3_irq_type;
        irq_desc[M32R_IRQ_INT1].action = 0;
        irq_desc[M32R_IRQ_INT1].depth = 1;
        icu_data[M32R_IRQ_INT1].icucr = M32R_ICUCR_ISMOD01;
@@ -147,7 +147,7 @@ void __init init_IRQ(void)
 
        /* CFC IREQ */
        irq_desc[PLD_IRQ_CFIREQ].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFIREQ].handler = &mappi3_irq_type;
+       irq_desc[PLD_IRQ_CFIREQ].chip = &mappi3_irq_type;
        irq_desc[PLD_IRQ_CFIREQ].action = 0;
        irq_desc[PLD_IRQ_CFIREQ].depth = 1;     /* disable nested irq */
        icu_data[PLD_IRQ_CFIREQ].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD01;
@@ -156,7 +156,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_M32R_CFC)
        /* ICUCR41: CFC Insert & eject */
        irq_desc[PLD_IRQ_CFC_INSERT].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFC_INSERT].handler = &mappi3_irq_type;
+       irq_desc[PLD_IRQ_CFC_INSERT].chip = &mappi3_irq_type;
        irq_desc[PLD_IRQ_CFC_INSERT].action = 0;
        irq_desc[PLD_IRQ_CFC_INSERT].depth = 1; /* disable nested irq */
        icu_data[PLD_IRQ_CFC_INSERT].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD00;
@@ -166,7 +166,7 @@ void __init init_IRQ(void)
 
        /* IDE IREQ */
        irq_desc[PLD_IRQ_IDEIREQ].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_IDEIREQ].handler = &mappi3_irq_type;
+       irq_desc[PLD_IRQ_IDEIREQ].chip = &mappi3_irq_type;
        irq_desc[PLD_IRQ_IDEIREQ].action = 0;
        irq_desc[PLD_IRQ_IDEIREQ].depth = 1;    /* disable nested irq */
        icu_data[PLD_IRQ_IDEIREQ].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD10;
index 0e9e63538c0f051cd95cedf7659c9e845d5c2cb3..ea64831aef7ad536869cfdd9dccb63c6ca47b3f6 100644 (file)
@@ -85,7 +85,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_NE2000
        /* INT3 : LAN controller (RTL8019AS) */
        irq_desc[M32R_IRQ_INT3].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT3].handler = &oaks32r_irq_type;
+       irq_desc[M32R_IRQ_INT3].chip = &oaks32r_irq_type;
        irq_desc[M32R_IRQ_INT3].action = 0;
        irq_desc[M32R_IRQ_INT3].depth = 1;
        icu_data[M32R_IRQ_INT3].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD10;
@@ -94,7 +94,7 @@ void __init init_IRQ(void)
 
        /* MFT2 : system timer */
        irq_desc[M32R_IRQ_MFT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_MFT2].handler = &oaks32r_irq_type;
+       irq_desc[M32R_IRQ_MFT2].chip = &oaks32r_irq_type;
        irq_desc[M32R_IRQ_MFT2].action = 0;
        irq_desc[M32R_IRQ_MFT2].depth = 1;
        icu_data[M32R_IRQ_MFT2].icucr = M32R_ICUCR_IEN;
@@ -103,7 +103,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_SERIAL_M32R_SIO
        /* SIO0_R : uart receive data */
        irq_desc[M32R_IRQ_SIO0_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_R].handler = &oaks32r_irq_type;
+       irq_desc[M32R_IRQ_SIO0_R].chip = &oaks32r_irq_type;
        irq_desc[M32R_IRQ_SIO0_R].action = 0;
        irq_desc[M32R_IRQ_SIO0_R].depth = 1;
        icu_data[M32R_IRQ_SIO0_R].icucr = 0;
@@ -111,7 +111,7 @@ void __init init_IRQ(void)
 
        /* SIO0_S : uart send data */
        irq_desc[M32R_IRQ_SIO0_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_S].handler = &oaks32r_irq_type;
+       irq_desc[M32R_IRQ_SIO0_S].chip = &oaks32r_irq_type;
        irq_desc[M32R_IRQ_SIO0_S].action = 0;
        irq_desc[M32R_IRQ_SIO0_S].depth = 1;
        icu_data[M32R_IRQ_SIO0_S].icucr = 0;
@@ -119,7 +119,7 @@ void __init init_IRQ(void)
 
        /* SIO1_R : uart receive data */
        irq_desc[M32R_IRQ_SIO1_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_R].handler = &oaks32r_irq_type;
+       irq_desc[M32R_IRQ_SIO1_R].chip = &oaks32r_irq_type;
        irq_desc[M32R_IRQ_SIO1_R].action = 0;
        irq_desc[M32R_IRQ_SIO1_R].depth = 1;
        icu_data[M32R_IRQ_SIO1_R].icucr = 0;
@@ -127,7 +127,7 @@ void __init init_IRQ(void)
 
        /* SIO1_S : uart send data */
        irq_desc[M32R_IRQ_SIO1_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_S].handler = &oaks32r_irq_type;
+       irq_desc[M32R_IRQ_SIO1_S].chip = &oaks32r_irq_type;
        irq_desc[M32R_IRQ_SIO1_S].action = 0;
        irq_desc[M32R_IRQ_SIO1_S].depth = 1;
        icu_data[M32R_IRQ_SIO1_S].icucr = 0;
index 548e8fc7949b113a39a697f1cce1407b03c938f5..55e8972d455aedd27a132766a3c89ad42f388474 100644 (file)
@@ -302,7 +302,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_SMC91X)
        /* INT#0: LAN controller on OPSPUT-LAN (SMC91C111)*/
        irq_desc[OPSPUT_LAN_IRQ_LAN].status = IRQ_DISABLED;
-       irq_desc[OPSPUT_LAN_IRQ_LAN].handler = &opsput_lanpld_irq_type;
+       irq_desc[OPSPUT_LAN_IRQ_LAN].chip = &opsput_lanpld_irq_type;
        irq_desc[OPSPUT_LAN_IRQ_LAN].action = 0;
        irq_desc[OPSPUT_LAN_IRQ_LAN].depth = 1; /* disable nested irq */
        lanpld_icu_data[irq2lanpldirq(OPSPUT_LAN_IRQ_LAN)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD02;     /* "H" edge sense */
@@ -311,7 +311,7 @@ void __init init_IRQ(void)
 
        /* MFT2 : system timer */
        irq_desc[M32R_IRQ_MFT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_MFT2].handler = &opsput_irq_type;
+       irq_desc[M32R_IRQ_MFT2].chip = &opsput_irq_type;
        irq_desc[M32R_IRQ_MFT2].action = 0;
        irq_desc[M32R_IRQ_MFT2].depth = 1;
        icu_data[M32R_IRQ_MFT2].icucr = M32R_ICUCR_IEN;
@@ -319,7 +319,7 @@ void __init init_IRQ(void)
 
        /* SIO0 : receive */
        irq_desc[M32R_IRQ_SIO0_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_R].handler = &opsput_irq_type;
+       irq_desc[M32R_IRQ_SIO0_R].chip = &opsput_irq_type;
        irq_desc[M32R_IRQ_SIO0_R].action = 0;
        irq_desc[M32R_IRQ_SIO0_R].depth = 1;
        icu_data[M32R_IRQ_SIO0_R].icucr = 0;
@@ -327,7 +327,7 @@ void __init init_IRQ(void)
 
        /* SIO0 : send */
        irq_desc[M32R_IRQ_SIO0_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_S].handler = &opsput_irq_type;
+       irq_desc[M32R_IRQ_SIO0_S].chip = &opsput_irq_type;
        irq_desc[M32R_IRQ_SIO0_S].action = 0;
        irq_desc[M32R_IRQ_SIO0_S].depth = 1;
        icu_data[M32R_IRQ_SIO0_S].icucr = 0;
@@ -335,7 +335,7 @@ void __init init_IRQ(void)
 
        /* SIO1 : receive */
        irq_desc[M32R_IRQ_SIO1_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_R].handler = &opsput_irq_type;
+       irq_desc[M32R_IRQ_SIO1_R].chip = &opsput_irq_type;
        irq_desc[M32R_IRQ_SIO1_R].action = 0;
        irq_desc[M32R_IRQ_SIO1_R].depth = 1;
        icu_data[M32R_IRQ_SIO1_R].icucr = 0;
@@ -343,7 +343,7 @@ void __init init_IRQ(void)
 
        /* SIO1 : send */
        irq_desc[M32R_IRQ_SIO1_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_S].handler = &opsput_irq_type;
+       irq_desc[M32R_IRQ_SIO1_S].chip = &opsput_irq_type;
        irq_desc[M32R_IRQ_SIO1_S].action = 0;
        irq_desc[M32R_IRQ_SIO1_S].depth = 1;
        icu_data[M32R_IRQ_SIO1_S].icucr = 0;
@@ -351,7 +351,7 @@ void __init init_IRQ(void)
 
        /* DMA1 : */
        irq_desc[M32R_IRQ_DMA1].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_DMA1].handler = &opsput_irq_type;
+       irq_desc[M32R_IRQ_DMA1].chip = &opsput_irq_type;
        irq_desc[M32R_IRQ_DMA1].action = 0;
        irq_desc[M32R_IRQ_DMA1].depth = 1;
        icu_data[M32R_IRQ_DMA1].icucr = 0;
@@ -360,7 +360,7 @@ void __init init_IRQ(void)
 #ifdef CONFIG_SERIAL_M32R_PLDSIO
        /* INT#1: SIO0 Receive on PLD */
        irq_desc[PLD_IRQ_SIO0_RCV].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_SIO0_RCV].handler = &opsput_pld_irq_type;
+       irq_desc[PLD_IRQ_SIO0_RCV].chip = &opsput_pld_irq_type;
        irq_desc[PLD_IRQ_SIO0_RCV].action = 0;
        irq_desc[PLD_IRQ_SIO0_RCV].depth = 1;   /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_SIO0_RCV)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD03;
@@ -368,7 +368,7 @@ void __init init_IRQ(void)
 
        /* INT#1: SIO0 Send on PLD */
        irq_desc[PLD_IRQ_SIO0_SND].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_SIO0_SND].handler = &opsput_pld_irq_type;
+       irq_desc[PLD_IRQ_SIO0_SND].chip = &opsput_pld_irq_type;
        irq_desc[PLD_IRQ_SIO0_SND].action = 0;
        irq_desc[PLD_IRQ_SIO0_SND].depth = 1;   /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_SIO0_SND)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD03;
@@ -378,7 +378,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_M32R_CFC)
        /* INT#1: CFC IREQ on PLD */
        irq_desc[PLD_IRQ_CFIREQ].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFIREQ].handler = &opsput_pld_irq_type;
+       irq_desc[PLD_IRQ_CFIREQ].chip = &opsput_pld_irq_type;
        irq_desc[PLD_IRQ_CFIREQ].action = 0;
        irq_desc[PLD_IRQ_CFIREQ].depth = 1;     /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_CFIREQ)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD01;       /* 'L' level sense */
@@ -386,7 +386,7 @@ void __init init_IRQ(void)
 
        /* INT#1: CFC Insert on PLD */
        irq_desc[PLD_IRQ_CFC_INSERT].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFC_INSERT].handler = &opsput_pld_irq_type;
+       irq_desc[PLD_IRQ_CFC_INSERT].chip = &opsput_pld_irq_type;
        irq_desc[PLD_IRQ_CFC_INSERT].action = 0;
        irq_desc[PLD_IRQ_CFC_INSERT].depth = 1; /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_CFC_INSERT)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD00;   /* 'L' edge sense */
@@ -394,7 +394,7 @@ void __init init_IRQ(void)
 
        /* INT#1: CFC Eject on PLD */
        irq_desc[PLD_IRQ_CFC_EJECT].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_CFC_EJECT].handler = &opsput_pld_irq_type;
+       irq_desc[PLD_IRQ_CFC_EJECT].chip = &opsput_pld_irq_type;
        irq_desc[PLD_IRQ_CFC_EJECT].action = 0;
        irq_desc[PLD_IRQ_CFC_EJECT].depth = 1;  /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_CFC_EJECT)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD02;    /* 'H' edge sense */
@@ -420,7 +420,7 @@ void __init init_IRQ(void)
        outw(USBCR_OTGS, USBCR);        /* USBCR: non-OTG */
 
     irq_desc[OPSPUT_LCD_IRQ_USB_INT1].status = IRQ_DISABLED;
-    irq_desc[OPSPUT_LCD_IRQ_USB_INT1].handler = &opsput_lcdpld_irq_type;
+    irq_desc[OPSPUT_LCD_IRQ_USB_INT1].chip = &opsput_lcdpld_irq_type;
     irq_desc[OPSPUT_LCD_IRQ_USB_INT1].action = 0;
     irq_desc[OPSPUT_LCD_IRQ_USB_INT1].depth = 1;
     lcdpld_icu_data[irq2lcdpldirq(OPSPUT_LCD_IRQ_USB_INT1)].icucr = PLD_ICUCR_IEN|PLD_ICUCR_ISMOD01;   /* "L" level sense */
@@ -438,7 +438,7 @@ void __init init_IRQ(void)
         * INT3# is used for AR
         */
        irq_desc[M32R_IRQ_INT3].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_INT3].handler = &opsput_irq_type;
+       irq_desc[M32R_IRQ_INT3].chip = &opsput_irq_type;
        irq_desc[M32R_IRQ_INT3].action = 0;
        irq_desc[M32R_IRQ_INT3].depth = 1;
        icu_data[M32R_IRQ_INT3].icucr = M32R_ICUCR_IEN|M32R_ICUCR_ISMOD10;
index 64be659a23e7efca76532e72e84c952ec6bd76a3..7fa12d8f66b47d63d8695422d429cc515a7a1f10 100644 (file)
@@ -158,7 +158,7 @@ void __init init_IRQ(void)
 
        /* MFT2 : system timer */
        irq_desc[M32R_IRQ_MFT2].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_MFT2].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_MFT2].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_MFT2].action = 0;
        irq_desc[M32R_IRQ_MFT2].depth = 1;
        icu_data[M32R_IRQ_MFT2].icucr = M32R_ICUCR_IEN;
@@ -167,7 +167,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_SERIAL_M32R_SIO)
        /* SIO0_R : uart receive data */
        irq_desc[M32R_IRQ_SIO0_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_R].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_SIO0_R].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_SIO0_R].action = 0;
        irq_desc[M32R_IRQ_SIO0_R].depth = 1;
        icu_data[M32R_IRQ_SIO0_R].icucr = 0;
@@ -175,7 +175,7 @@ void __init init_IRQ(void)
 
        /* SIO0_S : uart send data */
        irq_desc[M32R_IRQ_SIO0_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO0_S].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_SIO0_S].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_SIO0_S].action = 0;
        irq_desc[M32R_IRQ_SIO0_S].depth = 1;
        icu_data[M32R_IRQ_SIO0_S].icucr = 0;
@@ -183,7 +183,7 @@ void __init init_IRQ(void)
 
        /* SIO1_R : uart receive data */
        irq_desc[M32R_IRQ_SIO1_R].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_R].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_SIO1_R].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_SIO1_R].action = 0;
        irq_desc[M32R_IRQ_SIO1_R].depth = 1;
        icu_data[M32R_IRQ_SIO1_R].icucr = 0;
@@ -191,7 +191,7 @@ void __init init_IRQ(void)
 
        /* SIO1_S : uart send data */
        irq_desc[M32R_IRQ_SIO1_S].status = IRQ_DISABLED;
-       irq_desc[M32R_IRQ_SIO1_S].handler = &mappi_irq_type;
+       irq_desc[M32R_IRQ_SIO1_S].chip = &mappi_irq_type;
        irq_desc[M32R_IRQ_SIO1_S].action = 0;
        irq_desc[M32R_IRQ_SIO1_S].depth = 1;
        icu_data[M32R_IRQ_SIO1_S].icucr = 0;
@@ -201,7 +201,7 @@ void __init init_IRQ(void)
        /* INT#67-#71: CFC#0 IREQ on PLD */
        for (i = 0 ; i < CONFIG_CFC_NUM ; i++ ) {
                irq_desc[PLD_IRQ_CF0 + i].status = IRQ_DISABLED;
-               irq_desc[PLD_IRQ_CF0 + i].handler = &m32700ut_pld_irq_type;
+               irq_desc[PLD_IRQ_CF0 + i].chip = &m32700ut_pld_irq_type;
                irq_desc[PLD_IRQ_CF0 + i].action = 0;
                irq_desc[PLD_IRQ_CF0 + i].depth = 1;    /* disable nested irq */
                pld_icu_data[irq2pldirq(PLD_IRQ_CF0 + i)].icucr
@@ -212,7 +212,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_SERIAL_8250) || defined(CONFIG_SERIAL_8250_MODULE)
        /* INT#76: 16552D#0 IREQ on PLD */
        irq_desc[PLD_IRQ_UART0].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_UART0].handler = &m32700ut_pld_irq_type;
+       irq_desc[PLD_IRQ_UART0].chip = &m32700ut_pld_irq_type;
        irq_desc[PLD_IRQ_UART0].action = 0;
        irq_desc[PLD_IRQ_UART0].depth = 1;      /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_UART0)].icucr
@@ -221,7 +221,7 @@ void __init init_IRQ(void)
 
        /* INT#77: 16552D#1 IREQ on PLD */
        irq_desc[PLD_IRQ_UART1].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_UART1].handler = &m32700ut_pld_irq_type;
+       irq_desc[PLD_IRQ_UART1].chip = &m32700ut_pld_irq_type;
        irq_desc[PLD_IRQ_UART1].action = 0;
        irq_desc[PLD_IRQ_UART1].depth = 1;      /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_UART1)].icucr
@@ -232,7 +232,7 @@ void __init init_IRQ(void)
 #if defined(CONFIG_IDC_AK4524) || defined(CONFIG_IDC_AK4524_MODULE)
        /* INT#80: AK4524 IREQ on PLD */
        irq_desc[PLD_IRQ_SNDINT].status = IRQ_DISABLED;
-       irq_desc[PLD_IRQ_SNDINT].handler = &m32700ut_pld_irq_type;
+       irq_desc[PLD_IRQ_SNDINT].chip = &m32700ut_pld_irq_type;
        irq_desc[PLD_IRQ_SNDINT].action = 0;
        irq_desc[PLD_IRQ_SNDINT].depth = 1;     /* disable nested irq */
        pld_icu_data[irq2pldirq(PLD_IRQ_SNDINT)].icucr
index 8670938f1107a5f9c6a03d2e9bce29ca2d53f19e..db7a0c1cebae8dfe88ad393fa47eefc711790fdc 100644 (file)
@@ -357,7 +357,8 @@ void pcibios_fixup_bus(struct pci_bus *b)
 
 /*****************************************************************************/
 
-void pcibios_align_resource(void *data, struct resource *res, unsigned long size, unsigned long align)
+void pcibios_align_resource(void *data, struct resource *res,
+                               resource_size_t size, resource_size_t align)
 {
 }
 
index 35e038a974c6227940cc4ebe7c5ead85d52e4a65..08c2ece4ae405387d51269b80eec228dbee18dd7 100644 (file)
@@ -1618,6 +1618,11 @@ config GENERIC_IRQ_PROBE
        bool
        default y
 
+config IRQ_PER_CPU
+       depends on SMP
+       bool
+       default y
+
 #
 # - Highmem only makes sense for the 32-bit kernel.
 # - The current highmem code will only work properly on physically indexed
index afe05ec12c27d31326d73937081eb7e0631d1c33..da74ac21954bb573408c7936b471092cb03a50d9 100644 (file)
@@ -333,31 +333,31 @@ static void setup_local_irq(unsigned int irq_nr, int type, int int_req)
                                au_writel(1<<(irq_nr-32), IC1_CFG2CLR);
                                au_writel(1<<(irq_nr-32), IC1_CFG1CLR);
                                au_writel(1<<(irq_nr-32), IC1_CFG0SET);
-                               irq_desc[irq_nr].handler = &rise_edge_irq_type;
+                               irq_desc[irq_nr].chip = &rise_edge_irq_type;
                                break;
                        case INTC_INT_FALL_EDGE: /* 0:1:0 */
                                au_writel(1<<(irq_nr-32), IC1_CFG2CLR);
                                au_writel(1<<(irq_nr-32), IC1_CFG1SET);
                                au_writel(1<<(irq_nr-32), IC1_CFG0CLR);
-                               irq_desc[irq_nr].handler = &fall_edge_irq_type;
+                               irq_desc[irq_nr].chip = &fall_edge_irq_type;
                                break;
                        case INTC_INT_RISE_AND_FALL_EDGE: /* 0:1:1 */
                                au_writel(1<<(irq_nr-32), IC1_CFG2CLR);
                                au_writel(1<<(irq_nr-32), IC1_CFG1SET);
                                au_writel(1<<(irq_nr-32), IC1_CFG0SET);
-                               irq_desc[irq_nr].handler = &either_edge_irq_type;
+                               irq_desc[irq_nr].chip = &either_edge_irq_type;
                                break;
                        case INTC_INT_HIGH_LEVEL: /* 1:0:1 */
                                au_writel(1<<(irq_nr-32), IC1_CFG2SET);
                                au_writel(1<<(irq_nr-32), IC1_CFG1CLR);
                                au_writel(1<<(irq_nr-32), IC1_CFG0SET);
-                               irq_desc[irq_nr].handler = &level_irq_type;
+                               irq_desc[irq_nr].chip = &level_irq_type;
                                break;
                        case INTC_INT_LOW_LEVEL: /* 1:1:0 */
                                au_writel(1<<(irq_nr-32), IC1_CFG2SET);
                                au_writel(1<<(irq_nr-32), IC1_CFG1SET);
                                au_writel(1<<(irq_nr-32), IC1_CFG0CLR);
-                               irq_desc[irq_nr].handler = &level_irq_type;
+                               irq_desc[irq_nr].chip = &level_irq_type;
                                break;
                        case INTC_INT_DISABLED: /* 0:0:0 */
                                au_writel(1<<(irq_nr-32), IC1_CFG0CLR);
@@ -385,31 +385,31 @@ static void setup_local_irq(unsigned int irq_nr, int type, int int_req)
                                au_writel(1<<irq_nr, IC0_CFG2CLR);
                                au_writel(1<<irq_nr, IC0_CFG1CLR);
                                au_writel(1<<irq_nr, IC0_CFG0SET);
-                               irq_desc[irq_nr].handler = &rise_edge_irq_type;
+                               irq_desc[irq_nr].chip = &rise_edge_irq_type;
                                break;
                        case INTC_INT_FALL_EDGE: /* 0:1:0 */
                                au_writel(1<<irq_nr, IC0_CFG2CLR);
                                au_writel(1<<irq_nr, IC0_CFG1SET);
                                au_writel(1<<irq_nr, IC0_CFG0CLR);
-                               irq_desc[irq_nr].handler = &fall_edge_irq_type;
+                               irq_desc[irq_nr].chip = &fall_edge_irq_type;
                                break;
                        case INTC_INT_RISE_AND_FALL_EDGE: /* 0:1:1 */
                                au_writel(1<<irq_nr, IC0_CFG2CLR);
                                au_writel(1<<irq_nr, IC0_CFG1SET);
                                au_writel(1<<irq_nr, IC0_CFG0SET);
-                               irq_desc[irq_nr].handler = &either_edge_irq_type;
+                               irq_desc[irq_nr].chip = &either_edge_irq_type;
                                break;
                        case INTC_INT_HIGH_LEVEL: /* 1:0:1 */
                                au_writel(1<<irq_nr, IC0_CFG2SET);
                                au_writel(1<<irq_nr, IC0_CFG1CLR);
                                au_writel(1<<irq_nr, IC0_CFG0SET);
-                               irq_desc[irq_nr].handler = &level_irq_type;
+                               irq_desc[irq_nr].chip = &level_irq_type;
                                break;
                        case INTC_INT_LOW_LEVEL: /* 1:1:0 */
                                au_writel(1<<irq_nr, IC0_CFG2SET);
                                au_writel(1<<irq_nr, IC0_CFG1SET);
                                au_writel(1<<irq_nr, IC0_CFG0CLR);
-                               irq_desc[irq_nr].handler = &level_irq_type;
+                               irq_desc[irq_nr].chip = &level_irq_type;
                                break;
                        case INTC_INT_DISABLED: /* 0:0:0 */
                                au_writel(1<<irq_nr, IC0_CFG0CLR);
index bacc0c6bfe675e5f3570371ea4f98a9004664ee7..5dd164fc1889290e243d0855ba1978aecf932dc7 100644 (file)
@@ -172,7 +172,7 @@ void _board_init_irq(void)
 
        for (irq_nr = PB1200_INT_BEGIN; irq_nr <= PB1200_INT_END; irq_nr++)
        {
-               irq_desc[irq_nr].handler = &external_irq_type;
+               irq_desc[irq_nr].chip = &external_irq_type;
                pb1200_disable_irq(irq_nr);
        }
 
index 5fcd5f070cdcf6a52cdf5a9ed52185be36932fbb..63c3d6534b3a108bd8d87d11838d585fea80e790 100644 (file)
@@ -107,7 +107,7 @@ void __init vrc5477_irq_init(u32 irq_base)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = NULL;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &vrc5477_irq_controller;
+               irq_desc[i].chip = &vrc5477_irq_controller;
        }
 
        vrc5477_irq_base = irq_base;
index d5bca5d233b6e6b67d32546d7789b9be1052926f..da2dbb42f913fc21bfd7dd0177d5ec393ae5a82c 100644 (file)
@@ -144,13 +144,13 @@ void __init init_ioasic_irqs(int base)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &ioasic_irq_type;
+               irq_desc[i].chip = &ioasic_irq_type;
        }
        for (; i < base + IO_IRQ_LINES; i++) {
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &ioasic_dma_irq_type;
+               irq_desc[i].chip = &ioasic_dma_irq_type;
        }
 
        ioasic_irq_base = base;
index 898bed502a348fb3a7572e8bd65d550a20d0f46c..d44c00d9e80fa973f32100d4e8c192d4d53b741c 100644 (file)
@@ -123,7 +123,7 @@ void __init init_kn02_irqs(int base)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &kn02_irq_type;
+               irq_desc[i].chip = &kn02_irq_type;
        }
 
        kn02_irq_base = base;
index 46c468b26b30879c72b82e01e52a271b32e61d2a..f489a8067a93fa46570378fd85a5345beb78226c 100644 (file)
@@ -138,7 +138,7 @@ void __init arch_init_irq(void)
        /*  Let's initialize our IRQ descriptors  */
        for (i = 0; i < NR_IRQS; i++) {
                irq_desc[i].status = 0;
-               irq_desc[i].handler = &no_irq_type;
+               irq_desc[i].chip = &no_irq_type;
                irq_desc[i].action = NULL;
                irq_desc[i].depth = 0;
                spin_lock_init(&irq_desc[i].lock);
index 77be7216bdd091430735ccb89c1e356144a779fd..a6749c56fe38d620ea29ca4546fc6a79baf31470 100644 (file)
@@ -208,10 +208,10 @@ void __init arch_init_irq(void)
 #endif
 
        for (i = 0; i <= IT8172_LAST_IRQ; i++) {
-               irq_desc[i].handler = &it8172_irq_type;
+               irq_desc[i].chip = &it8172_irq_type;
                spin_lock_init(&irq_desc[i].lock);
        }
-       irq_desc[MIPS_CPU_TIMER_IRQ].handler = &cp0_irq_type;
+       irq_desc[MIPS_CPU_TIMER_IRQ].chip = &cp0_irq_type;
        set_c0_status(ALLINTS_NOTIMER);
 }
 
index becc9accd49573e5d24e052a8e3d8e2e40699339..478be9858a1e04117eb3456e2200119a083b9f04 100644 (file)
@@ -73,7 +73,7 @@ void __init init_r4030_ints(void)
                irq_desc[i].status     = IRQ_DISABLED;
                irq_desc[i].action     = 0;
                irq_desc[i].depth      = 1;
-               irq_desc[i].handler    = &r4030_irq_type;
+               irq_desc[i].chip    = &r4030_irq_type;
        }
 
        r4030_write_reg16(JAZZ_IO_IRQ_ENABLE, 0);
index 11304d1354f45b0d47afc511e9a7811fa9383ca6..380046ea1db55103f5ddbcc2c23e459b951c04ac 100644 (file)
@@ -435,7 +435,7 @@ void jmr3927_irq_init(u32 irq_base)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = NULL;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &jmr3927_irq_controller;
+               irq_desc[i].chip = &jmr3927_irq_controller;
        }
 
        jmr3927_irq_base = irq_base;
index 0cb8ed5662f3d2cbaa1f0ac6cde7cbfa6f5ff8bb..91ffb1233cad92cda4ce6ad163bc880798f7533a 100644 (file)
@@ -120,7 +120,7 @@ int i8259A_irq_pending(unsigned int irq)
 void make_8259A_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &i8259A_irq_type;
+       irq_desc[irq].chip = &i8259A_irq_type;
        enable_irq(irq);
 }
 
@@ -327,7 +327,7 @@ void __init init_i8259_irqs (void)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = NULL;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &i8259A_irq_type;
+               irq_desc[i].chip = &i8259A_irq_type;
        }
 
        setup_irq(2, &irq2);
index 97ebdc754b9e6e8a59a1edf02611819872e606fb..f8cd1ac64d88314785849eec94f3d801b49943d7 100644 (file)
@@ -174,14 +174,14 @@ void __init init_msc_irqs(unsigned int base, msc_irqmap_t *imp, int nirq)
 
                switch (imp->im_type) {
                case MSC01_IRQ_EDGE:
-                       irq_desc[base+n].handler = &msc_edgeirq_type;
+                       irq_desc[base+n].chip = &msc_edgeirq_type;
                        if (cpu_has_veic)
                                MSCIC_WRITE(MSC01_IC_SUP+n*8, MSC01_IC_SUP_EDGE_BIT);
                        else
                                MSCIC_WRITE(MSC01_IC_SUP+n*8, MSC01_IC_SUP_EDGE_BIT | imp->im_lvl);
                        break;
                case MSC01_IRQ_LEVEL:
-                       irq_desc[base+n].handler = &msc_levelirq_type;
+                       irq_desc[base+n].chip = &msc_levelirq_type;
                        if (cpu_has_veic)
                                MSCIC_WRITE(MSC01_IC_SUP+n*8, 0);
                        else
index 0613f1f36b1bb0f9dabb0adfcbfbf98b5d378e3c..f9c763a65547f0cc8760aaa8eaf61d8bdbe7d1b4 100644 (file)
@@ -155,7 +155,7 @@ void __init mv64340_irq_init(unsigned int base)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 2;
-               irq_desc[i].handler = &mv64340_irq_type;
+               irq_desc[i].chip = &mv64340_irq_type;
        }
 
        irq_base = base;
index 0b130c5ac5d915d6eee4df811cd4b7a5543b2c50..121da385a94d05216488abe15a20b398521e5ff4 100644 (file)
@@ -91,7 +91,7 @@ void __init rm7k_cpu_irq_init(int base)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = NULL;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &rm7k_irq_controller;
+               irq_desc[i].chip = &rm7k_irq_controller;
        }
 
        irq_base = base;
index 9b5f20c32acb97177b946fdb1c1a863c1a03cd1b..25109c103e44dff4ed3216ce45f7f27a39bc1732 100644 (file)
@@ -139,11 +139,11 @@ void __init rm9k_cpu_irq_init(int base)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = NULL;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &rm9k_irq_controller;
+               irq_desc[i].chip = &rm9k_irq_controller;
        }
 
        rm9000_perfcount_irq = base + 1;
-       irq_desc[rm9000_perfcount_irq].handler = &rm9k_perfcounter_irq;
+       irq_desc[rm9000_perfcount_irq].chip = &rm9k_perfcounter_irq;
 
        irq_base = base;
 }
index 3dce742e716fd3df1b36920dc3606d2e91fb056b..5c9dcd5eed59e7cf3459381990e873346d329d5a 100644 (file)
@@ -95,7 +95,7 @@ int show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
 #endif
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
@@ -137,7 +137,7 @@ void __init init_IRQ(void)
                irq_desc[i].status  = IRQ_DISABLED;
                irq_desc[i].action  = NULL;
                irq_desc[i].depth   = 1;
-               irq_desc[i].handler = &no_irq_type;
+               irq_desc[i].chip = &no_irq_type;
                spin_lock_init(&irq_desc[i].lock);
 #ifdef CONFIG_MIPS_MT_SMTC
                irq_hwmask[i] = 0;
index 5db67e31ec1accf28c0150ed43a8d91176a3609a..0e455a8ad860d612fa282a775d962275cc5f589e 100644 (file)
@@ -167,14 +167,14 @@ void __init mips_cpu_irq_init(int irq_base)
                        irq_desc[i].status = IRQ_DISABLED;
                        irq_desc[i].action = NULL;
                        irq_desc[i].depth = 1;
-                       irq_desc[i].handler = &mips_mt_cpu_irq_controller;
+                       irq_desc[i].chip = &mips_mt_cpu_irq_controller;
                }
 
        for (i = irq_base + 2; i < irq_base + 8; i++) {
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = NULL;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &mips_cpu_irq_controller;
+               irq_desc[i].chip = &mips_cpu_irq_controller;
        }
 
        mips_cpu_irq_base = irq_base;
index 2d3472b21ebbe3ad62b98ff3046380b0039107a3..9316a024a8188ed8d2e92d5db266263b08e2b47a 100644 (file)
@@ -156,6 +156,6 @@ void __init arch_init_irq(void)
                irq_desc[i].status      = IRQ_DISABLED;
                irq_desc[i].action      = 0;
                irq_desc[i].depth       = 1;
-               irq_desc[i].handler     = &lasat_irq_type;
+               irq_desc[i].chip        = &lasat_irq_type;
        }
 }
index db53950b7cfbae7bd9e8936ede6fd6f6f5c64882..9dd6b89255818ddbf22fbcc86e4f294b834c1499 100644 (file)
@@ -215,7 +215,7 @@ void __init arch_init_irq(void)
                irq_desc[i].status      = IRQ_DISABLED;
                irq_desc[i].action      = 0;
                irq_desc[i].depth       = 1;
-               irq_desc[i].handler     = &atlas_irq_type;
+               irq_desc[i].chip        = &atlas_irq_type;
                spin_lock_init(&irq_desc[i].lock);
        }
 }
index bd885785e2f992f6dd2d80295e5afa427c67551e..31d179c4673fe55cf9c812bcd813963b547a8fa1 100644 (file)
@@ -147,6 +147,6 @@ void cpci_irq_init(void)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 2;
-               irq_desc[i].handler = &cpci_irq_type;
+               irq_desc[i].chip = &cpci_irq_type;
        }
 }
index 755bde5146be1d5d0b77bb319e91be12ecb8923d..852265026fd1f5b830e3e172268c1b7a7425ab35 100644 (file)
@@ -137,10 +137,10 @@ void uart_irq_init(void)
        irq_desc[80].status = IRQ_DISABLED;
        irq_desc[80].action = 0;
        irq_desc[80].depth = 2;
-       irq_desc[80].handler = &uart_irq_type;
+       irq_desc[80].chip = &uart_irq_type;
 
        irq_desc[81].status = IRQ_DISABLED;
        irq_desc[81].action = 0;
        irq_desc[81].depth = 2;
-       irq_desc[81].handler = &uart_irq_type;
+       irq_desc[81].chip = &uart_irq_type;
 }
index 4dfce154d4af1cb33e7b35410f3a747d34c47555..ba66f8c9bd4eec824b21882d8129d284289cf6dc 100644 (file)
@@ -51,11 +51,11 @@ unsigned long PCIBIOS_MIN_MEM       = 0;
  */
 void
 pcibios_align_resource(void *data, struct resource *res,
-                      unsigned long size, unsigned long align)
+                      resource_size_t size, resource_size_t align)
 {
        struct pci_dev *dev = data;
        struct pci_controller *hose = dev->sysdata;
-       unsigned long start = res->start;
+       resource_size_t start = res->start;
 
        if (res->flags & IORESOURCE_IO) {
                /* Make sure we start at our min on all hoses */
index 39ee6314f62757279e12118448a04b70713fb2a7..8f18764a235956c6dbb14825b8cabba6daf8dd91 100644 (file)
@@ -236,7 +236,7 @@ void __init arch_init_irq(void)
        int configPR;
 
        for (i = 0; i < PNX8550_INT_CP0_TOTINT; i++) {
-               irq_desc[i].handler = &level_irq_type;
+               irq_desc[i].chip = &level_irq_type;
                pnx8550_ack(i); /* mask the irq just in case  */
        }
 
@@ -273,7 +273,7 @@ void __init arch_init_irq(void)
                /* mask/priority is still 0 so we will not get any
                 * interrupts until it is unmasked */
 
-               irq_desc[i].handler = &level_irq_type;
+               irq_desc[i].chip = &level_irq_type;
        }
 
        /* Priority level 0 */
@@ -282,12 +282,12 @@ void __init arch_init_irq(void)
        /* Set int vector table address */
        PNX8550_GIC_VECTOR_0 = PNX8550_GIC_VECTOR_1 = 0;
 
-       irq_desc[MIPS_CPU_GIC_IRQ].handler = &level_irq_type;
+       irq_desc[MIPS_CPU_GIC_IRQ].chip = &level_irq_type;
        setup_irq(MIPS_CPU_GIC_IRQ, &gic_action);
 
        /* init of Timer interrupts */
        for (i = PNX8550_INT_TIMER_MIN; i <= PNX8550_INT_TIMER_MAX; i++) {
-               irq_desc[i].handler = &level_irq_type;
+               irq_desc[i].chip = &level_irq_type;
        }
 
        /* Stop Timer 1-3 */
@@ -295,7 +295,7 @@ void __init arch_init_irq(void)
        configPR |= 0x00000038;
        write_c0_config7(configPR);
 
-       irq_desc[MIPS_CPU_TIMER_IRQ].handler = &level_irq_type;
+       irq_desc[MIPS_CPU_TIMER_IRQ].chip = &level_irq_type;
        setup_irq(MIPS_CPU_TIMER_IRQ, &timer_action);
 }
 
index 54b65a80abf587d30a54d613b1a268f780f38a3c..fb523ebcafa8e8a5e6c8ee753cdbaa8c6a347e57 100644 (file)
@@ -383,12 +383,12 @@ void pcibios_update_resource(struct pci_dev *dev, struct resource *root,
 
 
 void pcibios_align_resource(void *data, struct resource *res,
-                            unsigned long size, unsigned long align)
+                            resource_size_t size, resource_size_t align)
 {
         struct pci_dev *dev = data;
 
         if (res->flags & IORESOURCE_IO) {
-                unsigned long start = res->start;
+                resource_size_t start = res->start;
 
                 /* We need to avoid collisions with `mirrored' VGA ports
                    and other strange ISA hardware, so we always want the
index b19820110aa3a91c52c9bf1f0157b3979001a315..989167b49ce92e70611940937a10c3a7efff5e28 100644 (file)
@@ -279,9 +279,9 @@ int __init ip22_eisa_init(void)
                irq_desc[i].action = 0;
                irq_desc[i].depth = 1;
                if (i < (SGINT_EISA + 8))
-                       irq_desc[i].handler = &ip22_eisa1_irq_type;
+                       irq_desc[i].chip = &ip22_eisa1_irq_type;
                else
-                       irq_desc[i].handler = &ip22_eisa2_irq_type;
+                       irq_desc[i].chip = &ip22_eisa2_irq_type;
        }
 
        /* Cannot use request_irq because of kmalloc not being ready at such
index fc6a7e2b189ccd90224c54dbf6ac4ae62ba99b68..18906af6969100e7c51f9b0c9a62a60ad1c3ad3e 100644 (file)
@@ -436,7 +436,7 @@ void __init arch_init_irq(void)
                irq_desc[i].status      = IRQ_DISABLED;
                irq_desc[i].action      = 0;
                irq_desc[i].depth       = 1;
-               irq_desc[i].handler     = handler;
+               irq_desc[i].chip        = handler;
        }
 
        /* vector handler. this register the IRQ as non-sharable */
index 0b61a39ce2bb1f116f991b94d481aa6cd2825096..869566c360ae9b5fe5a4e7b2d848498d39dda975 100644 (file)
@@ -386,7 +386,7 @@ void __devinit register_bridge_irq(unsigned int irq)
        irq_desc[irq].status    = IRQ_DISABLED;
        irq_desc[irq].action    = 0;
        irq_desc[irq].depth     = 1;
-       irq_desc[irq].handler   = &bridge_irq_type;
+       irq_desc[irq].chip      = &bridge_irq_type;
 }
 
 int __devinit request_bridge_irq(struct bridge_controller *bc)
index 8ba08047d164222b31bf6315b66fb51603d3a93a..00b94aaf6371834134736b909979397c9c7c52f9 100644 (file)
@@ -591,7 +591,7 @@ void __init arch_init_irq(void)
                irq_desc[irq].status = IRQ_DISABLED;
                irq_desc[irq].action = 0;
                irq_desc[irq].depth = 0;
-               irq_desc[irq].handler = controller;
+               irq_desc[irq].chip = controller;
        }
        setup_irq(CRIME_MEMERR_IRQ, &memerr_irq);
        setup_irq(CRIME_CPUERR_IRQ, &cpuerr_irq);
index e61760b14d99ec208d741e85f121f99cfb189838..610df40cb82088241ed6fdcb52e98ed30cef455d 100644 (file)
@@ -276,10 +276,10 @@ void __init init_bcm1480_irqs(void)
                irq_desc[i].action = 0;
                irq_desc[i].depth = 1;
                if (i < BCM1480_NR_IRQS) {
-                       irq_desc[i].handler = &bcm1480_irq_type;
+                       irq_desc[i].chip = &bcm1480_irq_type;
                        bcm1480_irq_owner[i] = 0;
                } else {
-                       irq_desc[i].handler = &no_irq_type;
+                       irq_desc[i].chip = &no_irq_type;
                }
        }
 }
index f853c32f60a0f7e1b847f289a469b8e2b0932ada..fcc61940f1ff6444e8e03fed4cdf105a9cac555e 100644 (file)
@@ -246,10 +246,10 @@ void __init init_sb1250_irqs(void)
                irq_desc[i].action = 0;
                irq_desc[i].depth = 1;
                if (i < SB1250_NR_IRQS) {
-                       irq_desc[i].handler = &sb1250_irq_type;
+                       irq_desc[i].chip = &sb1250_irq_type;
                        sb1250_irq_owner[i] = 0;
                } else {
-                       irq_desc[i].handler = &no_irq_type;
+                       irq_desc[i].chip = &no_irq_type;
                }
        }
 }
index 7365b4853ddb212a0d6073d49d60460838819f1f..c19e158ec402ad22dc2b6f60a7677f7102e7b72f 100644 (file)
@@ -203,7 +203,7 @@ void __init arch_init_irq(void)
                irq_desc[i].status     = IRQ_DISABLED;
                irq_desc[i].action     = 0;
                irq_desc[i].depth      = 1;
-               irq_desc[i].handler    = &pciasic_irq_type;
+               irq_desc[i].chip    = &pciasic_irq_type;
        }
 
        change_c0_status(ST0_IM, IE_IRQ1|IE_IRQ2|IE_IRQ3|IE_IRQ4);
index 8ca68015cf40ffd9456a17febfa107187eb8b18d..a42be00483e6d57f07bcdbe10b1267570939a974 100644 (file)
@@ -227,7 +227,7 @@ static void __init tx4927_irq_cp0_init(void)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &tx4927_irq_cp0_type;
+               irq_desc[i].chip = &tx4927_irq_cp0_type;
        }
 
        return;
@@ -435,7 +435,7 @@ static void __init tx4927_irq_pic_init(void)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 2;
-               irq_desc[i].handler = &tx4927_irq_pic_type;
+               irq_desc[i].chip = &tx4927_irq_pic_type;
        }
 
        setup_irq(TX4927_IRQ_NEST_PIC_ON_CP0, &tx4927_irq_pic_action);
index aee07ff2212a37bb1348a6a48d783dea94a8146e..c67978b6dae494b5ec08f6b175f759be3c941faf 100644 (file)
@@ -368,7 +368,7 @@ static void __init toshiba_rbtx4927_irq_ioc_init(void)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 3;
-               irq_desc[i].handler = &toshiba_rbtx4927_irq_ioc_type;
+               irq_desc[i].chip = &toshiba_rbtx4927_irq_ioc_type;
        }
 
        setup_irq(TOSHIBA_RBTX4927_IRQ_NEST_IOC_ON_PIC,
@@ -526,7 +526,7 @@ static void __init toshiba_rbtx4927_irq_isa_init(void)
                irq_desc[i].action = 0;
                irq_desc[i].depth =
                    ((i < TOSHIBA_RBTX4927_IRQ_ISA_MID) ? (4) : (5));
-               irq_desc[i].handler = &toshiba_rbtx4927_irq_isa_type;
+               irq_desc[i].chip = &toshiba_rbtx4927_irq_isa_type;
        }
 
        setup_irq(TOSHIBA_RBTX4927_IRQ_NEST_ISA_ON_IOC,
@@ -692,13 +692,13 @@ void toshiba_rbtx4927_irq_dump(char *key)
        {
                u32 i, j = 0;
                for (i = 0; i < NR_IRQS; i++) {
-                       if (strcmp(irq_desc[i].handler->typename, "none")
+                       if (strcmp(irq_desc[i].chip->typename, "none")
                            == 0)
                                continue;
 
                        if ((i >= 1)
-                           && (irq_desc[i - 1].handler->typename ==
-                               irq_desc[i].handler->typename)) {
+                           && (irq_desc[i - 1].chip->typename ==
+                               irq_desc[i].chip->typename)) {
                                j++;
                        } else {
                                j = 0;
@@ -707,12 +707,12 @@ void toshiba_rbtx4927_irq_dump(char *key)
                            (TOSHIBA_RBTX4927_IRQ_INFO,
                             "%s irq=0x%02x/%3d s=0x%08x h=0x%08x a=0x%08x ah=0x%08x d=%1d n=%s/%02d\n",
                             key, i, i, irq_desc[i].status,
-                            (u32) irq_desc[i].handler,
+                            (u32) irq_desc[i].chip,
                             (u32) irq_desc[i].action,
                             (u32) (irq_desc[i].action ? irq_desc[i].
                                    action->handler : 0),
                             irq_desc[i].depth,
-                            irq_desc[i].handler->typename, j);
+                            irq_desc[i].chip->typename, j);
                }
        }
 #endif
index 873805178d8e993b09402aad77ce8a9524f9bf83..0b2f8c8492181e4724b5675fdffed196ba207877 100644 (file)
@@ -102,7 +102,7 @@ tx4938_irq_cp0_init(void)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &tx4938_irq_cp0_type;
+               irq_desc[i].chip = &tx4938_irq_cp0_type;
        }
 
        return;
@@ -306,7 +306,7 @@ tx4938_irq_pic_init(void)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 2;
-               irq_desc[i].handler = &tx4938_irq_pic_type;
+               irq_desc[i].chip = &tx4938_irq_pic_type;
        }
 
        setup_irq(TX4938_IRQ_NEST_PIC_ON_CP0, &tx4938_irq_pic_action);
index 9cd9c0fe22658c9bcbcd6fbdb6e62a73f3ca609b..3b8245dc5bd38e9b074a4e12902bae0efb1082a9 100644 (file)
@@ -146,7 +146,7 @@ toshiba_rbtx4938_irq_ioc_init(void)
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = 0;
                irq_desc[i].depth = 3;
-               irq_desc[i].handler = &toshiba_rbtx4938_irq_ioc_type;
+               irq_desc[i].chip = &toshiba_rbtx4938_irq_ioc_type;
        }
 
        setup_irq(RBTX4938_IRQ_IOCINT,
index 07ae19cf0c296d93422abe4db50f5d5c30c4f683..b9323302cc4e6fbf4b6312dab00b0617656ba4e3 100644 (file)
@@ -722,10 +722,10 @@ static int __init vr41xx_icu_init(void)
        icu2_write(MGIUINTHREG, 0xffff);
 
        for (i = SYSINT1_IRQ_BASE; i <= SYSINT1_IRQ_LAST; i++)
-               irq_desc[i].handler = &sysint1_irq_type;
+               irq_desc[i].chip = &sysint1_irq_type;
 
        for (i = SYSINT2_IRQ_BASE; i <= SYSINT2_IRQ_LAST; i++)
-               irq_desc[i].handler = &sysint2_irq_type;
+               irq_desc[i].chip = &sysint2_irq_type;
 
        cascade_irq(INT0_IRQ, icu_get_irq);
        cascade_irq(INT1_IRQ, icu_get_irq);
index 86796bb63c3c7e3d6b3aaa41626a52a43b8eca35..66aa50802deb6fcc06dd399a90b9c86a2a4a5d5a 100644 (file)
@@ -73,13 +73,13 @@ static void irq_dispatch(unsigned int irq, struct pt_regs *regs)
        if (cascade->get_irq != NULL) {
                unsigned int source_irq = irq;
                desc = irq_desc + source_irq;
-               desc->handler->ack(source_irq);
+               desc->chip->ack(source_irq);
                irq = cascade->get_irq(irq, regs);
                if (irq < 0)
                        atomic_inc(&irq_err_count);
                else
                        irq_dispatch(irq, regs);
-               desc->handler->end(source_irq);
+               desc->chip->end(source_irq);
        } else
                do_IRQ(irq, regs);
 }
index 3e31f8193d2115ef100674e6cddc015bd5acfa62..2d287b8893d90f4081c7742191e8ff2f24000af3 100644 (file)
@@ -483,7 +483,7 @@ static inline int vrc4173_icu_init(int cascade_irq)
        vr41xx_set_irq_level(GIU_IRQ_TO_PIN(cascade_irq), LEVEL_LOW);
 
        for (i = VRC4173_IRQ_BASE; i <= VRC4173_IRQ_LAST; i++)
-                irq_desc[i].handler = &vrc4173_irq_type;
+                irq_desc[i].chip = &vrc4173_irq_type;
 
        return 0;
 }
index 31db6b61a39e9627ad7c5da13e2e4de555880325..7b2511ca0a616a0c4729ba244d392fcbea0361ff 100644 (file)
@@ -104,7 +104,7 @@ void __init rockhopper_init_irq(void)
        }
 
        for (i = I8259_IRQ_BASE; i <= I8259_IRQ_LAST; i++)
-               irq_desc[i].handler = &i8259_irq_type;
+               irq_desc[i].chip = &i8259_irq_type;
 
        setup_irq(I8259_SLAVE_IRQ, &i8259_slave_cascade);
 
index 910fb3afc0b5c91e40c24a030a7b1b8241af5d60..6dd0ea8f88e0a49c273e3f04734efc3e42abb0d5 100644 (file)
@@ -51,6 +51,10 @@ config GENERIC_HARDIRQS
 config GENERIC_IRQ_PROBE
        def_bool y
 
+config IRQ_PER_CPU
+       bool
+       default y
+
 # unless you want to implement ACPI on PA-RISC ... ;-)
 config PM
        bool
index 197936d9359a4065332a2c9a67ad8bd69ad04f33..82fe6ba29727a6824bd4a83e5fef44322239f08f 100644 (file)
@@ -94,7 +94,7 @@ int cpu_check_affinity(unsigned int irq, cpumask_t *dest)
        if (irq == TIMER_IRQ || irq == IPI_IRQ) {
                /* Bad linux design decision.  The mask has already
                 * been set; we must reset it */
-               irq_affinity[irq] = CPU_MASK_ALL;
+               irq_desc[irq].affinity = CPU_MASK_ALL;
                return -EINVAL;
        }
 
@@ -110,7 +110,7 @@ static void cpu_set_affinity_irq(unsigned int irq, cpumask_t dest)
        if (cpu_check_affinity(irq, &dest))
                return;
 
-       irq_affinity[irq] = dest;
+       irq_desc[irq].affinity = dest;
 }
 #endif
 
@@ -125,6 +125,10 @@ static struct hw_interrupt_type cpu_interrupt_type = {
 #ifdef CONFIG_SMP
        .set_affinity   = cpu_set_affinity_irq,
 #endif
+       /* XXX: Needs to be written.  We managed without it so far, but
+        * we really ought to write it.
+        */
+       .retrigger      = NULL,
 };
 
 int show_interrupts(struct seq_file *p, void *v)
@@ -158,7 +162,7 @@ int show_interrupts(struct seq_file *p, void *v)
                seq_printf(p, "%10u ", kstat_irqs(i));
 #endif
 
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
 #ifndef PARISC_IRQ_CR16_COUNTS
                seq_printf(p, "  %s", action->name);
 
@@ -210,12 +214,12 @@ int cpu_claim_irq(unsigned int irq, struct hw_interrupt_type *type, void *data)
 {
        if (irq_desc[irq].action)
                return -EBUSY;
-       if (irq_desc[irq].handler != &cpu_interrupt_type)
+       if (irq_desc[irq].chip != &cpu_interrupt_type)
                return -EBUSY;
 
        if (type) {
-               irq_desc[irq].handler = type;
-               irq_desc[irq].handler_data = data;
+               irq_desc[irq].chip = type;
+               irq_desc[irq].chip_data = data;
                cpu_interrupt_type.enable(irq);
        }
        return 0;
@@ -265,7 +269,7 @@ int txn_alloc_irq(unsigned int bits_wide)
 unsigned long txn_affinity_addr(unsigned int irq, int cpu)
 {
 #ifdef CONFIG_SMP
-       irq_affinity[irq] = cpumask_of_cpu(cpu);
+       irq_desc[irq].affinity = cpumask_of_cpu(cpu);
 #endif
 
        return cpu_data[cpu].txn_addr;
@@ -326,7 +330,7 @@ void do_cpu_irq_mask(struct pt_regs *regs)
                /* Work our way from MSb to LSb...same order we alloc EIRs */
                for (irq = TIMER_IRQ; eirr_val && bit; bit>>=1, irq++) {
 #ifdef CONFIG_SMP
-                       cpumask_t dest = irq_affinity[irq];
+                       cpumask_t dest = irq_desc[irq].affinity;
 #endif
                        if (!(bit & eirr_val))
                                continue;
@@ -378,7 +382,7 @@ static void claim_cpu_irqs(void)
 {
        int i;
        for (i = CPU_IRQ_BASE; i <= CPU_IRQ_MAX; i++) {
-               irq_desc[i].handler = &cpu_interrupt_type;
+               irq_desc[i].chip = &cpu_interrupt_type;
        }
 
        irq_desc[TIMER_IRQ].action = &timer_action;
@@ -404,13 +408,6 @@ void __init init_IRQ(void)
 
 }
 
-void hw_resend_irq(struct hw_interrupt_type *type, unsigned int irq)
-{
-       /* XXX: Needs to be written.  We managed without it so far, but
-        * we really ought to write it.
-        */
-}
-
 void ack_bad_irq(unsigned int irq)
 {
        printk("unexpected IRQ %d\n", irq);
index 79c7db2705fd4b7b475a87af50e09cf57cc62a4a..7d6967ee367c7f8ef5784281d0eb082af7a9a9b2 100644 (file)
@@ -289,7 +289,7 @@ EXPORT_SYMBOL(pcibios_bus_to_resource);
  * than res->start.
  */
 void pcibios_align_resource(void *data, struct resource *res,
-                               unsigned long size, unsigned long alignment)
+                               resource_size_t size, resource_size_t alignment)
 {
        unsigned long mask, align;
 
index e922a88b2bad33fc4b17855600a9826f19b4c42d..d43e4521abf2c962378fe14395e546d5298090d9 100644 (file)
@@ -30,6 +30,10 @@ config GENERIC_HARDIRQS
        bool
        default y
 
+config IRQ_PER_CPU
+       bool
+       default y
+
 config RWSEM_GENERIC_SPINLOCK
        bool
 
@@ -618,6 +622,9 @@ config HOTPLUG_CPU
 
          Say N if you are unsure.
 
+config ARCH_ENABLE_MEMORY_HOTPLUG
+       def_bool y
+
 config KEXEC
        bool "kexec system call (EXPERIMENTAL)"
        depends on PPC_MULTIPLATFORM && EXPERIMENTAL
index e253a45dcf10d62cb8c18b5faa028d3415c125c9..22ceba844bf4ae729c4f898347a5715ab807b316 100644 (file)
@@ -190,13 +190,13 @@ void default_machine_crash_shutdown(struct pt_regs *regs)
        local_irq_disable();
 
        for_each_irq(irq) {
-               struct irq_desc *desc = irq_descp(irq);
+               struct irq_desc *desc = irq_desc + irq;
 
                if (desc->status & IRQ_INPROGRESS)
-                       desc->handler->end(irq);
+                       desc->chip->end(irq);
 
                if (!(desc->status & IRQ_DISABLED))
-                       desc->handler->disable(irq);
+                       desc->chip->disable(irq);
        }
 
        if (ppc_md.kexec_cpu_down)
index 40d4c14fde8fa2ae3333062786688584b3387757..24f6050aa4abb2d13a873659e737ae13442409bc 100644 (file)
@@ -120,8 +120,8 @@ int show_interrupts(struct seq_file *p, void *v)
 #else
                seq_printf(p, "%10u ", kstat_irqs(i));
 #endif /* CONFIG_SMP */
-               if (desc->handler)
-                       seq_printf(p, " %s ", desc->handler->typename);
+               if (desc->chip)
+                       seq_printf(p, " %s ", desc->chip->typename);
                else
                        seq_puts(p, "  None      ");
                seq_printf(p, "%s", (desc->status & IRQ_LEVEL) ? "Level " : "Edge  ");
@@ -164,13 +164,13 @@ void fixup_irqs(cpumask_t map)
                if (irq_desc[irq].status & IRQ_PER_CPU)
                        continue;
 
-               cpus_and(mask, irq_affinity[irq], map);
+               cpus_and(mask, irq_desc[irq].affinity, map);
                if (any_online_cpu(mask) == NR_CPUS) {
                        printk("Breaking affinity for irq %i\n", irq);
                        mask = map;
                }
-               if (irq_desc[irq].handler->set_affinity)
-                       irq_desc[irq].handler->set_affinity(irq, mask);
+               if (irq_desc[irq].chip->set_affinity)
+                       irq_desc[irq].chip->set_affinity(irq, mask);
                else if (irq_desc[irq].action && !(warned++))
                        printk("Cannot set affinity for irq %i\n", irq);
        }
index b5431ccf1147ae551c763b0fd360d3857c4ee00b..8474355a1a4f46d8a9e1df29a2ad403fc847713a 100644 (file)
@@ -99,7 +99,7 @@ pcibios_fixup_resources(struct pci_dev *dev)
                if (!res->flags)
                        continue;
                if (res->end == 0xffffffff) {
-                       DBG("PCI:%s Resource %d [%08lx-%08lx] is unassigned\n",
+                       DBG("PCI:%s Resource %d [%016llx-%016llx] is unassigned\n",
                            pci_name(dev), i, res->start, res->end);
                        res->end -= res->start;
                        res->start = 0;
@@ -117,7 +117,7 @@ pcibios_fixup_resources(struct pci_dev *dev)
                        res->start += offset;
                        res->end += offset;
 #ifdef DEBUG
-                       printk("Fixup res %d (%lx) of dev %s: %lx -> %lx\n",
+                       printk("Fixup res %d (%lx) of dev %s: %llx -> %llx\n",
                               i, res->flags, pci_name(dev),
                               res->start - offset, res->start);
 #endif
@@ -173,18 +173,18 @@ EXPORT_SYMBOL(pcibios_bus_to_resource);
  * but we want to try to avoid allocating at 0x2900-0x2bff
  * which might have be mirrored at 0x0100-0x03ff..
  */
-void pcibios_align_resource(void *data, struct resource *res, unsigned long size,
-                      unsigned long align)
+void pcibios_align_resource(void *data, struct resource *res,
+                               resource_size_t size, resource_size_t align)
 {
        struct pci_dev *dev = data;
 
        if (res->flags & IORESOURCE_IO) {
-               unsigned long start = res->start;
+               resource_size_t start = res->start;
 
                if (size > 0x100) {
                        printk(KERN_ERR "PCI: I/O Region %s/%d too large"
-                              " (%ld bytes)\n", pci_name(dev),
-                              dev->resource - res, size);
+                              " (%lld bytes)\n", pci_name(dev),
+                              dev->resource - res, (unsigned long long)size);
                }
 
                if (start & 0x300) {
@@ -255,8 +255,8 @@ pcibios_allocate_bus_resources(struct list_head *bus_list)
                                }
                        }
 
-                       DBG("PCI: bridge rsrc %lx..%lx (%lx), parent %p\n",
-                           res->start, res->end, res->flags, pr);
+                       DBG("PCI: bridge rsrc %llx..%llx (%lx), parent %p\n",
+                               res->start, res->end, res->flags, pr);
                        if (pr) {
                                if (request_resource(pr, res) == 0)
                                        continue;
@@ -306,7 +306,7 @@ reparent_resources(struct resource *parent, struct resource *res)
        *pp = NULL;
        for (p = res->child; p != NULL; p = p->sibling) {
                p->parent = res;
-               DBG(KERN_INFO "PCI: reparented %s [%lx..%lx] under %s\n",
+               DBG(KERN_INFO "PCI: reparented %s [%llx..%llx] under %s\n",
                    p->name, p->start, p->end, res->name);
        }
        return 0;
@@ -362,13 +362,14 @@ pci_relocate_bridge_resource(struct pci_bus *bus, int i)
                try = conflict->start - 1;
        }
        if (request_resource(pr, res)) {
-               DBG(KERN_ERR "PCI: huh? couldn't move to %lx..%lx\n",
+               DBG(KERN_ERR "PCI: huh? couldn't move to %llx..%llx\n",
                    res->start, res->end);
                return -1;              /* "can't happen" */
        }
        update_bridge_base(bus, i);
-       printk(KERN_INFO "PCI: bridge %d resource %d moved to %lx..%lx\n",
-              bus->number, i, res->start, res->end);
+       printk(KERN_INFO "PCI: bridge %d resource %d moved to %llx..%llx\n",
+              bus->number, i, (unsigned long long)res->start,
+              (unsigned long long)res->end);
        return 0;
 }
 
@@ -479,14 +480,14 @@ static inline void alloc_resource(struct pci_dev *dev, int idx)
 {
        struct resource *pr, *r = &dev->resource[idx];
 
-       DBG("PCI:%s: Resource %d: %08lx-%08lx (f=%lx)\n",
+       DBG("PCI:%s: Resource %d: %016llx-%016llx (f=%lx)\n",
            pci_name(dev), idx, r->start, r->end, r->flags);
        pr = pci_find_parent_resource(dev, r);
        if (!pr || request_resource(pr, r) < 0) {
                printk(KERN_ERR "PCI: Cannot allocate resource region %d"
                       " of device %s\n", idx, pci_name(dev));
                if (pr)
-                       DBG("PCI:  parent is %p: %08lx-%08lx (f=%lx)\n",
+                       DBG("PCI:  parent is %p: %016llx-%016llx (f=%lx)\n",
                            pr, pr->start, pr->end, pr->flags);
                /* We'll assign a new address later */
                r->flags |= IORESOURCE_UNSET;
@@ -956,7 +957,7 @@ pci_process_bridge_OF_ranges(struct pci_controller *hose,
                        res = &hose->io_resource;
                        res->flags = IORESOURCE_IO;
                        res->start = ranges[2];
-                       DBG("PCI: IO 0x%lx -> 0x%lx\n",
+                       DBG("PCI: IO 0x%llx -> 0x%llx\n",
                                    res->start, res->start + size - 1);
                        break;
                case 2:         /* memory space */
@@ -978,7 +979,7 @@ pci_process_bridge_OF_ranges(struct pci_controller *hose,
                                if(ranges[0] & 0x40000000)
                                        res->flags |= IORESOURCE_PREFETCH;
                                res->start = ranges[na+2];
-                               DBG("PCI: MEM[%d] 0x%lx -> 0x%lx\n", memno,
+                               DBG("PCI: MEM[%d] 0x%llx -> 0x%llx\n", memno,
                                            res->start, res->start + size - 1);
                        }
                        break;
@@ -1074,7 +1075,7 @@ do_update_p2p_io_resource(struct pci_bus *bus, int enable_vga)
        DBG("Remapping Bus %d, bridge: %s\n", bus->number, pci_name(bridge));
        res.start -= ((unsigned long) hose->io_base_virt - isa_io_base);
        res.end -= ((unsigned long) hose->io_base_virt - isa_io_base);
-       DBG("  IO window: %08lx-%08lx\n", res.start, res.end);
+       DBG("  IO window: %016llx-%016llx\n", res.start, res.end);
 
        /* Set up the top and bottom of the PCI I/O segment for this bus. */
        pci_read_config_dword(bridge, PCI_IO_BASE, &l);
@@ -1223,8 +1224,8 @@ do_fixup_p2p_level(struct pci_bus *bus)
                                        continue;
                                if ((r->flags & IORESOURCE_IO) == 0)
                                        continue;
-                               DBG("Trying to allocate from %08lx, size %08lx from parent"
-                                   " res %d: %08lx -> %08lx\n",
+                               DBG("Trying to allocate from %016llx, size %016llx from parent"
+                                   " res %d: %016llx -> %016llx\n",
                                        res->start, res->end, i, r->start, r->end);
                        
                                if (allocate_resource(r, res, res->end + 1, res->start, max,
@@ -1574,8 +1575,8 @@ static pgprot_t __pci_mmap_set_pgprot(struct pci_dev *dev, struct resource *rp,
        else
                prot |= _PAGE_GUARDED;
 
-       printk("PCI map for %s:%lx, prot: %lx\n", pci_name(dev), rp->start,
-              prot);
+       printk("PCI map for %s:%llx, prot: %lx\n", pci_name(dev),
+               (unsigned long long)rp->start, prot);
 
        return __pgprot(prot);
 }
@@ -1755,7 +1756,7 @@ long sys_pciconfig_iobase(long which, unsigned long bus, unsigned long devfn)
 
 void pci_resource_to_user(const struct pci_dev *dev, int bar,
                          const struct resource *rsrc,
-                         u64 *start, u64 *end)
+                         resource_size_t *start, resource_size_t *end)
 {
        struct pci_controller *hose = pci_bus_to_hose(dev->bus->number);
        unsigned long offset = 0;
index 247937dd8b736aab99a79df9bd6d5711bf951a4a..286aa52aae334db643c5769d5816ee7b6a8ba3f9 100644 (file)
@@ -138,11 +138,11 @@ EXPORT_SYMBOL(pcibios_bus_to_resource);
  * which might have be mirrored at 0x0100-0x03ff..
  */
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size, unsigned long align)
+                           resource_size_t size, resource_size_t align)
 {
        struct pci_dev *dev = data;
        struct pci_controller *hose = pci_bus_to_host(dev->bus);
-       unsigned long start = res->start;
+       resource_size_t start = res->start;
        unsigned long alignto;
 
        if (res->flags & IORESOURCE_IO) {
index 16f7d3b30e1dbf023e0229fe946441516fc3c845..3baceb00fefaacde0f2929e8572e17c8b3282960 100644 (file)
@@ -91,9 +91,10 @@ int __init add_bridge(struct device_node *dev)
                mpc83xx_pci2_busno = hose->first_busno;
        }
 
-       printk(KERN_INFO "Found MPC83xx PCI host bridge at 0x%08lx. "
+       printk(KERN_INFO "Found MPC83xx PCI host bridge at 0x%016llx. "
               "Firmware bus number: %d->%d\n",
-              rsrc.start, hose->first_busno, hose->last_busno);
+              (unsigned long long)rsrc.start, hose->first_busno,
+              hose->last_busno);
 
        DBG(" ->Hose at 0x%p, cfg_addr=0x%p,cfg_data=0x%p\n",
            hose, hose->cfg_addr, hose->cfg_data);
index bad290110ed1dcc34373b80670cefe770aee2587..48c8849c07ca39614caf78ae02206fa1a23dfdc1 100644 (file)
@@ -79,9 +79,10 @@ int __init add_bridge(struct device_node *dev)
                mpc85xx_pci2_busno = hose->first_busno;
        }
 
-       printk(KERN_INFO "Found MPC85xx PCI host bridge at 0x%08lx. "
+       printk(KERN_INFO "Found MPC85xx PCI host bridge at 0x%016llx. "
               "Firmware bus number: %d->%d\n",
-               rsrc.start, hose->first_busno, hose->last_busno);
+               (unsigned long long)rsrc.start, hose->first_busno,
+               hose->last_busno);
 
        DBG(" ->Hose at 0x%p, cfg_addr=0x%p,cfg_data=0x%p\n",
                hose, hose->cfg_addr, hose->cfg_data);
index 1bbf822b4efcafada7f9181af9de762772f37f29..7bff3cbc5723b1615b28a46c1e62fe91cdebaccd 100644 (file)
@@ -307,7 +307,7 @@ static void iic_request_ipi(int ipi, const char *name)
        irq = iic_ipi_to_irq(ipi);
        /* IPIs are marked SA_INTERRUPT as they must run with irqs
         * disabled */
-       get_irq_desc(irq)->handler = &iic_pic;
+       get_irq_desc(irq)->chip = &iic_pic;
        get_irq_desc(irq)->status |= IRQ_PER_CPU;
        request_irq(irq, iic_ipi_action, SA_INTERRUPT, name, NULL);
 }
@@ -330,7 +330,7 @@ static void iic_setup_spe_handlers(void)
        for (be=0; be < num_present_cpus() / 2; be++) {
                for (isrc = 0; isrc < IIC_CLASS_STRIDE * 3; isrc++) {
                        int irq = IIC_NODE_STRIDE * be + IIC_SPE_OFFSET + isrc;
-                       get_irq_desc(irq)->handler = &iic_pic;
+                       get_irq_desc(irq)->chip = &iic_pic;
                }
        }
 }
index 55cbdd77a62dc417136209438e7e249622283ce3..7c3a0b6d34fdffb443ebaab6771575423a50f241 100644 (file)
@@ -162,7 +162,7 @@ void spider_init_IRQ_hardcoded(void)
                spider_pics[node] = ioremap(spiderpic, 0x800);
                for (n = 0; n < IIC_NUM_EXT; n++) {
                        int irq = n + IIC_EXT_OFFSET + node * IIC_NODE_STRIDE;
-                       get_irq_desc(irq)->handler = &spider_pic;
+                       get_irq_desc(irq)->chip = &spider_pic;
                }
 
                /* do not mask any interrupts because of level */
@@ -217,7 +217,7 @@ void spider_init_IRQ(void)
 
                for (n = 0; n < IIC_NUM_EXT; n++) {
                        int irq = n + IIC_EXT_OFFSET + node * IIC_NODE_STRIDE;
-                       get_irq_desc(irq)->handler = &spider_pic;
+                       get_irq_desc(irq)->chip = &spider_pic;
                }
 
                /* do not mask any interrupts because of level */
index ac224876ce5943f999a0def0007f7214cd35ff9a..53515daf01b18196ab671f56b485330247833807 100644 (file)
@@ -143,7 +143,7 @@ hydra_init(void)
        if (np == NULL || of_address_to_resource(np, 0, &r))
                return 0;
        Hydra = ioremap(r.start, r.end-r.start);
-       printk("Hydra Mac I/O at %lx\n", r.start);
+       printk("Hydra Mac I/O at %llx\n", (unsigned long long)r.start);
        printk("Hydra Feature_Control was %x",
               in_le32(&Hydra->Feature_Control));
        out_le32(&Hydra->Feature_Control, (HYDRA_FC_SCC_CELL_EN |
@@ -267,7 +267,7 @@ chrp_find_bridges(void)
                               bus_range[0], bus_range[1]);
                printk(" controlled by %s", dev->type);
                if (!is_longtrail)
-                       printk(" at %lx", r.start);
+                       printk(" at %llx", (unsigned long long)r.start);
                printk("\n");
 
                hose = pcibios_alloc_controller();
index 62bbbcf5ded3e27d19f5c2ed0f1d2e402171b87f..33bb4aa0e1e819df8464376de3064b48622f76b1 100644 (file)
@@ -242,9 +242,9 @@ void __init iSeries_activate_IRQs()
        for_each_irq (irq) {
                irq_desc_t *desc = get_irq_desc(irq);
 
-               if (desc && desc->handler && desc->handler->startup) {
+               if (desc && desc->chip && desc->chip->startup) {
                        spin_lock_irqsave(&desc->lock, flags);
-                       desc->handler->startup(irq);
+                       desc->chip->startup(irq);
                        spin_unlock_irqrestore(&desc->lock, flags);
                }
        }
@@ -324,7 +324,7 @@ int __init iSeries_allocate_IRQ(HvBusNumber bus,
                + function;
        virtirq = virt_irq_create_mapping(realirq);
 
-       irq_desc[virtirq].handler = &iSeries_IRQ_handler;
+       irq_desc[virtirq].chip = &iSeries_IRQ_handler;
        return virtirq;
 }
 
index 9a4efc0c3b2932f025275287f9c42f4f94f30ad9..f7170ff86dab2d04cc1c0e7ec0b235c1684b1cee 100644 (file)
@@ -376,9 +376,10 @@ static void __init maple_fixup_phb_resources(void)
                unsigned long offset = (unsigned long)hose->io_base_virt - pci_io_base;
                hose->io_resource.start += offset;
                hose->io_resource.end += offset;
-               printk(KERN_INFO "PCI Host %d, io start: %lx; io end: %lx\n",
+               printk(KERN_INFO "PCI Host %d, io start: %llx; io end: %llx\n",
                       hose->global_number,
-                      hose->io_resource.start, hose->io_resource.end);
+                      (unsigned long long)hose->io_resource.start,
+                      (unsigned long long)hose->io_resource.end);
        }
 }
 
index 80035853467b000fa1517920762b8bc1bfdfef8b..d524a915aa8646e19080d32d90b8c6292ddcefd0 100644 (file)
@@ -939,9 +939,10 @@ static int __init add_bridge(struct device_node *dev)
                disp_name = "Chaos";
                primary = 0;
        }
-       printk(KERN_INFO "Found %s PCI host bridge at 0x%08lx. "
+       printk(KERN_INFO "Found %s PCI host bridge at 0x%016llx. "
               "Firmware bus number: %d->%d\n",
-               disp_name, rsrc.start, hose->first_busno, hose->last_busno);
+               disp_name, (unsigned long long)rsrc.start, hose->first_busno,
+               hose->last_busno);
 #endif /* CONFIG_PPC32 */
 
        DBG(" ->Hose at 0x%p, cfg_addr=0x%p,cfg_data=0x%p\n",
index 18bf3011d1e3ff103675b0bae793570f4c82606d..9f6189af6dd6b2c5daab9fb1d5d70a3e574ee233 100644 (file)
@@ -446,7 +446,7 @@ static void __init pmac_pic_probe_oldstyle(void)
 
        /* Set the handler for the main PIC */
        for ( i = 0; i < max_real_irqs ; i++ )
-               irq_desc[i].handler = &pmac_pic;
+               irq_desc[i].chip = &pmac_pic;
 
        /* Get addresses of first controller if we have a node for it */
        BUG_ON(of_address_to_resource(master, 0, &r));
@@ -493,7 +493,7 @@ static void __init pmac_pic_probe_oldstyle(void)
        /* Setup handlers for secondary controller and hook cascade irq*/
        if (slave) {
                for ( i = max_real_irqs ; i < max_irqs ; i++ )
-                       irq_desc[i].handler = &gatwick_pic;
+                       irq_desc[i].chip = &gatwick_pic;
                setup_irq(irq_cascade, &gatwick_cascade_action);
        }
        printk(KERN_INFO "irq: System has %d possible interrupts\n", max_irqs);
index b14f9b5c114edebf110120973e8fe43b4fa1168e..19c03dd43000fdd46c31413da79e7a11d7e5397c 100644 (file)
@@ -238,7 +238,7 @@ static int get_irq_server(unsigned int irq)
 {
        unsigned int server;
        /* For the moment only implement delivery to all cpus or one cpu */
-       cpumask_t cpumask = irq_affinity[irq];
+       cpumask_t cpumask = irq_desc[irq].affinity;
        cpumask_t tmp = CPU_MASK_NONE;
 
        if (!distribute_irqs)
@@ -558,7 +558,7 @@ nextnode:
        }
 
        for (i = irq_offset_value(); i < NR_IRQS; ++i)
-               get_irq_desc(i)->handler = &xics_pic;
+               get_irq_desc(i)->chip = &xics_pic;
 
        xics_setup_cpu();
 
@@ -701,9 +701,9 @@ void xics_migrate_irqs_away(void)
                        continue;
 
                /* We only need to migrate enabled IRQS */
-               if (desc == NULL || desc->handler == NULL
+               if (desc == NULL || desc->chip == NULL
                    || desc->action == NULL
-                   || desc->handler->set_affinity == NULL)
+                   || desc->chip->set_affinity == NULL)
                        continue;
 
                spin_lock_irqsave(&desc->lock, flags);
@@ -728,8 +728,8 @@ void xics_migrate_irqs_away(void)
                       virq, cpu);
 
                /* Reset affinity to all cpus */
-               desc->handler->set_affinity(virq, CPU_MASK_ALL);
-               irq_affinity[virq] = CPU_MASK_ALL;
+               desc->chip->set_affinity(virq, CPU_MASK_ALL);
+               irq_desc[irq].affinity = CPU_MASK_ALL;
 unlock:
                spin_unlock_irqrestore(&desc->lock, flags);
        }
index b7ac32fdd7766f74ceff0d2098df4614eae83701..2bff30f6d6357aa4b44a8bba2ae7ec17d2d17fcd 100644 (file)
@@ -208,7 +208,7 @@ void __init i8259_init(unsigned long intack_addr, int offset)
        spin_unlock_irqrestore(&i8259_lock, flags);
 
        for (i = 0; i < NUM_ISA_INTERRUPTS; ++i)
-               irq_desc[offset + i].handler = &i8259_pic;
+               irq_desc[offset + i].chip = &i8259_pic;
 
        /* reserve our resources */
        setup_irq(offset + 2, &i8259_irqaction);
index 8f01e0f1d847404ceea8ce035f390c1fa2091f6c..46801f5ec03f3883b424239e7a9c13b958ae9144 100644 (file)
@@ -472,7 +472,7 @@ void __init ipic_init(phys_addr_t phys_addr,
        ipic_write(primary_ipic->regs, IPIC_SEMSR, temp);
 
        for (i = 0 ; i < NR_IPIC_INTS ; i++) {
-               irq_desc[i+irq_offset].handler = &ipic;
+               irq_desc[i+irq_offset].chip = &ipic;
                irq_desc[i+irq_offset].status = IRQ_LEVEL;
        }
 
index bffe50d02c99578fc75f85055387216ee8a88761..28df9c827ca66b409d0b0427f09c22944dad2079 100644 (file)
@@ -379,14 +379,14 @@ static inline u32 mpic_physmask(u32 cpumask)
 /* Get the mpic structure from the IPI number */
 static inline struct mpic * mpic_from_ipi(unsigned int ipi)
 {
-       return container_of(irq_desc[ipi].handler, struct mpic, hc_ipi);
+       return container_of(irq_desc[ipi].chip, struct mpic, hc_ipi);
 }
 #endif
 
 /* Get the mpic structure from the irq number */
 static inline struct mpic * mpic_from_irq(unsigned int irq)
 {
-       return container_of(irq_desc[irq].handler, struct mpic, hc_irq);
+       return container_of(irq_desc[irq].chip, struct mpic, hc_irq);
 }
 
 /* Send an EOI */
@@ -752,7 +752,7 @@ void __init mpic_init(struct mpic *mpic)
                if (!(mpic->flags & MPIC_PRIMARY))
                        continue;
                irq_desc[mpic->ipi_offset+i].status |= IRQ_PER_CPU;
-               irq_desc[mpic->ipi_offset+i].handler = &mpic->hc_ipi;
+               irq_desc[mpic->ipi_offset+i].chip = &mpic->hc_ipi;
 #endif /* CONFIG_SMP */
        }
 
@@ -813,7 +813,7 @@ void __init mpic_init(struct mpic *mpic)
                /* init linux descriptors */
                if (i < mpic->irq_count) {
                        irq_desc[mpic->irq_offset+i].status = level ? IRQ_LEVEL : 0;
-                       irq_desc[mpic->irq_offset+i].handler = &mpic->hc_irq;
+                       irq_desc[mpic->irq_offset+i].chip = &mpic->hc_irq;
                }
        }
        
@@ -906,7 +906,7 @@ void mpic_setup_this_cpu(void)
        /* let the mpic know we want intrs. default affinity is 0xffffffff
         * until changed via /proc. That's how it's done on x86. If we want
         * it differently, then we should make sure we also change the default
-        * values of irq_affinity in irq.c.
+        * values of irq_desc[].affinity in irq.c.
         */
        if (distribute_irqs) {
                for (i = 0; i < mpic->num_sources ; i++)
index 12b84ca51327f570d8becc0696c0cd405f2edadc..9b3ace26280cb85301fd2954492f6dcb47530750 100644 (file)
@@ -187,7 +187,7 @@ cpm_interrupt_init(void)
          * interrupt vectors
          */
         for ( i = CPM_IRQ_OFFSET ; i < CPM_IRQ_OFFSET + NR_CPM_INTS ; i++ )
-                irq_desc[i].handler = &cpm_pic;
+                irq_desc[i].chip = &cpm_pic;
 
        /* Set our interrupt handler with the core CPU. */
        if (setup_irq(CPM_INTERRUPT, &cpm_interrupt_irqaction))
index d20accf9650dcbacc4ec88806c074d150cd10dca..242bb052be679f66bca5345fdeda0f226ef90046 100644 (file)
@@ -95,8 +95,10 @@ pcibios_fixup_resources(struct pci_dev *dev)
                if (!res->flags)
                        continue;
                if (res->end == 0xffffffff) {
-                       DBG("PCI:%s Resource %d [%08lx-%08lx] is unassigned\n",
-                           pci_name(dev), i, res->start, res->end);
+                       DBG("PCI:%s Resource %d [%016llx-%016llx] is unassigned\n",
+                               pci_name(dev), i,
+                               (unsigned long long)res->start,
+                               (unsigned long long)res->end);
                        res->end -= res->start;
                        res->start = 0;
                        res->flags |= IORESOURCE_UNSET;
@@ -169,18 +171,18 @@ EXPORT_SYMBOL(pcibios_bus_to_resource);
  * but we want to try to avoid allocating at 0x2900-0x2bff
  * which might have be mirrored at 0x0100-0x03ff..
  */
-void pcibios_align_resource(void *data, struct resource *res, unsigned long size,
-                      unsigned long align)
+void pcibios_align_resource(void *data, struct resource *res,
+                               resource_size_t size, resource_size_t align)
 {
        struct pci_dev *dev = data;
 
        if (res->flags & IORESOURCE_IO) {
-               unsigned long start = res->start;
+               resource_size_t start = res->start;
 
                if (size > 0x100) {
                        printk(KERN_ERR "PCI: I/O Region %s/%d too large"
-                              " (%ld bytes)\n", pci_name(dev),
-                              dev->resource - res, size);
+                              " (%lld bytes)\n", pci_name(dev),
+                              dev->resource - res, (unsigned long long)size);
                }
 
                if (start & 0x300) {
@@ -251,8 +253,9 @@ pcibios_allocate_bus_resources(struct list_head *bus_list)
                                }
                        }
 
-                       DBG("PCI: bridge rsrc %lx..%lx (%lx), parent %p\n",
-                           res->start, res->end, res->flags, pr);
+                       DBG("PCI: bridge rsrc %llx..%llx (%lx), parent %p\n",
+                               (unsigned long long)res->start,
+                               (unsigned long long)res->end, res->flags, pr);
                        if (pr) {
                                if (request_resource(pr, res) == 0)
                                        continue;
@@ -302,8 +305,9 @@ reparent_resources(struct resource *parent, struct resource *res)
        *pp = NULL;
        for (p = res->child; p != NULL; p = p->sibling) {
                p->parent = res;
-               DBG(KERN_INFO "PCI: reparented %s [%lx..%lx] under %s\n",
-                   p->name, p->start, p->end, res->name);
+               DBG(KERN_INFO "PCI: reparented %s [%llx..%llx] under %s\n",
+                       p->name, (unsigned long long)p->start,
+                       (unsigned long long)p->end, res->name);
        }
        return 0;
 }
@@ -358,13 +362,15 @@ pci_relocate_bridge_resource(struct pci_bus *bus, int i)
                try = conflict->start - 1;
        }
        if (request_resource(pr, res)) {
-               DBG(KERN_ERR "PCI: huh? couldn't move to %lx..%lx\n",
-                   res->start, res->end);
+               DBG(KERN_ERR "PCI: huh? couldn't move to %llx..%llx\n",
+                       (unsigned long long)res->start,
+                       (unsigned long long)res->end);
                return -1;              /* "can't happen" */
        }
        update_bridge_base(bus, i);
-       printk(KERN_INFO "PCI: bridge %d resource %d moved to %lx..%lx\n",
-              bus->number, i, res->start, res->end);
+       printk(KERN_INFO "PCI: bridge %d resource %d moved to %llx..%llx\n",
+               bus->number, i, (unsigned long long)res->start,
+               (unsigned long long)res->end);
        return 0;
 }
 
@@ -475,15 +481,17 @@ static inline void alloc_resource(struct pci_dev *dev, int idx)
 {
        struct resource *pr, *r = &dev->resource[idx];
 
-       DBG("PCI:%s: Resource %d: %08lx-%08lx (f=%lx)\n",
-           pci_name(dev), idx, r->start, r->end, r->flags);
+       DBG("PCI:%s: Resource %d: %016llx-%016llx (f=%lx)\n",
+           pci_name(dev), idx, (unsigned long long)r->start,
+           (unsigned long long)r->end, r->flags);
        pr = pci_find_parent_resource(dev, r);
        if (!pr || request_resource(pr, r) < 0) {
                printk(KERN_ERR "PCI: Cannot allocate resource region %d"
                       " of device %s\n", idx, pci_name(dev));
                if (pr)
-                       DBG("PCI:  parent is %p: %08lx-%08lx (f=%lx)\n",
-                           pr, pr->start, pr->end, pr->flags);
+                       DBG("PCI:  parent is %p: %016llx-%016llx (f=%lx)\n",
+                               pr, (unsigned long long)pr->start,
+                               (unsigned long long)pr->end, pr->flags);
                /* We'll assign a new address later */
                r->flags |= IORESOURCE_UNSET;
                r->end -= r->start;
@@ -952,8 +960,8 @@ static pgprot_t __pci_mmap_set_pgprot(struct pci_dev *dev, struct resource *rp,
        else
                prot |= _PAGE_GUARDED;
 
-       printk("PCI map for %s:%lx, prot: %lx\n", pci_name(dev), rp->start,
-              prot);
+       printk("PCI map for %s:%llx, prot: %lx\n", pci_name(dev),
+               (unsigned long long)rp->start, prot);
 
        return __pgprot(prot);
 }
@@ -1122,7 +1130,7 @@ long sys_pciconfig_iobase(long which, unsigned long bus, unsigned long devfn)
 
 void pci_resource_to_user(const struct pci_dev *dev, int bar,
                          const struct resource *rsrc,
-                         u64 *start, u64 *end)
+                         resource_size_t *start, resource_size_t *end)
 {
        struct pci_controller *hose = pci_bus_to_hose(dev->bus->number);
        unsigned long offset = 0;
index fe0cdc04d4366b0c9460486e25d8b00eb4a58a76..5c4118a459f3eb1b6822b5817ee16248f9c9da48 100644 (file)
@@ -734,9 +734,9 @@ void apus_init_IRQ(void)
        for ( i = 0 ; i < AMI_IRQS; i++ ) {
                irq_desc[i].status = IRQ_LEVEL;
                if (i < IRQ_AMIGA_AUTO) {
-                       irq_desc[i].handler = &amiga_irqctrl;
+                       irq_desc[i].chip = &amiga_irqctrl;
                } else {
-                       irq_desc[i].handler = &amiga_sys_irqctrl;
+                       irq_desc[i].chip = &amiga_sys_irqctrl;
                        action = &amiga_sys_irqaction[i-IRQ_AMIGA_AUTO];
                        if (action->name)
                                setup_irq(i, action);
index 866807b4ad0b32ffc32b92c281180b64a4356e9b..41006d2b4b3823a3438f2d79e43caf67b77ee5ab 100644 (file)
@@ -172,7 +172,7 @@ void __init sbc82xx_init_IRQ(void)
        
        /* Set up the interrupt handlers for the i8259 IRQs */
        for (i = NR_SIU_INTS; i < NR_SIU_INTS + 8; i++) {
-                irq_desc[i].handler = &sbc82xx_i8259_ic;
+                irq_desc[i].chip = &sbc82xx_i8259_ic;
                irq_desc[i].status |= IRQ_LEVEL;
        }
 
index 5add0a919ef6182695f88fee3d149bbdd985e7b5..172aa215fdb0d1ac059c725187f9afdc4f5aaaf7 100644 (file)
@@ -140,12 +140,12 @@ cpc700_init_IRQ(void)
                                                        /* IRQ 0 is highest */
 
        for (i = 0; i < 17; i++) {
-               irq_desc[i].handler = &cpc700_pic;
+               irq_desc[i].chip = &cpc700_pic;
                cpc700_pic_init_irq(i);
        }
 
        for (i = 20; i < 32; i++) {
-               irq_desc[i].handler = &cpc700_pic;
+               irq_desc[i].chip = &cpc700_pic;
                cpc700_pic_init_irq(i);
        }
 
index 29d95d415ceb7f70accd8c8381f9666f748be467..c0fee0beb81503722a64053122be7fe90d017b4f 100644 (file)
@@ -171,7 +171,7 @@ void cpm2_init_IRQ(void)
        /* Enable chaining to OpenPIC, and make everything level
         */
        for (i = 0; i < NR_CPM_INTS; i++) {
-               irq_desc[i+CPM_IRQ_OFFSET].handler = &cpm2_pic;
+               irq_desc[i+CPM_IRQ_OFFSET].chip = &cpm2_pic;
                irq_desc[i+CPM_IRQ_OFFSET].status |= IRQ_LEVEL;
        }
 }
index dc3bd9ecbbf6956c88079e1fc5a40e27c3c774f9..91096b38ae70297b77fcd8820e3e51a5d6ecf030 100644 (file)
@@ -98,7 +98,7 @@ gt64260_init_irq(void)
 
        /* use the gt64260 for all (possible) interrupt sources */
        for (i = gt64260_irq_base; i < (gt64260_irq_base + 96); i++)
-               irq_desc[i].handler = &gt64260_pic;
+               irq_desc[i].chip = &gt64260_pic;
 
        if (ppc_md.progress)
                ppc_md.progress("gt64260_init_irq: exit", 0x0);
index 1941a8c7ca9a3dbd851b619c6e55ea7b39bc5dcf..63fa5b313396b42fba12d24cc801b34921b49f96 100644 (file)
@@ -159,7 +159,7 @@ pq2pci_init_irq(void)
        immap->im_memctl.memc_or8 = 0xffff8010;
 #endif
        for (irq = NR_CPM_INTS; irq < NR_CPM_INTS + 4; irq++)
-               irq_desc[irq].handler = &pq2pci_ic;
+               irq_desc[irq].chip = &pq2pci_ic;
 
        /* make PCI IRQ level sensitive */
        immap->im_intctl.ic_siexr &=
index dae9af78bde1ba4674f889be162f87312bbe0733..0c4c0de7c59f0b10990969215b0bca76d37a8c55 100644 (file)
@@ -347,13 +347,13 @@ m8xx_init_IRQ(void)
        int i;
 
        for (i = SIU_IRQ_OFFSET ; i < SIU_IRQ_OFFSET + NR_SIU_INTS ; i++)
-               irq_desc[i].handler = &ppc8xx_pic;
+               irq_desc[i].chip = &ppc8xx_pic;
 
        cpm_interrupt_init();
 
 #if defined(CONFIG_PCI)
        for (i = I8259_IRQ_OFFSET ; i < I8259_IRQ_OFFSET + NR_8259_INTS ; i++)
-               irq_desc[i].handler = &i8259_pic;
+               irq_desc[i].chip = &i8259_pic;
 
        i8259_pic_irq_offset = I8259_IRQ_OFFSET;
        i8259_init(0);
index c4406f9dc6a3d0d8c2174524533b914a4313f1af..6425b5cee7db2bc7c638c5c5faa41b07467af98b 100644 (file)
@@ -204,9 +204,9 @@ mpc52xx_init_irq(void)
        out_be32(&intr->main_pri1, 0);
        out_be32(&intr->main_pri2, 0);
 
-       /* Initialize irq_desc[i].handler's with mpc52xx_ic. */
+       /* Initialize irq_desc[i].chip's with mpc52xx_ic. */
        for (i = 0; i < NR_IRQS; i++) {
-               irq_desc[i].handler = &mpc52xx_ic;
+               irq_desc[i].chip = &mpc52xx_ic;
                irq_desc[i].status = IRQ_LEVEL;
        }
 
index 5a19697060f0290ba124adb2fca72001ad82e0a3..a4244d46838197d0b6b20126ba7a454f2b7659f8 100644 (file)
@@ -119,7 +119,7 @@ mv64360_init_irq(void)
        /* All interrupts are level interrupts */
        for (i = mv64360_irq_base; i < (mv64360_irq_base + 96); i++) {
                irq_desc[i].status |= IRQ_LEVEL;
-               irq_desc[i].handler = &mv64360_pic;
+               irq_desc[i].chip = &mv64360_pic;
        }
 
        if (ppc_md.progress)
index 70456c8f998c7be7c992cad3ec8c8a61c2959fa4..767a0bc9581765fb21c70920a0fc93e7b3697735 100644 (file)
@@ -373,7 +373,7 @@ void __init openpic_init(int offset)
                                OPENPIC_VEC_IPI+i+offset);
                /* IPIs are per-CPU */
                irq_desc[OPENPIC_VEC_IPI+i+offset].status |= IRQ_PER_CPU;
-               irq_desc[OPENPIC_VEC_IPI+i+offset].handler = &open_pic_ipi;
+               irq_desc[OPENPIC_VEC_IPI+i+offset].chip = &open_pic_ipi;
        }
 #endif
 
@@ -408,7 +408,7 @@ void __init openpic_init(int offset)
 
        /* Init descriptors */
        for (i = offset; i < NumSources + offset; i++)
-               irq_desc[i].handler = &open_pic;
+               irq_desc[i].chip = &open_pic;
 
        /* Initialize the spurious interrupt */
        if (ppc_md.progress) ppc_md.progress("openpic: spurious",0x3bd);
@@ -615,8 +615,8 @@ void __devinit do_openpic_setup_cpu(void)
        /* let the openpic know we want intrs. default affinity
         * is 0xffffffff until changed via /proc
         * That's how it's done on x86. If we want it differently, then
-        * we should make sure we also change the default values of irq_affinity
-        * in irq.c.
+        * we should make sure we also change the default values of
+        * irq_desc[].affinity in irq.c.
         */
        for (i = 0; i < NumSources; i++)
                openpic_mapirq(i, msk, CPU_MASK_ALL);
index bcbe40de26fe511cf42aba2faa98ff449a7f00d9..b8154efff6ede2c7a14224a920542b4650488dac 100644 (file)
@@ -290,7 +290,7 @@ void __init openpic2_init(int offset)
 
        /* Init descriptors */
        for (i = offset; i < NumSources + offset; i++)
-               irq_desc[i].handler = &open_pic2;
+               irq_desc[i].chip = &open_pic2;
 
        /* Initialize the spurious interrupt */
        if (ppc_md.progress) ppc_md.progress("openpic2: spurious",0x3bd);
index c46043c47225b72b737d79dcaac46cb2a4ced2bf..1584c8b1229f76bac6627a939c4d3efd9b206d4d 100644 (file)
@@ -121,5 +121,5 @@ ppc4xx_pic_init(void)
        ppc_md.get_irq = ppc403_pic_get_irq;
 
        for (i = 0; i < NR_IRQS; i++)
-               irq_desc[i].handler = &ppc403_aic;
+               irq_desc[i].chip = &ppc403_aic;
 }
index fd9af0fc0e9f43ddce46abdba519b73e6c6c1810..e669c1335d47e93bf46a603e2e9ce1dd098420a3 100644 (file)
@@ -276,7 +276,7 @@ void __init ppc4xx_pic_init(void)
 
        /* Attach low-level handlers */
        for (i = 0; i < (NR_UICS << 5); ++i) {
-               irq_desc[i].handler = &__uic[i >> 5].decl;
+               irq_desc[i].chip = &__uic[i >> 5].decl;
                if (is_level_sensitive(i))
                        irq_desc[i].status |= IRQ_LEVEL;
        }
index e672b600f315499a50b84a5ee5750e86f0e8e5c7..39a93dc6375b82a074aad29b9774865e27f001a5 100644 (file)
@@ -143,7 +143,7 @@ ppc4xx_pic_init(void)
        ppc_md.get_irq = xilinx_pic_get_irq;
 
        for (i = 0; i < NR_IRQS; ++i) {
-               irq_desc[i].handler = &xilinx_intc;
+               irq_desc[i].chip = &xilinx_intc;
 
                if (XPAR_INTC_0_KIND_OF_INTR & (0x00000001 << i))
                        irq_desc[i].status &= ~IRQ_LEVEL;
index c0973f8d57bae3c6060a9f4e67ddf9a11adfef21..357fab1bac2ba518eebfc968260b2cd259ec8798 100644 (file)
@@ -102,6 +102,6 @@ static void end_maskreg_irq(unsigned int irq)
 void make_maskreg_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &maskreg_irq_type;
+       irq_desc[irq].chip = &maskreg_irq_type;
        disable_maskreg_irq(irq);
 }
index 6ddbcc77244da4d81653baa2c6bb2a6bb838debd..1d32425782c00cec5fb8ee72875202d2cd667268 100644 (file)
@@ -253,7 +253,7 @@ static void make_bigsur_l1isr(unsigned int irq) {
         /* sanity check first */
         if(irq >= BIGSUR_IRQ_LOW && irq < BIGSUR_IRQ_HIGH) {
                 /* save the handler in the main description table */
-                irq_desc[irq].handler = &bigsur_l1irq_type;
+                irq_desc[irq].chip = &bigsur_l1irq_type;
                 irq_desc[irq].status = IRQ_DISABLED;
                 irq_desc[irq].action = 0;
                 irq_desc[irq].depth = 1;
@@ -270,7 +270,7 @@ static void make_bigsur_l2isr(unsigned int irq) {
         /* sanity check first */
         if(irq >= BIGSUR_2NDLVL_IRQ_LOW && irq < BIGSUR_2NDLVL_IRQ_HIGH) {
                 /* save the handler in the main description table */
-                irq_desc[irq].handler = &bigsur_l2irq_type;
+                irq_desc[irq].chip = &bigsur_l2irq_type;
                 irq_desc[irq].status = IRQ_DISABLED;
                 irq_desc[irq].action = 0;
                 irq_desc[irq].depth = 1;
index d1da0d844567f66156bff7632a4c73012e466fbe..2955adc52310a8afedaa0fe868165d1d7c467403 100644 (file)
@@ -103,7 +103,7 @@ void __init init_cqreek_IRQ(void)
                cqreek_irq_data[14].stat_port = BRIDGE_IDE_INTR_STAT;
                cqreek_irq_data[14].bit = 1;
 
-               irq_desc[14].handler = &cqreek_irq_type;
+               irq_desc[14].chip = &cqreek_irq_type;
                irq_desc[14].status = IRQ_DISABLED;
                irq_desc[14].action = 0;
                irq_desc[14].depth = 1;
@@ -117,7 +117,7 @@ void __init init_cqreek_IRQ(void)
                cqreek_irq_data[10].bit = (1 << 10);
 
                /* XXX: Err... we may need demultiplexer for ISA irq... */
-               irq_desc[10].handler = &cqreek_irq_type;
+               irq_desc[10].chip = &cqreek_irq_type;
                irq_desc[10].status = IRQ_DISABLED;
                irq_desc[10].action = 0;
                irq_desc[10].depth = 1;
index 55dece35cde5c3be7c687a0eeab5ced10508ba06..0027b80a23435cfd005e45f255ddd62fd5801a52 100644 (file)
@@ -70,7 +70,7 @@ int __init platform_setup(void)
 
        /* Assign all virtual IRQs to the System ASIC int. handler */
        for (i = HW_EVENT_IRQ_BASE; i < HW_EVENT_IRQ_MAX; i++)
-               irq_desc[i].handler = &systemasic_int;
+               irq_desc[i].chip = &systemasic_int;
 
        board_time_init = aica_time_init;
 
index 5130ba2b6ff1aeb95f2631f496a3a72c25d9e1e3..4b3ef16a0e960dc11d207966454e902dfc3e42c2 100644 (file)
@@ -63,7 +63,7 @@ int __init platform_setup(void)
                str[i] = ctrl_readb(EC3104_BASE + i);
 
        for (i = EC3104_IRQBASE; i < EC3104_IRQBASE + 32; i++)
-               irq_desc[i].handler = &ec3104_int;
+               irq_desc[i].chip = &ec3104_int;
 
        printk("initializing EC3104 \"%.8s\" at %08x, IRQ %d, IRQ base %d\n",
               str, EC3104_BASE, EC3104_IRQ, EC3104_IRQBASE);
index 52d0ba39031b7215a1a9c62dc3af49461c6f817f..701fa55d52978b25cc0f0067700e9fe49e1bdce8 100644 (file)
@@ -114,7 +114,7 @@ static void enable_harp_irq(unsigned int irq)
 static void __init make_harp_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &harp_irq_type;
+       irq_desc[irq].chip = &harp_irq_type;
        disable_harp_irq(irq);
 }
 
index ba3a6543975227fb6a40c3a6f93f18c3989a884c..9f7ccd33ffb603d76e8262af032ca93e87b03911 100644 (file)
@@ -273,9 +273,9 @@ void __init pcibios_fixup_irqs(void)
 }
 
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size, unsigned long align)
+                           resource_size_t size, resource_size_t align)
 {
-       unsigned long start = res->start;
+       resource_size_t start = res->start;
 
        if (res->flags & IORESOURCE_IO) {
                if (start >= 0x10000UL) {
index 2bb581b916834749a71c0ff0c0e66996b51372e5..b72f009c52c26cee58fe5317adb246e83b1ac23d 100644 (file)
@@ -194,7 +194,7 @@ static struct hw_interrupt_type mpc1211_irq_type = {
 
 static void make_mpc1211_irq(unsigned int irq)
 {
-       irq_desc[irq].handler = &mpc1211_irq_type;
+       irq_desc[irq].chip = &mpc1211_irq_type;
        irq_desc[irq].status  = IRQ_DISABLED;
        irq_desc[irq].action  = 0;
        irq_desc[irq].depth   = 1;
index 276fa11ee4ce0c4ad581415c146217a825d68141..b055809d2ac1a4459befa360b5d20d4e632db8f1 100644 (file)
@@ -536,7 +536,7 @@ void __init pcibios_fixup_bus(struct pci_bus *bus)
 }
 
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size)
+                           resource_size_t size)
 {
 }
 
index 715e8feb3a68783cc8d1b4375beb632db0f21a7d..2c13a7de6b22ada84a822b199b84cad8af6a4b7b 100644 (file)
@@ -150,7 +150,7 @@ static void enable_od_irq(unsigned int irq)
 static void __init make_od_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &od_irq_type;
+       irq_desc[irq].chip = &od_irq_type;
        disable_od_irq(irq);
 }
 
index ed4c5b50ea45edc29cb77c57f0731dfeda251f47..52a98b524e1fe6263522db00488974dd079046a2 100644 (file)
@@ -86,7 +86,7 @@ static struct hw_interrupt_type hs7751rvoip_irq_type = {
 static void make_hs7751rvoip_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &hs7751rvoip_irq_type;
+       irq_desc[irq].chip = &hs7751rvoip_irq_type;
        disable_hs7751rvoip_irq(irq);
 }
 
index d36c9374aed1dffc9daf9980a5a8439f3da2dd00..e16915d9cda440a3b6e754c6f90e0075eb608cf1 100644 (file)
@@ -100,7 +100,7 @@ static struct hw_interrupt_type rts7751r2d_irq_type = {
 static void make_rts7751r2d_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &rts7751r2d_irq_type;
+       irq_desc[irq].chip = &rts7751r2d_irq_type;
        disable_rts7751r2d_irq(irq);
 }
 
index 7a2eb10edb563c4b108b35204528b536aa1d6e45..845979181059e708cf68d9d902e9b626a1bc1a27 100644 (file)
@@ -105,7 +105,7 @@ static void end_systemh_irq(unsigned int irq)
 void make_systemh_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &systemh_irq_type;
+       irq_desc[irq].chip = &systemh_irq_type;
        disable_systemh_irq(irq);
 }
 
index 70f04caad9a414a1897eab2c585700bd9e8384fa..402735c7c89831cec484953cac01a8d3d5f8bb12 100644 (file)
@@ -85,7 +85,7 @@ void
 make_intreq_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &intreq_irq_type;
+       irq_desc[irq].chip = &intreq_irq_type;
        disable_intreq_irq(irq);
 }
 
index efcbd86b7cd2ff0c546671aaa318916f3ba15def..cb5999425d163641619ce4b403d10675c40e1b9a 100644 (file)
@@ -147,7 +147,7 @@ static void enable_microdev_irq(unsigned int irq)
 static void __init make_microdev_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &microdev_irq_type;
+       irq_desc[irq].chip = &microdev_irq_type;
        disable_microdev_irq(irq);
 }
 
index f014b9bf69224003bdbbb05ff62cfc0540e70e40..724db04cb3929acf6c53ae8ff343a5964045c10c 100644 (file)
@@ -154,7 +154,7 @@ int __init setup_hd64461(void)
        outw(0xffff, HD64461_NIMR);
 
        for (i = HD64461_IRQBASE; i < HD64461_IRQBASE + 16; i++) {
-               irq_desc[i].handler = &hd64461_irq_type;
+               irq_desc[i].chip = &hd64461_irq_type;
        }
 
        setup_irq(CONFIG_HD64461_IRQ, &irq0);
index 68e4c4e4283dc6341b6cc20d63f8244c2766cb04..cf9142c620b7fbc7b30916dab36e02482fc2b10a 100644 (file)
@@ -182,7 +182,7 @@ static int __init setup_hd64465(void)
        outw(0xffff, HD64465_REG_NIMR);         /* mask all interrupts */
 
        for (i = 0; i < HD64465_IRQ_NUM ; i++) {
-               irq_desc[HD64465_IRQ_BASE + i].handler = &hd64465_irq_type;
+               irq_desc[HD64465_IRQ_BASE + i].chip = &hd64465_irq_type;
        }
 
        setup_irq(CONFIG_HD64465_IRQ, &irq0);
index 2ee330b3c38f68e5b2b3113ab1ffd56aaf54427e..892214bade194edf67e0387b435ef04b3c792e50 100644 (file)
@@ -191,7 +191,7 @@ void __init setup_voyagergx_irq(void)
                        flag = 1;
                }
                if (flag == 1)
-                       irq_desc[VOYAGER_IRQ_BASE + i].handler = &voyagergx_irq_type;
+                       irq_desc[VOYAGER_IRQ_BASE + i].chip = &voyagergx_irq_type;
        }
 
        setup_irq(IRQ_VOYAGER, &irq0);
index c1669905abe4d8e632fe823d48b0d0d5420aba27..3d546ba329cfb866a9457751f6ab888523b867cd 100644 (file)
@@ -75,7 +75,7 @@ pcibios_update_resource(struct pci_dev *dev, struct resource *root,
 }
 
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size, unsigned long align)
+                           resource_size_t size, resource_size_t align)
                            __attribute__ ((weak));
 
 /*
@@ -85,10 +85,10 @@ void pcibios_align_resource(void *data, struct resource *res,
  * modulo 0x400.
  */
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size, unsigned long align)
+                           resource_size_t size, resource_size_t align)
 {
        if (res->flags & IORESOURCE_IO) {
-               unsigned long start = res->start;
+               resource_size_t start = res->start;
 
                if (start & 0x300) {
                        start = (start + 0x3ff) & ~0x3ff;
index baed9a550d39d9aff4223992b9db6d48b0eb4c5e..a33ae3e0a5a5dc808f72c425d69afca96d4ed531 100644 (file)
@@ -105,6 +105,6 @@ static void shutdown_imask_irq(unsigned int irq)
 void make_imask_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &imask_irq_type;
+       irq_desc[irq].chip = &imask_irq_type;
        enable_irq(irq);
 }
index 06e8afab32e438f75f49c83385229c6f9776a43d..30064bf6e154bf5f46a2f5c0cfea97bf50c616d4 100644 (file)
@@ -137,7 +137,7 @@ void make_intc2_irq(unsigned int irq,
 
        local_irq_restore(flags);
 
-       irq_desc[irq].handler = &intc2_irq_type;
+       irq_desc[irq].chip = &intc2_irq_type;
 
        disable_intc2_irq(irq);
 }
index e55150ed085619d5962e039e1ebb2a4fdc2e9b15..0373b65c77f9c452b9f9d60cb5ad9bf0cf2862be 100644 (file)
@@ -115,7 +115,7 @@ void make_ipr_irq(unsigned int irq, unsigned int addr, int pos, int priority)
        ipr_data[irq].shift = pos*4; /* POSition (0-3) x 4 means shift */
        ipr_data[irq].priority = priority;
 
-       irq_desc[irq].handler = &ipr_irq_type;
+       irq_desc[irq].chip = &ipr_irq_type;
        disable_ipr_irq(irq);
 }
 
index 95d6024fe1ae8b0c218ffd665b7b09d1abe05673..714963a25bbaaa7767ff86ad66adc6791724dcd4 100644 (file)
@@ -85,7 +85,7 @@ static void end_pint_irq(unsigned int irq)
 void make_pint_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &pint_irq_type;
+       irq_desc[irq].chip = &pint_irq_type;
        disable_pint_irq(irq);
 }
 
index b56e79632f241aaa28fb91935ef3dace2c69924c..c2e07f7f3496a45efa79b87be2cc953b2ebd49e0 100644 (file)
@@ -47,7 +47,7 @@ int show_interrupts(struct seq_file *p, void *v)
                        goto unlock;
                seq_printf(p, "%3d: ",i);
                seq_printf(p, "%10u ", kstat_irqs(i));
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
index d69879c0e063dc7ed39f890fd5020345f830a268..675776a5477e04d5e72dfcda1c02f42d61878d00 100644 (file)
@@ -65,7 +65,7 @@ int show_interrupts(struct seq_file *p, void *v)
                        goto unlock;
                seq_printf(p, "%3d: ",i);
                seq_printf(p, "%10u ", kstat_irqs(i));
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
index fc99bf4e362c9dfca4dada4ff45263baa3f46a08..fa730f5fe2e6e6729ab1b9a2b19ae4c7556ecfc9 100644 (file)
@@ -178,7 +178,7 @@ static void end_intc_irq(unsigned int irq)
 void make_intc_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
-       irq_desc[irq].handler = &intc_irq_type;
+       irq_desc[irq].chip = &intc_irq_type;
        disable_intc_irq(irq);
 }
 
@@ -208,7 +208,7 @@ void __init init_IRQ(void)
        /* Set default: per-line enable/disable, priority driven ack/eoi */
        for (i = 0; i < NR_INTC_IRQS; i++) {
                if (platform_int_priority[i] != NO_PRIORITY) {
-                       irq_desc[i].handler = &intc_irq_type;
+                       irq_desc[i].chip = &intc_irq_type;
                }
        }
 
index 50c61dcb9faee7b79bcdc071ef79634d13bbda8e..945920bc24db62421f0948ada2ab91125644b96c 100644 (file)
@@ -69,10 +69,10 @@ pcibios_update_resource(struct pci_dev *dev, struct resource *root,
  * modulo 0x400.
  */
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size, unsigned long align)
+                           resource_size_t size, resource_size_t align)
 {
        if (res->flags & IORESOURCE_IO) {
-               unsigned long start = res->start;
+               resource_size_t start = res->start;
 
                if (start & 0x300) {
                        start = (start + 0x3ff) & ~0x3ff;
index f797c84bfdd1e9dae8c26211d9ca2024e9297861..05eb7cdc26f0557921231486893d869338974eef 100644 (file)
@@ -187,7 +187,7 @@ void init_cayman_irq(void)
        }
 
        for (i=0; i<NR_EXT_IRQS; i++) {
-               irq_desc[START_EXT_IRQS + i].handler = &cayman_irq_type;
+               irq_desc[START_EXT_IRQS + i].chip = &cayman_irq_type;
        }
 
        /* Setup the SMSC interrupt */
index ae4c667c906f5caf0ef2d049bc5b35382330be03..79d177149fdb351825c750559a05a0f4b92b4094 100644 (file)
@@ -208,7 +208,7 @@ _sparc_ioremap(struct resource *res, u32 bus, u32 pa, int sz)
        pa &= PAGE_MASK;
        sparc_mapiorange(bus, pa, res->start, res->end - res->start + 1);
 
-       return (void __iomem *) (res->start + offset);
+       return (void __iomem *)(unsigned long)(res->start + offset);
 }
 
 /*
@@ -325,7 +325,7 @@ void *sbus_alloc_consistent(struct sbus_dev *sdev, long len, u32 *dma_addrp)
                res->name = sdev->prom_name;
        }
 
-       return (void *)res->start;
+       return (void *)(unsigned long)res->start;
 
 err_noiommu:
        release_resource(res);
@@ -819,7 +819,9 @@ _sparc_io_get_info(char *buf, char **start, off_t fpos, int length, int *eof,
                if (p + 32 >= e)        /* Better than nothing */
                        break;
                if ((nm = r->name) == 0) nm = "???";
-               p += sprintf(p, "%08lx-%08lx: %s\n", r->start, r->end, nm);
+               p += sprintf(p, "%016llx-%016llx: %s\n",
+                               (unsigned long long)r->start,
+                               (unsigned long long)r->end, nm);
        }
 
        return p-buf;
index bcfdddd0418aeda77ab17a87c46e8df5f16287d8..5df3ebdc0ab180b3cbffdfa5a3d9cdbebf33439b 100644 (file)
@@ -860,7 +860,7 @@ char * __init pcibios_setup(char *str)
 }
 
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size, unsigned long align)
+                           resource_size_t size, resource_size_t align)
 {
 }
 
index a893a9cc953473a335668569407c0b8d7a35ccf1..2e5d08ce217b28104dc9e8ce9d49bec867ed5d9d 100644 (file)
@@ -496,7 +496,7 @@ static int __init topology_init(void)
                if (!p)
                        err = -ENOMEM;
                else
-                       register_cpu(p, i, NULL);
+                       register_cpu(p, i);
        }
 
        return err;
index cc89b06d01785a73ca974202da67f6852f52e9da..ab9e640df22820a5ffd9084b73258ea09042c41e 100644 (file)
@@ -151,7 +151,7 @@ int show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
 #endif
-               seq_printf(p, " %9s", irq_desc[i].handler->typename);
+               seq_printf(p, " %9s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
@@ -224,7 +224,7 @@ static inline struct ino_bucket *virt_irq_to_bucket(unsigned int virt_irq)
 #ifdef CONFIG_SMP
 static int irq_choose_cpu(unsigned int virt_irq)
 {
-       cpumask_t mask = irq_affinity[virt_irq];
+       cpumask_t mask = irq_desc[virt_irq].affinity;
        int cpuid;
 
        if (cpus_equal(mask, CPU_MASK_ALL)) {
@@ -414,8 +414,8 @@ void irq_install_pre_handler(int virt_irq,
        data->pre_handler_arg1 = arg1;
        data->pre_handler_arg2 = arg2;
 
-       desc->handler = (desc->handler == &sun4u_irq ?
-                        &sun4u_irq_ack : &sun4v_irq_ack);
+       desc->chip = (desc->chip == &sun4u_irq ?
+                     &sun4u_irq_ack : &sun4v_irq_ack);
 }
 
 unsigned int build_irq(int inofixup, unsigned long iclr, unsigned long imap)
@@ -431,7 +431,7 @@ unsigned int build_irq(int inofixup, unsigned long iclr, unsigned long imap)
        bucket = &ivector_table[ino];
        if (!bucket->virt_irq) {
                bucket->virt_irq = virt_irq_alloc(__irq(bucket));
-               irq_desc[bucket->virt_irq].handler = &sun4u_irq;
+               irq_desc[bucket->virt_irq].chip = &sun4u_irq;
        }
 
        desc = irq_desc + bucket->virt_irq;
@@ -465,7 +465,7 @@ unsigned int sun4v_build_irq(u32 devhandle, unsigned int devino)
        bucket = &ivector_table[sysino];
        if (!bucket->virt_irq) {
                bucket->virt_irq = virt_irq_alloc(__irq(bucket));
-               irq_desc[bucket->virt_irq].handler = &sun4v_irq;
+               irq_desc[bucket->virt_irq].chip = &sun4v_irq;
        }
 
        desc = irq_desc + bucket->virt_irq;
index 6c9e3e94abaa74a68fb06f05f9ba857c0721661f..20ca9ec8fd3bbef18c844490c4f8f553c9a23116 100644 (file)
@@ -357,7 +357,7 @@ void pcibios_update_irq(struct pci_dev *pdev, int irq)
 }
 
 void pcibios_align_resource(void *data, struct resource *res,
-                           unsigned long size, unsigned long align)
+                           resource_size_t size, resource_size_t align)
 {
 }
 
index 2ffda012385e9e5f9f3f15be42389f42c3e1164c..fae43a3054a0bec3c00782e70e66926186a28e8c 100644 (file)
@@ -63,7 +63,7 @@ int show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
 #endif
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
@@ -451,13 +451,13 @@ void __init init_IRQ(void)
        irq_desc[TIMER_IRQ].status = IRQ_DISABLED;
        irq_desc[TIMER_IRQ].action = NULL;
        irq_desc[TIMER_IRQ].depth = 1;
-       irq_desc[TIMER_IRQ].handler = &SIGVTALRM_irq_type;
+       irq_desc[TIMER_IRQ].chip = &SIGVTALRM_irq_type;
        enable_irq(TIMER_IRQ);
        for (i = 1; i < NR_IRQS; i++) {
                irq_desc[i].status = IRQ_DISABLED;
                irq_desc[i].action = NULL;
                irq_desc[i].depth = 1;
-               irq_desc[i].handler = &normal_irq_type;
+               irq_desc[i].chip = &normal_irq_type;
                enable_irq(i);
        }
 }
index 7a151c26f82e2bd7be47a0053deb18bf84f0004d..858c45819aabe496dd663eb27195ea3d835b4f1c 100644 (file)
@@ -65,10 +65,10 @@ int show_interrupts(struct seq_file *p, void *v)
                        int j;
                        int count = 0;
                        int num = -1;
-                       const char *type_name = irq_desc[irq].handler->typename;
+                       const char *type_name = irq_desc[irq].chip->typename;
 
                        for (j = 0; j < NR_IRQS; j++)
-                               if (irq_desc[j].handler->typename == type_name){
+                               if (irq_desc[j].chip->typename == type_name){
                                        if (irq == j)
                                                num = count;
                                        count++;
@@ -117,7 +117,7 @@ init_irq_handlers (int base_irq, int num, int interval,
                irq_desc[base_irq].status  = IRQ_DISABLED;
                irq_desc[base_irq].action  = NULL;
                irq_desc[base_irq].depth   = 1;
-               irq_desc[base_irq].handler = irq_type;
+               irq_desc[base_irq].chip = irq_type;
                base_irq += interval;
        }
 }
index ffbb6d073bf2b39e9f24814662d6a6129a132171..3a7c5c9c3ac66f5fd248c81d823e582dadcce1e9 100644 (file)
@@ -329,7 +329,7 @@ void pcibios_fixup_bus(struct pci_bus *b)
 
 void
 pcibios_align_resource (void *data, struct resource *res,
-                       unsigned long size, unsigned long align)
+                       resource_size_t size, resource_size_t align)
 {
 }
 
index ccc4a7fb97a370f8d56baf16e4eb1439a17621d3..91039844820ce5b29f516e427f569a48b7d632b0 100644 (file)
@@ -370,6 +370,8 @@ config HOTPLUG_CPU
                can be controlled through /sys/devices/system/cpu/cpu#.
                Say N if you want to disable CPU hotplug.
 
+config ARCH_ENABLE_MEMORY_HOTPLUG
+       def_bool y
 
 config HPET_TIMER
        bool
index 86b2c1e197aa3f6b1b86c7537aa7d42c6959bcc8..3dd1659427dc3a78f6c09c3e2827d36278f2b1e7 100644 (file)
@@ -235,7 +235,7 @@ void make_8259A_irq(unsigned int irq)
 {
        disable_irq_nosync(irq);
        io_apic_irqs &= ~(1<<irq);
-       irq_desc[irq].handler = &i8259A_irq_type;
+       irq_desc[irq].chip = &i8259A_irq_type;
        enable_irq(irq);
 }
 
@@ -468,12 +468,12 @@ void __init init_ISA_irqs (void)
                        /*
                         * 16 old-style INTA-cycle interrupts:
                         */
-                       irq_desc[i].handler = &i8259A_irq_type;
+                       irq_desc[i].chip = &i8259A_irq_type;
                } else {
                        /*
                         * 'high' PCI IRQs filled in on demand
                         */
-                       irq_desc[i].handler = &no_irq_type;
+                       irq_desc[i].chip = &no_irq_type;
                }
        }
 }
index c768d8a036d0c7998e802944f4cc0103e4ec0dbc..401b687fef21b2f4736c6a79d3f51b1fa1ac99b8 100644 (file)
@@ -876,15 +876,17 @@ static struct hw_interrupt_type ioapic_edge_type;
 #define IOAPIC_EDGE    0
 #define IOAPIC_LEVEL   1
 
-static inline void ioapic_register_intr(int irq, int vector, unsigned long trigger)
+static void ioapic_register_intr(int irq, int vector, unsigned long trigger)
 {
-       unsigned idx = use_pci_vector() && !platform_legacy_irq(irq) ? vector : irq;
+       unsigned idx;
+
+       idx = use_pci_vector() && !platform_legacy_irq(irq) ? vector : irq;
 
        if ((trigger == IOAPIC_AUTO && IO_APIC_irq_trigger(irq)) ||
                        trigger == IOAPIC_LEVEL)
-               irq_desc[idx].handler = &ioapic_level_type;
+               irq_desc[idx].chip = &ioapic_level_type;
        else
-               irq_desc[idx].handler = &ioapic_edge_type;
+               irq_desc[idx].chip = &ioapic_edge_type;
        set_intr_gate(vector, interrupt[idx]);
 }
 
@@ -986,7 +988,7 @@ static void __init setup_ExtINT_IRQ0_pin(unsigned int apic, unsigned int pin, in
         * The timer IRQ doesn't have to know that behind the
         * scene we have a 8259A-master in AEOI mode ...
         */
-       irq_desc[0].handler = &ioapic_edge_type;
+       irq_desc[0].chip = &ioapic_edge_type;
 
        /*
         * Add it to the IO-APIC irq-routing table:
@@ -1616,6 +1618,13 @@ static void set_ioapic_affinity_vector (unsigned int vector,
 #endif // CONFIG_SMP
 #endif // CONFIG_PCI_MSI
 
+static int ioapic_retrigger(unsigned int irq)
+{
+       send_IPI_self(IO_APIC_VECTOR(irq));
+
+       return 1;
+}
+
 /*
  * Level and edge triggered IO-APIC interrupts need different handling,
  * so we use two separate IRQ descriptors. Edge triggered IRQs can be
@@ -1636,6 +1645,7 @@ static struct hw_interrupt_type ioapic_edge_type __read_mostly = {
 #ifdef CONFIG_SMP
        .set_affinity = set_ioapic_affinity,
 #endif
+       .retrigger      = ioapic_retrigger,
 };
 
 static struct hw_interrupt_type ioapic_level_type __read_mostly = {
@@ -1649,6 +1659,7 @@ static struct hw_interrupt_type ioapic_level_type __read_mostly = {
 #ifdef CONFIG_SMP
        .set_affinity = set_ioapic_affinity,
 #endif
+       .retrigger      = ioapic_retrigger,
 };
 
 static inline void init_IO_APIC_traps(void)
@@ -1683,7 +1694,7 @@ static inline void init_IO_APIC_traps(void)
                                make_8259A_irq(irq);
                        else
                                /* Strange. Oh, well.. */
-                               irq_desc[irq].handler = &no_irq_type;
+                               irq_desc[irq].chip = &no_irq_type;
                }
        }
 }
@@ -1900,7 +1911,7 @@ static inline void check_timer(void)
        apic_printk(APIC_VERBOSE, KERN_INFO "...trying to set up timer as Virtual Wire IRQ...");
 
        disable_8259A_irq(0);
-       irq_desc[0].handler = &lapic_irq_type;
+       irq_desc[0].chip = &lapic_irq_type;
        apic_write(APIC_LVT0, APIC_DM_FIXED | vector);  /* Fixed mode */
        enable_8259A_irq(0);
 
index bfa82f52a5cc5cb869f0c04905cd474ae54853b3..a1f1df5f7bfc2d5a40d6269e5a37f69d6dc746af 100644 (file)
@@ -79,7 +79,7 @@ int show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
 #endif
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
 
                seq_printf(p, "  %s", action->name);
                for (action=action->next; action; action = action->next)
@@ -146,13 +146,13 @@ void fixup_irqs(cpumask_t map)
                if (irq == 2)
                        continue;
 
-               cpus_and(mask, irq_affinity[irq], map);
+               cpus_and(mask, irq_desc[irq].affinity, map);
                if (any_online_cpu(mask) == NR_CPUS) {
                        printk("Breaking affinity for irq %i\n", irq);
                        mask = map;
                }
-               if (irq_desc[irq].handler->set_affinity)
-                       irq_desc[irq].handler->set_affinity(irq, mask);
+               if (irq_desc[irq].chip->set_affinity)
+                       irq_desc[irq].chip->set_affinity(irq, mask);
                else if (irq_desc[irq].action && !(warned++))
                        printk("Cannot set affinity for irq %i\n", irq);
        }
index 51f9bed455fab0c0576933a7702efb0d51cb84f4..1cf744ee0959e2515d5c47ebcbaffb9e6ac9fba3 100644 (file)
@@ -100,7 +100,7 @@ int show_interrupts(struct seq_file *p, void *v)
                for_each_online_cpu(j)
                        seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]);
 #endif
-               seq_printf(p, " %14s", irq_desc[i].handler->typename);
+               seq_printf(p, " %14s", irq_desc[i].chip->typename);
                seq_printf(p, "  %s", action->name);
 
                for (action=action->next; action; action = action->next)
@@ -181,7 +181,7 @@ void __init init_IRQ(void)
        int i;
 
        for (i=0; i < XTENSA_NR_IRQS; i++)
-               irq_desc[i].handler = &xtensa_irq_type;
+               irq_desc[i].chip = &xtensa_irq_type;
 
        cached_irq_mask = 0;
 
index c6f471b9eaa0c603f356441bea6b980c2e85492e..eda029fc897218a53d38a4f82a66db0a42272963 100644 (file)
@@ -71,13 +71,13 @@ static int pci_bus_count;
  * which might have be mirrored at 0x0100-0x03ff..
  */
 void
-pcibios_align_resource(void *data, struct resource *res, unsigned long size,
-                      unsigned long align)
+pcibios_align_resource(void *data, struct resource *res, resource_size_t size,
+                      resource_size_t align)
 {
        struct pci_dev *dev = data;
 
        if (res->flags & IORESOURCE_IO) {
-               unsigned long start = res->start;
+               resource_size_t start = res->start;
 
                if (size > 0x100) {
                        printk(KERN_ERR "PCI: I/O Region %s/%d too large"
index 889855d8d9f9080ee9b98c3a1a1bcd0691006f59..9e3e2a69c03a6dedd375b32666e94b0989ed1566 100644 (file)
@@ -180,8 +180,9 @@ static DEVICE_ATTR(name, S_IRUGO, show_##name, NULL)
 amba_attr(id, "%08x\n", dev->periphid);
 amba_attr(irq0, "%u\n", dev->irq[0]);
 amba_attr(irq1, "%u\n", dev->irq[1]);
-amba_attr(resource, "\t%08lx\t%08lx\t%08lx\n",
-         dev->res.start, dev->res.end, dev->res.flags);
+amba_attr(resource, "\t%016llx\t%016llx\t%016lx\n",
+        (unsigned long long)dev->res.start, (unsigned long long)dev->res.end,
+        dev->res.flags);
 
 /**
  *     amba_device_register - register an AMBA device
index 4b6bf19c39c004d4b2277f11e68ac2ea59a4b753..4048681f36d503ca2030d0954311ce97327cc183 100644 (file)
@@ -2257,7 +2257,8 @@ static int __devinit amb_probe(struct pci_dev *pci_dev, const struct pci_device_
        }
 
        PRINTD (DBG_INFO, "found Madge ATM adapter (amb) at"
-               " IO %lx, IRQ %u, MEM %p", pci_resource_start(pci_dev, 1),
+               " IO %llx, IRQ %u, MEM %p",
+               (unsigned long long)pci_resource_start(pci_dev, 1),
                irq, bus_to_virt(pci_resource_start(pci_dev, 0)));
 
        // check IO region
index 1bca86edf5708b174220ee41fa5fb05bfaeb064a..d40605c1af73819daf6095dbcd3112bd7fb1c724 100644 (file)
@@ -1658,9 +1658,10 @@ static int __devinit fs_init (struct fs_dev *dev)
        func_enter ();
        pci_dev = dev->pci_dev;
 
-       printk (KERN_INFO "found a FireStream %d card, base %08lx, irq%d.\n", 
+       printk (KERN_INFO "found a FireStream %d card, base %16llx, irq%d.\n",
                IS_FS50(dev)?50:155,
-               pci_resource_start(pci_dev, 0), dev->pci_dev->irq);
+               (unsigned long long)pci_resource_start(pci_dev, 0),
+               dev->pci_dev->irq);
 
        if (fs_debug & FS_DEBUG_INIT)
                my_hd ((unsigned char *) dev, sizeof (*dev));
index 852b564e903a69566a1f3b82d3a339d884db9b98..1a9dee19efcf11cfc61d02dc383a4cb04ff222d9 100644 (file)
@@ -707,7 +707,7 @@ static int pf_detect(void)
                        if (pi_init(pf->pi, 0, conf[D_PRT], conf[D_MOD],
                                    conf[D_UNI], conf[D_PRO], conf[D_DLY],
                                    pf_scratch, PI_PF, verbose, pf->name)) {
-                               if (!pf_probe(pf) && pf->disk) {
+                               if (pf->disk && !pf_probe(pf)) {
                                        pf->present = 1;
                                        k++;
                                } else
index 2ae08b343b935518c86098959866299e73f213e8..8144ce9f4df0543555aa71573ad1c69a43748013 100644 (file)
@@ -1694,9 +1694,10 @@ static int carm_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
        DPRINTK("waiting for probe_comp\n");
        wait_for_completion(&host->probe_comp);
 
-       printk(KERN_INFO "%s: pci %s, ports %d, io %lx, irq %u, major %d\n",
+       printk(KERN_INFO "%s: pci %s, ports %d, io %llx, irq %u, major %d\n",
               host->name, pci_name(pdev), (int) CARM_MAX_PORTS,
-              pci_resource_start(pdev, 0), pdev->irq, host->major);
+              (unsigned long long)pci_resource_start(pdev, 0),
+                  pdev->irq, host->major);
 
        carm_host_id++;
        pci_set_drvdata(pdev, host);
index 410d70cb76fbee1a6b97f329ea78d9e16788c4fc..c40e487d9f5cd8a35475e4357800968eca3ba838 100644 (file)
@@ -961,6 +961,7 @@ config PC8736x_GPIO
 
 config NSC_GPIO
        tristate "NatSemi Base GPIO Support"
+       depends on X86_32
        # selected by SCx200_GPIO and PC8736x_GPIO
        # what about 2 selectors differing: m != y
        help
index 9275d5e52e6de63d86309c82096f19ac5776592e..72fb60765c45a4f973c77ae67c916e85aff80485 100644 (file)
@@ -209,13 +209,16 @@ static int __init applicom_init(void)
                RamIO = ioremap(dev->resource[0].start, LEN_RAM_IO);
 
                if (!RamIO) {
-                       printk(KERN_INFO "ac.o: Failed to ioremap PCI memory space at 0x%lx\n", dev->resource[0].start);
+                       printk(KERN_INFO "ac.o: Failed to ioremap PCI memory "
+                               "space at 0x%llx\n",
+                               (unsigned long long)dev->resource[0].start);
                        pci_disable_device(dev);
                        return -EIO;
                }
 
-               printk(KERN_INFO "Applicom %s found at mem 0x%lx, irq %d\n",
-                      applicom_pci_devnames[dev->device-1], dev->resource[0].start, 
+               printk(KERN_INFO "Applicom %s found at mem 0x%llx, irq %d\n",
+                      applicom_pci_devnames[dev->device-1],
+                          (unsigned long long)dev->resource[0].start,
                       dev->irq);
 
                boardno = ac_register_board(dev->resource[0].start, RamIO,0);
index 05e6e814d86fd64d4670dccd38fe8e1eb7132138..073da48c092e0ae804cc6354b9c897c668b6033c 100644 (file)
@@ -689,9 +689,9 @@ static int __devinit giu_probe(struct platform_device *dev)
 
        for (i = GIU_IRQ_BASE; i <= GIU_IRQ_LAST; i++) {
                if (i < GIU_IRQ(GIUINT_HIGH_OFFSET))
-                       irq_desc[i].handler = &giuint_low_irq_type;
+                       irq_desc[i].chip = &giuint_low_irq_type;
                else
-                       irq_desc[i].handler = &giuint_high_irq_type;
+                       irq_desc[i].chip = &giuint_high_irq_type;
        }
 
        return cascade_irq(GIUINT_IRQ, giu_get_irq);
index ff0cdc142f174d854c7de3e521456767451309ea..3edd7060510fa6e668e46cc6deb1000fe4c4fc69 100644 (file)
@@ -254,7 +254,8 @@ static unsigned int __devinit init_chipset_aec62xx(struct pci_dev *dev, const ch
 
        if (dev->resource[PCI_ROM_RESOURCE].start) {
                pci_write_config_dword(dev, PCI_ROM_ADDRESS, dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
-               printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name, dev->resource[PCI_ROM_RESOURCE].start);
+               printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name,
+                       (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
        }
 
        if (bus_speed <= 33)
index be334da7a7549b4fb44f82e59000450875c1abfb..7da550281cf23a112d61b6cc68d946ad0e540d19 100644 (file)
@@ -176,7 +176,7 @@ static unsigned int __devinit init_chipset_hpt34x(struct pci_dev *dev, const cha
                        pci_write_config_dword(dev, PCI_ROM_ADDRESS,
                                dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
                        printk(KERN_INFO "HPT345: ROM enabled at 0x%08lx\n",
-                               dev->resource[PCI_ROM_RESOURCE].start);
+                               (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
                }
                pci_write_config_byte(dev, PCI_LATENCY_TIMER, 0xF0);
        } else {
index 2c9e938dd1cd534693f54e26067237041c9e3829..5a8334d134fbda2d1caebb0ab0ea4e93444f80e9 100644 (file)
@@ -313,8 +313,8 @@ static unsigned int __devinit init_chipset_pdcnew(struct pci_dev *dev, const cha
        if (dev->resource[PCI_ROM_RESOURCE].start) {
                pci_write_config_dword(dev, PCI_ROM_ADDRESS,
                        dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
-               printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n",
-                       name, dev->resource[PCI_ROM_RESOURCE].start);
+               printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name,
+                       (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
        }
 
 #ifdef CONFIG_PPC_PMAC
index 26bc688a18212a748f2779de3ef64c0d962b3ce0..1e209d8f9437f4e04199bc8b4365d4c48bd0f298 100644 (file)
@@ -490,8 +490,8 @@ static unsigned int __devinit init_chipset_pdc202xx(struct pci_dev *dev,
        if (dev->resource[PCI_ROM_RESOURCE].start) {
                pci_write_config_dword(dev, PCI_ROM_ADDRESS,
                        dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
-               printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n",
-                       name, dev->resource[PCI_ROM_RESOURCE].start);
+               printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name,
+                       (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
        }
 
        return dev->irq;
index 3d278412e1ca07f46b9e69887864d1d076c91a26..800c8d5184302b0195f5ab1f34783d718523e192 100644 (file)
@@ -590,11 +590,11 @@ static void ohci_initialize(struct ti_ohci *ohci)
        buf = reg_read(ohci, OHCI1394_Version);
        sprintf (irq_buf, "%d", ohci->dev->irq);
        PRINT(KERN_INFO, "OHCI-1394 %d.%d (PCI): IRQ=[%s]  "
-             "MMIO=[%lx-%lx]  Max Packet=[%d]  IR/IT contexts=[%d/%d]",
+             "MMIO=[%llx-%llx]  Max Packet=[%d]  IR/IT contexts=[%d/%d]",
              ((((buf) >> 16) & 0xf) + (((buf) >> 20) & 0xf) * 10),
              ((((buf) >> 4) & 0xf) + ((buf) & 0xf) * 10), irq_buf,
-             pci_resource_start(ohci->dev, 0),
-             pci_resource_start(ohci->dev, 0) + OHCI1394_REGISTER_SIZE - 1,
+             (unsigned long long)pci_resource_start(ohci->dev, 0),
+             (unsigned long long)pci_resource_start(ohci->dev, 0) + OHCI1394_REGISTER_SIZE - 1,
              ohci->max_packet_size,
              ohci->nb_iso_rcv_ctx, ohci->nb_iso_xmit_ctx);
 
@@ -3217,7 +3217,7 @@ static int __devinit ohci1394_pci_probe(struct pci_dev *dev,
 {
        struct hpsb_host *host;
        struct ti_ohci *ohci;   /* shortcut to currently handled device */
-       unsigned long ohci_base;
+       resource_size_t ohci_base;
 
         if (pci_enable_device(dev))
                FAIL(-ENXIO, "Failed to enable OHCI hardware");
@@ -3270,15 +3270,16 @@ static int __devinit ohci1394_pci_probe(struct pci_dev *dev,
         * clearly says it's 2kb, so this shouldn't be a problem. */
        ohci_base = pci_resource_start(dev, 0);
        if (pci_resource_len(dev, 0) < OHCI1394_REGISTER_SIZE)
-               PRINT(KERN_WARNING, "PCI resource length of %lx too small!",
-                     pci_resource_len(dev, 0));
+               PRINT(KERN_WARNING, "PCI resource length of 0x%llx too small!",
+                     (unsigned long long)pci_resource_len(dev, 0));
 
        /* Seems PCMCIA handles this internally. Not sure why. Seems
         * pretty bogus to force a driver to special case this.  */
 #ifndef PCMCIA
        if (!request_mem_region (ohci_base, OHCI1394_REGISTER_SIZE, OHCI1394_DRIVER_NAME))
-               FAIL(-ENOMEM, "MMIO resource (0x%lx - 0x%lx) unavailable",
-                    ohci_base, ohci_base + OHCI1394_REGISTER_SIZE);
+               FAIL(-ENOMEM, "MMIO resource (0x%llx - 0x%llx) unavailable",
+                       (unsigned long long)ohci_base,
+                       (unsigned long long)ohci_base + OHCI1394_REGISTER_SIZE);
 #endif
        ohci->init_state = OHCI_INIT_HAVE_MEM_REGION;
 
index dddcdae736ac89151d659a65e8521e98523890fb..e4b897fa569a5e945841fee575e1db1706f4ecd4 100644 (file)
@@ -460,10 +460,10 @@ static int __devinit ipath_init_one(struct pci_dev *pdev,
        for (j = 0; j < 6; j++) {
                if (!pdev->resource[j].start)
                        continue;
-               ipath_cdbg(VERBOSE, "BAR %d start %lx, end %lx, len %lx\n",
-                          j, pdev->resource[j].start,
-                          pdev->resource[j].end,
-                          pci_resource_len(pdev, j));
+               ipath_cdbg(VERBOSE, "BAR %d start %llx, end %llx, len %llx\n",
+                          j, (unsigned long long)pdev->resource[j].start,
+                          (unsigned long long)pdev->resource[j].end,
+                          (unsigned long long)pci_resource_len(pdev, j));
        }
 
        if (!addr) {
index 9b9ff7bff357a2ea8a4d9ab8d6747eea373ade95..465fd220569c651a1cb7499daa1f970b5241811a 100644 (file)
@@ -172,8 +172,9 @@ static int __devinit mthca_dev_lim(struct mthca_dev *mdev, struct mthca_dev_lim
 
        if (dev_lim->uar_size > pci_resource_len(mdev->pdev, 2)) {
                mthca_err(mdev, "HCA reported UAR size of 0x%x bigger than "
-                         "PCI resource 2 size of 0x%lx, aborting.\n",
-                         dev_lim->uar_size, pci_resource_len(mdev->pdev, 2));
+                         "PCI resource 2 size of 0x%llx, aborting.\n",
+                         dev_lim->uar_size,
+                         (unsigned long long)pci_resource_len(mdev->pdev, 2));
                return -ENODEV;
        }
 
index 096b6a0b5ccad6598702233350322d71f28860a6..1ac739ef2ffa53a41053b5bd02218f9073c33281 100644 (file)
@@ -189,7 +189,7 @@ static int __devinit ct82c710_probe(struct platform_device *dev)
        strlcpy(ct82c710_port->name, "C&T 82c710 mouse port",
                sizeof(ct82c710_port->name));
        snprintf(ct82c710_port->phys, sizeof(ct82c710_port->phys),
-                "isa%04lx/serio0", CT82C710_DATA);
+                "isa%16llx/serio0", (unsigned long long)CT82C710_DATA);
 
        serio_register_port(ct82c710_port);
 
@@ -241,8 +241,8 @@ static int __init ct82c710_init(void)
 
        serio_register_port(ct82c710_port);
 
-       printk(KERN_INFO "serio: C&T 82c710 mouse port at %#lx irq %d\n",
-               CT82C710_DATA, CT82C710_IRQ);
+       printk(KERN_INFO "serio: C&T 82c710 mouse port at %#llx irq %d\n",
+               (unsigned long long)CT82C710_DATA, CT82C710_IRQ);
 
        return 0;
 
index 91d25acb5ede07f39d8859204e5b6daa9f150315..3622720f05053a01cb37161ab27b2ce9a2fb6f0c 100644 (file)
@@ -1688,7 +1688,7 @@ setup_hfcpci(struct IsdnCard *card)
                                printk(KERN_WARNING "HFC-PCI: No IRQ for PCI card found\n");
                                return (0);
                        }
-                       cs->hw.hfcpci.pci_io = (char *) dev_hfcpci->resource[ 1].start;
+                       cs->hw.hfcpci.pci_io = (char *)(unsigned long)dev_hfcpci->resource[1].start;
                        printk(KERN_INFO "HiSax: HFC-PCI card manufacturer: %s card name: %s\n", id_list[i].vendor_name, id_list[i].card_name);
                } else {
                        printk(KERN_WARNING "HFC-PCI: No PCI card found\n");
index e2bb4fd8e25e7602e9c69fd0151edb739a119daa..e82ab2251b825089b9f0a28ad68b007c6dbfd0f9 100644 (file)
@@ -311,8 +311,9 @@ setup_telespci(struct IsdnCard *card)
                }
                cs->hw.teles0.membase = ioremap(pci_resource_start(dev_tel, 0),
                        PAGE_SIZE);
-               printk(KERN_INFO "Found: Zoran, base-address: 0x%lx, irq: 0x%x\n",
-                       pci_resource_start(dev_tel, 0), dev_tel->irq);
+               printk(KERN_INFO "Found: Zoran, base-address: 0x%llx, irq: 0x%x\n",
+                       (unsigned long long)pci_resource_start(dev_tel, 0),
+                       dev_tel->irq);
        } else {
                printk(KERN_WARNING "TelesPCI: No PCI card found\n");
                return(0);
index 743ac4077f35b24b17af0b08fc5a23dce9b0733f..8b3efc243161a201fd8029d5d43900371c48b2b5 100644 (file)
@@ -208,7 +208,7 @@ static int isdn_x25iface_receive(struct concap_proto *cprot, struct sk_buff *skb
  */
 static int isdn_x25iface_connect_ind(struct concap_proto *cprot)
 {
-       struct sk_buff * skb = dev_alloc_skb(1);
+       struct sk_buff * skb;
        enum wan_states *state_p 
          = &( ( (ix25_pdata_t*) (cprot->proto_data) ) -> state);
        IX25DEBUG( "isdn_x25iface_connect_ind %s \n"
@@ -220,6 +220,8 @@ static int isdn_x25iface_connect_ind(struct concap_proto *cprot)
                return -1;
        }
        *state_p = WAN_CONNECTED;
+
+       skb = dev_alloc_skb(1);
        if( skb ){
                *( skb_put(skb, 1) ) = 0x01;
                skb->protocol = x25_type_trans(skb, cprot->net_dev);
index 431bd37225a13a05be8891b44de545e88b5802c1..c687ac703941f514af7c352ab456e72be2fc18e2 100644 (file)
@@ -428,10 +428,10 @@ static struct macio_dev * macio_add_one_device(struct macio_chip *chip,
 
        /* MacIO itself has a different reg, we use it's PCI base */
        if (np == chip->of_node) {
-               sprintf(dev->ofdev.dev.bus_id, "%1d.%08lx:%.*s",
+               sprintf(dev->ofdev.dev.bus_id, "%1d.%016llx:%.*s",
                        chip->lbus.index,
 #ifdef CONFIG_PCI
-                       pci_resource_start(chip->lbus.pdev, 0),
+                       (unsigned long long)pci_resource_start(chip->lbus.pdev, 0),
 #else
                        0, /* NuBus may want to do something better here */
 #endif
index f920e50ea124dfe9052288f8f526cb314b230249..837ec4eb3d604ce4e01023ccf87d0804ceef7f88 100644 (file)
@@ -2827,7 +2827,6 @@ static inline sector_t sync_request(mddev_t *mddev, sector_t sector_nr, int *ski
        struct stripe_head *sh;
        int pd_idx;
        int raid_disks = conf->raid_disks;
-       int data_disks = raid_disks - conf->max_degraded;
        sector_t max_sector = mddev->size << 1;
        int sync_blocks;
        int still_degraded = 0;
index 423e954948beb01153b17aafadaf694100996749..aa3203ae670c94a7333fd6c2ea4561179ab6c676 100644 (file)
@@ -4019,8 +4019,9 @@ static int __devinit bttv_probe(struct pci_dev *dev,
        if (!request_mem_region(pci_resource_start(dev,0),
                                pci_resource_len(dev,0),
                                btv->c.name)) {
-               printk(KERN_WARNING "bttv%d: can't request iomem (0x%lx).\n",
-                      btv->c.nr, pci_resource_start(dev,0));
+               printk(KERN_WARNING "bttv%d: can't request iomem (0x%llx).\n",
+                      btv->c.nr,
+                      (unsigned long long)pci_resource_start(dev,0));
                return -EBUSY;
        }
        pci_set_master(dev);
@@ -4031,8 +4032,9 @@ static int __devinit bttv_probe(struct pci_dev *dev,
        pci_read_config_byte(dev, PCI_LATENCY_TIMER, &lat);
        printk(KERN_INFO "bttv%d: Bt%d (rev %d) at %s, ",
               bttv_num,btv->id, btv->revision, pci_name(dev));
-       printk("irq: %d, latency: %d, mmio: 0x%lx\n",
-              btv->c.pci->irq, lat, pci_resource_start(dev,0));
+       printk("irq: %d, latency: %d, mmio: 0x%llx\n",
+              btv->c.pci->irq, lat,
+              (unsigned long long)pci_resource_start(dev,0));
        schedule();
 
        btv->bt848_mmio=ioremap(pci_resource_start(dev,0), 0x1000);
index 2194cbeca33b61b3c1eccf4864cbccbec44e4566..292a5e81eb75fab5ad9a855f3623dae38b80067b 100644 (file)
@@ -712,9 +712,9 @@ static int __devinit snd_cx88_create(struct snd_card *card,
        pci_read_config_byte(pci, PCI_LATENCY_TIMER,  &chip->pci_lat);
 
        dprintk(1,"ALSA %s/%i: found at %s, rev: %d, irq: %d, "
-              "latency: %d, mmio: 0x%lx\n", core->name, devno,
+              "latency: %d, mmio: 0x%llx\n", core->name, devno,
               pci_name(pci), chip->pci_rev, pci->irq,
-              chip->pci_lat,pci_resource_start(pci,0));
+              chip->pci_lat,(unsigned long long)pci_resource_start(pci,0));
 
        chip->irq = pci->irq;
        synchronize_irq(chip->irq);
@@ -766,8 +766,8 @@ static int __devinit cx88_audio_initdev(struct pci_dev *pci,
 
        strcpy (card->driver, "CX88x");
        sprintf(card->shortname, "Conexant CX%x", pci->device);
-       sprintf(card->longname, "%s at %#lx",
-               card->shortname, pci_resource_start(pci, 0));
+       sprintf(card->longname, "%s at %#llx",
+               card->shortname,(unsigned long long)pci_resource_start(pci, 0));
        strcpy (card->mixername, "CX88");
 
        dprintk (0, "%s/%i: ALSA support for cx2388x boards\n",
index 26f4c0fb8c36cab989a9f2ab7a8269f9e6f6f11c..973d3f39b2d540133c5398abd4e028956dee212b 100644 (file)
@@ -1031,8 +1031,8 @@ static int get_ressources(struct cx88_core *core, struct pci_dev *pci)
                               pci_resource_len(pci,0),
                               core->name))
                return 0;
-       printk(KERN_ERR "%s: can't get MMIO memory @ 0x%lx\n",
-              core->name,pci_resource_start(pci,0));
+       printk(KERN_ERR "%s: can't get MMIO memory @ 0x%llx\n",
+              core->name,(unsigned long long)pci_resource_start(pci,0));
        return -EBUSY;
 }
 
index a9d7795a8e143563ed155c109d474d725671012e..2c12aca1b6a3d69fdf8a2b1f5e91e7cac7856093 100644 (file)
@@ -420,9 +420,9 @@ int cx8802_init_common(struct cx8802_dev *dev)
        pci_read_config_byte(dev->pci, PCI_CLASS_REVISION, &dev->pci_rev);
        pci_read_config_byte(dev->pci, PCI_LATENCY_TIMER,  &dev->pci_lat);
        printk(KERN_INFO "%s/2: found at %s, rev: %d, irq: %d, "
-              "latency: %d, mmio: 0x%lx\n", dev->core->name,
+              "latency: %d, mmio: 0x%llx\n", dev->core->name,
               pci_name(dev->pci), dev->pci_rev, dev->pci->irq,
-              dev->pci_lat,pci_resource_start(dev->pci,0));
+              dev->pci_lat,(unsigned long long)pci_resource_start(dev->pci,0));
 
        /* initialize driver struct */
        spin_lock_init(&dev->slock);
index dcda5291b990e979c8490001ea18d7fedc053d6e..8d5cf474b68e817c9729d40ad3f5745092290d9c 100644 (file)
@@ -1847,9 +1847,9 @@ static int __devinit cx8800_initdev(struct pci_dev *pci_dev,
        pci_read_config_byte(pci_dev, PCI_CLASS_REVISION, &dev->pci_rev);
        pci_read_config_byte(pci_dev, PCI_LATENCY_TIMER,  &dev->pci_lat);
        printk(KERN_INFO "%s/0: found at %s, rev: %d, irq: %d, "
-              "latency: %d, mmio: 0x%lx\n", core->name,
+              "latency: %d, mmio: 0x%llx\n", core->name,
               pci_name(pci_dev), dev->pci_rev, pci_dev->irq,
-              dev->pci_lat,pci_resource_start(pci_dev,0));
+              dev->pci_lat,(unsigned long long)pci_resource_start(pci_dev,0));
 
        pci_set_master(pci_dev);
        if (!pci_dma_supported(pci_dev,0xffffffff)) {
index f0c2111f14ad1f11c5bbe0575edd6aedd23420bd..da3007d2f4115df49b6a53ba01dec178a7292529 100644 (file)
@@ -871,9 +871,9 @@ static int __devinit saa7134_initdev(struct pci_dev *pci_dev,
        pci_read_config_byte(pci_dev, PCI_CLASS_REVISION, &dev->pci_rev);
        pci_read_config_byte(pci_dev, PCI_LATENCY_TIMER,  &dev->pci_lat);
        printk(KERN_INFO "%s: found at %s, rev: %d, irq: %d, "
-              "latency: %d, mmio: 0x%lx\n", dev->name,
+              "latency: %d, mmio: 0x%llx\n", dev->name,
               pci_name(pci_dev), dev->pci_rev, pci_dev->irq,
-              dev->pci_lat,pci_resource_start(pci_dev,0));
+              dev->pci_lat,(unsigned long long)pci_resource_start(pci_dev,0));
        pci_set_master(pci_dev);
        if (!pci_dma_supported(pci_dev, DMA_32BIT_MASK)) {
                printk("%s: Oops: no 32bit PCI DMA ???\n",dev->name);
@@ -905,8 +905,8 @@ static int __devinit saa7134_initdev(struct pci_dev *pci_dev,
                                pci_resource_len(pci_dev,0),
                                dev->name)) {
                err = -EBUSY;
-               printk(KERN_ERR "%s: can't get MMIO memory @ 0x%lx\n",
-                      dev->name,pci_resource_start(pci_dev,0));
+               printk(KERN_ERR "%s: can't get MMIO memory @ 0x%llx\n",
+                      dev->name,(unsigned long long)pci_resource_start(pci_dev,0));
                goto fail1;
        }
        dev->lmmio = ioremap(pci_resource_start(pci_dev,0), 0x1000);
index c74e5460f83406f786b34ecc2ff67acdfadb7c22..3305c12372a2f341c68fbca98f3ab5c58e2f7f9a 100644 (file)
@@ -683,9 +683,10 @@ static int i2o_iop_systab_set(struct i2o_controller *c)
                        c->mem_alloc = 1;
                        sb->current_mem_size = 1 + res->end - res->start;
                        sb->current_mem_base = res->start;
-                       osm_info("%s: allocated %ld bytes of PCI memory at "
-                                "0x%08lX.\n", c->name,
-                                1 + res->end - res->start, res->start);
+                       osm_info("%s: allocated %llu bytes of PCI memory at "
+                               "0x%016llX.\n", c->name,
+                               (unsigned long long)(1 + res->end - res->start),
+                               (unsigned long long)res->start);
                }
        }
 
@@ -704,9 +705,10 @@ static int i2o_iop_systab_set(struct i2o_controller *c)
                        c->io_alloc = 1;
                        sb->current_io_size = 1 + res->end - res->start;
                        sb->current_mem_base = res->start;
-                       osm_info("%s: allocated %ld bytes of PCI I/O at 0x%08lX"
-                                ".\n", c->name, 1 + res->end - res->start,
-                                res->start);
+                       osm_info("%s: allocated %llu bytes of PCI I/O at "
+                               "0x%016llX.\n", c->name,
+                               (unsigned long long)(1 + res->end - res->start),
+                               (unsigned long long)res->start);
                }
        }
 
index da8e4d7339cc42f6d2cc7c58106e6bf9604ffe40..8576a65ca1c3383fbdf2c74ff895fbc8b75e7ba7 100644 (file)
@@ -546,9 +546,9 @@ static int mmci_probe(struct amba_device *dev, void *id)
 
        mmc_add_host(mmc);
 
-       printk(KERN_INFO "%s: MMCI rev %x cfg %02x at 0x%08lx irq %d,%d\n",
+       printk(KERN_INFO "%s: MMCI rev %x cfg %02x at 0x%016llx irq %d,%d\n",
                mmc_hostname(mmc), amba_rev(dev), amba_config(dev),
-               dev->res.start, dev->irq[0], dev->irq[1]);
+               (unsigned long long)dev->res.start, dev->irq[0], dev->irq[1]);
 
        init_timer(&host->timer);
        host->timer.data = (unsigned long)host;
index f620d74f10042449ae077f632eaeacb423717f13..30f07b473ae2ad55b026c4f2ea23d30520c03957 100644 (file)
@@ -551,11 +551,11 @@ static u32 fixup_pmc551 (struct pci_dev *dev)
         /*
          * Some screen fun
          */
-        printk(KERN_DEBUG "pmc551: %d%c (0x%x) of %sprefetchable memory at 0x%lx\n",
+        printk(KERN_DEBUG "pmc551: %d%c (0x%x) of %sprefetchable memory at 0x%llx\n",
               (size<1024)?size:(size<1048576)?size>>10:size>>20,
                (size<1024)?'B':(size<1048576)?'K':'M',
               size, ((dcmd&(0x1<<3)) == 0)?"non-":"",
-               (dev->resource[0].start)&PCI_BASE_ADDRESS_MEM_MASK );
+               (unsigned long long)((dev->resource[0].start)&PCI_BASE_ADDRESS_MEM_MASK));
 
         /*
          * Check to see the state of the memory
@@ -685,8 +685,8 @@ static int __init init_pmc551(void)
                         break;
                 }
 
-                printk(KERN_NOTICE "pmc551: Found PCI V370PDC at 0x%lX\n",
-                                   PCI_Device->resource[0].start);
+                printk(KERN_NOTICE "pmc551: Found PCI V370PDC at 0x%llx\n",
+                                   (unsigned long long)PCI_Device->resource[0].start);
 
                 /*
                  * The PMC551 device acts VERY weird if you don't init it
index c350878d4592978ffece3fe1b1e97cb4caae5187..a505870052635b6acc253b42c565e41099cc7ec6 100644 (file)
@@ -123,9 +123,10 @@ static int __devinit amd76xrom_init_one (struct pci_dev *pdev,
                window->rsrc.parent = NULL;
                printk(KERN_ERR MOD_NAME
                        " %s(): Unable to register resource"
-                       " 0x%.08lx-0x%.08lx - kernel bug?\n",
+                       " 0x%.16llx-0x%.16llx - kernel bug?\n",
                        __func__,
-                       window->rsrc.start, window->rsrc.end);
+                       (unsigned long long)window->rsrc.start,
+                       (unsigned long long)window->rsrc.end);
        }
 
 #if 0
index ea5073781b3a38265053e2710606d5ef26464854..16732794edf31b8ebb522528f3bb330a97f7ea22 100644 (file)
@@ -177,9 +177,10 @@ static int __devinit ichxrom_init_one (struct pci_dev *pdev,
                window->rsrc.parent = NULL;
                printk(KERN_DEBUG MOD_NAME
                        ": %s(): Unable to register resource"
-                       " 0x%.08lx-0x%.08lx - kernel bug?\n",
+                       " 0x%.16llx-0x%.16llx - kernel bug?\n",
                        __func__,
-                       window->rsrc.start, window->rsrc.end);
+                       (unsigned long long)window->rsrc.start,
+                       (unsigned long long)window->rsrc.end);
        }
 
        /* Map the firmware hub into my address space. */
index 28b8a571a91a4ff60f133b5de4ed127684d5d78c..331a15859d710df20354f143e5f34a98ae17e22e 100644 (file)
@@ -164,8 +164,9 @@ static int __init init_scx200_docflash(void)
                outl(pmr, scx200_cb_base + SCx200_PMR);
        }
 
-               printk(KERN_INFO NAME ": DOCCS mapped at 0x%lx-0x%lx, width %d\n",
-              docmem.start, docmem.end, width);
+               printk(KERN_INFO NAME ": DOCCS mapped at 0x%llx-0x%llx, width %d\n",
+                       (unsigned long long)docmem.start,
+                       (unsigned long long)docmem.end, width);
 
        scx200_docflash_map.size = size;
        if (width == 8)
index 24a03152d196fc494cc0605827fbd66347699401..4db2055cee31ef9e68967e9d56a3e4c7d4b731c6 100644 (file)
@@ -62,9 +62,10 @@ int uflash_devinit(struct linux_ebus_device *edev, struct device_node *dp)
                /* Non-CFI userflash device-- once I find one we
                 * can work on supporting it.
                 */
-               printk("%s: unsupported device at 0x%lx (%d regs): " \
+               printk("%s: unsupported device at 0x%llx (%d regs): " \
                        "email ebrower@usa.net\n",
-                      dp->full_name, res->start, edev->num_addrs);
+                      dp->full_name, (unsigned long long)res->start,
+                      edev->num_addrs);
 
                return -ENODEV;
        }
index b467c383ae60d82f450dedd5487871f16f7de89d..d2f808979a2b5a9a598f45310f6fdd9ef5905b95 100644 (file)
@@ -1407,8 +1407,10 @@ static int __devinit vortex_probe1(struct device *gendev,
                }
 
                if (print_info) {
-                       printk(KERN_INFO "%s: CardBus functions mapped %8.8lx->%p\n",
-                               print_name, pci_resource_start(pdev, 2),
+                       printk(KERN_INFO "%s: CardBus functions mapped "
+                               "%16.16llx->%p\n",
+                               print_name,
+                               (unsigned long long)pci_resource_start(pdev, 2),
                                vp->cb_fn_base);
                }
                EL3WINDOW(2);
index 0cdc830449d8e58e29b772fa3cbe5f4bf8da2cb0..d26dd6a7062dcd2e72cb05a973fe1e78962fb7b4 100644 (file)
@@ -1823,7 +1823,7 @@ static int cp_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
        struct cp_private *cp;
        int rc;
        void __iomem *regs;
-       long pciaddr;
+       resource_size_t pciaddr;
        unsigned int addr_len, i, pci_using_dac;
        u8 pci_rev;
 
@@ -1883,8 +1883,8 @@ static int cp_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
        }
        if (pci_resource_len(pdev, 1) < CP_REGS_SIZE) {
                rc = -EIO;
-               printk(KERN_ERR PFX "MMIO resource (%lx) too small on pci dev %s\n",
-                      pci_resource_len(pdev, 1), pci_name(pdev));
+               printk(KERN_ERR PFX "MMIO resource (%llx) too small on pci dev %s\n",
+                      (unsigned long long)pci_resource_len(pdev, 1), pci_name(pdev));
                goto err_out_res;
        }
 
@@ -1916,8 +1916,9 @@ static int cp_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
        regs = ioremap(pciaddr, CP_REGS_SIZE);
        if (!regs) {
                rc = -EIO;
-               printk(KERN_ERR PFX "Cannot map PCI MMIO (%lx@%lx) on pci dev %s\n",
-                      pci_resource_len(pdev, 1), pciaddr, pci_name(pdev));
+               printk(KERN_ERR PFX "Cannot map PCI MMIO (%llx@%llx) on pci dev %s\n",
+                       (unsigned long long)pci_resource_len(pdev, 1),
+                       (unsigned long long)pciaddr, pci_name(pdev));
                goto err_out_res;
        }
        dev->base_addr = (unsigned long) regs;
index abd6261465f16e2692c45033ab81e3263dc6716e..ed2e3c03bc880678307b42a73b4fa61b005655c9 100644 (file)
@@ -1341,9 +1341,9 @@ static int rtl8139_open (struct net_device *dev)
        netif_start_queue (dev);
 
        if (netif_msg_ifup(tp))
-               printk(KERN_DEBUG "%s: rtl8139_open() ioaddr %#lx IRQ %d"
-                       " GP Pins %2.2x %s-duplex.\n",
-                       dev->name, pci_resource_start (tp->pci_dev, 1),
+               printk(KERN_DEBUG "%s: rtl8139_open() ioaddr %#llx IRQ %d"
+                       " GP Pins %2.2x %s-duplex.\n", dev->name,
+                       (unsigned long long)pci_resource_start (tp->pci_dev, 1),
                        dev->irq, RTL_R8 (MediaStatus),
                        tp->mii.full_duplex ? "full" : "half");
 
index f37170cc1a377fb3b05a17622c28c27f048fe043..93a286570923c523e118022a8024ddec68755843 100644 (file)
@@ -2678,9 +2678,9 @@ static int __devinit e100_probe(struct pci_dev *pdev,
                goto err_out_free;
        }
 
-       DPRINTK(PROBE, INFO, "addr 0x%lx, irq %d, "
+       DPRINTK(PROBE, INFO, "addr 0x%llx, irq %d, "
                "MAC addr %02X:%02X:%02X:%02X:%02X:%02X\n",
-               pci_resource_start(pdev, 0), pdev->irq,
+               (unsigned long long)pci_resource_start(pdev, 0), pdev->irq,
                netdev->dev_addr[0], netdev->dev_addr[1], netdev->dev_addr[2],
                netdev->dev_addr[3], netdev->dev_addr[4], netdev->dev_addr[5]);
 
index 19a4a16055dc2435e13a0103d90663dde5485ac4..1608efab4e3de39c914dfb964dfbd767a2ccea4b 100644 (file)
@@ -3354,8 +3354,8 @@ static int __devinit skge_probe(struct pci_dev *pdev,
        if (err)
                goto err_out_free_irq;
 
-       printk(KERN_INFO PFX DRV_VERSION " addr 0x%lx irq %d chip %s rev %d\n",
-              pci_resource_start(pdev, 0), pdev->irq,
+       printk(KERN_INFO PFX DRV_VERSION " addr 0x%llx irq %d chip %s rev %d\n",
+              (unsigned long long)pci_resource_start(pdev, 0), pdev->irq,
               skge_board_name(hw), hw->chip_rev);
 
        if ((dev = skge_devinit(hw, 0, using_dac)) == NULL)
index d3577871be28ddc3897d835a59f5f83fbc6b3c0f..e122007e16da08b599d5644a503f34b2f359758f 100644 (file)
@@ -3311,9 +3311,9 @@ static int __devinit sky2_probe(struct pci_dev *pdev,
        if (err)
                goto err_out_iounmap;
 
-       printk(KERN_INFO PFX "v%s addr 0x%lx irq %d Yukon-%s (0x%x) rev %d\n",
-              DRV_VERSION, pci_resource_start(pdev, 0), pdev->irq,
-              yukon2_name[hw->chip_id - CHIP_ID_YUKON_XL],
+       printk(KERN_INFO PFX "v%s addr 0x%llx irq %d Yukon-%s (0x%x) rev %d\n",
+              DRV_VERSION, (unsigned long long)pci_resource_start(pdev, 0),
+              pdev->irq, yukon2_name[hw->chip_id - CHIP_ID_YUKON_XL],
               hw->chip_id, hw->chip_rev);
 
        dev = sky2_init_netdev(hw, 0, using_dac);
index 5f743b972949930929335ed20fb55288d47b1dd1..fc2468ecce0b1db743e8158d07468c15f1eca80c 100644 (file)
@@ -2007,8 +2007,8 @@ static int __init de_init_one (struct pci_dev *pdev,
        }
        if (pci_resource_len(pdev, 1) < DE_REGS_SIZE) {
                rc = -EIO;
-               printk(KERN_ERR PFX "MMIO resource (%lx) too small on pci dev %s\n",
-                      pci_resource_len(pdev, 1), pci_name(pdev));
+               printk(KERN_ERR PFX "MMIO resource (%llx) too small on pci dev %s\n",
+                      (unsigned long long)pci_resource_len(pdev, 1), pci_name(pdev));
                goto err_out_res;
        }
 
@@ -2016,8 +2016,9 @@ static int __init de_init_one (struct pci_dev *pdev,
        regs = ioremap_nocache(pciaddr, DE_REGS_SIZE);
        if (!regs) {
                rc = -EIO;
-               printk(KERN_ERR PFX "Cannot map PCI MMIO (%lx@%lx) on pci dev %s\n",
-                      pci_resource_len(pdev, 1), pciaddr, pci_name(pdev));
+               printk(KERN_ERR PFX "Cannot map PCI MMIO (%llx@%lx) on pci dev %s\n",
+                       (unsigned long long)pci_resource_len(pdev, 1),
+                       pciaddr, pci_name(pdev));
                goto err_out_res;
        }
        dev->base_addr = (unsigned long) regs;
index e0de66739a422744616ae3205e89db5504f2036c..53fd9b56d0bd7967b51cbf794128c1c15918979b 100644 (file)
@@ -1350,10 +1350,10 @@ static int __devinit tulip_init_one (struct pci_dev *pdev,
        SET_MODULE_OWNER(dev);
        SET_NETDEV_DEV(dev, &pdev->dev);
        if (pci_resource_len (pdev, 0) < tulip_tbl[chip_idx].io_size) {
-               printk (KERN_ERR PFX "%s: I/O region (0x%lx@0x%lx) too small, "
+               printk (KERN_ERR PFX "%s: I/O region (0x%llx@0x%llx) too small, "
                        "aborting\n", pci_name(pdev),
-                       pci_resource_len (pdev, 0),
-                       pci_resource_start (pdev, 0));
+                       (unsigned long long)pci_resource_len (pdev, 0),
+                       (unsigned long long)pci_resource_start (pdev, 0));
                goto err_out_free_netdev;
        }
 
index e49e8b520c28120f9aaa346d80b310a5b6e2814b..e24d2dafcf6c3695662c4ea3cdb8ece7cd672e38 100644 (file)
@@ -2568,9 +2568,10 @@ typhoon_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
 
        pci_set_drvdata(pdev, dev);
 
-       printk(KERN_INFO "%s: %s at %s 0x%lx, ",
+       printk(KERN_INFO "%s: %s at %s 0x%llx, ",
               dev->name, typhoon_card_info[card_id].name,
-              use_mmio ? "MMIO" : "IO", pci_resource_start(pdev, use_mmio));
+              use_mmio ? "MMIO" : "IO",
+              (unsigned long long)pci_resource_start(pdev, use_mmio));
        for(i = 0; i < 5; i++)
                printk("%2.2x:", dev->dev_addr[i]);
        printk("%2.2x\n", dev->dev_addr[i]);
index 4505540e3c591611182645433ac5dbc353e07a2a..04a376ec0ed84ab737c373342914ed172a4b1129 100644 (file)
@@ -732,15 +732,15 @@ static int __devinit dscc4_init_one(struct pci_dev *pdev,
        ioaddr = ioremap(pci_resource_start(pdev, 0),
                                        pci_resource_len(pdev, 0));
        if (!ioaddr) {
-               printk(KERN_ERR "%s: cannot remap MMIO region %lx @ %lx\n",
-                       DRV_NAME, pci_resource_len(pdev, 0),
-                       pci_resource_start(pdev, 0));
+               printk(KERN_ERR "%s: cannot remap MMIO region %llx @ %llx\n",
+                       DRV_NAME, (unsigned long long)pci_resource_len(pdev, 0),
+                       (unsigned long long)pci_resource_start(pdev, 0));
                rc = -EIO;
                goto err_free_mmio_regions_2;
        }
-       printk(KERN_DEBUG "Siemens DSCC4, MMIO at %#lx (regs), %#lx (lbi), IRQ %d\n",
-               pci_resource_start(pdev, 0),
-               pci_resource_start(pdev, 1), pdev->irq);
+       printk(KERN_DEBUG "Siemens DSCC4, MMIO at %#llx (regs), %#llx (lbi), IRQ %d\n",
+               (unsigned long long)pci_resource_start(pdev, 0),
+               (unsigned long long)pci_resource_start(pdev, 1), pdev->irq);
 
        /* Cf errata DS5 p.2 */
        pci_write_config_byte(pdev, PCI_LATENCY_TIMER, 0xf8);
index a3e65d1bc19bbcddda71bd74f2ec707a6a0bf5f1..d7897ae89f904dc906250c67cdde073f2243e7ed 100644 (file)
@@ -3445,9 +3445,9 @@ cpc_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
 
        card = (pc300_t *) kmalloc(sizeof(pc300_t), GFP_KERNEL);
        if (card == NULL) {
-               printk("PC300 found at RAM 0x%08lx, "
+               printk("PC300 found at RAM 0x%016llx, "
                       "but could not allocate card structure.\n",
-                      pci_resource_start(pdev, 3));
+                      (unsigned long long)pci_resource_start(pdev, 3));
                err = -ENOMEM;
                goto err_disable_dev;
        }
index 6e8ed0c81a6cbd5883fafa74b940e77077d9cee7..ce0a6ebcff15dfa74a4ff8e8812878078a8e46a9 100644 (file)
@@ -299,7 +299,7 @@ struct pci_port_ops dino_port_ops = {
 
 static void dino_disable_irq(unsigned int irq)
 {
-       struct dino_device *dino_dev = irq_desc[irq].handler_data;
+       struct dino_device *dino_dev = irq_desc[irq].chip_data;
        int local_irq = gsc_find_local_irq(irq, dino_dev->global_irq, DINO_LOCAL_IRQS);
 
        DBG(KERN_WARNING "%s(0x%p, %d)\n", __FUNCTION__, dino_dev, irq);
@@ -311,7 +311,7 @@ static void dino_disable_irq(unsigned int irq)
 
 static void dino_enable_irq(unsigned int irq)
 {
-       struct dino_device *dino_dev = irq_desc[irq].handler_data;
+       struct dino_device *dino_dev = irq_desc[irq].chip_data;
        int local_irq = gsc_find_local_irq(irq, dino_dev->global_irq, DINO_LOCAL_IRQS);
        u32 tmp;
 
index 9d3bd15bf53be98c071b2c7d7585ba689974b6f9..58f0ce8d78e066c2f75fb63371924db5f41f549f 100644 (file)
@@ -350,7 +350,7 @@ static int __devinit eisa_probe(struct parisc_device *dev)
        irq_desc[2].action = &irq2_action;
        
        for (i = 0; i < 16; i++) {
-               irq_desc[i].handler = &eisa_interrupt_type;
+               irq_desc[i].chip = &eisa_interrupt_type;
        }
        
        EISA_bus = 1;
index 16d40f95978d135d8cf310efff612094c1e6d451..5476ba7709b3cc4a9a7aec1612d74be7898a0f83 100644 (file)
@@ -109,7 +109,7 @@ int gsc_find_local_irq(unsigned int irq, int *global_irqs, int limit)
 
 static void gsc_asic_disable_irq(unsigned int irq)
 {
-       struct gsc_asic *irq_dev = irq_desc[irq].handler_data;
+       struct gsc_asic *irq_dev = irq_desc[irq].chip_data;
        int local_irq = gsc_find_local_irq(irq, irq_dev->global_irq, 32);
        u32 imr;
 
@@ -124,7 +124,7 @@ static void gsc_asic_disable_irq(unsigned int irq)
 
 static void gsc_asic_enable_irq(unsigned int irq)
 {
-       struct gsc_asic *irq_dev = irq_desc[irq].handler_data;
+       struct gsc_asic *irq_dev = irq_desc[irq].chip_data;
        int local_irq = gsc_find_local_irq(irq, irq_dev->global_irq, 32);
        u32 imr;
 
@@ -164,8 +164,8 @@ int gsc_assign_irq(struct hw_interrupt_type *type, void *data)
        if (irq > GSC_IRQ_MAX)
                return NO_IRQ;
 
-       irq_desc[irq].handler = type;
-       irq_desc[irq].handler_data = data;
+       irq_desc[irq].chip = type;
+       irq_desc[irq].chip_data = data;
        return irq++;
 }
 
index 7a458d5bc75134d925aa272b34af805f1646384e..1fbda77cefc29bfb0bbe820314feabce0d2c9700 100644 (file)
@@ -619,7 +619,7 @@ iosapic_set_irt_data( struct vector_info *vi, u32 *dp0, u32 *dp1)
 
 static struct vector_info *iosapic_get_vector(unsigned int irq)
 {
-       return irq_desc[irq].handler_data;
+       return irq_desc[irq].chip_data;
 }
 
 static void iosapic_disable_irq(unsigned int irq)
index 828eb45062de3fa51182d1c61660961307fc0b11..a988dc7a9abd33a4c7f579bcf15e7a3aab003dfe 100644 (file)
@@ -360,7 +360,7 @@ int superio_fixup_irq(struct pci_dev *pcidev)
 #endif
 
        for (i = 0; i < 16; i++) {
-               irq_desc[i].handler = &superio_interrupt_type;
+               irq_desc[i].chip = &superio_interrupt_type;
        }
 
        /*
index 7230926820234f3c676d50397abcdf41be4a7b52..5f7db9d2436e76141e15d50a44e9f1fc38e54378 100644 (file)
  */
 int
 pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res,
-       unsigned long size, unsigned long align, unsigned long min,
-       unsigned int type_mask,
-       void (*alignf)(void *, struct resource *,
-                       unsigned long, unsigned long),
-       void *alignf_data)
+               resource_size_t size, resource_size_t align,
+               resource_size_t min, unsigned int type_mask,
+               void (*alignf)(void *, struct resource *, resource_size_t,
+                               resource_size_t),
+               void *alignf_data)
 {
        int i, ret = -ENOMEM;
 
index f7cb00da38dfabbfd32e6c6ec366bf261f9ed7e4..1ec165df85223e4495ebb310b2702b70a1e14fd6 100644 (file)
@@ -95,8 +95,8 @@ static int zt5550_hc_config(struct pci_dev *pdev)
 
        hc_dev = pdev;
        dbg("hc_dev = %p", hc_dev);
-       dbg("pci resource start %lx", pci_resource_start(hc_dev, 1));
-       dbg("pci resource len %lx", pci_resource_len(hc_dev, 1));
+       dbg("pci resource start %llx", (unsigned long long)pci_resource_start(hc_dev, 1));
+       dbg("pci resource len %llx", (unsigned long long)pci_resource_len(hc_dev, 1));
 
        if(!request_mem_region(pci_resource_start(hc_dev, 1),
                                pci_resource_len(hc_dev, 1), MY_NAME)) {
@@ -108,8 +108,9 @@ static int zt5550_hc_config(struct pci_dev *pdev)
        hc_registers =
            ioremap(pci_resource_start(hc_dev, 1), pci_resource_len(hc_dev, 1));
        if(!hc_registers) {
-               err("cannot remap MMIO region %lx @ %lx",
-                   pci_resource_len(hc_dev, 1), pci_resource_start(hc_dev, 1));
+               err("cannot remap MMIO region %llx @ %llx",
+                       (unsigned long long)pci_resource_len(hc_dev, 1),
+                       (unsigned long long)pci_resource_start(hc_dev, 1));
                ret = -ENODEV;
                goto exit_release_region;
        }
index 9bc1deb8df524225decdc7a5322d72ce2638f7bc..f8658d63f0773ca7022505bbe0aef995e4aaca12 100644 (file)
@@ -1089,8 +1089,8 @@ static int cpqhpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
        }
        
        dbg("pdev = %p\n", pdev);
-       dbg("pci resource start %lx\n", pci_resource_start(pdev, 0));
-       dbg("pci resource len %lx\n", pci_resource_len(pdev, 0));
+       dbg("pci resource start %llx\n", (unsigned long long)pci_resource_start(pdev, 0));
+       dbg("pci resource len %llx\n", (unsigned long long)pci_resource_len(pdev, 0));
 
        if (!request_mem_region(pci_resource_start(pdev, 0),
                                pci_resource_len(pdev, 0), MY_NAME)) {
@@ -1102,9 +1102,9 @@ static int cpqhpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
        ctrl->hpc_reg = ioremap(pci_resource_start(pdev, 0),
                                        pci_resource_len(pdev, 0));
        if (!ctrl->hpc_reg) {
-               err("cannot remap MMIO region %lx @ %lx\n",
-                               pci_resource_len(pdev, 0),
-                               pci_resource_start(pdev, 0));
+               err("cannot remap MMIO region %llx @ %llx\n",
+                   (unsigned long long)pci_resource_len(pdev, 0),
+                   (unsigned long long)pci_resource_start(pdev, 0));
                rc = -ENODEV;
                goto err_free_mem_region;
        }
index d77138ecb0981ec827a6d482d96f31eb6c5acc43..11f7858f0064f7a6ef992e7de171468e53806208 100644 (file)
@@ -1398,8 +1398,9 @@ int pcie_init(struct controller * ctrl, struct pcie_device *dev)
 
        for ( rc = 0; rc < DEVICE_COUNT_RESOURCE; rc++)
                if (pci_resource_len(pdev, rc) > 0)
-                       dbg("pci resource[%d] start=0x%lx(len=0x%lx)\n", rc,
-                               pci_resource_start(pdev, rc), pci_resource_len(pdev, rc));
+                       dbg("pci resource[%d] start=0x%llx(len=0x%llx)\n", rc,
+                           (unsigned long long)pci_resource_start(pdev, rc),
+                           (unsigned long long)pci_resource_len(pdev, rc));
 
        info("HPC vendor_id %x device_id %x ss_vid %x ss_did %x\n", pdev->vendor, pdev->device, 
                pdev->subsystem_vendor, pdev->subsystem_device);
index f5cfbf2c047c92796c7bdde79d4dbc33c977c6a8..620e1139e607c763dfaa69ff25413c971de82310 100644 (file)
@@ -51,8 +51,10 @@ static ssize_t show_ctrl (struct device *dev, struct device_attribute *attr, cha
                res = bus->resource[index];
                if (res && (res->flags & IORESOURCE_MEM) &&
                                !(res->flags & IORESOURCE_PREFETCH)) {
-                       out += sprintf(out, "start = %8.8lx, length = %8.8lx\n",
-                                       res->start, (res->end - res->start));
+                       out += sprintf(out, "start = %8.8llx, "
+                                       "length = %8.8llx\n",
+                                       (unsigned long long)res->start,
+                                       (unsigned long long)(res->end - res->start));
                }
        }
        out += sprintf(out, "Free resources: prefetchable memory\n");
@@ -60,16 +62,20 @@ static ssize_t show_ctrl (struct device *dev, struct device_attribute *attr, cha
                res = bus->resource[index];
                if (res && (res->flags & IORESOURCE_MEM) &&
                               (res->flags & IORESOURCE_PREFETCH)) {
-                       out += sprintf(out, "start = %8.8lx, length = %8.8lx\n",
-                                       res->start, (res->end - res->start));
+                       out += sprintf(out, "start = %8.8llx, "
+                                       "length = %8.8llx\n",
+                                       (unsigned long long)res->start,
+                                       (unsigned long long)(res->end - res->start));
                }
        }
        out += sprintf(out, "Free resources: IO\n");
        for (index = 0; index < PCI_BUS_NUM_RESOURCES; index++) {
                res = bus->resource[index];
                if (res && (res->flags & IORESOURCE_IO)) {
-                       out += sprintf(out, "start = %8.8lx, length = %8.8lx\n",
-                                       res->start, (res->end - res->start));
+                       out += sprintf(out, "start = %8.8llx, "
+                                       "length = %8.8llx\n",
+                                       (unsigned long long)res->start,
+                                       (unsigned long long)(res->end - res->start));
                }
        }
        out += sprintf(out, "Free resources: bus numbers\n");
index 7f8429284fabe0663e4c6dc30fc6deefeaa178e3..76d023d8a33b92c7f940c05815434061f47a6adb 100644 (file)
@@ -429,12 +429,12 @@ static void irq_handler_init(int cap_id, int pos, int mask)
 
        spin_lock_irqsave(&irq_desc[pos].lock, flags);
        if (cap_id == PCI_CAP_ID_MSIX)
-               irq_desc[pos].handler = &msix_irq_type;
+               irq_desc[pos].chip = &msix_irq_type;
        else {
                if (!mask)
-                       irq_desc[pos].handler = &msi_irq_wo_maskbit_type;
+                       irq_desc[pos].chip = &msi_irq_wo_maskbit_type;
                else
-                       irq_desc[pos].handler = &msi_irq_w_maskbit_type;
+                       irq_desc[pos].chip = &msi_irq_w_maskbit_type;
        }
        spin_unlock_irqrestore(&irq_desc[pos].lock, flags);
 }
index bc405c035ce34b4ae00d54a61286782e31416125..606f9b6f70ebe220617aa437982c4f5287046d40 100644 (file)
@@ -87,7 +87,7 @@ resource_show(struct device * dev, struct device_attribute *attr, char * buf)
        char * str = buf;
        int i;
        int max = 7;
-       u64 start, end;
+       resource_size_t start, end;
 
        if (pci_dev->subordinate)
                max = DEVICE_COUNT_RESOURCE;
@@ -365,7 +365,7 @@ pci_mmap_resource(struct kobject *kobj, struct bin_attribute *attr,
                                                       struct device, kobj));
        struct resource *res = (struct resource *)attr->private;
        enum pci_mmap_state mmap_type;
-       u64 start, end;
+       resource_size_t start, end;
        int i;
 
        for (i = 0; i < PCI_ROM_RESOURCE; i++)
index 23d3b17c8cad2cacacb32bd042aefa2c532eb848..cf57d7de3765fcceb37216501c0ace480cc95fa2 100644 (file)
@@ -691,10 +691,12 @@ int pci_request_region(struct pci_dev *pdev, int bar, const char *res_name)
        return 0;
 
 err_out:
-       printk (KERN_WARNING "PCI: Unable to reserve %s region #%d:%lx@%lx for device %s\n",
+       printk (KERN_WARNING "PCI: Unable to reserve %s region #%d:%llx@%llx "
+               "for device %s\n",
                pci_resource_flags(pdev, bar) & IORESOURCE_IO ? "I/O" : "mem",
                bar + 1, /* PCI BAR # */
-               pci_resource_len(pdev, bar), pci_resource_start(pdev, bar),
+               (unsigned long long)pci_resource_len(pdev, bar),
+               (unsigned long long)pci_resource_start(pdev, bar),
                pci_name(pdev));
        return -EBUSY;
 }
index 29bdeca031a8b49c60c7de124eabc68022c3c3b2..9cc842b666eb1d1d43fc24f9b06b2a3dd3a2f491 100644 (file)
@@ -6,10 +6,10 @@ extern int pci_create_sysfs_dev_files(struct pci_dev *pdev);
 extern void pci_remove_sysfs_dev_files(struct pci_dev *pdev);
 extern void pci_cleanup_rom(struct pci_dev *dev);
 extern int pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res,
-                                 unsigned long size, unsigned long align,
-                                 unsigned long min, unsigned int type_mask,
+                                 resource_size_t size, resource_size_t align,
+                                 resource_size_t min, unsigned int type_mask,
                                  void (*alignf)(void *, struct resource *,
-                                                unsigned long, unsigned long),
+                                             resource_size_t, resource_size_t),
                                  void *alignf_data);
 /* Firmware callbacks */
 extern int (*platform_pci_choose_state)(struct pci_dev *dev, pm_message_t state);
index 54b2ebc9c91a4b4e18dead4f363b0c9c5150d2a5..99cf33379769310619557605b72c390bc913b39f 100644 (file)
@@ -302,12 +302,6 @@ static struct file_operations proc_bus_pci_operations = {
 #endif /* HAVE_PCI_MMAP */
 };
 
-#if BITS_PER_LONG == 32
-#define LONG_FORMAT "\t%08lx"
-#else
-#define LONG_FORMAT "\t%16lx"
-#endif
-
 /* iterator */
 static void *pci_seq_start(struct seq_file *m, loff_t *pos)
 {
@@ -356,18 +350,18 @@ static int show_device(struct seq_file *m, void *v)
                        dev->irq);
        /* Here should be 7 and not PCI_NUM_RESOURCES as we need to preserve compatibility */
        for (i=0; i<7; i++) {
-               u64 start, end;
+               resource_size_t start, end;
                pci_resource_to_user(dev, i, &dev->resource[i], &start, &end);
-               seq_printf(m, LONG_FORMAT,
-                       ((unsigned long)start) |
-                       (dev->resource[i].flags & PCI_REGION_FLAG_MASK));
+               seq_printf(m, "\t%16llx",
+                       (unsigned long long)(start |
+                       (dev->resource[i].flags & PCI_REGION_FLAG_MASK)));
        }
        for (i=0; i<7; i++) {
-               u64 start, end;
+               resource_size_t start, end;
                pci_resource_to_user(dev, i, &dev->resource[i], &start, &end);
-               seq_printf(m, LONG_FORMAT,
+               seq_printf(m, "\t%16llx",
                        dev->resource[i].start < dev->resource[i].end ?
-                       (unsigned long)(end - start) + 1 : 0);
+                       (unsigned long long)(end - start) + 1 : 0);
        }
        seq_putc(m, '\t');
        if (drv)
index 598a115cd00e762abb868b76e16447fa11faa0a3..cbb69cf41311a947f96fd3231f1d00b070d98082 100644 (file)
@@ -80,8 +80,8 @@ void __iomem *pci_map_rom(struct pci_dev *pdev, size_t *size)
        } else {
                if (res->flags & IORESOURCE_ROM_COPY) {
                        *size = pci_resource_len(pdev, PCI_ROM_RESOURCE);
-                       return (void __iomem *)pci_resource_start(pdev,
-                                                            PCI_ROM_RESOURCE);
+                       return (void __iomem *)(unsigned long)
+                               pci_resource_start(pdev, PCI_ROM_RESOURCE);
                } else {
                        /* assign the ROM an address if it doesn't have one */
                        if (res->parent == NULL &&
@@ -170,11 +170,11 @@ void __iomem *pci_map_rom_copy(struct pci_dev *pdev, size_t *size)
                return rom;
 
        res->end = res->start + *size;
-       memcpy_fromio((void*)res->start, rom, *size);
+       memcpy_fromio((void*)(unsigned long)res->start, rom, *size);
        pci_unmap_rom(pdev, rom);
        res->flags |= IORESOURCE_ROM_COPY;
 
-       return (void __iomem *)res->start;
+       return (void __iomem *)(unsigned long)res->start;
 }
 
 /**
@@ -227,7 +227,7 @@ void pci_cleanup_rom(struct pci_dev *pdev)
 {
        struct resource *res = &pdev->resource[PCI_ROM_RESOURCE];
        if (res->flags & IORESOURCE_ROM_COPY) {
-               kfree((void*)res->start);
+               kfree((void*)(unsigned long)res->start);
                res->flags &= ~IORESOURCE_ROM_COPY;
                res->start = 0;
                res->end = 0;
index 35086e80faa91a9db5ea225b5166d29f1b88e1b4..47c1071ad84ea06b057faac42e6ea60aeb87c5fe 100644 (file)
@@ -357,8 +357,10 @@ pbus_size_mem(struct pci_bus *bus, unsigned long mask, unsigned long type)
                        order = __ffs(align) - 20;
                        if (order > 11) {
                                printk(KERN_WARNING "PCI: region %s/%d "
-                                      "too large: %lx-%lx\n",
-                                      pci_name(dev), i, r->start, r->end);
+                                      "too large: %llx-%llx\n",
+                                       pci_name(dev), i,
+                                       (unsigned long long)r->start,
+                                       (unsigned long long)r->end);
                                r->flags = 0;
                                continue;
                        }
index 577f4b55c46d6e37f52b5f67654ac94ecf73b0ab..ab78e4bbdd83044bc6bb6a3f32e4d7ea3834bf52 100644 (file)
@@ -40,8 +40,9 @@ pci_update_resource(struct pci_dev *dev, struct resource *res, int resno)
 
        pcibios_resource_to_bus(dev, &region, res);
 
-       pr_debug("  got res [%lx:%lx] bus [%lx:%lx] flags %lx for "
-                "BAR %d of %s\n", res->start, res->end,
+       pr_debug("  got res [%llx:%llx] bus [%lx:%lx] flags %lx for "
+                "BAR %d of %s\n", (unsigned long long)res->start,
+                (unsigned long long)res->end,
                 region.start, region.end, res->flags, resno, pci_name(dev));
 
        new = region.start | (res->flags & PCI_REGION_FLAG_MASK);
@@ -104,10 +105,12 @@ pci_claim_resource(struct pci_dev *dev, int resource)
                err = insert_resource(root, res);
 
        if (err) {
-               printk(KERN_ERR "PCI: %s region %d of %s %s [%lx:%lx]\n",
-                      root ? "Address space collision on" :
-                             "No parent found for",
-                      resource, dtype, pci_name(dev), res->start, res->end);
+               printk(KERN_ERR "PCI: %s region %d of %s %s [%llx:%llx]\n",
+                       root ? "Address space collision on" :
+                               "No parent found for",
+                       resource, dtype, pci_name(dev),
+                       (unsigned long long)res->start,
+                       (unsigned long long)res->end);
        }
 
        return err;
@@ -118,7 +121,7 @@ int pci_assign_resource(struct pci_dev *dev, int resno)
 {
        struct pci_bus *bus = dev->bus;
        struct resource *res = dev->resource + resno;
-       unsigned long size, min, align;
+       resource_size_t size, min, align;
        int ret;
 
        size = res->end - res->start + 1;
@@ -145,9 +148,11 @@ int pci_assign_resource(struct pci_dev *dev, int resno)
        }
 
        if (ret) {
-               printk(KERN_ERR "PCI: Failed to allocate %s resource #%d:%lx@%lx for %s\n",
-                      res->flags & IORESOURCE_IO ? "I/O" : "mem",
-                      resno, size, res->start, pci_name(dev));
+               printk(KERN_ERR "PCI: Failed to allocate %s resource "
+                       "#%d:%llx@%llx for %s\n",
+                       res->flags & IORESOURCE_IO ? "I/O" : "mem",
+                       resno, (unsigned long long)size,
+                       (unsigned long long)res->start, pci_name(dev));
        } else if (resno < PCI_BRIDGE_RESOURCES) {
                pci_update_resource(dev, res, resno);
        }
@@ -204,7 +209,7 @@ pdev_sort_resources(struct pci_dev *dev, struct resource_list *head)
        for (i = 0; i < PCI_NUM_RESOURCES; i++) {
                struct resource *r;
                struct resource_list *list, *tmp;
-               unsigned long r_align;
+               resource_size_t r_align;
 
                r = &dev->resource[i];
                r_align = r->end - r->start;
@@ -213,13 +218,14 @@ pdev_sort_resources(struct pci_dev *dev, struct resource_list *head)
                        continue;
                if (!r_align) {
                        printk(KERN_WARNING "PCI: Ignore bogus resource %d "
-                                           "[%lx:%lx] of %s\n",
-                                           i, r->start, r->end, pci_name(dev));
+                               "[%llx:%llx] of %s\n",
+                               i, (unsigned long long)r->start,
+                               (unsigned long long)r->end, pci_name(dev));
                        continue;
                }
                r_align = (i < PCI_BRIDGE_RESOURCES) ? r_align + 1 : r->start;
                for (list = head; ; list = list->next) {
-                       unsigned long align = 0;
+                       resource_size_t align = 0;
                        struct resource_list *ln = list->next;
                        int idx;
 
index b39435bbfaeb2aa3c3f14bbc34499f6a16046313..c662e4f89d46174cf54b2d8af74c8d63b23fcc10 100644 (file)
@@ -244,8 +244,8 @@ static void hs_map_irq(hs_socket_t *sp, unsigned int irq)
 
        hs_mapped_irq[irq].sock = sp;
        /* insert ourselves as the irq controller */
-       hs_mapped_irq[irq].old_handler = irq_desc[irq].handler;
-       irq_desc[irq].handler = &hd64465_ss_irq_type;
+       hs_mapped_irq[irq].old_handler = irq_desc[irq].chip;
+       irq_desc[irq].chip = &hd64465_ss_irq_type;
 }
 
 
@@ -260,7 +260,7 @@ static void hs_unmap_irq(hs_socket_t *sp, unsigned int irq)
            return;
                
        /* restore the original irq controller */
-       irq_desc[irq].handler = hs_mapped_irq[irq].old_handler;
+       irq_desc[irq].chip = hs_mapped_irq[irq].old_handler;
 }
 
 /*============================================================*/
index a2f05f48515654e25d1284a260a6c52a522917f3..ff51a65d9433af984b04ce8cf2fe88812f023796 100644 (file)
@@ -1084,9 +1084,10 @@ static int i365_set_mem_map(u_short sock, struct pccard_mem_map *mem)
     u_short base, i;
     u_char map;
     
-    debug(1, "SetMemMap(%d, %d, %#2.2x, %d ns, %#lx-%#lx, "
+    debug(1, "SetMemMap(%d, %d, %#2.2x, %d ns, %#llx-%#llx, "
          "%#x)\n", sock, mem->map, mem->flags, mem->speed,
-         mem->res->start, mem->res->end, mem->card_start);
+         (unsigned long long)mem->res->start,
+         (unsigned long long)mem->res->end, mem->card_start);
 
     map = mem->map;
     if ((map > 4) || (mem->card_start > 0x3ffffff) ||
index 247ab837f841739f0982c51ecd937692d841f5ef..9ee26c1b863566a0d846e4033a424aa3b8f9f68d 100644 (file)
@@ -642,7 +642,8 @@ static int __devinit pd6729_pci_probe(struct pci_dev *dev,
                goto err_out_free_mem;
 
        printk(KERN_INFO "pd6729: Cirrus PD6729 PCI to PCMCIA Bridge "
-               "at 0x%lx on irq %d\n", pci_resource_start(dev, 0), dev->irq);
+               "at 0x%llx on irq %d\n",
+               (unsigned long long)pci_resource_start(dev, 0), dev->irq);
        /*
         * Since we have no memory BARs some firmware may not
         * have had PCI_COMMAND_MEMORY enabled, yet the device needs it.
index 0f8b157c97177d30c3dc2389a70dd85a211c5b75..c3176b16b7bea5223aba2031251196cd88440533 100644 (file)
@@ -72,7 +72,7 @@ static DEFINE_MUTEX(rsrc_mutex);
 ======================================================================*/
 
 static struct resource *
-make_resource(unsigned long b, unsigned long n, int flags, char *name)
+make_resource(resource_size_t b, resource_size_t n, int flags, char *name)
 {
        struct resource *res = kzalloc(sizeof(*res), GFP_KERNEL);
 
@@ -86,8 +86,8 @@ make_resource(unsigned long b, unsigned long n, int flags, char *name)
 }
 
 static struct resource *
-claim_region(struct pcmcia_socket *s, unsigned long base, unsigned long size,
-            int type, char *name)
+claim_region(struct pcmcia_socket *s, resource_size_t base,
+               resource_size_t size, int type, char *name)
 {
        struct resource *res, *parent;
 
@@ -519,10 +519,10 @@ struct pcmcia_align_data {
 
 static void
 pcmcia_common_align(void *align_data, struct resource *res,
-                   unsigned long size, unsigned long align)
+                       resource_size_t size, resource_size_t align)
 {
        struct pcmcia_align_data *data = align_data;
-       unsigned long start;
+       resource_size_t start;
        /*
         * Ensure that we have the correct start address
         */
@@ -533,8 +533,8 @@ pcmcia_common_align(void *align_data, struct resource *res,
 }
 
 static void
-pcmcia_align(void *align_data, struct resource *res,
-            unsigned long size, unsigned long align)
+pcmcia_align(void *align_data, struct resource *res, resource_size_t size,
+               resource_size_t align)
 {
        struct pcmcia_align_data *data = align_data;
        struct resource_map *m;
@@ -808,8 +808,10 @@ static int nonstatic_autoadd_resources(struct pcmcia_socket *s)
                if (res->flags & IORESOURCE_IO) {
                        if (res == &ioport_resource)
                                continue;
-                       printk(KERN_INFO "pcmcia: parent PCI bridge I/O window: 0x%lx - 0x%lx\n",
-                              res->start, res->end);
+                       printk(KERN_INFO "pcmcia: parent PCI bridge I/O "
+                               "window: 0x%llx - 0x%llx\n",
+                               (unsigned long long)res->start,
+                               (unsigned long long)res->end);
                        if (!adjust_io(s, ADD_MANAGED_RESOURCE, res->start, res->end))
                                done |= IORESOURCE_IO;
 
@@ -818,8 +820,10 @@ static int nonstatic_autoadd_resources(struct pcmcia_socket *s)
                if (res->flags & IORESOURCE_MEM) {
                        if (res == &iomem_resource)
                                continue;
-                       printk(KERN_INFO "pcmcia: parent PCI bridge Memory window: 0x%lx - 0x%lx\n",
-                              res->start, res->end);
+                       printk(KERN_INFO "pcmcia: parent PCI bridge Memory "
+                               "window: 0x%llx - 0x%llx\n",
+                               (unsigned long long)res->start,
+                               (unsigned long long)res->end);
                        if (!adjust_memory(s, ADD_MANAGED_RESOURCE, res->start, res->end))
                                done |= IORESOURCE_MEM;
                }
index 73bad1d5cb23d8660b803f9933a026dd36ad530a..65a60671659f1e1c77861a2235e5d31bbcc1035b 100644 (file)
@@ -756,8 +756,9 @@ static int tcic_set_mem_map(struct pcmcia_socket *sock, struct pccard_mem_map *m
     u_long base, len, mmap;
 
     debug(1, "SetMemMap(%d, %d, %#2.2x, %d ns, "
-         "%#lx-%#lx, %#x)\n", psock, mem->map, mem->flags,
-         mem->speed, mem->res->start, mem->res->end, mem->card_start);
+         "%#llx-%#llx, %#x)\n", psock, mem->map, mem->flags,
+         mem->speed, (unsigned long long)mem->res->start,
+         (unsigned long long)mem->res->end, mem->card_start);
     if ((mem->map > 3) || (mem->card_start > 0x3ffffff) ||
        (mem->res->start > 0xffffff) || (mem->res->end > 0xffffff) ||
        (mem->res->start > mem->res->end) || (mem->speed > 1000))
index a2d8ce7fef9c97bb0149b4e6166e044820119ea2..3163e3d73da13c1d6f58beecd6271a36f1bcb2e1 100644 (file)
@@ -264,7 +264,7 @@ static ssize_t pnp_show_current_resources(struct device *dmdev, struct device_at
                        if (pnp_port_flags(dev, i) & IORESOURCE_DISABLED)
                                pnp_printf(buffer," disabled\n");
                        else
-                               pnp_printf(buffer," 0x%lx-0x%lx\n",
+                               pnp_printf(buffer," 0x%llx-0x%llx\n",
                                                pnp_port_start(dev, i),
                                                pnp_port_end(dev, i));
                }
@@ -275,7 +275,7 @@ static ssize_t pnp_show_current_resources(struct device *dmdev, struct device_at
                        if (pnp_mem_flags(dev, i) & IORESOURCE_DISABLED)
                                pnp_printf(buffer," disabled\n");
                        else
-                               pnp_printf(buffer," 0x%lx-0x%lx\n",
+                               pnp_printf(buffer," 0x%llx-0x%llx\n",
                                                pnp_mem_start(dev, i),
                                                pnp_mem_end(dev, i));
                }
@@ -286,7 +286,7 @@ static ssize_t pnp_show_current_resources(struct device *dmdev, struct device_at
                        if (pnp_irq_flags(dev, i) & IORESOURCE_DISABLED)
                                pnp_printf(buffer," disabled\n");
                        else
-                               pnp_printf(buffer," %ld\n",
+                               pnp_printf(buffer," %lld\n",
                                                pnp_irq(dev, i));
                }
        }
@@ -296,7 +296,7 @@ static ssize_t pnp_show_current_resources(struct device *dmdev, struct device_at
                        if (pnp_dma_flags(dev, i) & IORESOURCE_DISABLED)
                                pnp_printf(buffer," disabled\n");
                        else
-                               pnp_printf(buffer," %ld\n",
+                               pnp_printf(buffer," %lld\n",
                                                pnp_dma(dev, i));
                }
        }
index 6fff109bdab606e98eb188f70a4b4a1dcafe6415..1d7a5b87f4cbc3157e7abbf86d11da638f748eeb 100644 (file)
@@ -20,7 +20,8 @@ DECLARE_MUTEX(pnp_res_mutex);
 
 static int pnp_assign_port(struct pnp_dev *dev, struct pnp_port *rule, int idx)
 {
-       unsigned long *start, *end, *flags;
+       resource_size_t *start, *end;
+       unsigned long *flags;
 
        if (!dev || !rule)
                return -EINVAL;
@@ -63,7 +64,8 @@ static int pnp_assign_port(struct pnp_dev *dev, struct pnp_port *rule, int idx)
 
 static int pnp_assign_mem(struct pnp_dev *dev, struct pnp_mem *rule, int idx)
 {
-       unsigned long *start, *end, *flags;
+       resource_size_t *start, *end;
+       unsigned long *flags;
 
        if (!dev || !rule)
                return -EINVAL;
@@ -116,7 +118,8 @@ static int pnp_assign_mem(struct pnp_dev *dev, struct pnp_mem *rule, int idx)
 
 static int pnp_assign_irq(struct pnp_dev * dev, struct pnp_irq *rule, int idx)
 {
-       unsigned long *start, *end, *flags;
+       resource_size_t *start, *end;
+       unsigned long *flags;
        int i;
 
        /* IRQ priority: this table is good for i386 */
@@ -168,7 +171,8 @@ static int pnp_assign_irq(struct pnp_dev * dev, struct pnp_irq *rule, int idx)
 
 static int pnp_assign_dma(struct pnp_dev *dev, struct pnp_dma *rule, int idx)
 {
-       unsigned long *start, *end, *flags;
+       resource_size_t *start, *end;
+       unsigned long *flags;
        int i;
 
        /* DMA priority: this table is good for i386 */
@@ -582,7 +586,8 @@ int pnp_disable_dev(struct pnp_dev *dev)
  * @size: size of region
  *
  */
-void pnp_resource_change(struct resource *resource, unsigned long start, unsigned long size)
+void pnp_resource_change(struct resource *resource, resource_size_t start,
+                               resource_size_t size)
 {
        if (resource == NULL)
                return;
index 6ded527169f4b805b43a77dba11a5c0b23d42af8..7bb892f58cc09815da0ee5963417cbc312bf0f9b 100644 (file)
@@ -241,7 +241,7 @@ int pnp_check_port(struct pnp_dev * dev, int idx)
 {
        int tmp;
        struct pnp_dev *tdev;
-       unsigned long *port, *end, *tport, *tend;
+       resource_size_t *port, *end, *tport, *tend;
        port = &dev->res.port_resource[idx].start;
        end = &dev->res.port_resource[idx].end;
 
@@ -297,7 +297,7 @@ int pnp_check_mem(struct pnp_dev * dev, int idx)
 {
        int tmp;
        struct pnp_dev *tdev;
-       unsigned long *addr, *end, *taddr, *tend;
+       resource_size_t *addr, *end, *taddr, *tend;
        addr = &dev->res.mem_resource[idx].start;
        end = &dev->res.mem_resource[idx].end;
 
@@ -358,7 +358,7 @@ int pnp_check_irq(struct pnp_dev * dev, int idx)
 {
        int tmp;
        struct pnp_dev *tdev;
-       unsigned long * irq = &dev->res.irq_resource[idx].start;
+       resource_size_t * irq = &dev->res.irq_resource[idx].start;
 
        /* if the resource doesn't exist, don't complain about it */
        if (cannot_compare(dev->res.irq_resource[idx].flags))
@@ -423,7 +423,7 @@ int pnp_check_dma(struct pnp_dev * dev, int idx)
 #ifndef CONFIG_IA64
        int tmp;
        struct pnp_dev *tdev;
-       unsigned long * dma = &dev->res.dma_resource[idx].start;
+       resource_size_t * dma = &dev->res.dma_resource[idx].start;
 
        /* if the resource doesn't exist, don't complain about it */
        if (cannot_compare(dev->res.dma_resource[idx].flags))
index 67c3d299977582786542271846542f0db2acdcdc..501ce1791782a7284f5af4614d1552468d29bb5b 100644 (file)
@@ -335,10 +335,10 @@ static int svia_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
                if ((pci_resource_start(pdev, i) == 0) ||
                    (pci_resource_len(pdev, i) < bar_sizes[i])) {
                        dev_printk(KERN_ERR, &pdev->dev,
-                                  "invalid PCI BAR %u (sz 0x%lx, val 0x%lx)\n",
-                                  i,
-                                  pci_resource_start(pdev, i),
-                                  pci_resource_len(pdev, i));
+                               "invalid PCI BAR %u (sz 0x%llx, val 0x%llx)\n",
+                               i,
+                               (unsigned long long)pci_resource_start(pdev, i),
+                               (unsigned long long)pci_resource_len(pdev, i));
                        rc = -ENODEV;
                        goto err_out_regions;
                }
index 94886c000d2a2e8ff9581d83423bee68cfeaa409..864ef859be5676e3c6638517e31d87d1a4045229 100644 (file)
@@ -594,8 +594,8 @@ pci_default_setup(struct serial_private *priv, struct pciserial_board *board,
        else
                offset += idx * board->uart_offset;
 
-       maxnr = (pci_resource_len(priv->dev, bar) - board->first_offset) /
-               (8 << board->reg_shift);
+       maxnr = (pci_resource_len(priv->dev, bar) - board->first_offset) >>
+               (board->reg_shift + 3);
 
        if (board->flags & FL_REGION_SZ_CAP && idx >= maxnr)
                return 1;
index 8256a97eb508c1b4db3ff98574894091cb51dece..8562821e6498be2324f8763f17d1292c70f105a7 100644 (file)
@@ -438,7 +438,7 @@ static struct pci_device_id ioc4_id_table[] = {
        {0}
 };
 
-static struct pci_driver __devinitdata ioc4_driver = {
+static struct pci_driver ioc4_driver = {
        .name = "IOC4",
        .id_table = ioc4_id_table,
        .probe = ioc4_probe,
index 6b4bc3f2bd864fd28b3b135118db929735ecf016..89bcda5a329897aee7d5694b879595355190d84e 100644 (file)
@@ -1684,9 +1684,13 @@ sl811h_probe(struct platform_device *dev)
                if (!addr || !data)
                        return -ENODEV;
                ioaddr = 1;
-
-               addr_reg = (void __iomem *) addr->start;
-               data_reg = (void __iomem *) data->start;
+               /*
+                * NOTE: 64-bit resource->start is getting truncated
+                * to avoid compiler warning, assuming that ->start
+                * is always 32-bit for this case
+                */
+               addr_reg = (void __iomem *) (unsigned long) addr->start;
+               data_reg = (void __iomem *) (unsigned long) data->start;
        } else {
                addr_reg = ioremap(addr->start, 1);
                if (addr_reg == NULL) {
index f32b590730f237943c1589f401bceb9fc5211c5c..01401cd63ac061279a382f9884cb86424f2d0cd7 100644 (file)
@@ -390,7 +390,7 @@ static const char *vgacon_startup(void)
                vga_video_port_val = VGA_CRT_DM;
                if ((ORIG_VIDEO_EGA_BX & 0xff) != 0x10) {
                        static struct resource ega_console_resource =
-                           { "ega", 0x3B0, 0x3BF };
+                           { .name = "ega", .start = 0x3B0, .end = 0x3BF };
                        vga_video_type = VIDEO_TYPE_EGAM;
                        vga_vram_size = 0x8000;
                        display_desc = "EGA+";
@@ -398,9 +398,9 @@ static const char *vgacon_startup(void)
                                         &ega_console_resource);
                } else {
                        static struct resource mda1_console_resource =
-                           { "mda", 0x3B0, 0x3BB };
+                           { .name = "mda", .start = 0x3B0, .end = 0x3BB };
                        static struct resource mda2_console_resource =
-                           { "mda", 0x3BF, 0x3BF };
+                           { .name = "mda", .start = 0x3BF, .end = 0x3BF };
                        vga_video_type = VIDEO_TYPE_MDA;
                        vga_vram_size = 0x2000;
                        display_desc = "*MDA";
@@ -423,14 +423,14 @@ static const char *vgacon_startup(void)
 
                        if (!ORIG_VIDEO_ISVGA) {
                                static struct resource ega_console_resource
-                                   = { "ega", 0x3C0, 0x3DF };
+                                   = { .name = "ega", .start = 0x3C0, .end = 0x3DF };
                                vga_video_type = VIDEO_TYPE_EGAC;
                                display_desc = "EGA";
                                request_resource(&ioport_resource,
                                                 &ega_console_resource);
                        } else {
                                static struct resource vga_console_resource
-                                   = { "vga+", 0x3C0, 0x3DF };
+                                   = { .name = "vga+", .start = 0x3C0, .end = 0x3DF };
                                vga_video_type = VIDEO_TYPE_VGAC;
                                display_desc = "VGA+";
                                request_resource(&ioport_resource,
@@ -474,7 +474,7 @@ static const char *vgacon_startup(void)
                        }
                } else {
                        static struct resource cga_console_resource =
-                           { "cga", 0x3D4, 0x3D5 };
+                           { .name = "cga", .start = 0x3D4, .end = 0x3D5 };
                        vga_video_type = VIDEO_TYPE_CGA;
                        vga_vram_size = 0x2000;
                        display_desc = "*CGA";
index 2e6df1fcb2b926e875508bc8ff3181bb4d89a7bc..c0cc5e3ba7b5fe28d689071a52836897d8450627 100644 (file)
@@ -23,6 +23,8 @@
 #include <asm/io.h>
 #include <asm/mtrr.h>
 
+#include <setup_arch.h>
+
 #define INCLUDE_TIMING_TABLE_DATA
 #define DBE_REG_BASE par->regs
 #include <video/sgivw.h>
@@ -42,10 +44,6 @@ struct sgivw_par {
  *  The default can be overridden if the driver is compiled as a module
  */
 
-/* set by arch/i386/kernel/setup.c */
-extern unsigned long sgivwfb_mem_phys;
-extern unsigned long sgivwfb_mem_size;
-
 static int ypan = 0;
 static int ywrap = 0;
 
index 8e1f90e420400af82bf963354013d5f4cb62a845..488b5ff48afb1330ca5f40360af42e25231637d3 100644 (file)
@@ -98,7 +98,9 @@ static u64 ufs_frag_map(struct inode *inode, sector_t frag)
        u64 temp = 0L;
 
        UFSD(": frag = %llu  depth = %d\n", (unsigned long long)frag, depth);
-       UFSD(": uspi->s_fpbshift = %d ,uspi->s_apbmask = %x, mask=%llx\n",uspi->s_fpbshift,uspi->s_apbmask,mask);
+       UFSD(": uspi->s_fpbshift = %d ,uspi->s_apbmask = %x, mask=%llx\n",
+               uspi->s_fpbshift, uspi->s_apbmask,
+               (unsigned long long)mask);
 
        if (depth == 0)
                return 0;
@@ -429,7 +431,7 @@ int ufs_getfrag_block(struct inode *inode, sector_t fragment, struct buffer_head
        
        if (!create) {
                phys64 = ufs_frag_map(inode, fragment);
-               UFSD("phys64 = %llu \n",phys64);
+               UFSD("phys64 = %llu\n", (unsigned long long)phys64);
                if (phys64)
                        map_bh(bh_result, sb, phys64);
                return 0;
index ca9d43b6350276b1bf07e675907033b52690a9e8..a37db0f95092f495a02819a7382631c34b686c37 100644 (file)
@@ -2,8 +2,6 @@
 #define _ALPHA_HW_IRQ_H
 
 
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) {}
-
 extern volatile unsigned long irq_err_count;
 
 #ifdef CONFIG_ALPHA_GENERIC
index 25d540ed0079bf2063921dddbe83b9fdadf67949..923e0ca66200c1f0a592ff470528d4c524a15583 100644 (file)
@@ -28,7 +28,7 @@ struct hw_pci {
 struct pci_sys_data {
        struct list_head node;
        int             busnr;          /* primary bus number                   */
-       unsigned long   mem_offset;     /* bus->cpu memory mapping offset       */
+       u64             mem_offset;     /* bus->cpu memory mapping offset       */
        unsigned long   io_offset;      /* bus->cpu IO mapping offset           */
        struct pci_bus  *bus;           /* PCI bus                              */
        struct resource *resource[3];   /* Primary PCI bus resources            */
index 341536a234e9ccd4e62cd4de8174821c450f4b5c..298066020af212a98a26c15b82b65401832ac151 100644 (file)
@@ -1,7 +1,5 @@
 #ifndef _ASM_HW_IRQ_H
 #define _ASM_HW_IRQ_H
 
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) {}
-
 #endif
 
index 4b338792218b045ce9593af9f5bac2329f686986..998cce9f3200308dd6c87c5f23276e13709ae724 100644 (file)
@@ -1,11 +1,6 @@
 #ifndef _ASM_IRQ_H
 #define _ASM_IRQ_H
 
-/*
- * IRQ line status macro IRQ_PER_CPU is used
- */
-#define ARCH_HAS_IRQ_PER_CPU
-
 #include <asm/arch/irq.h>
 
 static inline int irq_canonicalize(int irq)
index a4c0a5a9ffd84cd4a5c18eab814dc89f08cb69f8..87e5a351d8812b369bf1fc88187214d947d87fa9 100644 (file)
@@ -69,14 +69,4 @@ extern atomic_t irq_mis_count;
 
 #define IO_APIC_IRQ(x) (((x) >= 16) || ((1<<(x)) & io_apic_irqs))
 
-#if defined(CONFIG_X86_IO_APIC)
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i)
-{
-       if (IO_APIC_IRQ(i))
-               send_IPI_self(IO_APIC_VECTOR(i));
-}
-#else
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) {}
-#endif
-
 #endif /* _ASM_HW_IRQ_H */
index b92d6d9a4d3ced6b7785a9f4d9bdbdf0d124e427..33f700ef68316048cdb049f436d187d57854295a 100644 (file)
@@ -1,5 +1,8 @@
 /* Hook to call BIOS initialisation function */
 
+extern unsigned long sgivwfb_mem_phys;
+extern unsigned long sgivwfb_mem_size;
+
 /* no action for visws */
 
 #define ARCH_SETUP
index ea8b8c407ab4a210f50b055c2030cb34222fdca0..27f9df6b914539401c26421ce0bb38d970ef0081 100644 (file)
@@ -97,8 +97,7 @@ extern int reserve_irq_vector (int vector);
 extern void ia64_send_ipi (int cpu, int vector, int delivery_mode, int redirect);
 extern void register_percpu_irq (ia64_vector vec, struct irqaction *action);
 
-static inline void
-hw_resend_irq (struct hw_interrupt_type *h, unsigned int vector)
+static inline void ia64_resend_irq(unsigned int vector)
 {
        platform_send_ipi(smp_processor_id(), vector, IA64_IPI_DM_INT, 0);
 }
index dbe86c0bbce5f896f25e4934228ac2c36228227a..79479e2c6966b0cb468db6f348538e8b0e19d32f 100644 (file)
 #define NR_IRQS                256
 #define NR_IRQ_VECTORS NR_IRQS
 
-/*
- * IRQ line status macro IRQ_PER_CPU is used
- */
-#define ARCH_HAS_IRQ_PER_CPU
-
 static __inline__ int
 irq_canonicalize (int irq)
 {
index 8d7e9d0e09e876329089bc7401c662430dc78ae2..7138537cda03017c2bce4cb15f1a7a7380a82a2a 100644 (file)
@@ -1,9 +1,4 @@
 #ifndef _ASM_M32R_HW_IRQ_H
 #define _ASM_M32R_HW_IRQ_H
 
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i)
-{
-       /* Nothing to do */
-}
-
 #endif /* _ASM_M32R_HW_IRQ_H */
index c854d017c0e5b2090af5b3bdadc56751b839a504..458d9fdc76bf2eed4372a0993dd0ebb0f1b08baa 100644 (file)
@@ -19,9 +19,9 @@ extern void init_8259A(int aeoi);
 
 extern atomic_t irq_err_count;
 
-/* This may not be apropriate for all machines, we'll see ...  */
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i)
-{
-}
+/*
+ * interrupt-retrigger: NOP for now. This may not be apropriate for all
+ * machines, we'll see ...
+ */
 
 #endif /* __ASM_HW_IRQ_H */
index 083d9c512a04914c6520f54603c310af932a5213..e994b0c012279a316693e403b4f94d80ea522c4d 100644 (file)
@@ -4,10 +4,4 @@
 
 #define NR_IRQS        256
 
-#ifdef CONFIG_SMP
-
-#define ARCH_HAS_IRQ_PER_CPU
-
-#endif
-
 #endif /* __ASM_MACH_MIPS_IRQ_H */
index 151426e275213c23a6e1afa124fcb681a672e54e..6707f7df3921f566e044bb39ea0c31b95154f290 100644 (file)
@@ -3,15 +3,6 @@
 
 /*
  *     linux/include/asm/hw_irq.h
- *
- *     (C) 1992, 1993 Linus Torvalds, (C) 1997 Ingo Molnar
- *
- *     moved some of the old arch/i386/kernel/irq.h to here. VY
- *
- *     IRQ/IPI changes taken from work by Thomas Radke
- *     <tomsoft@informatik.tu-chemnitz.de>
  */
 
-extern void hw_resend_irq(struct hw_interrupt_type *, unsigned int);
-
 #endif
index 377ba90c7d0256841568386405399164191569b4..5cae260615a22a74d14075d529a47419e9d02137 100644 (file)
 
 #define NR_IRQS                (CPU_IRQ_MAX + 1)
 
-/*
- * IRQ line status macro IRQ_PER_CPU is used
- */
-#define ARCH_HAS_IRQ_PER_CPU
-
 static __inline__ int irq_canonicalize(int irq)
 {
        return (irq == 2) ? 9 : irq;
index ce0f7db63c1673a1435d93e7906a27bb9cb947cd..d40359204abaa1ff38743c718a72e40ba22d3f96 100644 (file)
@@ -86,27 +86,27 @@ static inline void local_irq_save_ptr(unsigned long *flags)
 #define mask_irq(irq)                                          \
        ({                                                      \
                irq_desc_t *desc = get_irq_desc(irq);           \
-               if (desc->handler && desc->handler->disable)    \
-                       desc->handler->disable(irq);            \
+               if (desc->chip && desc->chip->disable)  \
+                       desc->chip->disable(irq);               \
        })
 #define unmask_irq(irq)                                                \
        ({                                                      \
                irq_desc_t *desc = get_irq_desc(irq);           \
-               if (desc->handler && desc->handler->enable)     \
-                       desc->handler->enable(irq);             \
+               if (desc->chip && desc->chip->enable)   \
+                       desc->chip->enable(irq);                \
        })
 #define ack_irq(irq)                                           \
        ({                                                      \
                irq_desc_t *desc = get_irq_desc(irq);           \
-               if (desc->handler && desc->handler->ack)        \
-                       desc->handler->ack(irq);                \
+               if (desc->chip && desc->chip->ack)      \
+                       desc->chip->ack(irq);           \
        })
 
-/* Should we handle this via lost interrupts and IPIs or should we don't care like
- * we do now ? --BenH.
+/*
+ * interrupt-retrigger: should we handle this via lost interrupts and IPIs
+ * or should we not care like we do now ? --BenH.
  */
 struct hw_interrupt_type;
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) {}
 
 #endif /* __KERNEL__ */
 #endif /* _ASM_POWERPC_HW_IRQ_H */
index a10feec29d4d4dce05685d8e112cecbbf37d8a29..eb5f33e1977a2cce8ff839eb7917f2813b4b7ce1 100644 (file)
 #define IRQ_POLARITY_POSITIVE  0x2     /* high level or low->high edge */
 #define IRQ_POLARITY_NEGATIVE  0x0     /* low level or high->low edge */
 
-/*
- * IRQ line status macro IRQ_PER_CPU is used
- */
-#define ARCH_HAS_IRQ_PER_CPU
-
 #define get_irq_desc(irq) (&irq_desc[(irq)])
 
 /* Define a way to iterate across irqs. */
index 5d2c9e6c4be2ba1483118e2de61b572ccbb2c2b1..46afd29b904e47694c1f2127b07738bf091cd075 100644 (file)
@@ -242,7 +242,7 @@ extern pgprot_t     pci_phys_mem_access_prot(struct file *file,
 #define HAVE_ARCH_PCI_RESOURCE_TO_USER
 extern void pci_resource_to_user(const struct pci_dev *dev, int bar,
                                 const struct resource *rsrc,
-                                u64 *start, u64 *end);
+                                resource_size_t *start, resource_size_t *end);
 #endif /* CONFIG_PPC_MULTIPLATFORM || CONFIG_PPC32 */
 
 #endif /* __KERNEL__ */
index 61434edbad7b7fd8489ca0a11743f0e604b565da..11ffaaa5da165abe9adec4d586eba35864fa71dc 100644 (file)
@@ -133,7 +133,7 @@ extern pgprot_t     pci_phys_mem_access_prot(struct file *file,
 #define HAVE_ARCH_PCI_RESOURCE_TO_USER
 extern void pci_resource_to_user(const struct pci_dev *dev, int bar,
                                 const struct resource *rsrc,
-                                u64 *start, u64 *end);
+                                resource_size_t *start, resource_size_t *end);
 
 
 #endif /* __KERNEL__ */
index 1d934fb2c581c69ac6b6fe7906af5adc010a2f01..fed26616967a03979d0d6ea6e7c14d1d6a446f97 100644 (file)
@@ -1,9 +1,4 @@
 #ifndef __ASM_SH_HW_IRQ_H
 #define __ASM_SH_HW_IRQ_H
 
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i)
-{
-       /* Nothing to do */
-}
-
 #endif /* __ASM_SH_HW_IRQ_H */
index ae718d1f2d6cc90d416284453c5c01cdbfb652dd..ebb39089b0acf3be7f39841243447e3b94427a07 100644 (file)
@@ -11,6 +11,5 @@
  * Copyright (C) 2000, 2001  Paolo Alberelli
  *
  */
-static __inline__ void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) { /* Nothing to do */ }
 
 #endif /* __ASM_SH64_HW_IRQ_H */
index 4ee38c0b6a64c0378c110cf7beb9d2aeeebfeae6..1cf84cf5f21af301596b5439289e1183071e2661 100644 (file)
@@ -4,7 +4,4 @@
 #include "asm/irq.h"
 #include "asm/archparam.h"
 
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i)
-{}
-
 #endif
index a8aab4342712a77a7e1f2ac49ae8b536fb270d40..043e94bb6bd8e51f0c94dd6473c92d00e4f86a99 100644 (file)
@@ -1,8 +1,4 @@
 #ifndef __V850_HW_IRQ_H__
 #define __V850_HW_IRQ_H__
 
-static inline void hw_resend_irq (struct hw_interrupt_type *h, unsigned int i)
-{
-}
-
 #endif /* __V850_HW_IRQ_H__ */
index 931877462788473f71d39b04198dfa56986d79eb..48a4a5364e85ddfc651c6716e0cf54deeac21df2 100644 (file)
@@ -127,15 +127,6 @@ __asm__( \
        "push $~(" #nr ") ; " \
        "jmp common_interrupt");
 
-#if defined(CONFIG_X86_IO_APIC)
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) {
-       if (IO_APIC_IRQ(i))
-               send_IPI_self(IO_APIC_VECTOR(i));
-}
-#else
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) {}
-#endif
-
 #define platform_legacy_irq(irq)       ((irq) < 16)
 
 #endif
index ccf436249eaaa90f66c6d746701bcce74f1f01ad..3ddbea759b2bc32be0839976e1d582b23f90fdfe 100644 (file)
@@ -11,8 +11,4 @@
 #ifndef _XTENSA_HW_IRQ_H
 #define _XTENSA_HW_IRQ_H
 
-static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i)
-{
-}
-
 #endif
index 70741e170114e5f9328553fa9b8eadc1a60fc7ab..db2a63a11633cb9ebdfeb21dc9436b1a23bd92ea 100644 (file)
@@ -36,6 +36,20 @@ extern void free_irq(unsigned int, void *);
 extern void disable_irq_nosync(unsigned int irq);
 extern void disable_irq(unsigned int irq);
 extern void enable_irq(unsigned int irq);
+
+/* IRQ wakeup (PM) control: */
+extern int set_irq_wake(unsigned int irq, unsigned int on);
+
+static inline int enable_irq_wake(unsigned int irq)
+{
+       return set_irq_wake(irq, 1);
+}
+
+static inline int disable_irq_wake(unsigned int irq)
+{
+       return set_irq_wake(irq, 0);
+}
+
 #endif
 
 #ifndef __ARCH_SET_SOFTIRQ_PENDING
index edfc733b1575c4f4c5d47644784e83e1d0d32a75..87a9fc039b4789e6d68e65510cb06bafaf18c801 100644 (file)
@@ -9,13 +9,15 @@
 #define _LINUX_IOPORT_H
 
 #include <linux/compiler.h>
+#include <linux/types.h>
 /*
  * Resources are tree-like, allowing
  * nesting etc..
  */
 struct resource {
+       resource_size_t start;
+       resource_size_t end;
        const char *name;
-       unsigned long start, end;
        unsigned long flags;
        struct resource *parent, *sibling, *child;
 };
@@ -96,14 +98,13 @@ extern struct resource * ____request_resource(struct resource *root, struct reso
 extern int release_resource(struct resource *new);
 extern __deprecated_for_modules int insert_resource(struct resource *parent, struct resource *new);
 extern int allocate_resource(struct resource *root, struct resource *new,
-                            unsigned long size,
-                            unsigned long min, unsigned long max,
-                            unsigned long align,
+                            resource_size_t size, resource_size_t min,
+                            resource_size_t max, resource_size_t align,
                             void (*alignf)(void *, struct resource *,
-                                           unsigned long, unsigned long),
+                                           resource_size_t, resource_size_t),
                             void *alignf_data);
-int adjust_resource(struct resource *res, unsigned long start,
-                   unsigned long size);
+int adjust_resource(struct resource *res, resource_size_t start,
+                   resource_size_t size);
 
 /* get registered SYSTEM_RAM resources in specified area */
 extern int find_next_system_ram(struct resource *res);
@@ -113,17 +114,21 @@ extern int find_next_system_ram(struct resource *res);
 #define request_mem_region(start,n,name) __request_region(&iomem_resource, (start), (n), (name))
 #define rename_region(region, newname) do { (region)->name = (newname); } while (0)
 
-extern struct resource * __request_region(struct resource *, unsigned long start, unsigned long n, const char *name);
+extern struct resource * __request_region(struct resource *,
+                                       resource_size_t start,
+                                       resource_size_t n, const char *name);
 
 /* Compatibility cruft */
 #define release_region(start,n)        __release_region(&ioport_resource, (start), (n))
 #define check_mem_region(start,n)      __check_region(&iomem_resource, (start), (n))
 #define release_mem_region(start,n)    __release_region(&iomem_resource, (start), (n))
 
-extern int __check_region(struct resource *, unsigned long, unsigned long);
-extern void __release_region(struct resource *, unsigned long, unsigned long);
+extern int __check_region(struct resource *, resource_size_t, resource_size_t);
+extern void __release_region(struct resource *, resource_size_t,
+                               resource_size_t);
 
-static inline int __deprecated check_region(unsigned long s, unsigned long n)
+static inline int __deprecated check_region(resource_size_t s,
+                                               resource_size_t n)
 {
        return __check_region(&ioport_resource, s, n);
 }
index 676e00dfb21a623c6922436646cc4e85be8d7656..0832149cdb180df6e8ba75e1f7a951c438b03546 100644 (file)
@@ -1,5 +1,5 @@
-#ifndef __irq_h
-#define __irq_h
+#ifndef _LINUX_IRQ_H
+#define _LINUX_IRQ_H
 
 /*
  * Please do not include this file in generic code.  There is currently
@@ -11,7 +11,7 @@
 
 #include <linux/smp.h>
 
-#if !defined(CONFIG_S390)
+#ifndef CONFIG_S390
 
 #include <linux/linkage.h>
 #include <linux/cache.h>
 #define IRQ_WAITING    32      /* IRQ not yet seen - for autodetection */
 #define IRQ_LEVEL      64      /* IRQ level triggered */
 #define IRQ_MASKED     128     /* IRQ masked - shouldn't be seen again */
-#if defined(ARCH_HAS_IRQ_PER_CPU)
+#ifdef CONFIG_IRQ_PER_CPU
 # define IRQ_PER_CPU   256     /* IRQ is per CPU */
 # define CHECK_IRQ_PER_CPU(var) ((var) & IRQ_PER_CPU)
 #else
 # define CHECK_IRQ_PER_CPU(var) 0
 #endif
 
+#define IRQ_NOPROBE    512     /* IRQ is not valid for probing */
+#define IRQ_NOREQUEST  1024    /* IRQ cannot be requested */
+#define IRQ_NOAUTOEN   2048    /* IRQ will not be enabled on request irq */
+#define IRQ_DELAYED_DISABLE \
+                       4096    /* IRQ disable (masking) happens delayed. */
+
 /*
- * Interrupt controller descriptor. This is all we need
- * to describe about the low-level hardware. 
+ * IRQ types, see also include/linux/interrupt.h
  */
-struct hw_interrupt_type {
-       const char * typename;
-       unsigned int (*startup)(unsigned int irq);
-       void (*shutdown)(unsigned int irq);
-       void (*enable)(unsigned int irq);
-       void (*disable)(unsigned int irq);
-       void (*ack)(unsigned int irq);
-       void (*end)(unsigned int irq);
-       void (*set_affinity)(unsigned int irq, cpumask_t dest);
+#define IRQ_TYPE_NONE          0x0000          /* Default, unspecified type */
+#define IRQ_TYPE_EDGE_RISING   0x0001          /* Edge rising type */
+#define IRQ_TYPE_EDGE_FALLING  0x0002          /* Edge falling type */
+#define IRQ_TYPE_EDGE_BOTH (IRQ_TYPE_EDGE_FALLING | IRQ_TYPE_EDGE_RISING)
+#define IRQ_TYPE_LEVEL_HIGH    0x0004          /* Level high type */
+#define IRQ_TYPE_LEVEL_LOW     0x0008          /* Level low type */
+#define IRQ_TYPE_SENSE_MASK    0x000f          /* Mask of the above */
+#define IRQ_TYPE_SIMPLE                0x0010          /* Simple type */
+#define IRQ_TYPE_PERCPU                0x0020          /* Per CPU type */
+#define IRQ_TYPE_PROBE         0x0040          /* Probing in progress */
+
+struct proc_dir_entry;
+
+/**
+ * struct irq_chip - hardware interrupt chip descriptor
+ *
+ * @name:              name for /proc/interrupts
+ * @startup:           start up the interrupt (defaults to ->enable if NULL)
+ * @shutdown:          shut down the interrupt (defaults to ->disable if NULL)
+ * @enable:            enable the interrupt (defaults to chip->unmask if NULL)
+ * @disable:           disable the interrupt (defaults to chip->mask if NULL)
+ * @ack:               start of a new interrupt
+ * @mask:              mask an interrupt source
+ * @mask_ack:          ack and mask an interrupt source
+ * @unmask:            unmask an interrupt source
+ * @eoi:               end of interrupt - chip level
+ * @end:               end of interrupt - flow level
+ * @set_affinity:      set the CPU affinity on SMP machines
+ * @retrigger:         resend an IRQ to the CPU
+ * @set_type:          set the flow type (IRQ_TYPE_LEVEL/etc.) of an IRQ
+ * @set_wake:          enable/disable power-management wake-on of an IRQ
+ *
+ * @release:           release function solely used by UML
+ * @typename:          obsoleted by name, kept as migration helper
+ */
+struct irq_chip {
+       const char      *name;
+       unsigned int    (*startup)(unsigned int irq);
+       void            (*shutdown)(unsigned int irq);
+       void            (*enable)(unsigned int irq);
+       void            (*disable)(unsigned int irq);
+
+       void            (*ack)(unsigned int irq);
+       void            (*mask)(unsigned int irq);
+       void            (*mask_ack)(unsigned int irq);
+       void            (*unmask)(unsigned int irq);
+       void            (*eoi)(unsigned int irq);
+
+       void            (*end)(unsigned int irq);
+       void            (*set_affinity)(unsigned int irq, cpumask_t dest);
+       int             (*retrigger)(unsigned int irq);
+       int             (*set_type)(unsigned int irq, unsigned int flow_type);
+       int             (*set_wake)(unsigned int irq, unsigned int on);
+
        /* Currently used only by UML, might disappear one day.*/
 #ifdef CONFIG_IRQ_RELEASE_METHOD
-       void (*release)(unsigned int irq, void *dev_id);
+       void            (*release)(unsigned int irq, void *dev_id);
 #endif
+       /*
+        * For compatibility, ->typename is copied into ->name.
+        * Will disappear.
+        */
+       const char      *typename;
 };
 
-typedef struct hw_interrupt_type  hw_irq_controller;
-
-/*
- * This is the "IRQ descriptor", which contains various information
- * about the irq, including what kind of hardware handling it has,
- * whether it is disabled etc etc.
+/**
+ * struct irq_desc - interrupt descriptor
+ *
+ * @handle_irq:                highlevel irq-events handler [if NULL, __do_IRQ()]
+ * @chip:              low level interrupt hardware access
+ * @handler_data:      per-IRQ data for the irq_chip methods
+ * @chip_data:         platform-specific per-chip private data for the chip
+ *                     methods, to allow shared chip implementations
+ * @action:            the irq action chain
+ * @status:            status information
+ * @depth:             disable-depth, for nested irq_disable() calls
+ * @irq_count:         stats field to detect stalled irqs
+ * @irqs_unhandled:    stats field for spurious unhandled interrupts
+ * @lock:              locking for SMP
+ * @affinity:          IRQ affinity on SMP
+ * @cpu:               cpu index useful for balancing
+ * @pending_mask:      pending rebalanced interrupts
+ * @move_irq:          need to re-target IRQ destination
+ * @dir:               /proc/irq/ procfs entry
+ * @affinity_entry:    /proc/irq/smp_affinity procfs entry on SMP
  *
  * Pad this out to 32 bytes for cache and indexing reasons.
  */
-typedef struct irq_desc {
-       hw_irq_controller *handler;
-       void *handler_data;
-       struct irqaction *action;       /* IRQ action list */
-       unsigned int status;            /* IRQ status */
-       unsigned int depth;             /* nested irq disables */
-       unsigned int irq_count;         /* For detecting broken interrupts */
-       unsigned int irqs_unhandled;
-       spinlock_t lock;
-#if defined (CONFIG_GENERIC_PENDING_IRQ) || defined (CONFIG_IRQBALANCE)
-       unsigned int move_irq;          /* Flag need to re-target intr dest*/
+struct irq_desc {
+       void fastcall           (*handle_irq)(unsigned int irq,
+                                             struct irq_desc *desc,
+                                             struct pt_regs *regs);
+       struct irq_chip         *chip;
+       void                    *handler_data;
+       void                    *chip_data;
+       struct irqaction        *action;        /* IRQ action list */
+       unsigned int            status;         /* IRQ status */
+
+       unsigned int            depth;          /* nested irq disables */
+       unsigned int            irq_count;      /* For detecting broken IRQs */
+       unsigned int            irqs_unhandled;
+       spinlock_t              lock;
+#ifdef CONFIG_SMP
+       cpumask_t               affinity;
+       unsigned int            cpu;
+#endif
+#if defined(CONFIG_GENERIC_PENDING_IRQ) || defined(CONFIG_IRQBALANCE)
+       cpumask_t               pending_mask;
+       unsigned int            move_irq;       /* need to re-target IRQ dest */
 #endif
-} ____cacheline_aligned irq_desc_t;
+#ifdef CONFIG_PROC_FS
+       struct proc_dir_entry *dir;
+#endif
+} ____cacheline_aligned;
 
-extern irq_desc_t irq_desc [NR_IRQS];
+extern struct irq_desc irq_desc[NR_IRQS];
 
-/* Return a pointer to the irq descriptor for IRQ.  */
-static inline irq_desc_t *
-irq_descp (int irq)
-{
-       return irq_desc + irq;
-}
+/*
+ * Migration helpers for obsolete names, they will go away:
+ */
+#define hw_interrupt_type      irq_chip
+typedef struct irq_chip                hw_irq_controller;
+#define no_irq_type            no_irq_chip
+typedef struct irq_desc                irq_desc_t;
 
-#include <asm/hw_irq.h> /* the arch dependent stuff */
+/*
+ * Pick up the arch-dependent methods:
+ */
+#include <asm/hw_irq.h>
 
-extern int setup_irq(unsigned int irq, struct irqaction * new);
+extern int setup_irq(unsigned int irq, struct irqaction *new);
 
 #ifdef CONFIG_GENERIC_HARDIRQS
-extern cpumask_t irq_affinity[NR_IRQS];
 
 #ifdef CONFIG_SMP
 static inline void set_native_irq_info(int irq, cpumask_t mask)
 {
-       irq_affinity[irq] = mask;
+       irq_desc[irq].affinity = mask;
 }
 #else
 static inline void set_native_irq_info(int irq, cpumask_t mask)
@@ -111,8 +196,7 @@ static inline void set_native_irq_info(int irq, cpumask_t mask)
 
 #ifdef CONFIG_SMP
 
-#if defined (CONFIG_GENERIC_PENDING_IRQ) || defined (CONFIG_IRQBALANCE)
-extern cpumask_t pending_irq_cpumask[NR_IRQS];
+#if defined(CONFIG_GENERIC_PENDING_IRQ) || defined(CONFIG_IRQBALANCE)
 
 void set_pending_irq(unsigned int irq, cpumask_t mask);
 void move_native_irq(int irq);
@@ -133,7 +217,7 @@ static inline void set_irq_info(int irq, cpumask_t mask)
 {
 }
 
-#else // CONFIG_PCI_MSI
+#else /* CONFIG_PCI_MSI */
 
 static inline void move_irq(int irq)
 {
@@ -144,26 +228,36 @@ static inline void set_irq_info(int irq, cpumask_t mask)
 {
        set_native_irq_info(irq, mask);
 }
-#endif // CONFIG_PCI_MSI
 
-#else  // CONFIG_GENERIC_PENDING_IRQ || CONFIG_IRQBALANCE
+#endif /* CONFIG_PCI_MSI */
+
+#else /* CONFIG_GENERIC_PENDING_IRQ || CONFIG_IRQBALANCE */
+
+static inline void move_irq(int irq)
+{
+}
+
+static inline void move_native_irq(int irq)
+{
+}
+
+static inline void set_pending_irq(unsigned int irq, cpumask_t mask)
+{
+}
 
-#define move_irq(x)
-#define move_native_irq(x)
-#define set_pending_irq(x,y)
 static inline void set_irq_info(int irq, cpumask_t mask)
 {
        set_native_irq_info(irq, mask);
 }
 
-#endif // CONFIG_GENERIC_PENDING_IRQ
+#endif /* CONFIG_GENERIC_PENDING_IRQ */
 
-#else // CONFIG_SMP
+#else /* CONFIG_SMP */
 
 #define move_irq(x)
 #define move_native_irq(x)
 
-#endif // CONFIG_SMP
+#endif /* CONFIG_SMP */
 
 #ifdef CONFIG_IRQBALANCE
 extern void set_balance_irq_affinity(unsigned int irq, cpumask_t mask);
@@ -173,32 +267,138 @@ static inline void set_balance_irq_affinity(unsigned int irq, cpumask_t mask)
 }
 #endif
 
+#ifdef CONFIG_AUTO_IRQ_AFFINITY
+extern int select_smp_affinity(unsigned int irq);
+#else
+static inline int select_smp_affinity(unsigned int irq)
+{
+       return 1;
+}
+#endif
+
 extern int no_irq_affinity;
-extern int noirqdebug_setup(char *str);
 
-extern fastcall irqreturn_t handle_IRQ_event(unsigned int irq, struct pt_regs *regs,
-                                       struct irqaction *action);
+/* Handle irq action chains: */
+extern int handle_IRQ_event(unsigned int irq, struct pt_regs *regs,
+                           struct irqaction *action);
+
+/*
+ * Built-in IRQ handlers for various IRQ types,
+ * callable via desc->chip->handle_irq()
+ */
+extern void fastcall
+handle_level_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs);
+extern void fastcall
+handle_fasteoi_irq(unsigned int irq, struct irq_desc *desc,
+                        struct pt_regs *regs);
+extern void fastcall
+handle_edge_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs);
+extern void fastcall
+handle_simple_irq(unsigned int irq, struct irq_desc *desc,
+                 struct pt_regs *regs);
+extern void fastcall
+handle_percpu_irq(unsigned int irq, struct irq_desc *desc,
+                 struct pt_regs *regs);
+extern void fastcall
+handle_bad_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs);
+
+/*
+ * Get a descriptive string for the highlevel handler, for
+ * /proc/interrupts output:
+ */
+extern const char *
+handle_irq_name(void fastcall (*handle)(unsigned int, struct irq_desc *,
+                                       struct pt_regs *));
+
+/*
+ * Monolithic do_IRQ implementation.
+ * (is an explicit fastcall, because i386 4KSTACKS calls it from assembly)
+ */
 extern fastcall unsigned int __do_IRQ(unsigned int irq, struct pt_regs *regs);
-extern void note_interrupt(unsigned int irq, irq_desc_t *desc,
-                                       int action_ret, struct pt_regs *regs);
-extern int can_request_irq(unsigned int irq, unsigned long irqflags);
 
+/*
+ * Architectures call this to let the generic IRQ layer
+ * handle an interrupt. If the descriptor is attached to an
+ * irqchip-style controller then we call the ->handle_irq() handler,
+ * and it calls __do_IRQ() if it's attached to an irqtype-style controller.
+ */
+static inline void generic_handle_irq(unsigned int irq, struct pt_regs *regs)
+{
+       struct irq_desc *desc = irq_desc + irq;
+
+       if (likely(desc->handle_irq))
+               desc->handle_irq(irq, desc, regs);
+       else
+               __do_IRQ(irq, regs);
+}
+
+/* Handling of unhandled and spurious interrupts: */
+extern void note_interrupt(unsigned int irq, struct irq_desc *desc,
+                          int action_ret, struct pt_regs *regs);
+
+/* Resending of interrupts :*/
+void check_irq_resend(struct irq_desc *desc, unsigned int irq);
+
+/* Initialize /proc/irq/ */
 extern void init_irq_proc(void);
 
-#ifdef CONFIG_AUTO_IRQ_AFFINITY
-extern int select_smp_affinity(unsigned int irq);
-#else
-static inline int
-select_smp_affinity(unsigned int irq)
+/* Enable/disable irq debugging output: */
+extern int noirqdebug_setup(char *str);
+
+/* Checks whether the interrupt can be requested by request_irq(): */
+extern int can_request_irq(unsigned int irq, unsigned long irqflags);
+
+/* Dummy irq-chip implementation: */
+extern struct irq_chip no_irq_chip;
+
+extern void
+set_irq_chip_and_handler(unsigned int irq, struct irq_chip *chip,
+                        void fastcall (*handle)(unsigned int,
+                                                struct irq_desc *,
+                                                struct pt_regs *));
+extern void
+__set_irq_handler(unsigned int irq,
+                 void fastcall (*handle)(unsigned int, struct irq_desc *,
+                                         struct pt_regs *),
+                 int is_chained);
+
+/*
+ * Set a highlevel flow handler for a given IRQ:
+ */
+static inline void
+set_irq_handler(unsigned int irq,
+               void fastcall (*handle)(unsigned int, struct irq_desc *,
+                                       struct pt_regs *))
 {
-       return 1;
+       __set_irq_handler(irq, handle, 0);
 }
-#endif
 
-#endif
+/*
+ * Set a highlevel chained flow handler for a given IRQ.
+ * (a chained handler is automatically enabled and set to
+ *  IRQ_NOREQUEST and IRQ_NOPROBE)
+ */
+static inline void
+set_irq_chained_handler(unsigned int irq,
+                       void fastcall (*handle)(unsigned int, struct irq_desc *,
+                                               struct pt_regs *))
+{
+       __set_irq_handler(irq, handle, 1);
+}
 
-extern hw_irq_controller no_irq_type;  /* needed in every arch ? */
+/* Set/get chip/data for an IRQ: */
 
-#endif
+extern int set_irq_chip(unsigned int irq, struct irq_chip *chip);
+extern int set_irq_data(unsigned int irq, void *data);
+extern int set_irq_chip_data(unsigned int irq, void *data);
+extern int set_irq_type(unsigned int irq, unsigned int type);
+
+#define get_irq_chip(irq)      (irq_desc[irq].chip)
+#define get_irq_chip_data(irq) (irq_desc[irq].chip_data)
+#define get_irq_data(irq)      (irq_desc[irq].handler_data)
+
+#endif /* CONFIG_GENERIC_HARDIRQS */
+
+#endif /* !CONFIG_S390 */
 
-#endif /* __irq_h */
+#endif /* _LINUX_IRQ_H */
diff --git a/include/linux/isdn/tpam.h b/include/linux/isdn/tpam.h
deleted file mode 100644 (file)
index d18dd0d..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/* $Id: tpam.h,v 1.1.2.1 2001/06/08 08:23:46 kai Exp $
- *
- * Turbo PAM ISDN driver for Linux. (Kernel Driver)
- *
- * Copyright 2001 Stelian Pop <stelian.pop@fr.alcove.com>, Alcôve
- *
- * For all support questions please contact: <support@auvertech.fr>
- *
- * 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
- * the Free Software Foundation; either version 2, or (at your option)
- * any later version.
- *
- * 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.
- *
- * 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., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- */
-
-#ifndef _TPAM_H_
-#define _TPAM_H_
-
-#include <linux/types.h>
-
-/* IOCTL commands */
-#define TPAM_CMD_DSPLOAD       0x0001
-#define TPAM_CMD_DSPSAVE       0x0002
-#define TPAM_CMD_DSPRUN                0x0003
-#define TPAM_CMD_LOOPMODEON    0x0004
-#define TPAM_CMD_LOOPMODEOFF   0x0005
-
-/* addresses of debug information zones on board */
-#define TPAM_TRAPAUDIT_REGISTER                0x005493e4
-#define TPAM_NCOAUDIT_REGISTER         0x00500000
-#define TPAM_MSGAUDIT_REGISTER         0x008E30F0
-
-/* length of debug information zones on board */
-#define TPAM_TRAPAUDIT_LENGTH          10000
-#define TPAM_NCOAUDIT_LENGTH           300000
-#define TPAM_NCOAUDIT_COUNT            30
-#define TPAM_MSGAUDIT_LENGTH           60000
-
-/* IOCTL load/save parameter */
-typedef struct tpam_dsp_ioctl {
-       __u32 address;  /* address to load/save data */
-       __u32 data_len; /* size of data to be loaded/saved */
-       __u8 data[0];   /* data */
-} tpam_dsp_ioctl;
-
-#endif /* _TPAM_H_ */
index e693e729bc92141b77440c217599e70860a81934..169f05e4863ed140058674a1e5a1fcab5f06f766 100644 (file)
@@ -177,7 +177,8 @@ struct key {
 /*
  * kernel managed key type definition
  */
-typedef int (*request_key_actor_t)(struct key *key, struct key *authkey, const char *op);
+typedef int (*request_key_actor_t)(struct key *key, struct key *authkey,
+                                  const char *op, void *aux);
 
 struct key_type {
        /* name of the type */
@@ -285,6 +286,11 @@ extern struct key *request_key(struct key_type *type,
                               const char *description,
                               const char *callout_info);
 
+extern struct key *request_key_with_auxdata(struct key_type *type,
+                                           const char *description,
+                                           const char *callout_info,
+                                           void *aux);
+
 extern int key_validate(struct key *key);
 
 extern key_ref_t key_create_or_update(key_ref_t keyring,
index 62a8c22f5f604981970a762d780c0f9eff101165..983fca251b25c67bfc23c738d282eb09a411602b 100644 (file)
@@ -404,8 +404,8 @@ int pcibios_enable_device(struct pci_dev *, int mask);
 char *pcibios_setup (char *str);
 
 /* Used only when drivers/pci/setup.c is used */
-void pcibios_align_resource(void *, struct resource *,
-                           unsigned long, unsigned long);
+void pcibios_align_resource(void *, struct resource *, resource_size_t,
+                               resource_size_t);
 void pcibios_update_irq(struct pci_dev *, int irq);
 
 /* Generic PCI functions used internally */
@@ -532,10 +532,10 @@ void pci_release_region(struct pci_dev *, int);
 
 /* drivers/pci/bus.c */
 int pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res,
-                          unsigned long size, unsigned long align,
-                          unsigned long min, unsigned int type_mask,
+                          resource_size_t size, resource_size_t align,
+                          resource_size_t min, unsigned int type_mask,
                           void (*alignf)(void *, struct resource *,
-                                         unsigned long, unsigned long),
+                                         resource_size_t, resource_size_t),
                           void *alignf_data);
 void pci_enable_bridges(struct pci_bus *bus);
 
@@ -730,7 +730,8 @@ static inline char *pci_name(struct pci_dev *pdev)
  */
 #ifndef HAVE_ARCH_PCI_RESOURCE_TO_USER
 static inline void pci_resource_to_user(const struct pci_dev *dev, int bar,
-                const struct resource *rsrc, u64 *start, u64 *end)
+                const struct resource *rsrc, resource_size_t *start,
+               resource_size_t *end)
 {
        *start = rsrc->start;
        *end = rsrc->end;
index 93b0959eb40f466ba0e1834da22c558b090a937e..ab8a8dd8d64c5f55c88bd28c05d7439875239b72 100644 (file)
@@ -389,7 +389,8 @@ int pnp_start_dev(struct pnp_dev *dev);
 int pnp_stop_dev(struct pnp_dev *dev);
 int pnp_activate_dev(struct pnp_dev *dev);
 int pnp_disable_dev(struct pnp_dev *dev);
-void pnp_resource_change(struct resource *resource, unsigned long start, unsigned long size);
+void pnp_resource_change(struct resource *resource, resource_size_t start,
+                               resource_size_t size);
 
 /* protocol helpers */
 int pnp_is_active(struct pnp_dev * dev);
@@ -434,7 +435,9 @@ static inline int pnp_start_dev(struct pnp_dev *dev) { return -ENODEV; }
 static inline int pnp_stop_dev(struct pnp_dev *dev) { return -ENODEV; }
 static inline int pnp_activate_dev(struct pnp_dev *dev) { return -ENODEV; }
 static inline int pnp_disable_dev(struct pnp_dev *dev) { return -ENODEV; }
-static inline void pnp_resource_change(struct resource *resource, unsigned long start, unsigned long size) { }
+static inline void pnp_resource_change(struct resource *resource,
+                                       resource_size_t start,
+                                       resource_size_t size) { }
 
 /* protocol helpers */
 static inline int pnp_is_active(struct pnp_dev * dev) { return 0; }
index a5e46e783ffa03ca4d38e918e09f4e8b78367380..3f235660a3cd6a76c4fa0480e649deaa5a4077d3 100644 (file)
@@ -177,8 +177,15 @@ typedef __u64 __bitwise __be64;
 
 #ifdef __KERNEL__
 typedef unsigned __bitwise__ gfp_t;
+
+#ifdef CONFIG_RESOURCES_64BIT
+typedef u64 resource_size_t;
+#else
+typedef u32 resource_size_t;
 #endif
 
+#endif /* __KERNEL__ */
+
 struct ustat {
        __kernel_daddr_t        f_tfree;
        __kernel_ino_t          f_tinode;
index 9f77f50d814317409f1ed02ce73372bfb428c99f..1dab0ac3f79782a129dc5736ac8d838ee9d4ba01 100644 (file)
@@ -1,5 +1,5 @@
 
-obj-y := handle.o manage.o spurious.o
+obj-y := handle.o manage.o spurious.o resend.o chip.o
 obj-$(CONFIG_GENERIC_IRQ_PROBE) += autoprobe.o
 obj-$(CONFIG_PROC_FS) += proc.o
 obj-$(CONFIG_GENERIC_PENDING_IRQ) += migration.o
index 3467097ca61ae476a74a7eb1519950acc9a8ebcf..533068cfb607fad10202210b916909efd314cbb7 100644 (file)
 #include <linux/interrupt.h>
 #include <linux/delay.h>
 
+#include "internals.h"
+
 /*
  * Autodetection depends on the fact that any interrupt that
  * comes in on to an unassigned handler will get stuck with
  * "IRQ_WAITING" cleared and the interrupt disabled.
  */
-static DECLARE_MUTEX(probe_sem);
+static DEFINE_MUTEX(probing_active);
 
 /**
  *     probe_irq_on    - begin an interrupt autodetect
@@ -27,11 +29,11 @@ static DECLARE_MUTEX(probe_sem);
  */
 unsigned long probe_irq_on(void)
 {
-       unsigned long val;
-       irq_desc_t *desc;
+       struct irq_desc *desc;
+       unsigned long mask;
        unsigned int i;
 
-       down(&probe_sem);
+       mutex_lock(&probing_active);
        /*
         * something may have generated an irq long ago and we want to
         * flush such a longstanding irq before considering it as spurious.
@@ -40,8 +42,21 @@ unsigned long probe_irq_on(void)
                desc = irq_desc + i;
 
                spin_lock_irq(&desc->lock);
-               if (!irq_desc[i].action)
-                       irq_desc[i].handler->startup(i);
+               if (!desc->action && !(desc->status & IRQ_NOPROBE)) {
+                       /*
+                        * An old-style architecture might still have
+                        * the handle_bad_irq handler there:
+                        */
+                       compat_irq_chip_set_default_handler(desc);
+
+                       /*
+                        * Some chips need to know about probing in
+                        * progress:
+                        */
+                       if (desc->chip->set_type)
+                               desc->chip->set_type(i, IRQ_TYPE_PROBE);
+                       desc->chip->startup(i);
+               }
                spin_unlock_irq(&desc->lock);
        }
 
@@ -57,9 +72,9 @@ unsigned long probe_irq_on(void)
                desc = irq_desc + i;
 
                spin_lock_irq(&desc->lock);
-               if (!desc->action) {
+               if (!desc->action && !(desc->status & IRQ_NOPROBE)) {
                        desc->status |= IRQ_AUTODETECT | IRQ_WAITING;
-                       if (desc->handler->startup(i))
+                       if (desc->chip->startup(i))
                                desc->status |= IRQ_PENDING;
                }
                spin_unlock_irq(&desc->lock);
@@ -73,11 +88,11 @@ unsigned long probe_irq_on(void)
        /*
         * Now filter out any obviously spurious interrupts
         */
-       val = 0;
+       mask = 0;
        for (i = 0; i < NR_IRQS; i++) {
-               irq_desc_t *desc = irq_desc + i;
                unsigned int status;
 
+               desc = irq_desc + i;
                spin_lock_irq(&desc->lock);
                status = desc->status;
 
@@ -85,17 +100,16 @@ unsigned long probe_irq_on(void)
                        /* It triggered already - consider it spurious. */
                        if (!(status & IRQ_WAITING)) {
                                desc->status = status & ~IRQ_AUTODETECT;
-                               desc->handler->shutdown(i);
+                               desc->chip->shutdown(i);
                        } else
                                if (i < 32)
-                                       val |= 1 << i;
+                                       mask |= 1 << i;
                }
                spin_unlock_irq(&desc->lock);
        }
 
-       return val;
+       return mask;
 }
-
 EXPORT_SYMBOL(probe_irq_on);
 
 /**
@@ -117,7 +131,7 @@ unsigned int probe_irq_mask(unsigned long val)
 
        mask = 0;
        for (i = 0; i < NR_IRQS; i++) {
-               irq_desc_t *desc = irq_desc + i;
+               struct irq_desc *desc = irq_desc + i;
                unsigned int status;
 
                spin_lock_irq(&desc->lock);
@@ -128,11 +142,11 @@ unsigned int probe_irq_mask(unsigned long val)
                                mask |= 1 << i;
 
                        desc->status = status & ~IRQ_AUTODETECT;
-                       desc->handler->shutdown(i);
+                       desc->chip->shutdown(i);
                }
                spin_unlock_irq(&desc->lock);
        }
-       up(&probe_sem);
+       mutex_unlock(&probing_active);
 
        return mask & val;
 }
@@ -160,7 +174,7 @@ int probe_irq_off(unsigned long val)
        int i, irq_found = 0, nr_irqs = 0;
 
        for (i = 0; i < NR_IRQS; i++) {
-               irq_desc_t *desc = irq_desc + i;
+               struct irq_desc *desc = irq_desc + i;
                unsigned int status;
 
                spin_lock_irq(&desc->lock);
@@ -173,16 +187,16 @@ int probe_irq_off(unsigned long val)
                                nr_irqs++;
                        }
                        desc->status = status & ~IRQ_AUTODETECT;
-                       desc->handler->shutdown(i);
+                       desc->chip->shutdown(i);
                }
                spin_unlock_irq(&desc->lock);
        }
-       up(&probe_sem);
+       mutex_unlock(&probing_active);
 
        if (nr_irqs > 1)
                irq_found = -irq_found;
+
        return irq_found;
 }
-
 EXPORT_SYMBOL(probe_irq_off);
 
diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c
new file mode 100644 (file)
index 0000000..4a0952d
--- /dev/null
@@ -0,0 +1,525 @@
+/*
+ * linux/kernel/irq/chip.c
+ *
+ * Copyright (C) 1992, 1998-2006 Linus Torvalds, Ingo Molnar
+ * Copyright (C) 2005-2006, Thomas Gleixner, Russell King
+ *
+ * This file contains the core interrupt handling code, for irq-chip
+ * based architectures.
+ *
+ * Detailed information is available in Documentation/DocBook/genericirq
+ */
+
+#include <linux/irq.h>
+#include <linux/module.h>
+#include <linux/interrupt.h>
+#include <linux/kernel_stat.h>
+
+#include "internals.h"
+
+/**
+ *     set_irq_chip - set the irq chip for an irq
+ *     @irq:   irq number
+ *     @chip:  pointer to irq chip description structure
+ */
+int set_irq_chip(unsigned int irq, struct irq_chip *chip)
+{
+       struct irq_desc *desc;
+       unsigned long flags;
+
+       if (irq >= NR_IRQS) {
+               printk(KERN_ERR "Trying to install chip for IRQ%d\n", irq);
+               WARN_ON(1);
+               return -EINVAL;
+       }
+
+       if (!chip)
+               chip = &no_irq_chip;
+
+       desc = irq_desc + irq;
+       spin_lock_irqsave(&desc->lock, flags);
+       irq_chip_set_defaults(chip);
+       desc->chip = chip;
+       /*
+        * For compatibility only:
+        */
+       desc->chip = chip;
+       spin_unlock_irqrestore(&desc->lock, flags);
+
+       return 0;
+}
+EXPORT_SYMBOL(set_irq_chip);
+
+/**
+ *     set_irq_type - set the irq type for an irq
+ *     @irq:   irq number
+ *     @type:  interrupt type - see include/linux/interrupt.h
+ */
+int set_irq_type(unsigned int irq, unsigned int type)
+{
+       struct irq_desc *desc;
+       unsigned long flags;
+       int ret = -ENXIO;
+
+       if (irq >= NR_IRQS) {
+               printk(KERN_ERR "Trying to set irq type for IRQ%d\n", irq);
+               return -ENODEV;
+       }
+
+       desc = irq_desc + irq;
+       if (desc->chip->set_type) {
+               spin_lock_irqsave(&desc->lock, flags);
+               ret = desc->chip->set_type(irq, type);
+               spin_unlock_irqrestore(&desc->lock, flags);
+       }
+       return ret;
+}
+EXPORT_SYMBOL(set_irq_type);
+
+/**
+ *     set_irq_data - set irq type data for an irq
+ *     @irq:   Interrupt number
+ *     @data:  Pointer to interrupt specific data
+ *
+ *     Set the hardware irq controller data for an irq
+ */
+int set_irq_data(unsigned int irq, void *data)
+{
+       struct irq_desc *desc;
+       unsigned long flags;
+
+       if (irq >= NR_IRQS) {
+               printk(KERN_ERR
+                      "Trying to install controller data for IRQ%d\n", irq);
+               return -EINVAL;
+       }
+
+       desc = irq_desc + irq;
+       spin_lock_irqsave(&desc->lock, flags);
+       desc->handler_data = data;
+       spin_unlock_irqrestore(&desc->lock, flags);
+       return 0;
+}
+EXPORT_SYMBOL(set_irq_data);
+
+/**
+ *     set_irq_chip_data - set irq chip data for an irq
+ *     @irq:   Interrupt number
+ *     @data:  Pointer to chip specific data
+ *
+ *     Set the hardware irq chip data for an irq
+ */
+int set_irq_chip_data(unsigned int irq, void *data)
+{
+       struct irq_desc *desc = irq_desc + irq;
+       unsigned long flags;
+
+       if (irq >= NR_IRQS || !desc->chip) {
+               printk(KERN_ERR "BUG: bad set_irq_chip_data(IRQ#%d)\n", irq);
+               return -EINVAL;
+       }
+
+       spin_lock_irqsave(&desc->lock, flags);
+       desc->chip_data = data;
+       spin_unlock_irqrestore(&desc->lock, flags);
+
+       return 0;
+}
+EXPORT_SYMBOL(set_irq_chip_data);
+
+/*
+ * default enable function
+ */
+static void default_enable(unsigned int irq)
+{
+       struct irq_desc *desc = irq_desc + irq;
+
+       desc->chip->unmask(irq);
+       desc->status &= ~IRQ_MASKED;
+}
+
+/*
+ * default disable function
+ */
+static void default_disable(unsigned int irq)
+{
+       struct irq_desc *desc = irq_desc + irq;
+
+       if (!(desc->status & IRQ_DELAYED_DISABLE))
+               irq_desc[irq].chip->mask(irq);
+}
+
+/*
+ * default startup function
+ */
+static unsigned int default_startup(unsigned int irq)
+{
+       irq_desc[irq].chip->enable(irq);
+
+       return 0;
+}
+
+/*
+ * Fixup enable/disable function pointers
+ */
+void irq_chip_set_defaults(struct irq_chip *chip)
+{
+       if (!chip->enable)
+               chip->enable = default_enable;
+       if (!chip->disable)
+               chip->disable = default_disable;
+       if (!chip->startup)
+               chip->startup = default_startup;
+       if (!chip->shutdown)
+               chip->shutdown = chip->disable;
+       if (!chip->name)
+               chip->name = chip->typename;
+}
+
+static inline void mask_ack_irq(struct irq_desc *desc, int irq)
+{
+       if (desc->chip->mask_ack)
+               desc->chip->mask_ack(irq);
+       else {
+               desc->chip->mask(irq);
+               desc->chip->ack(irq);
+       }
+}
+
+/**
+ *     handle_simple_irq - Simple and software-decoded IRQs.
+ *     @irq:   the interrupt number
+ *     @desc:  the interrupt description structure for this irq
+ *     @regs:  pointer to a register structure
+ *
+ *     Simple interrupts are either sent from a demultiplexing interrupt
+ *     handler or come from hardware, where no interrupt hardware control
+ *     is necessary.
+ *
+ *     Note: The caller is expected to handle the ack, clear, mask and
+ *     unmask issues if necessary.
+ */
+void fastcall
+handle_simple_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs)
+{
+       struct irqaction *action;
+       irqreturn_t action_ret;
+       const unsigned int cpu = smp_processor_id();
+
+       spin_lock(&desc->lock);
+
+       if (unlikely(desc->status & IRQ_INPROGRESS))
+               goto out_unlock;
+       desc->status &= ~(IRQ_REPLAY | IRQ_WAITING);
+       kstat_cpu(cpu).irqs[irq]++;
+
+       action = desc->action;
+       if (unlikely(!action || (desc->status & IRQ_DISABLED)))
+               goto out_unlock;
+
+       desc->status |= IRQ_INPROGRESS;
+       spin_unlock(&desc->lock);
+
+       action_ret = handle_IRQ_event(irq, regs, action);
+       if (!noirqdebug)
+               note_interrupt(irq, desc, action_ret, regs);
+
+       spin_lock(&desc->lock);
+       desc->status &= ~IRQ_INPROGRESS;
+out_unlock:
+       spin_unlock(&desc->lock);
+}
+
+/**
+ *     handle_level_irq - Level type irq handler
+ *     @irq:   the interrupt number
+ *     @desc:  the interrupt description structure for this irq
+ *     @regs:  pointer to a register structure
+ *
+ *     Level type interrupts are active as long as the hardware line has
+ *     the active level. This may require to mask the interrupt and unmask
+ *     it after the associated handler has acknowledged the device, so the
+ *     interrupt line is back to inactive.
+ */
+void fastcall
+handle_level_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs)
+{
+       unsigned int cpu = smp_processor_id();
+       struct irqaction *action;
+       irqreturn_t action_ret;
+
+       spin_lock(&desc->lock);
+       mask_ack_irq(desc, irq);
+
+       if (unlikely(desc->status & IRQ_INPROGRESS))
+               goto out;
+       desc->status &= ~(IRQ_REPLAY | IRQ_WAITING);
+       kstat_cpu(cpu).irqs[irq]++;
+
+       /*
+        * If its disabled or no action available
+        * keep it masked and get out of here
+        */
+       action = desc->action;
+       if (unlikely(!action || (desc->status & IRQ_DISABLED)))
+               goto out;
+
+       desc->status |= IRQ_INPROGRESS;
+       spin_unlock(&desc->lock);
+
+       action_ret = handle_IRQ_event(irq, regs, action);
+       if (!noirqdebug)
+               note_interrupt(irq, desc, action_ret, regs);
+
+       spin_lock(&desc->lock);
+       desc->status &= ~IRQ_INPROGRESS;
+out:
+       if (!(desc->status & IRQ_DISABLED) && desc->chip->unmask)
+               desc->chip->unmask(irq);
+       spin_unlock(&desc->lock);
+}
+
+/**
+ *     handle_fasteoi_irq - irq handler for transparent controllers
+ *     @irq:   the interrupt number
+ *     @desc:  the interrupt description structure for this irq
+ *     @regs:  pointer to a register structure
+ *
+ *     Only a single callback will be issued to the chip: an ->eoi()
+ *     call when the interrupt has been serviced. This enables support
+ *     for modern forms of interrupt handlers, which handle the flow
+ *     details in hardware, transparently.
+ */
+void fastcall
+handle_fasteoi_irq(unsigned int irq, struct irq_desc *desc,
+                  struct pt_regs *regs)
+{
+       unsigned int cpu = smp_processor_id();
+       struct irqaction *action;
+       irqreturn_t action_ret;
+
+       spin_lock(&desc->lock);
+
+       if (unlikely(desc->status & IRQ_INPROGRESS))
+               goto out;
+
+       desc->status &= ~(IRQ_REPLAY | IRQ_WAITING);
+       kstat_cpu(cpu).irqs[irq]++;
+
+       /*
+        * If its disabled or no action available
+        * keep it masked and get out of here
+        */
+       action = desc->action;
+       if (unlikely(!action || (desc->status & IRQ_DISABLED))) {
+               desc->status |= IRQ_PENDING;
+               goto out;
+       }
+
+       desc->status |= IRQ_INPROGRESS;
+       desc->status &= ~IRQ_PENDING;
+       spin_unlock(&desc->lock);
+
+       action_ret = handle_IRQ_event(irq, regs, action);
+       if (!noirqdebug)
+               note_interrupt(irq, desc, action_ret, regs);
+
+       spin_lock(&desc->lock);
+       desc->status &= ~IRQ_INPROGRESS;
+out:
+       desc->chip->eoi(irq);
+
+       spin_unlock(&desc->lock);
+}
+
+/**
+ *     handle_edge_irq - edge type IRQ handler
+ *     @irq:   the interrupt number
+ *     @desc:  the interrupt description structure for this irq
+ *     @regs:  pointer to a register structure
+ *
+ *     Interrupt occures on the falling and/or rising edge of a hardware
+ *     signal. The occurence is latched into the irq controller hardware
+ *     and must be acked in order to be reenabled. After the ack another
+ *     interrupt can happen on the same source even before the first one
+ *     is handled by the assosiacted event handler. If this happens it
+ *     might be necessary to disable (mask) the interrupt depending on the
+ *     controller hardware. This requires to reenable the interrupt inside
+ *     of the loop which handles the interrupts which have arrived while
+ *     the handler was running. If all pending interrupts are handled, the
+ *     loop is left.
+ */
+void fastcall
+handle_edge_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs)
+{
+       const unsigned int cpu = smp_processor_id();
+
+       spin_lock(&desc->lock);
+
+       desc->status &= ~(IRQ_REPLAY | IRQ_WAITING);
+
+       /*
+        * If we're currently running this IRQ, or its disabled,
+        * we shouldn't process the IRQ. Mark it pending, handle
+        * the necessary masking and go out
+        */
+       if (unlikely((desc->status & (IRQ_INPROGRESS | IRQ_DISABLED)) ||
+                   !desc->action)) {
+               desc->status |= (IRQ_PENDING | IRQ_MASKED);
+               mask_ack_irq(desc, irq);
+               goto out_unlock;
+       }
+
+       kstat_cpu(cpu).irqs[irq]++;
+
+       /* Start handling the irq */
+       desc->chip->ack(irq);
+
+       /* Mark the IRQ currently in progress.*/
+       desc->status |= IRQ_INPROGRESS;
+
+       do {
+               struct irqaction *action = desc->action;
+               irqreturn_t action_ret;
+
+               if (unlikely(!action)) {
+                       desc->chip->mask(irq);
+                       goto out_unlock;
+               }
+
+               /*
+                * When another irq arrived while we were handling
+                * one, we could have masked the irq.
+                * Renable it, if it was not disabled in meantime.
+                */
+               if (unlikely((desc->status &
+                              (IRQ_PENDING | IRQ_MASKED | IRQ_DISABLED)) ==
+                             (IRQ_PENDING | IRQ_MASKED))) {
+                       desc->chip->unmask(irq);
+                       desc->status &= ~IRQ_MASKED;
+               }
+
+               desc->status &= ~IRQ_PENDING;
+               spin_unlock(&desc->lock);
+               action_ret = handle_IRQ_event(irq, regs, action);
+               if (!noirqdebug)
+                       note_interrupt(irq, desc, action_ret, regs);
+               spin_lock(&desc->lock);
+
+       } while ((desc->status & (IRQ_PENDING | IRQ_DISABLED)) == IRQ_PENDING);
+
+       desc->status &= ~IRQ_INPROGRESS;
+out_unlock:
+       spin_unlock(&desc->lock);
+}
+
+#ifdef CONFIG_SMP
+/**
+ *     handle_percpu_IRQ - Per CPU local irq handler
+ *     @irq:   the interrupt number
+ *     @desc:  the interrupt description structure for this irq
+ *     @regs:  pointer to a register structure
+ *
+ *     Per CPU interrupts on SMP machines without locking requirements
+ */
+void fastcall
+handle_percpu_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs)
+{
+       irqreturn_t action_ret;
+
+       kstat_this_cpu.irqs[irq]++;
+
+       if (desc->chip->ack)
+               desc->chip->ack(irq);
+
+       action_ret = handle_IRQ_event(irq, regs, desc->action);
+       if (!noirqdebug)
+               note_interrupt(irq, desc, action_ret, regs);
+
+       if (desc->chip->eoi)
+               desc->chip->eoi(irq);
+}
+
+#endif /* CONFIG_SMP */
+
+void
+__set_irq_handler(unsigned int irq,
+                 void fastcall (*handle)(unsigned int, irq_desc_t *,
+                                         struct pt_regs *),
+                 int is_chained)
+{
+       struct irq_desc *desc;
+       unsigned long flags;
+
+       if (irq >= NR_IRQS) {
+               printk(KERN_ERR
+                      "Trying to install type control for IRQ%d\n", irq);
+               return;
+       }
+
+       desc = irq_desc + irq;
+
+       if (!handle)
+               handle = handle_bad_irq;
+
+       if (is_chained && desc->chip == &no_irq_chip)
+               printk(KERN_WARNING "Trying to install "
+                      "chained interrupt type for IRQ%d\n", irq);
+
+       spin_lock_irqsave(&desc->lock, flags);
+
+       /* Uninstall? */
+       if (handle == handle_bad_irq) {
+               if (desc->chip != &no_irq_chip) {
+                       desc->chip->mask(irq);
+                       desc->chip->ack(irq);
+               }
+               desc->status |= IRQ_DISABLED;
+               desc->depth = 1;
+       }
+       desc->handle_irq = handle;
+
+       if (handle != handle_bad_irq && is_chained) {
+               desc->status &= ~IRQ_DISABLED;
+               desc->status |= IRQ_NOREQUEST | IRQ_NOPROBE;
+               desc->depth = 0;
+               desc->chip->unmask(irq);
+       }
+       spin_unlock_irqrestore(&desc->lock, flags);
+}
+
+void
+set_irq_chip_and_handler(unsigned int irq, struct irq_chip *chip,
+                        void fastcall (*handle)(unsigned int,
+                                                struct irq_desc *,
+                                                struct pt_regs *))
+{
+       set_irq_chip(irq, chip);
+       __set_irq_handler(irq, handle, 0);
+}
+
+/*
+ * Get a descriptive string for the highlevel handler, for
+ * /proc/interrupts output:
+ */
+const char *
+handle_irq_name(void fastcall (*handle)(unsigned int, struct irq_desc *,
+                                       struct pt_regs *))
+{
+       if (handle == handle_level_irq)
+               return "level  ";
+       if (handle == handle_fasteoi_irq)
+               return "fasteoi";
+       if (handle == handle_edge_irq)
+               return "edge   ";
+       if (handle == handle_simple_irq)
+               return "simple ";
+#ifdef CONFIG_SMP
+       if (handle == handle_percpu_irq)
+               return "percpu ";
+#endif
+       if (handle == handle_bad_irq)
+               return "bad    ";
+
+       return NULL;
+}
index 0f6530117105c6f000668c3bcae8ca8be1b6e4bd..5a360dd4331b0505a6f4e54c0c26317f23d3c189 100644 (file)
@@ -1,9 +1,13 @@
 /*
  * linux/kernel/irq/handle.c
  *
- * Copyright (C) 1992, 1998-2004 Linus Torvalds, Ingo Molnar
+ * Copyright (C) 1992, 1998-2006 Linus Torvalds, Ingo Molnar
+ * Copyright (C) 2005-2006, Thomas Gleixner, Russell King
  *
  * This file contains the core interrupt handling code.
+ *
+ * Detailed information is available in Documentation/DocBook/genericirq
+ *
  */
 
 #include <linux/irq.h>
 
 #include "internals.h"
 
+/**
+ * handle_bad_irq - handle spurious and unhandled irqs
+ */
+void fastcall
+handle_bad_irq(unsigned int irq, struct irq_desc *desc, struct pt_regs *regs)
+{
+       print_irq_desc(irq, desc);
+       kstat_this_cpu.irqs[irq]++;
+       ack_bad_irq(irq);
+}
+
 /*
  * Linux has a controller-independent interrupt architecture.
  * Every controller has a 'controller-template', that is used
  * by the main code to do the right thing. Each driver-visible
- * interrupt source is transparently wired to the apropriate
+ * interrupt source is transparently wired to the appropriate
  * controller. Thus drivers need not be aware of the
  * interrupt-controller.
  *
  *
  * Controller mappings for all interrupt sources:
  */
-irq_desc_t irq_desc[NR_IRQS] __cacheline_aligned = {
+struct irq_desc irq_desc[NR_IRQS] __cacheline_aligned = {
        [0 ... NR_IRQS-1] = {
                .status = IRQ_DISABLED,
-               .handler = &no_irq_type,
-               .lock = SPIN_LOCK_UNLOCKED
+               .chip = &no_irq_chip,
+               .handle_irq = handle_bad_irq,
+               .depth = 1,
+               .lock = SPIN_LOCK_UNLOCKED,
+#ifdef CONFIG_SMP
+               .affinity = CPU_MASK_ALL
+#endif
        }
 };
 
 /*
- * Generic 'no controller' code
+ * What should we do if we get a hw irq event on an illegal vector?
+ * Each architecture has to answer this themself.
  */
-static void end_none(unsigned int irq) { }
-static void enable_none(unsigned int irq) { }
-static void disable_none(unsigned int irq) { }
-static void shutdown_none(unsigned int irq) { }
-static unsigned int startup_none(unsigned int irq) { return 0; }
-
-static void ack_none(unsigned int irq)
+static void ack_bad(unsigned int irq)
 {
-       /*
-        * 'what should we do if we get a hw irq event on an illegal vector'.
-        * each architecture has to answer this themself.
-        */
+       print_irq_desc(irq, irq_desc + irq);
        ack_bad_irq(irq);
 }
 
-struct hw_interrupt_type no_irq_type = {
-       .typename =     "none",
-       .startup =      startup_none,
-       .shutdown =     shutdown_none,
-       .enable =       enable_none,
-       .disable =      disable_none,
-       .ack =          ack_none,
-       .end =          end_none,
-       .set_affinity = NULL
+/*
+ * NOP functions
+ */
+static void noop(unsigned int irq)
+{
+}
+
+static unsigned int noop_ret(unsigned int irq)
+{
+       return 0;
+}
+
+/*
+ * Generic no controller implementation
+ */
+struct irq_chip no_irq_chip = {
+       .name           = "none",
+       .startup        = noop_ret,
+       .shutdown       = noop,
+       .enable         = noop,
+       .disable        = noop,
+       .ack            = ack_bad,
+       .end            = noop,
 };
 
 /*
@@ -73,11 +99,16 @@ irqreturn_t no_action(int cpl, void *dev_id, struct pt_regs *regs)
        return IRQ_NONE;
 }
 
-/*
- * Have got an event to handle:
+/**
+ * handle_IRQ_event - irq action chain handler
+ * @irq:       the interrupt number
+ * @regs:      pointer to a register structure
+ * @action:    the interrupt action chain for this irq
+ *
+ * Handles the action chain of an irq event
  */
-fastcall irqreturn_t handle_IRQ_event(unsigned int irq, struct pt_regs *regs,
-                               struct irqaction *action)
+irqreturn_t handle_IRQ_event(unsigned int irq, struct pt_regs *regs,
+                            struct irqaction *action)
 {
        irqreturn_t ret, retval = IRQ_NONE;
        unsigned int status = 0;
@@ -100,15 +131,22 @@ fastcall irqreturn_t handle_IRQ_event(unsigned int irq, struct pt_regs *regs,
        return retval;
 }
 
-/*
- * do_IRQ handles all normal device IRQ's (the special
+/**
+ * __do_IRQ - original all in one highlevel IRQ handler
+ * @irq:       the interrupt number
+ * @regs:      pointer to a register structure
+ *
+ * __do_IRQ handles all normal device IRQ's (the special
  * SMP cross-CPU interrupts have their own specific
  * handlers).
+ *
+ * This is the original x86 implementation which is used for every
+ * interrupt type.
  */
 fastcall unsigned int __do_IRQ(unsigned int irq, struct pt_regs *regs)
 {
-       irq_desc_t *desc = irq_desc + irq;
-       struct irqaction * action;
+       struct irq_desc *desc = irq_desc + irq;
+       struct irqaction *action;
        unsigned int status;
 
        kstat_this_cpu.irqs[irq]++;
@@ -118,16 +156,16 @@ fastcall unsigned int __do_IRQ(unsigned int irq, struct pt_regs *regs)
                /*
                 * No locking required for CPU-local interrupts:
                 */
-               if (desc->handler->ack)
-                       desc->handler->ack(irq);
+               if (desc->chip->ack)
+                       desc->chip->ack(irq);
                action_ret = handle_IRQ_event(irq, regs, desc->action);
-               desc->handler->end(irq);
+               desc->chip->end(irq);
                return 1;
        }
 
        spin_lock(&desc->lock);
-       if (desc->handler->ack)
-               desc->handler->ack(irq);
+       if (desc->chip->ack)
+               desc->chip->ack(irq);
        /*
         * REPLAY is when Linux resends an IRQ that was dropped earlier
         * WAITING is used by probe to mark irqs that are being tested
@@ -187,7 +225,7 @@ out:
         * The ->end() handler has to deal with interrupts which got
         * disabled while the handler was running.
         */
-       desc->handler->end(irq);
+       desc->chip->end(irq);
        spin_unlock(&desc->lock);
 
        return 1;
index 46feba630266eedb5ac55b83d5dfdbf86b3c7d0c..08a849a224475102084ca807de6861b6ab7286b5 100644 (file)
@@ -4,6 +4,12 @@
 
 extern int noirqdebug;
 
+/* Set default functions for irq_chip structures: */
+extern void irq_chip_set_defaults(struct irq_chip *chip);
+
+/* Set default handler: */
+extern void compat_irq_chip_set_default_handler(struct irq_desc *desc);
+
 #ifdef CONFIG_PROC_FS
 extern void register_irq_proc(unsigned int irq);
 extern void register_handler_proc(unsigned int irq, struct irqaction *action);
@@ -16,3 +22,43 @@ static inline void unregister_handler_proc(unsigned int irq,
                                           struct irqaction *action) { }
 #endif
 
+/*
+ * Debugging printout:
+ */
+
+#include <linux/kallsyms.h>
+
+#define P(f) if (desc->status & f) printk("%14s set\n", #f)
+
+static inline void print_irq_desc(unsigned int irq, struct irq_desc *desc)
+{
+       printk("irq %d, desc: %p, depth: %d, count: %d, unhandled: %d\n",
+               irq, desc, desc->depth, desc->irq_count, desc->irqs_unhandled);
+       printk("->handle_irq():  %p, ", desc->handle_irq);
+       print_symbol("%s\n", (unsigned long)desc->handle_irq);
+       printk("->chip(): %p, ", desc->chip);
+       print_symbol("%s\n", (unsigned long)desc->chip);
+       printk("->action(): %p\n", desc->action);
+       if (desc->action) {
+               printk("->action->handler(): %p, ", desc->action->handler);
+               print_symbol("%s\n", (unsigned long)desc->action->handler);
+       }
+
+       P(IRQ_INPROGRESS);
+       P(IRQ_DISABLED);
+       P(IRQ_PENDING);
+       P(IRQ_REPLAY);
+       P(IRQ_AUTODETECT);
+       P(IRQ_WAITING);
+       P(IRQ_LEVEL);
+       P(IRQ_MASKED);
+#ifdef CONFIG_IRQ_PER_CPU
+       P(IRQ_PER_CPU);
+#endif
+       P(IRQ_NOPROBE);
+       P(IRQ_NOREQUEST);
+       P(IRQ_NOAUTOEN);
+}
+
+#undef P
+
index 1279e3499534d490212053812a64671a59b3132d..9eb1d518ee1c8dc8da68f7903cd207482352e8fa 100644 (file)
@@ -1,7 +1,8 @@
 /*
  * linux/kernel/irq/manage.c
  *
- * Copyright (C) 1992, 1998-2004 Linus Torvalds, Ingo Molnar
+ * Copyright (C) 1992, 1998-2006 Linus Torvalds, Ingo Molnar
+ * Copyright (C) 2005-2006 Thomas Gleixner
  *
  * This file contains driver APIs to the irq subsystem.
  */
 
 #ifdef CONFIG_SMP
 
-cpumask_t irq_affinity[NR_IRQS] = { [0 ... NR_IRQS-1] = CPU_MASK_ALL };
-
-#if defined (CONFIG_GENERIC_PENDING_IRQ) || defined (CONFIG_IRQBALANCE)
-cpumask_t __cacheline_aligned pending_irq_cpumask[NR_IRQS];
-#endif
-
 /**
  *     synchronize_irq - wait for pending IRQ handlers (on other CPUs)
  *     @irq: interrupt number to wait for
@@ -42,7 +37,6 @@ void synchronize_irq(unsigned int irq)
        while (desc->status & IRQ_INPROGRESS)
                cpu_relax();
 }
-
 EXPORT_SYMBOL(synchronize_irq);
 
 #endif
@@ -60,7 +54,7 @@ EXPORT_SYMBOL(synchronize_irq);
  */
 void disable_irq_nosync(unsigned int irq)
 {
-       irq_desc_t *desc = irq_desc + irq;
+       struct irq_desc *desc = irq_desc + irq;
        unsigned long flags;
 
        if (irq >= NR_IRQS)
@@ -69,11 +63,10 @@ void disable_irq_nosync(unsigned int irq)
        spin_lock_irqsave(&desc->lock, flags);
        if (!desc->depth++) {
                desc->status |= IRQ_DISABLED;
-               desc->handler->disable(irq);
+               desc->chip->disable(irq);
        }
        spin_unlock_irqrestore(&desc->lock, flags);
 }
-
 EXPORT_SYMBOL(disable_irq_nosync);
 
 /**
@@ -90,7 +83,7 @@ EXPORT_SYMBOL(disable_irq_nosync);
  */
 void disable_irq(unsigned int irq)
 {
-       irq_desc_t *desc = irq_desc + irq;
+       struct irq_desc *desc = irq_desc + irq;
 
        if (irq >= NR_IRQS)
                return;
@@ -99,7 +92,6 @@ void disable_irq(unsigned int irq)
        if (desc->action)
                synchronize_irq(irq);
 }
-
 EXPORT_SYMBOL(disable_irq);
 
 /**
@@ -114,7 +106,7 @@ EXPORT_SYMBOL(disable_irq);
  */
 void enable_irq(unsigned int irq)
 {
-       irq_desc_t *desc = irq_desc + irq;
+       struct irq_desc *desc = irq_desc + irq;
        unsigned long flags;
 
        if (irq >= NR_IRQS)
@@ -123,17 +115,15 @@ void enable_irq(unsigned int irq)
        spin_lock_irqsave(&desc->lock, flags);
        switch (desc->depth) {
        case 0:
+               printk(KERN_WARNING "Unablanced enable_irq(%d)\n", irq);
                WARN_ON(1);
                break;
        case 1: {
                unsigned int status = desc->status & ~IRQ_DISABLED;
 
-               desc->status = status;
-               if ((status & (IRQ_PENDING | IRQ_REPLAY)) == IRQ_PENDING) {
-                       desc->status = status | IRQ_REPLAY;
-                       hw_resend_irq(desc->handler,irq);
-               }
-               desc->handler->enable(irq);
+               /* Prevent probing on this irq: */
+               desc->status = status | IRQ_NOPROBE;
+               check_irq_resend(desc, irq);
                /* fall-through */
        }
        default:
@@ -141,9 +131,29 @@ void enable_irq(unsigned int irq)
        }
        spin_unlock_irqrestore(&desc->lock, flags);
 }
-
 EXPORT_SYMBOL(enable_irq);
 
+/**
+ *     set_irq_wake - control irq power management wakeup
+ *     @irq:   interrupt to control
+ *     @on:    enable/disable power management wakeup
+ *
+ *     Enable/disable power management wakeup mode
+ */
+int set_irq_wake(unsigned int irq, unsigned int on)
+{
+       struct irq_desc *desc = irq_desc + irq;
+       unsigned long flags;
+       int ret = -ENXIO;
+
+       spin_lock_irqsave(&desc->lock, flags);
+       if (desc->chip->set_wake)
+               ret = desc->chip->set_wake(irq, on);
+       spin_unlock_irqrestore(&desc->lock, flags);
+       return ret;
+}
+EXPORT_SYMBOL(set_irq_wake);
+
 /*
  * Internal function that tells the architecture code whether a
  * particular irq has been exclusively allocated or is available
@@ -153,7 +163,7 @@ int can_request_irq(unsigned int irq, unsigned long irqflags)
 {
        struct irqaction *action;
 
-       if (irq >= NR_IRQS)
+       if (irq >= NR_IRQS || irq_desc[irq].status & IRQ_NOREQUEST)
                return 0;
 
        action = irq_desc[irq].action;
@@ -164,11 +174,22 @@ int can_request_irq(unsigned int irq, unsigned long irqflags)
        return !action;
 }
 
+void compat_irq_chip_set_default_handler(struct irq_desc *desc)
+{
+       /*
+        * If the architecture still has not overriden
+        * the flow handler then zap the default. This
+        * should catch incorrect flow-type setting.
+        */
+       if (desc->handle_irq == &handle_bad_irq)
+               desc->handle_irq = NULL;
+}
+
 /*
  * Internal function to register an irqaction - typically used to
  * allocate special interrupts that are part of the architecture.
  */
-int setup_irq(unsigned int irq, struct irqaction * new)
+int setup_irq(unsigned int irq, struct irqaction *new)
 {
        struct irq_desc *desc = irq_desc + irq;
        struct irqaction *old, **p;
@@ -178,7 +199,7 @@ int setup_irq(unsigned int irq, struct irqaction * new)
        if (irq >= NR_IRQS)
                return -EINVAL;
 
-       if (desc->handler == &no_irq_type)
+       if (desc->chip == &no_irq_chip)
                return -ENOSYS;
        /*
         * Some drivers like serial.c use request_irq() heavily,
@@ -200,14 +221,21 @@ int setup_irq(unsigned int irq, struct irqaction * new)
        /*
         * The following block of code has to be executed atomically
         */
-       spin_lock_irqsave(&desc->lock,flags);
+       spin_lock_irqsave(&desc->lock, flags);
        p = &desc->action;
-       if ((old = *p) != NULL) {
-               /* Can't share interrupts unless both agree to */
-               if (!(old->flags & new->flags & SA_SHIRQ))
+       old = *p;
+       if (old) {
+               /*
+                * Can't share interrupts unless both agree to and are
+                * the same type (level, edge, polarity). So both flag
+                * fields must have SA_SHIRQ set and the bits which
+                * set the trigger type must match.
+                */
+               if (!((old->flags & new->flags) & SA_SHIRQ) ||
+                   ((old->flags ^ new->flags) & SA_TRIGGER_MASK))
                        goto mismatch;
 
-#if defined(ARCH_HAS_IRQ_PER_CPU) && defined(SA_PERCPU_IRQ)
+#if defined(CONFIG_IRQ_PER_CPU) && defined(SA_PERCPU_IRQ)
                /* All handlers must agree on per-cpuness */
                if ((old->flags & IRQ_PER_CPU) != (new->flags & IRQ_PER_CPU))
                        goto mismatch;
@@ -222,20 +250,44 @@ int setup_irq(unsigned int irq, struct irqaction * new)
        }
 
        *p = new;
-#if defined(ARCH_HAS_IRQ_PER_CPU) && defined(SA_PERCPU_IRQ)
+#if defined(CONFIG_IRQ_PER_CPU) && defined(SA_PERCPU_IRQ)
        if (new->flags & SA_PERCPU_IRQ)
                desc->status |= IRQ_PER_CPU;
 #endif
        if (!shared) {
-               desc->depth = 0;
-               desc->status &= ~(IRQ_DISABLED | IRQ_AUTODETECT |
-                                 IRQ_WAITING | IRQ_INPROGRESS);
-               if (desc->handler->startup)
-                       desc->handler->startup(irq);
-               else
-                       desc->handler->enable(irq);
+               irq_chip_set_defaults(desc->chip);
+
+               /* Setup the type (level, edge polarity) if configured: */
+               if (new->flags & SA_TRIGGER_MASK) {
+                       if (desc->chip && desc->chip->set_type)
+                               desc->chip->set_type(irq,
+                                               new->flags & SA_TRIGGER_MASK);
+                       else
+                               /*
+                                * SA_TRIGGER_* but the PIC does not support
+                                * multiple flow-types?
+                                */
+                               printk(KERN_WARNING "setup_irq(%d) SA_TRIGGER"
+                                      "set. No set_type function available\n",
+                                      irq);
+               } else
+                       compat_irq_chip_set_default_handler(desc);
+
+               desc->status &= ~(IRQ_AUTODETECT | IRQ_WAITING |
+                                 IRQ_INPROGRESS);
+
+               if (!(desc->status & IRQ_NOAUTOEN)) {
+                       desc->depth = 0;
+                       desc->status &= ~IRQ_DISABLED;
+                       if (desc->chip->startup)
+                               desc->chip->startup(irq);
+                       else
+                               desc->chip->enable(irq);
+               } else
+                       /* Undo nested disables: */
+                       desc->depth = 1;
        }
-       spin_unlock_irqrestore(&desc->lock,flags);
+       spin_unlock_irqrestore(&desc->lock, flags);
 
        new->irq = irq;
        register_irq_proc(irq);
@@ -278,10 +330,10 @@ void free_irq(unsigned int irq, void *dev_id)
                return;
 
        desc = irq_desc + irq;
-       spin_lock_irqsave(&desc->lock,flags);
+       spin_lock_irqsave(&desc->lock, flags);
        p = &desc->action;
        for (;;) {
-               struct irqaction * action = *p;
+               struct irqaction *action = *p;
 
                if (action) {
                        struct irqaction **pp = p;
@@ -295,18 +347,18 @@ void free_irq(unsigned int irq, void *dev_id)
 
                        /* Currently used only by UML, might disappear one day.*/
 #ifdef CONFIG_IRQ_RELEASE_METHOD
-                       if (desc->handler->release)
-                               desc->handler->release(irq, dev_id);
+                       if (desc->chip->release)
+                               desc->chip->release(irq, dev_id);
 #endif
 
                        if (!desc->action) {
                                desc->status |= IRQ_DISABLED;
-                               if (desc->handler->shutdown)
-                                       desc->handler->shutdown(irq);
+                               if (desc->chip->shutdown)
+                                       desc->chip->shutdown(irq);
                                else
-                                       desc->handler->disable(irq);
+                                       desc->chip->disable(irq);
                        }
-                       spin_unlock_irqrestore(&desc->lock,flags);
+                       spin_unlock_irqrestore(&desc->lock, flags);
                        unregister_handler_proc(irq, action);
 
                        /* Make sure it's not being used on another CPU */
@@ -314,12 +366,11 @@ void free_irq(unsigned int irq, void *dev_id)
                        kfree(action);
                        return;
                }
-               printk(KERN_ERR "Trying to free free IRQ%d\n",irq);
-               spin_unlock_irqrestore(&desc->lock,flags);
+               printk(KERN_ERR "Trying to free free IRQ%d\n", irq);
+               spin_unlock_irqrestore(&desc->lock, flags);
                return;
        }
 }
-
 EXPORT_SYMBOL(free_irq);
 
 /**
@@ -353,9 +404,9 @@ EXPORT_SYMBOL(free_irq);
  */
 int request_irq(unsigned int irq,
                irqreturn_t (*handler)(int, void *, struct pt_regs *),
-               unsigned long irqflags, const char * devname, void *dev_id)
+               unsigned long irqflags, const char *devname, void *dev_id)
 {
-       struct irqaction * action;
+       struct irqaction *action;
        int retval;
 
        /*
@@ -368,6 +419,8 @@ int request_irq(unsigned int irq,
                return -EINVAL;
        if (irq >= NR_IRQS)
                return -EINVAL;
+       if (irq_desc[irq].status & IRQ_NOREQUEST)
+               return -EINVAL;
        if (!handler)
                return -EINVAL;
 
@@ -390,6 +443,5 @@ int request_irq(unsigned int irq,
 
        return retval;
 }
-
 EXPORT_SYMBOL(request_irq);
 
index a12d00eb5e7c01e9495704fbfdae248ab081ed8e..a57ebe9fa6f6b89169eb7e7e093167c341caed71 100644 (file)
@@ -3,19 +3,19 @@
 
 void set_pending_irq(unsigned int irq, cpumask_t mask)
 {
-       irq_desc_t *desc = irq_desc + irq;
+       struct irq_desc *desc = irq_desc + irq;
        unsigned long flags;
 
        spin_lock_irqsave(&desc->lock, flags);
        desc->move_irq = 1;
-       pending_irq_cpumask[irq] = mask;
+       irq_desc[irq].pending_mask = mask;
        spin_unlock_irqrestore(&desc->lock, flags);
 }
 
 void move_native_irq(int irq)
 {
+       struct irq_desc *desc = irq_desc + irq;
        cpumask_t tmp;
-       irq_desc_t *desc = irq_descp(irq);
 
        if (likely(!desc->move_irq))
                return;
@@ -30,15 +30,15 @@ void move_native_irq(int irq)
 
        desc->move_irq = 0;
 
-       if (unlikely(cpus_empty(pending_irq_cpumask[irq])))
+       if (unlikely(cpus_empty(irq_desc[irq].pending_mask)))
                return;
 
-       if (!desc->handler->set_affinity)
+       if (!desc->chip->set_affinity)
                return;
 
        assert_spin_locked(&desc->lock);
 
-       cpus_and(tmp, pending_irq_cpumask[irq], cpu_online_map);
+       cpus_and(tmp, irq_desc[irq].pending_mask, cpu_online_map);
 
        /*
         * If there was a valid mask to work with, please
@@ -51,12 +51,12 @@ void move_native_irq(int irq)
         */
        if (likely(!cpus_empty(tmp))) {
                if (likely(!(desc->status & IRQ_DISABLED)))
-                       desc->handler->disable(irq);
+                       desc->chip->disable(irq);
 
-               desc->handler->set_affinity(irq,tmp);
+               desc->chip->set_affinity(irq,tmp);
 
                if (likely(!(desc->status & IRQ_DISABLED)))
-                       desc->handler->enable(irq);
+                       desc->chip->enable(irq);
        }
-       cpus_clear(pending_irq_cpumask[irq]);
+       cpus_clear(irq_desc[irq].pending_mask);
 }
index afacd6f585fad187cfa950e651ad7e08a0301d81..607c7809ad0125e7aad8d28a308319601a7223ea 100644 (file)
 
 #include "internals.h"
 
-static struct proc_dir_entry *root_irq_dir, *irq_dir[NR_IRQS];
+static struct proc_dir_entry *root_irq_dir;
 
 #ifdef CONFIG_SMP
 
-/*
- * The /proc/irq/<irq>/smp_affinity values:
- */
-static struct proc_dir_entry *smp_affinity_entry[NR_IRQS];
-
 #ifdef CONFIG_GENERIC_PENDING_IRQ
 void proc_set_irq_affinity(unsigned int irq, cpumask_t mask_val)
 {
@@ -36,15 +31,15 @@ void proc_set_irq_affinity(unsigned int irq, cpumask_t mask_val)
 void proc_set_irq_affinity(unsigned int irq, cpumask_t mask_val)
 {
        set_balance_irq_affinity(irq, mask_val);
-       irq_affinity[irq] = mask_val;
-       irq_desc[irq].handler->set_affinity(irq, mask_val);
+       irq_desc[irq].affinity = mask_val;
+       irq_desc[irq].chip->set_affinity(irq, mask_val);
 }
 #endif
 
 static int irq_affinity_read_proc(char *page, char **start, off_t off,
                                  int count, int *eof, void *data)
 {
-       int len = cpumask_scnprintf(page, count, irq_affinity[(long)data]);
+       int len = cpumask_scnprintf(page, count, irq_desc[(long)data].affinity);
 
        if (count - len < 2)
                return -EINVAL;
@@ -59,7 +54,7 @@ static int irq_affinity_write_proc(struct file *file, const char __user *buffer,
        unsigned int irq = (int)(long)data, full_count = count, err;
        cpumask_t new_value, tmp;
 
-       if (!irq_desc[irq].handler->set_affinity || no_irq_affinity)
+       if (!irq_desc[irq].chip->set_affinity || no_irq_affinity)
                return -EIO;
 
        err = cpumask_parse(buffer, count, new_value);
@@ -102,7 +97,7 @@ void register_handler_proc(unsigned int irq, struct irqaction *action)
 {
        char name [MAX_NAMELEN];
 
-       if (!irq_dir[irq] || action->dir || !action->name ||
+       if (!irq_desc[irq].dir || action->dir || !action->name ||
                                        !name_unique(irq, action))
                return;
 
@@ -110,7 +105,7 @@ void register_handler_proc(unsigned int irq, struct irqaction *action)
        snprintf(name, MAX_NAMELEN, "%s", action->name);
 
        /* create /proc/irq/1234/handler/ */
-       action->dir = proc_mkdir(name, irq_dir[irq]);
+       action->dir = proc_mkdir(name, irq_desc[irq].dir);
 }
 
 #undef MAX_NAMELEN
@@ -122,22 +117,22 @@ void register_irq_proc(unsigned int irq)
        char name [MAX_NAMELEN];
 
        if (!root_irq_dir ||
-               (irq_desc[irq].handler == &no_irq_type) ||
-                       irq_dir[irq])
+               (irq_desc[irq].chip == &no_irq_chip) ||
+                       irq_desc[irq].dir)
                return;
 
        memset(name, 0, MAX_NAMELEN);
        sprintf(name, "%d", irq);
 
        /* create /proc/irq/1234 */
-       irq_dir[irq] = proc_mkdir(name, root_irq_dir);
+       irq_desc[irq].dir = proc_mkdir(name, root_irq_dir);
 
 #ifdef CONFIG_SMP
        {
                struct proc_dir_entry *entry;
 
                /* create /proc/irq/<irq>/smp_affinity */
-               entry = create_proc_entry("smp_affinity", 0600, irq_dir[irq]);
+               entry = create_proc_entry("smp_affinity", 0600, irq_desc[irq].dir);
 
                if (entry) {
                        entry->nlink = 1;
@@ -145,7 +140,6 @@ void register_irq_proc(unsigned int irq)
                        entry->read_proc = irq_affinity_read_proc;
                        entry->write_proc = irq_affinity_write_proc;
                }
-               smp_affinity_entry[irq] = entry;
        }
 #endif
 }
@@ -155,7 +149,7 @@ void register_irq_proc(unsigned int irq)
 void unregister_handler_proc(unsigned int irq, struct irqaction *action)
 {
        if (action->dir)
-               remove_proc_entry(action->dir->name, irq_dir[irq]);
+               remove_proc_entry(action->dir->name, irq_desc[irq].dir);
 }
 
 void init_irq_proc(void)
diff --git a/kernel/irq/resend.c b/kernel/irq/resend.c
new file mode 100644 (file)
index 0000000..872f91b
--- /dev/null
@@ -0,0 +1,78 @@
+/*
+ * linux/kernel/irq/resend.c
+ *
+ * Copyright (C) 1992, 1998-2006 Linus Torvalds, Ingo Molnar
+ * Copyright (C) 2005-2006, Thomas Gleixner
+ *
+ * This file contains the IRQ-resend code
+ *
+ * If the interrupt is waiting to be processed, we try to re-run it.
+ * We can't directly run it from here since the caller might be in an
+ * interrupt-protected region. Not all irq controller chips can
+ * retrigger interrupts at the hardware level, so in those cases
+ * we allow the resending of IRQs via a tasklet.
+ */
+
+#include <linux/irq.h>
+#include <linux/module.h>
+#include <linux/random.h>
+#include <linux/interrupt.h>
+
+#include "internals.h"
+
+#ifdef CONFIG_HARDIRQS_SW_RESEND
+
+/* Bitmap to handle software resend of interrupts: */
+static DECLARE_BITMAP(irqs_resend, NR_IRQS);
+
+/*
+ * Run software resends of IRQ's
+ */
+static void resend_irqs(unsigned long arg)
+{
+       struct irq_desc *desc;
+       int irq;
+
+       while (!bitmap_empty(irqs_resend, NR_IRQS)) {
+               irq = find_first_bit(irqs_resend, NR_IRQS);
+               clear_bit(irq, irqs_resend);
+               desc = irq_desc + irq;
+               local_irq_disable();
+               desc->handle_irq(irq, desc, NULL);
+               local_irq_enable();
+       }
+}
+
+/* Tasklet to handle resend: */
+static DECLARE_TASKLET(resend_tasklet, resend_irqs, 0);
+
+#endif
+
+/*
+ * IRQ resend
+ *
+ * Is called with interrupts disabled and desc->lock held.
+ */
+void check_irq_resend(struct irq_desc *desc, unsigned int irq)
+{
+       unsigned int status = desc->status;
+
+       /*
+        * Make sure the interrupt is enabled, before resending it:
+        */
+       desc->chip->enable(irq);
+
+       if ((status & (IRQ_PENDING | IRQ_REPLAY)) == IRQ_PENDING) {
+               desc->status &= ~IRQ_PENDING;
+               desc->status = status | IRQ_REPLAY;
+
+               if (!desc->chip || !desc->chip->retrigger ||
+                                       !desc->chip->retrigger(irq)) {
+#ifdef CONFIG_HARDIRQS_SW_RESEND
+                       /* Set it pending and activate the softirq: */
+                       set_bit(irq, irqs_resend);
+                       tasklet_schedule(&resend_tasklet);
+#endif
+               }
+       }
+}
index b2fb3c18d06bd77d88ed9eb8784f8a4254712a83..b483deed311cf7a3111fd31aafd938a1aae1f9f7 100644 (file)
@@ -16,22 +16,20 @@ static int irqfixup __read_mostly;
 /*
  * Recovery handler for misrouted interrupts.
  */
-
 static int misrouted_irq(int irq, struct pt_regs *regs)
 {
        int i;
-       irq_desc_t *desc;
        int ok = 0;
        int work = 0;   /* Did we do work for a real IRQ */
 
-       for(i = 1; i < NR_IRQS; i++) {
+       for (i = 1; i < NR_IRQS; i++) {
+               struct irq_desc *desc = irq_desc + i;
                struct irqaction *action;
 
                if (i == irq)   /* Already tried */
                        continue;
-               desc = &irq_desc[i];
+
                spin_lock(&desc->lock);
-               action = desc->action;
                /* Already running on another processor */
                if (desc->status & IRQ_INPROGRESS) {
                        /*
@@ -45,7 +43,9 @@ static int misrouted_irq(int irq, struct pt_regs *regs)
                }
                /* Honour the normal IRQ locking */
                desc->status |= IRQ_INPROGRESS;
+               action = desc->action;
                spin_unlock(&desc->lock);
+
                while (action) {
                        /* Only shared IRQ handlers are safe to call */
                        if (action->flags & SA_SHIRQ) {
@@ -62,9 +62,8 @@ static int misrouted_irq(int irq, struct pt_regs *regs)
 
                /*
                 * While we were looking for a fixup someone queued a real
-                * IRQ clashing with our walk
+                * IRQ clashing with our walk:
                 */
-
                while ((desc->status & IRQ_PENDING) && action) {
                        /*
                         * Perform real IRQ processing for the IRQ we deferred
@@ -80,8 +79,8 @@ static int misrouted_irq(int irq, struct pt_regs *regs)
                 * If we did actual work for the real IRQ line we must let the
                 * IRQ controller clean up too
                 */
-               if(work)
-                       desc->handler->end(i);
+               if (work && desc->chip && desc->chip->end)
+                       desc->chip->end(i);
                spin_unlock(&desc->lock);
        }
        /* So the caller can adjust the irq error counts */
@@ -100,7 +99,8 @@ static int misrouted_irq(int irq, struct pt_regs *regs)
  */
 
 static void
-__report_bad_irq(unsigned int irq, irq_desc_t *desc, irqreturn_t action_ret)
+__report_bad_irq(unsigned int irq, struct irq_desc *desc,
+                irqreturn_t action_ret)
 {
        struct irqaction *action;
 
@@ -113,6 +113,7 @@ __report_bad_irq(unsigned int irq, irq_desc_t *desc, irqreturn_t action_ret)
        }
        dump_stack();
        printk(KERN_ERR "handlers:\n");
+
        action = desc->action;
        while (action) {
                printk(KERN_ERR "[<%p>]", action->handler);
@@ -123,7 +124,8 @@ __report_bad_irq(unsigned int irq, irq_desc_t *desc, irqreturn_t action_ret)
        }
 }
 
-static void report_bad_irq(unsigned int irq, irq_desc_t *desc, irqreturn_t action_ret)
+static void
+report_bad_irq(unsigned int irq, struct irq_desc *desc, irqreturn_t action_ret)
 {
        static int count = 100;
 
@@ -133,8 +135,8 @@ static void report_bad_irq(unsigned int irq, irq_desc_t *desc, irqreturn_t actio
        }
 }
 
-void note_interrupt(unsigned int irq, irq_desc_t *desc, irqreturn_t action_ret,
-                       struct pt_regs *regs)
+void note_interrupt(unsigned int irq, struct irq_desc *desc,
+                   irqreturn_t action_ret, struct pt_regs *regs)
 {
        if (unlikely(action_ret != IRQ_HANDLED)) {
                desc->irqs_unhandled++;
@@ -166,7 +168,8 @@ void note_interrupt(unsigned int irq, irq_desc_t *desc, irqreturn_t action_ret,
                 */
                printk(KERN_EMERG "Disabling IRQ #%d\n", irq);
                desc->status |= IRQ_DISABLED;
-               desc->handler->disable(irq);
+               desc->depth = 1;
+               desc->chip->disable(irq);
        }
        desc->irqs_unhandled = 0;
 }
@@ -177,6 +180,7 @@ int __init noirqdebug_setup(char *str)
 {
        noirqdebug = 1;
        printk(KERN_INFO "IRQ lockup detection disabled\n");
+
        return 1;
 }
 
@@ -187,6 +191,7 @@ static int __init irqfixup_setup(char *str)
        irqfixup = 1;
        printk(KERN_WARNING "Misrouted IRQ fixup support enabled.\n");
        printk(KERN_WARNING "This may impact system performance.\n");
+
        return 1;
 }
 
index 2404f9b0bc4772411adf8a8e69076642e6ded487..bf1130d81b7f09d35c81e436592b407e56c526d3 100644 (file)
 
 struct resource ioport_resource = {
        .name   = "PCI IO",
-       .start  = 0x0000,
+       .start  = 0,
        .end    = IO_SPACE_LIMIT,
        .flags  = IORESOURCE_IO,
 };
-
 EXPORT_SYMBOL(ioport_resource);
 
 struct resource iomem_resource = {
        .name   = "PCI mem",
-       .start  = 0UL,
-       .end    = ~0UL,
+       .start  = 0,
+       .end    = -1,
        .flags  = IORESOURCE_MEM,
 };
-
 EXPORT_SYMBOL(iomem_resource);
 
 static DEFINE_RWLOCK(resource_lock);
@@ -83,10 +81,10 @@ static int r_show(struct seq_file *m, void *v)
        for (depth = 0, p = r; depth < MAX_IORES_LEVEL; depth++, p = p->parent)
                if (p->parent == root)
                        break;
-       seq_printf(m, "%*s%0*lx-%0*lx : %s\n",
+       seq_printf(m, "%*s%0*llx-%0*llx : %s\n",
                        depth * 2, "",
-                       width, r->start,
-                       width, r->end,
+                       width, (unsigned long long) r->start,
+                       width, (unsigned long long) r->end,
                        r->name ? r->name : "<BAD>");
        return 0;
 }
@@ -151,8 +149,8 @@ __initcall(ioresources_init);
 /* Return the conflict entry if you can't request it */
 static struct resource * __request_resource(struct resource *root, struct resource *new)
 {
-       unsigned long start = new->start;
-       unsigned long end = new->end;
+       resource_size_t start = new->start;
+       resource_size_t end = new->end;
        struct resource *tmp, **p;
 
        if (end < start)
@@ -274,11 +272,10 @@ int find_next_system_ram(struct resource *res)
  * Find empty slot in the resource tree given range and alignment.
  */
 static int find_resource(struct resource *root, struct resource *new,
-                        unsigned long size,
-                        unsigned long min, unsigned long max,
-                        unsigned long align,
+                        resource_size_t size, resource_size_t min,
+                        resource_size_t max, resource_size_t align,
                         void (*alignf)(void *, struct resource *,
-                                       unsigned long, unsigned long),
+                                       resource_size_t, resource_size_t),
                         void *alignf_data)
 {
        struct resource *this = root->child;
@@ -320,11 +317,10 @@ static int find_resource(struct resource *root, struct resource *new,
  * Allocate empty slot in the resource tree given range and alignment.
  */
 int allocate_resource(struct resource *root, struct resource *new,
-                     unsigned long size,
-                     unsigned long min, unsigned long max,
-                     unsigned long align,
+                     resource_size_t size, resource_size_t min,
+                     resource_size_t max, resource_size_t align,
                      void (*alignf)(void *, struct resource *,
-                                    unsigned long, unsigned long),
+                                    resource_size_t, resource_size_t),
                      void *alignf_data)
 {
        int err;
@@ -416,10 +412,10 @@ EXPORT_SYMBOL(insert_resource);
  * arguments.  Returns -EBUSY if it can't fit.  Existing children of
  * the resource are assumed to be immutable.
  */
-int adjust_resource(struct resource *res, unsigned long start, unsigned long size)
+int adjust_resource(struct resource *res, resource_size_t start, resource_size_t size)
 {
        struct resource *tmp, *parent = res->parent;
-       unsigned long end = start + size - 1;
+       resource_size_t end = start + size - 1;
        int result = -EBUSY;
 
        write_lock(&resource_lock);
@@ -466,7 +462,9 @@ EXPORT_SYMBOL(adjust_resource);
  *
  * Release-region releases a matching busy region.
  */
-struct resource * __request_region(struct resource *parent, unsigned long start, unsigned long n, const char *name)
+struct resource * __request_region(struct resource *parent,
+                                  resource_size_t start, resource_size_t n,
+                                  const char *name)
 {
        struct resource *res = kzalloc(sizeof(*res), GFP_KERNEL);
 
@@ -502,7 +500,8 @@ struct resource * __request_region(struct resource *parent, unsigned long start,
 
 EXPORT_SYMBOL(__request_region);
 
-int __check_region(struct resource *parent, unsigned long start, unsigned long n)
+int __check_region(struct resource *parent, resource_size_t start,
+                       resource_size_t n)
 {
        struct resource * res;
 
@@ -517,10 +516,11 @@ int __check_region(struct resource *parent, unsigned long start, unsigned long n
 
 EXPORT_SYMBOL(__check_region);
 
-void __release_region(struct resource *parent, unsigned long start, unsigned long n)
+void __release_region(struct resource *parent, resource_size_t start,
+                       resource_size_t n)
 {
        struct resource **p;
-       unsigned long end;
+       resource_size_t end;
 
        p = &parent->child;
        end = start + n - 1;
@@ -549,7 +549,9 @@ void __release_region(struct resource *parent, unsigned long start, unsigned lon
 
        write_unlock(&resource_lock);
 
-       printk(KERN_WARNING "Trying to free nonexistent resource <%08lx-%08lx>\n", start, end);
+       printk(KERN_WARNING "Trying to free nonexistent resource "
+               "<%016llx-%016llx>\n", (unsigned long long)start,
+               (unsigned long long)end);
 }
 
 EXPORT_SYMBOL(__release_region);
index e76c023eb0bb4696be89ffb8185dc1ff502c0ed9..8f5b45615f7bf1b43c35253b8f28f1ef4871818e 100644 (file)
@@ -115,7 +115,7 @@ config SPARSEMEM_EXTREME
 # eventually, we can have this option just 'select SPARSEMEM'
 config MEMORY_HOTPLUG
        bool "Allow for memory hot-add"
-       depends on SPARSEMEM && HOTPLUG && !SOFTWARE_SUSPEND
+       depends on SPARSEMEM && HOTPLUG && !SOFTWARE_SUSPEND && ARCH_ENABLE_MEMORY_HOTPLUG
        depends on (IA64 || X86 || PPC64)
 
 comment "Memory hotplug is currently incompatible with Software Suspend"
@@ -146,3 +146,9 @@ config MIGRATION
          while the virtual addresses are not changed. This is useful for
          example on NUMA systems to put pages nearer to the processors accessing
          the page.
+
+config RESOURCES_64BIT
+       bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && EXPERIMENTAL)
+       default 64BIT
+       help
+         This option allows memory and IO resources to be 64 bit.
index 4082b3b3cea761693d563c523129bf80128f577b..648f2c0c8e18896b1f979f2f31a848986cc6492b 100644 (file)
@@ -2125,6 +2125,12 @@ generic_file_buffered_write(struct kiocb *iocb, const struct iovec *iov,
                        break;
                }
 
+               if (unlikely(bytes == 0)) {
+                       status = 0;
+                       copied = 0;
+                       goto zero_length_segment;
+               }
+
                status = a_ops->prepare_write(file, page, offset, offset+bytes);
                if (unlikely(status)) {
                        loff_t isize = i_size_read(inode);
@@ -2154,7 +2160,8 @@ generic_file_buffered_write(struct kiocb *iocb, const struct iovec *iov,
                        page_cache_release(page);
                        continue;
                }
-               if (likely(copied > 0)) {
+zero_length_segment:
+               if (likely(copied >= 0)) {
                        if (!status)
                                status = copied;
 
index 536979fb4ba717443be39b9e0e8a95dfd012200c..3f2a343c6015f2b4b9564307bb557a0dbdddb8f5 100644 (file)
@@ -88,7 +88,7 @@ filemap_set_next_iovec(const struct iovec **iovp, size_t *basep, size_t bytes)
        const struct iovec *iov = *iovp;
        size_t base = *basep;
 
-       while (bytes) {
+       do {
                int copy = min(bytes, iov->iov_len - base);
 
                bytes -= copy;
@@ -97,7 +97,7 @@ filemap_set_next_iovec(const struct iovec **iovp, size_t *basep, size_t bytes)
                        iov++;
                        base = 0;
                }
-       }
+       } while (bytes);
        *iovp = iov;
        *basep = base;
 }
index 3c2877f0663ebc6f60d5a9585ff985df52a502f5..1bb416f4bbcef7aa9315e9efcb59d292389ee8b2 100644 (file)
@@ -99,6 +99,7 @@ extern int install_process_keyring(struct task_struct *tsk);
 extern struct key *request_key_and_link(struct key_type *type,
                                        const char *description,
                                        const char *callout_info,
+                                       void *aux,
                                        struct key *dest_keyring,
                                        unsigned long flags);
 
index 329411cf8768ef6e8e90f387e35a65d2f3194782..d9ca15c109ccfaa167cafc8c39dec87f2a3e305d 100644 (file)
@@ -183,7 +183,7 @@ asmlinkage long sys_request_key(const char __user *_type,
        }
 
        /* do the search */
-       key = request_key_and_link(ktype, description, callout_info,
+       key = request_key_and_link(ktype, description, callout_info, NULL,
                                   key_ref_to_ptr(dest_ref),
                                   KEY_ALLOC_IN_QUOTA);
        if (IS_ERR(key)) {
index 58d1efd4fc2c66788788edcc2e5d90bd32e1dc10..f573ac189a0a6595b2184b43a9d54c3b01e0d5a0 100644 (file)
@@ -1,6 +1,6 @@
 /* request_key.c: request a key from userspace
  *
- * Copyright (C) 2004-5 Red Hat, Inc. All Rights Reserved.
+ * Copyright (C) 2004-6 Red Hat, Inc. All Rights Reserved.
  * Written by David Howells (dhowells@redhat.com)
  *
  * This program is free software; you can redistribute it and/or
@@ -33,7 +33,8 @@ DECLARE_WAIT_QUEUE_HEAD(request_key_conswq);
  */
 static int call_sbin_request_key(struct key *key,
                                 struct key *authkey,
-                                const char *op)
+                                const char *op,
+                                void *aux)
 {
        struct task_struct *tsk = current;
        key_serial_t prkey, sskey;
@@ -127,6 +128,7 @@ error_alloc:
 static struct key *__request_key_construction(struct key_type *type,
                                              const char *description,
                                              const char *callout_info,
+                                             void *aux,
                                              unsigned long flags)
 {
        request_key_actor_t actor;
@@ -164,7 +166,7 @@ static struct key *__request_key_construction(struct key_type *type,
        actor = call_sbin_request_key;
        if (type->request_key)
                actor = type->request_key;
-       ret = actor(key, authkey, "create");
+       ret = actor(key, authkey, "create", aux);
        if (ret < 0)
                goto request_failed;
 
@@ -258,8 +260,9 @@ alloc_failed:
  */
 static struct key *request_key_construction(struct key_type *type,
                                            const char *description,
-                                           struct key_user *user,
                                            const char *callout_info,
+                                           void *aux,
+                                           struct key_user *user,
                                            unsigned long flags)
 {
        struct key_construction *pcons;
@@ -284,7 +287,7 @@ static struct key *request_key_construction(struct key_type *type,
        }
 
        /* see about getting userspace to construct the key */
-       key = __request_key_construction(type, description, callout_info,
+       key = __request_key_construction(type, description, callout_info, aux,
                                         flags);
  error:
        kleave(" = %p", key);
@@ -392,6 +395,7 @@ static void request_key_link(struct key *key, struct key *dest_keyring)
 struct key *request_key_and_link(struct key_type *type,
                                 const char *description,
                                 const char *callout_info,
+                                void *aux,
                                 struct key *dest_keyring,
                                 unsigned long flags)
 {
@@ -399,8 +403,9 @@ struct key *request_key_and_link(struct key_type *type,
        struct key *key;
        key_ref_t key_ref;
 
-       kenter("%s,%s,%s,%p,%lx",
-              type->name, description, callout_info, dest_keyring, flags);
+       kenter("%s,%s,%s,%p,%p,%lx",
+              type->name, description, callout_info, aux,
+              dest_keyring, flags);
 
        /* search all the process keyrings for a key */
        key_ref = search_process_keyrings(type, description, type->match,
@@ -433,8 +438,8 @@ struct key *request_key_and_link(struct key_type *type,
                        /* ask userspace (returns NULL if it waited on a key
                         * being constructed) */
                        key = request_key_construction(type, description,
-                                                      user, callout_info,
-                                                      flags);
+                                                      callout_info, aux,
+                                                      user, flags);
                        if (key)
                                break;
 
@@ -491,8 +496,27 @@ struct key *request_key(struct key_type *type,
                        const char *callout_info)
 {
        return request_key_and_link(type, description, callout_info, NULL,
-                                   KEY_ALLOC_IN_QUOTA);
+                                   NULL, KEY_ALLOC_IN_QUOTA);
 
 } /* end request_key() */
 
 EXPORT_SYMBOL(request_key);
+
+/*****************************************************************************/
+/*
+ * request a key with auxiliary data for the upcaller
+ * - search the process's keyrings
+ * - check the list of keys being created or updated
+ * - call out to userspace for a key if supplementary info was provided
+ */
+struct key *request_key_with_auxdata(struct key_type *type,
+                                    const char *description,
+                                    const char *callout_info,
+                                    void *aux)
+{
+       return request_key_and_link(type, description, callout_info, aux,
+                                   NULL, KEY_ALLOC_IN_QUOTA);
+
+} /* end request_key_with_auxdata() */
+
+EXPORT_SYMBOL(request_key_with_auxdata);
index 5f22d70fefc0fa114a7f9b12814f8c7a6b31b41e..6b18225672c7ae6227a8ebb206c9aaf6460cee00 100644 (file)
@@ -779,8 +779,9 @@ static struct aaci * __devinit aaci_init_card(struct amba_device *dev)
        strlcpy(card->driver, DRIVER_NAME, sizeof(card->driver));
        strlcpy(card->shortname, "ARM AC'97 Interface", sizeof(card->shortname));
        snprintf(card->longname, sizeof(card->longname),
-                "%s at 0x%08lx, irq %d",
-                card->shortname, dev->res.start, dev->irq[0]);
+                "%s at 0x%016llx, irq %d",
+                card->shortname, (unsigned long long)dev->res.start,
+                dev->irq[0]);
 
        aaci = card->private_data;
        mutex_init(&aaci->ac97_sem);
index d3cbbb04758231940d21f2d43a2caa7bddf164cd..8b80024968be7d32f32e0b15fdfe5c1e6352425e 100644 (file)
@@ -160,8 +160,9 @@ static int __devinit snd_mpu401_pnp(int dev, struct pnp_dev *device,
                return -ENODEV;
        }
        if (pnp_port_len(device, 0) < IO_EXTENT) {
-               snd_printk(KERN_ERR "PnP port length is %ld, expected %d\n",
-                          pnp_port_len(device, 0), IO_EXTENT);
+               snd_printk(KERN_ERR "PnP port length is %llu, expected %d\n",
+                          (unsigned long long)pnp_port_len(device, 0),
+                          IO_EXTENT);
                return -ENODEV;
        }
        port[dev] = pnp_port_start(device, 0);
index e6945db8ed1b8a2fcd4b877712b96db8ff791c98..af60b0bc8115f59986b0be019adc050f8695f0cc 100644 (file)
@@ -2088,7 +2088,8 @@ static int __devinit snd_audiodrive_pnp(int dev, struct snd_audiodrive *acard,
                kfree(cfg);
                return -EAGAIN;
        }
-       snd_printdd("pnp: port=0x%lx\n", pnp_port_start(acard->devc, 0));
+       snd_printdd("pnp: port=0x%llx\n",
+                       (unsigned long long)pnp_port_start(acard->devc, 0));
        /* PnP initialization */
        pdev = acard->dev;
        pnp_init_resource_table(cfg);
index 866300f2acbbd930cda9d0c92217919b1be58faa..c1c86e0fa56df0056b7a18cb2586fc5a7dd13242 100644 (file)
@@ -611,10 +611,10 @@ static int __devinit snd_interwave_pnp(int dev, struct snd_interwave *iwcard,
        if (dma2[dev] >= 0)
                dma2[dev] = pnp_dma(pdev, 1);
        irq[dev] = pnp_irq(pdev, 0);
-       snd_printdd("isapnp IW: sb port=0x%lx, gf1 port=0x%lx, codec port=0x%lx\n",
-                               pnp_port_start(pdev, 0),
-                               pnp_port_start(pdev, 1),
-                               pnp_port_start(pdev, 2));
+       snd_printdd("isapnp IW: sb port=0x%llx, gf1 port=0x%llx, codec port=0x%llx\n",
+                       (unsigned long long)pnp_port_start(pdev, 0),
+                       (unsigned long long)pnp_port_start(pdev, 1),
+                       (unsigned long long)pnp_port_start(pdev, 2));
        snd_printdd("isapnp IW: dma1=%i, dma2=%i, irq=%i\n", dma1[dev], dma2[dev], irq[dev]);
 #ifdef SNDRV_STB
        /* Tone Control initialization */
index 7f7f05fa518afa78cd228b3f9a677215b74a873b..d64e67f2bafa3ef2537c03a703ff800d2b6ac8a8 100644 (file)
@@ -327,7 +327,8 @@ static int __devinit snd_card_sb16_pnp(int dev, struct snd_card_sb16 *acard,
                        goto __wt_error; 
                } 
                awe_port[dev] = pnp_port_start(pdev, 0);
-               snd_printdd("pnp SB16: wavetable port=0x%lx\n", pnp_port_start(pdev, 0));
+               snd_printdd("pnp SB16: wavetable port=0x%llx\n",
+                               (unsigned long long)pnp_port_start(pdev, 0));
        } else {
 __wt_error:
                if (pdev) {
index 3b8cdbca263665e53eca3f06b96c353912f6a218..f4980ca5c05c86d9f4cbd8c86c885f2bd35af09c 100644 (file)
@@ -493,6 +493,19 @@ config SOUND_CS4232
          See <file:Documentation/sound/oss/CS4232> for more information on
          configuring this card.
 
+config SOUND_SSCAPE
+       tristate "Ensoniq SoundScape support"
+       depends on SOUND_OSS
+       help
+         Answer Y if you have a sound card based on the Ensoniq SoundScape
+         chipset. Such cards are being manufactured at least by Ensoniq, Spea
+         and Reveal (Reveal makes also other cards).
+
+         If you compile the driver into the kernel, you have to add
+         "sscape=<io>,<irq>,<dma>,<mpuio>,<mpuirq>" to the kernel command
+         line.
+
+
 config SOUND_VMIDI
        tristate "Loopback MIDI device support"
        depends on SOUND_OSS
index 0294eec8ad9035ee621f516df74d692bab95faff..44e578098d76e77768ea6a872ff077eb5e89be85 100644 (file)
@@ -2035,8 +2035,9 @@ forte_probe (struct pci_dev *pci_dev, const struct pci_device_id *pci_id)
        
        pci_set_drvdata (pci_dev, chip);
 
-       printk (KERN_INFO PFX "FM801 chip found at 0x%04lX-0x%04lX IRQ %u\n", 
-               chip->iobase, pci_resource_end (pci_dev, 0), chip->irq);
+       printk (KERN_INFO PFX "FM801 chip found at 0x%04lX-0x%16llX IRQ %u\n",
+               chip->iobase, (unsigned long long)pci_resource_end (pci_dev, 0),
+               chip->irq);
 
        /* Power it up */
        if ((ret = forte_chip_init (chip)) == 0)
index c33642d8d9a11e37e56e762b3342e4d660b8ae5c..497ed6b200608e8331fb3dd42656ebe05dca6c1d 100644 (file)
@@ -888,8 +888,9 @@ static int __devinit snd_bt87x_probe(struct pci_dev *pci,
 
        strcpy(card->driver, "Bt87x");
        sprintf(card->shortname, "Brooktree Bt%x", pci->device);
-       sprintf(card->longname, "%s at %#lx, irq %i",
-               card->shortname, pci_resource_start(pci, 0), chip->irq);
+       sprintf(card->longname, "%s at %#llx, irq %i",
+               card->shortname, (unsigned long long)pci_resource_start(pci, 0),
+               chip->irq);
        strcpy(card->mixername, "Bt87x");
 
        err = snd_card_register(card);
index dcf4029483474bd3790b6ef45e7e71d434491d8b..e5511606af04e9e58ff4b91f26a05aba41d20fba 100644 (file)
@@ -1441,10 +1441,10 @@ static int __devinit snd_sonic_probe(struct pci_dev *pci,
 
        strcpy(card->driver, "SonicVibes");
        strcpy(card->shortname, "S3 SonicVibes");
-       sprintf(card->longname, "%s rev %i at 0x%lx, irq %i",
+       sprintf(card->longname, "%s rev %i at 0x%llx, irq %i",
                card->shortname,
                sonic->revision,
-               pci_resource_start(pci, 1),
+               (unsigned long long)pci_resource_start(pci, 1),
                sonic->irq);
 
        if ((err = snd_sonicvibes_pcm(sonic, 0, NULL)) < 0) {
index b678814975c9e1dd93297033966a527172ec8b28..be98f63773392af7e9afa04c748acffc5d5c8b94 100644 (file)
@@ -1170,9 +1170,10 @@ int __init snd_pmac_new(struct snd_card *card, struct snd_pmac **chip_return)
                                               chip->rsrc[i].start + 1,
                                               rnames[i]) == NULL) {
                                printk(KERN_ERR "snd: can't request rsrc "
-                                      " %d (%s: 0x%08lx:%08lx)\n",
-                                      i, rnames[i], chip->rsrc[i].start,
-                                      chip->rsrc[i].end);
+                                      " %d (%s: 0x%016lx:%016lx)\n",
+                                      i, rnames[i],
+                                      (unsigned long long)chip->rsrc[i].start,
+                                      (unsigned long long)chip->rsrc[i].end);
                                err = -ENODEV;
                                goto __error;
                        }
@@ -1201,9 +1202,10 @@ int __init snd_pmac_new(struct snd_card *card, struct snd_pmac **chip_return)
                                               chip->rsrc[i].start + 1,
                                               rnames[i]) == NULL) {
                                printk(KERN_ERR "snd: can't request rsrc "
-                                      " %d (%s: 0x%08lx:%08lx)\n",
-                                      i, rnames[i], chip->rsrc[i].start,
-                                      chip->rsrc[i].end);
+                                      " %d (%s: 0x%016llx:%016llx)\n",
+                                      i, rnames[i],
+                                      (unsigned long long)chip->rsrc[i].start,
+                                      (unsigned long long)chip->rsrc[i].end);
                                err = -ENODEV;
                                goto __error;
                        }
index da54d04a3e3a4a9af73dd32d9689c808d77edba3..d9d14c2707dbf922a622b5889b9c2b78af74068b 100644 (file)
@@ -2037,10 +2037,10 @@ static int __init cs4231_sbus_attach(struct sbus_dev *sdev)
        if (err)
                return err;
 
-       sprintf(card->longname, "%s at 0x%02lx:0x%08lx, irq %d",
+       sprintf(card->longname, "%s at 0x%02lx:0x%016lx, irq %d",
                card->shortname,
                rp->flags & 0xffL,
-               rp->start,
+               (unsigned long long)rp->start,
                sdev->irqs[0]);
 
        if ((err = snd_cs4231_sbus_create(card, sdev, dev, &cp)) < 0) {
index 5eecdd09a79ddd91a3345eb92f7a82303d474a3e..a7489a3dd75ac4f68fc328f128332e760a77a28f 100644 (file)
@@ -2645,9 +2645,9 @@ static int __init dbri_attach(int prom_node, struct sbus_dev *sdev)
        strcpy(card->driver, "DBRI");
        strcpy(card->shortname, "Sun DBRI");
        rp = &sdev->resource[0];
-       sprintf(card->longname, "%s at 0x%02lx:0x%08lx, irq %d",
+       sprintf(card->longname, "%s at 0x%02lx:0x%016lx, irq %d",
                card->shortname,
-               rp->flags & 0xffL, rp->start, irq.pri);
+               rp->flags & 0xffL, (unsigned long long)rp->start, irq.pri);
 
        if ((err = snd_dbri_create(card, sdev, &irq, dev)) < 0) {
                snd_card_free(card);