1. 27 9月, 2006 22 次提交
    • H
      [PATCH] own header file for struct page · 5b99cd0e
      Heiko Carstens 提交于
      This moves the definition of struct page from mm.h to its own header file
      page-struct.h.  This is a prereq to fix SetPageUptodate which is broken on
      s390:
      
      #define SetPageUptodate(_page)
             do {
                     struct page *__page = (_page);
                     if (!test_and_set_bit(PG_uptodate, &__page->flags))
                             page_test_and_clear_dirty(_page);
             } while (0)
      
      _page gets used twice in this macro which can cause subtle bugs.  Using
      __page for the page_test_and_clear_dirty call doesn't work since it causes
      yet another problem with the page_test_and_clear_dirty macro as well.
      
      In order to avoid all these problems caused by macros it seems to be a good
      idea to get rid of them and convert them to static inline functions.
      Because of header file include order it's necessary to have a seperate
      header file for the struct page definition.
      
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Signed-off-by: NHeiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      5b99cd0e
    • A
      [PATCH] vm: add per-zone writeout counter · e129b5c2
      Andrew Morton 提交于
      The VM is supposed to minimise the number of pages which get written off the
      LRU (for IO scheduling efficiency, and for high reclaim-success rates).  But
      we don't actually have a clear way of showing how true this is.
      
      So add `nr_vmscan_write' to /proc/vmstat and /proc/zoneinfo - the number of
      pages which have been written by the vm scanner in this zone and globally.
      
      Cc: Christoph Lameter <clameter@engr.sgi.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      e129b5c2
    • M
      [PATCH] Allow an arch to expand node boundaries · fb01439c
      Mel Gorman 提交于
      Arch-independent zone-sizing determines the size of a node
      (pgdat->node_spanned_pages) based on the physical memory that was
      registered by the architecture.  However, when
      CONFIG_MEMORY_HOTPLUG_RESERVE is set, the architecture expects that the
      spanned_pages will be much larger and that mem_map will be allocated that
      is used lated on memory hot-add.
      
      This patch allows an architecture that sets CONFIG_MEMORY_HOTPLUG_RESERVE
      to call push_node_boundaries() which will set the node beginning and end to
      at *least* the requested boundary.
      
      Cc: Dave Hansen <haveblue@us.ibm.com>
      Cc: Andy Whitcroft <apw@shadowen.org>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: "Keith Mannthey" <kmannth@gmail.com>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
      Cc: Yasunori Goto <y-goto@jp.fujitsu.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      fb01439c
    • M
      [PATCH] Account for memmap and optionally the kernel image as holes · 0e0b864e
      Mel Gorman 提交于
      The x86_64 code accounted for memmap and some portions of the the DMA zone as
      holes.  This was because those areas would never be reclaimed and accounting
      for them as memory affects min watermarks.  This patch will account for the
      memmap as a memory hole.  Architectures may optionally use set_dma_reserve()
      if they wish to account for a portion of memory in ZONE_DMA as a hole.
      Signed-off-by: NMel Gorman <mel@csn.ul.ie>
      Cc: Dave Hansen <haveblue@us.ibm.com>
      Cc: Andy Whitcroft <apw@shadowen.org>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: "Keith Mannthey" <kmannth@gmail.com>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
      Cc: Yasunori Goto <y-goto@jp.fujitsu.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      0e0b864e
    • M
      [PATCH] Introduce mechanism for registering active regions of memory · c713216d
      Mel Gorman 提交于
      At a basic level, architectures define structures to record where active
      ranges of page frames are located.  Once located, the code to calculate zone
      sizes and holes in each architecture is very similar.  Some of this zone and
      hole sizing code is difficult to read for no good reason.  This set of patches
      eliminates the similar-looking architecture-specific code.
      
      The patches introduce a mechanism where architectures register where the
      active ranges of page frames are with add_active_range().  When all areas have
      been discovered, free_area_init_nodes() is called to initialise the pgdat and
      zones.  The zone sizes and holes are then calculated in an architecture
      independent manner.
      
      Patch 1 introduces the mechanism for registering and initialising PFN ranges
      Patch 2 changes ppc to use the mechanism - 139 arch-specific LOC removed
      Patch 3 changes x86 to use the mechanism - 136 arch-specific LOC removed
      Patch 4 changes x86_64 to use the mechanism - 74 arch-specific LOC removed
      Patch 5 changes ia64 to use the mechanism - 52 arch-specific LOC removed
      Patch 6 accounts for mem_map as a memory hole as the pages are not reclaimable.
      	It adjusts the watermarks slightly
      
      Tony Luck has successfully tested for ia64 on Itanium with tiger_defconfig,
      gensparse_defconfig and defconfig.  Bob Picco has also tested and debugged on
      IA64.  Jack Steiner successfully boot tested on a mammoth SGI IA64-based
      machine.  These were on patches against 2.6.17-rc1 and release 3 of these
      patches but there have been no ia64-changes since release 3.
      
      There are differences in the zone sizes for x86_64 as the arch-specific code
      for x86_64 accounts the kernel image and the starting mem_maps as memory holes
      but the architecture-independent code accounts the memory as present.
      
      The big benefit of this set of patches is a sizable reduction of
      architecture-specific code, some of which is very hairy.  There should be a
      greater reduction when other architectures use the same mechanisms for zone
      and hole sizing but I lack the hardware to test on.
      
      Additional credit;
      	Dave Hansen for the initial suggestion and comments on early patches
      	Andy Whitcroft for reviewing early versions and catching numerous
      		errors
      	Tony Luck for testing and debugging on IA64
      	Bob Picco for fixing bugs related to pfn registration, reviewing a
      		number of patch revisions, providing a number of suggestions
      		on future direction and testing heavily
      	Jack Steiner and Robin Holt for testing on IA64 and clarifying
      		issues related to memory holes
      	Yasunori for testing on IA64
      	Andi Kleen for reviewing and feeding back about x86_64
      	Christian Kujau for providing valuable information related to ACPI
      		problems on x86_64 and testing potential fixes
      
      This patch:
      
      Define the structure to represent an active range of page frames within a node
      in an architecture independent manner.  Architectures are expected to register
      active ranges of PFNs using add_active_range(nid, start_pfn, end_pfn) and call
      free_area_init_nodes() passing the PFNs of the end of each zone.
      Signed-off-by: NMel Gorman <mel@csn.ul.ie>
      Signed-off-by: NBob Picco <bob.picco@hp.com>
      Cc: Dave Hansen <haveblue@us.ibm.com>
      Cc: Andy Whitcroft <apw@shadowen.org>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: "Keith Mannthey" <kmannth@gmail.com>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
      Cc: Yasunori Goto <y-goto@jp.fujitsu.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      c713216d
    • A
      [PATCH] Make kmem_cache_destroy() return void · 133d205a
      Alexey Dobriyan 提交于
      un-, de-, -free, -destroy, -exit, etc functions should in general return
      void.  Also,
      
      There is very little, say, filesystem driver code can do upon failed
      kmem_cache_destroy().  If it will be decided to BUG in this case, BUG
      should be put in generic code, instead.
      Signed-off-by: NAlexey Dobriyan <adobriyan@gmail.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      133d205a
    • D
      [PATCH] ext3: Fix sparse warnings · a4e4de36
      Dave Kleikamp 提交于
      Fixing up some endian-ness warnings in preparation to clone ext4 from ext3.
      Signed-off-by: NDave Kleikamp <shaggy@austin.ibm.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      a4e4de36
    • D
      [PATCH] ext3: More whitespace cleanups · e9ad5620
      Dave Kleikamp 提交于
      More white space cleanups in preparation of cloning ext4 from ext3.
      Removing spaces that precede a tab.
      Signed-off-by: NDave Kleikamp <shaggy@austin.ibm.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      e9ad5620
    • E
      [PATCH] JBD: 16T fixes · 37ed3222
      Eric Sandeen 提交于
      These are a few places I've found in jbd that look like they may not be
      16T-safe, or consistent with the use of unsigned longs for block
      containers.  Problems here would be somewhat hard to hit, would require
      journal blocks past the 8T boundary, which would not be terribly common.
      Still, should fix.
      
      (some of these have come from the ext4 work on jbd as well).
      
      I think there's one more possibility that the wrap() function may not be
      safe IF your last block in the journal butts right up against the 232 block
      boundary, but that seems like a VERY remote possibility, and I'm not
      worrying about it at this point.
      Signed-off-by: NEric Sandeen <esandeen@redhat.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      37ed3222
    • M
      [PATCH] ext3 and jbd cleanup: remove whitespace · ae6ddcc5
      Mingming Cao 提交于
      Remove whitespace from ext3 and jbd, before we clone ext4.
      
      Signed-off-by: Mingming Cao<cmm@us.ibm.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      ae6ddcc5
    • R
      [MIPS] Remove EV96100 as previously announced. · d48f1de2
      Ralf Baechle 提交于
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      d48f1de2
    • S
      PCI: add pci_stop_bus_device · 24f8aa9b
      Satoru Takeuchi 提交于
      This patch adds pci_stop_bus_device() which stops a PCI device (detach
      the driver, remove from the global list and so on) and any children.
      This is needed for ACPI based PCI-to-PCI bridge hot-remove, and it will
      be also needed for ACPI based PCI root bridge hot-remove.
      Signed-off-by: NKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
      Signed-off-by: NMUNEDA Takahiro <muneda.takahiro@jp.fujitsu.com>
      Signed-off-by: NSatoru Takeuchi <takeuchi_satoru@jp.fujitsu.com>
      Signed-off-by: NKristen Carlson Accardi <kristen.c.accardi@intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      24f8aa9b
    • A
      PCI: Multiprobe sanitizer · 50b00755
      Alan Cox 提交于
      There are numerous drivers that can use multithreaded probing but having
      some kind of global flag as the way to control this makes migration to
      threaded probing hard and since it enables it everywhere and is almost
      as likely to cause serious pain as holding a clog dance in a minefield.
      
      If we have a pci_driver multithread_probe flag to inherit you can turn
      it on for one driver at a time.
      
      From playing so far however I think we need a different model at the
      device layer which serializes until the called probe function says "ok
      you can start another one now". That would need some kind of flag and
      semaphore plus a helper function.
      
      Anyway in the absence of that this is a starting point to usefully play
      with this stuff
      Signed-off-by: NAlan Cox <alan@redhat.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      50b00755
    • G
      PCI: fix __must_check warnings · b19441af
      Greg Kroah-Hartman 提交于
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      b19441af
    • Z
      PCI-Express AER implemetation: AER core and aerdriver · 6c2b374d
      Zhang, Yanmin 提交于
      Patch 3 implements the core part of PCI-Express AER and aerdrv
      port service driver.
      
      When a root port service device is probed, the aerdrv will call
      request_irq to register irq handler for AER error interrupt.
      
      When a device sends an PCI-Express error message to the root port,
      the root port will trigger an interrupt, by either MSI or IO-APIC,
      then kernel would run the irq handler. The handler collects root
      error status register and schedules a work. The work will call
      the core part to process the error based on its type
      (Correctable/non-fatal/fatal).
      
      As for Correctable errors, the patch chooses to just clear the correctable
      error status register of the device.
      
      As for the non-fatal error, the patch follows generic PCI error handler
      rules to call the error callback functions of the endpoint's driver. If
      the device is a bridge, the patch chooses to broadcast the error to
      downstream devices.
      
      As for the fatal error, the patch resets the pci-express link and
      follows generic PCI error handler rules to call the error callback
      functions of the endpoint's driver. If the device is a bridge, the patch
      chooses to broadcast the error to downstream devices.
      Signed-off-by: NZhang Yanmin <yanmin.zhang@intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      6c2b374d
    • B
      MSI: Blacklist PCI-E chipsets depending on Hypertransport MSI capability · 6397c75c
      Brice Goglin 提交于
      Introduce msi_ht_cap_enabled() to check the MSI capability in the
      Hypertransport configuration space.
      It is used in a generic quirk quirk_msi_ht_cap() to check whether
      MSI is enabled on hypertransport chipset, and a nVidia specific quirk
      quirk_nvidia_ck804_msi_ht_cap() where two 2 HT MSI mappings have to
      be checked.
      Both quirks set the PCI_BUS_FLAGS_NO_MSI bus flag when MSI is disabled.
      Signed-off-by: NBrice Goglin <brice@myri.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      6397c75c
    • B
      MSI: Rename PCI_CAP_ID_HT_IRQCONF into PCI_CAP_ID_HT · 46ff3463
      Brice Goglin 提交于
      0x08 is the HT capability, while PCI_CAP_ID_HT_IRQCONF would be
      the subtype 0x80 that mpic_scan_ht_pic() uses.
      Rename PCI_CAP_ID_HT_IRQCONF into PCI_CAP_ID_HT.
      
      And by the way, use it in the ipath driver instead of defining its
      own HT_CAPABILITY_ID.
      Signed-off-by: NBrice Goglin <brice@myri.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      46ff3463
    • J
      i2c: Drop unimplemented slave functions · 6d3aae9d
      Jean Delvare 提交于
      i2c: Drop unimplemented slave functions
      
      Drop the function declarations for slave mode support of i2c adapters.
      This was never implemented, and by the time it is I bet we will want
      something different anyway.
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      6d3aae9d
    • D
      i2c: Let drivers constify i2c_algorithm data · af71ff69
      David Brownell 提交于
      i2c: Let drivers constify i2c_algorithm data
      
      Let drivers constify I2C algorithm method operations tables,
      moving them from ".data" to ".rodata".
      Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      af71ff69
    • A
      i2c-algo-pcf: Discard the mdelay data struct member · 9b4ccb86
      Adrian Bunk 提交于
      i2c-algo-pcf: Discard the mdelay data struct member
      
      Just as i2c-algo-bit, i2c-algo-pcf has an unused mdelay struct member,
      which we can get rid of to spare some code and memory.
      Signed-off-by: NAdrian Bunk <bunk@stusta.de>
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      9b4ccb86
    • J
      i2c-algo-bit: Discard the mdelay data struct member · a0d9c63d
      Jean Delvare 提交于
      i2c-algo-bit: Discard the mdelay data struct member
      
      The i2c_algo_bit_data structure has an mdelay member, which is not
      used by the algorithm code (the code has always been ifdef'd out.)
      Let's discard it to save some code and memory.
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      Acked-by: NMauro Carvalho Chehab <mchehab@brturbo.com.br>
      Cc: Adrian Bunk <bunk@stusta.de>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      a0d9c63d
    • J
      i2c-algo-sibyte: Merge into i2c-sibyte · 51c37117
      Jean Delvare 提交于
      i2c-algo-sibyte: Merge into i2c-sibyte
      
      Merge i2c-algo-sibyte into i2c-sibyte, as this is a complete,
      hardware-dependent SMBus implementation and not a reusable algorithm.
      
      Perform some basic coding style cleanups while we're here (mainly
      space-based indentation replaced by tabulations.)
      Signed-off-by: NJean Delvare <khali@linux-fr.org>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      51c37117
  2. 26 9月, 2006 18 次提交