1. 02 12月, 2006 2 次提交
    • K
      Driver core: fix "driver" symlink timing · 1901fb26
      Kay Sievers 提交于
      Create the "driver" link before the child device may be created by
      the probing logic. This makes it possible for userspace (udev), to
      determine the driver property of the parent device, at the time the
      child device is created.
      Signed-off-by: NKay Sievers <kay.sievers@novell.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      1901fb26
    • B
      Driver core: add notification of bus events · 116af378
      Benjamin Herrenschmidt 提交于
      I finally did as you suggested and added the notifier to the struct
      bus_type itself. There are still problems to be expected is something
      attaches to a bus type where the code can hook in different struct
      device sub-classes (which is imho a big bogosity but I won't even try to
      argue that case now) but it will solve nicely a number of issues I've
      had so far.
      
      That also means that clients interested in registering for such
      notifications have to do it before devices are added and after bus types
      are registered. Fortunately, most bus types that matter for the various
      usage scenarios I have in mind are registerd at postcore_initcall time,
      which means I have a really nice spot at arch_initcall time to add my
      notifiers.
      
      There are 4 notifications provided. Device being added (before hooked to
      the bus) and removed (failure of previous case or after being unhooked
      from the bus), along with driver being bound to a device and about to be
      unbound.
      
      The usage I have for these are:
      
       - The 2 first ones are used to maintain a struct device_ext that is
      hooked to struct device.firmware_data. This structure contains for now a
      pointer to the Open Firmware node related to the device (if any), the
      NUMA node ID (for quick access to it) and the DMA operations pointers &
      iommu table instance for DMA to/from this device. For bus types I own
      (like IBM VIO or EBUS), I just maintain that structure directly from the
      bus code when creating the devices. But for bus types managed by generic
      code like PCI or platform (actually, of_platform which is a variation of
      platform linked to Open Firmware device-tree), I need this notifier.
      
       - The other two ones have a completely different usage scenario. I have
      cases where multiple devices and their drivers depend on each other. For
      example, the IBM EMAC network driver needs to attach to a MAL DMA engine
      which is a separate device, and a PHY interface which is also a separate
      device. They are all of_platform_device's (well, about to be with my
      upcoming patches) but there is no say in what precise order the core
      will "probe" them and instanciate the various modules. The solution I
      found for that is to have the drivers for emac to use multithread_probe,
      and wait for a driver to be bound to the target MAL and PHY control
      devices (the device-tree contains reference to the MAL and PHY interface
      nodes, which I can then match to of_platform_devices). Right now, I've
      been polling, but with that notifier, I can more cleanly wait (with a
      timeout of course).
      Signed-off-by: NBenjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      116af378
  2. 30 11月, 2006 1 次提交
  3. 29 11月, 2006 1 次提交
  4. 28 11月, 2006 3 次提交
  5. 26 11月, 2006 16 次提交
  6. 24 11月, 2006 2 次提交
  7. 23 11月, 2006 2 次提交
    • L
      [AGP] Allocate AGP pages with GFP_DMA32 by default · 66c669ba
      Linus Torvalds 提交于
      Not all graphic page remappers support physical addresses over the 4GB
      mark for remapping, so while some do (the AMD64 GART always did, and I
      just fixed the i965 to do so properly), we're safest off just forcing
      GFP_DMA32 allocations to make sure graphics pages get allocated in the
      low 32-bit address space by default.
      
      AGP sub-drivers that really care, and can do better, could just choose
      to implement their own allocator (or we could add another "64-bit safe"
      default allocator for their use), but quite frankly, you're not likely
      to care in practice.
      
      So for now, this trivial change means that we won't be allocating pages
      that we can't map correctly by mistake on x86-64.
      
      [ On traditional 32-bit x86, this could never happen, because GFP_KERNEL
        would never allocate any highmem memory anyway ]
      Acked-by: NAndi Kleen <ak@suse.de>
      Acked-by: NDave Jones <davej@redhat.com>
      Cc: Eric Anholt <eric@anholt.net>
      Cc: Keith Packard <keithp@keithp.com>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      66c669ba
    • L
      [AGP] Fix intel 965 AGP memory mapping function · 7d915a38
      Linus Torvalds 提交于
      This introduces a i965-specific "mask_memory()" function that knows
      about the extended physical addresses that the i965 supports.  This
      allows us to correctly map in physical memory in the >4GB range into the
      GTT.
      
      Also simplify/clean-up the i965 case for the aperture sizing by just
      returning the fixed 512kB size from "fetch_size()".  We don't really
      care that not all of the aperture may be visible - the only thing that
      cares about the aperture size is the Intel "stolen memory" calculation,
      which depends on the fixed size.
      
      Cc: Keith Packard <keithp@keithp.com>
      Cc: Eric Anholt <eric@anholt.net>
      Cc: Dave Jones <davej@redhat.com>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      7d915a38
  8. 22 11月, 2006 2 次提交
  9. 21 11月, 2006 7 次提交
  10. 18 11月, 2006 1 次提交
    • L
      Revert "ACPI: created a dedicated workqueue for notify() execution" · b976fe19
      Linus Torvalds 提交于
      This reverts commit 37605a69.
      
      Again.
      
      This same bug has now been introduced twice: it was done earlier by
      commit b8d35192, only to be reverted
      last time in commit 72945b2b.
      
      We must NOT try to queue up notify handlers to another thread than the
      normal ACPI execution thread, because the notifications on some systems
      seem to just keep on accumulating until we run out of memory and/or
      threads.
      
      Keeping events within the one deferred execution thread automatically
      throttles the events properly.
      
      At least the Compaq N620c will lock up completely on the first thermal
      event without this patch reverted.
      
      Cc: David Brownell <david-b@pacbell.net>
      Cc: Len Brown <len.brown@intel.com>
      Cc: Alexey Starikovskiy <alexey.y.starikovskiy@linux.intel.com>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      b976fe19
  11. 17 11月, 2006 3 次提交