1. 18 4月, 2009 1 次提交
  2. 08 4月, 2009 1 次提交
  3. 07 4月, 2009 1 次提交
  4. 31 3月, 2009 1 次提交
    • A
      proc 2/2: remove struct proc_dir_entry::owner · 99b76233
      Alexey Dobriyan 提交于
      Setting ->owner as done currently (pde->owner = THIS_MODULE) is racy
      as correctly noted at bug #12454. Someone can lookup entry with NULL
      ->owner, thus not pinning enything, and release it later resulting
      in module refcount underflow.
      
      We can keep ->owner and supply it at registration time like ->proc_fops
      and ->data.
      
      But this leaves ->owner as easy-manipulative field (just one C assignment)
      and somebody will forget to unpin previous/pin current module when
      switching ->owner. ->proc_fops is declared as "const" which should give
      some thoughts.
      
      ->read_proc/->write_proc were just fixed to not require ->owner for
      protection.
      
      rmmod'ed directories will be empty and return "." and ".." -- no harm.
      And directories with tricky enough readdir and lookup shouldn't be modular.
      We definitely don't want such modular code.
      
      Removing ->owner will also make PDE smaller.
      
      So, let's nuke it.
      
      Kudos to Jeff Layton for reminding about this, let's say, oversight.
      
      http://bugzilla.kernel.org/show_bug.cgi?id=12454Signed-off-by: NAlexey Dobriyan <adobriyan@gmail.com>
      99b76233
  5. 30 3月, 2009 1 次提交
  6. 28 3月, 2009 1 次提交
  7. 21 2月, 2009 1 次提交
  8. 20 2月, 2009 1 次提交
  9. 17 1月, 2009 1 次提交
  10. 08 11月, 2008 1 次提交
  11. 07 11月, 2008 1 次提交
    • K
      ACPI: struct device - replace bus_id with dev_name(), dev_set_name() · 0794469d
      Kay Sievers 提交于
      This patch is part of a larger patch series which will remove
      the "char bus_id[20]" name string from struct device. The device
      name is managed in the kobject anyway, and without any size
      limitation, and just needlessly copied into "struct device".
      
      To set and read the device name dev_name(dev) and dev_set_name(dev)
      must be used. If your code uses static kobjects, which it shouldn't
      do, "const char *init_name" can be used to statically provide the
      name the registered device should have. At registration time, the
      init_name field is cleared, to enforce the use of dev_name(dev) to
      access the device name at a later time.
      
      We need to get rid of all occurrences of bus_id in the entire tree
      to be able to enable the new interface. Please apply this patch,
      and possibly convert any remaining remaining occurrences of bus_id.
      
      We want to submit a patch to -next, which will remove bus_id from
      "struct device", to find the remaining pieces to convert, and finally
      switch over to the new api, which will remove the 20 bytes array
      and does no longer have a size limitation.
      Acked-by: NGreg Kroah-Hartman <gregkh@suse.de>
      Signed-Off-By: NKay Sievers <kay.sievers@vrfy.org>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      0794469d
  12. 23 10月, 2008 1 次提交
  13. 17 10月, 2008 1 次提交
  14. 11 10月, 2008 2 次提交
  15. 22 7月, 2008 1 次提交
  16. 18 7月, 2008 1 次提交
  17. 12 6月, 2008 1 次提交
  18. 29 4月, 2008 4 次提交
  19. 28 4月, 2008 1 次提交
  20. 09 4月, 2008 1 次提交
  21. 13 3月, 2008 1 次提交
  22. 02 2月, 2008 5 次提交
  23. 07 12月, 2007 1 次提交
  24. 10 10月, 2007 1 次提交
    • J
      drivers/firmware: const-ify DMI API and internals · 1855256c
      Jeff Garzik 提交于
      Three main sets of changes:
      
      1) dmi_get_system_info() return value should have been marked const,
         since callers should not be changing that data.
      
      2) const-ify DMI internals, since DMI firmware tables should,
         whenever possible, be marked const to ensure we never ever write to
         that data area.
      
      3) const-ify DMI API, to enable marking tables const where possible
         in low-level drivers.
      
      And if we're really lucky, this might enable some additional
      optimizations on the part of the compiler.
      
      The bulk of the changes are #2 and #3, which are interrelated.  #1 could
      have been a separate patch, but it was so small compared to the others,
      it was easier to roll it into this changeset.
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      1855256c
  25. 06 9月, 2007 1 次提交
  26. 05 9月, 2007 1 次提交
    • L
      ACPI: thermal: use round_jiffies when thermal zone polling is enabled · 21bc42ab
      Len Brown 提交于
      Properly functioning systems do not use thermal zone polling,
      they use event-based notification.
      
      However, some users enable periodic thermal zone polling
      to work around bugs on their platforms, and at least one
      platform exists with a real _TZP that requests polling.
      
      While thermal zone polling (_TZP) is specified in units to 0.1 seconds,
      it actually has a maximum granularity of 1 second.  Thus, we can safely
      round up the _TZP timeout to occur on the next 1-second boundary.
      This will batch it with other 1-second-granularity timers in the
      system and thus potentially extend processor idle duration.
      
      Note that the same timer is used both for _TZP
      and for passive processor thermal throttling.
      We can not round up the timeout when it is used
      for passive thermal throttling.
      
      Also, we can not make this a deferrable timer,
      as temperature is just as relevant during idle
      as it is during non-idle.
      Signed-off-by: NLen Brown <len.brown@intel.com>
      21bc42ab
  27. 25 8月, 2007 1 次提交
  28. 24 8月, 2007 2 次提交
    • L
      ACPI: Schedule /proc/acpi/event for removal · 14e04fb3
      Len Brown 提交于
      Schedule /proc/acpi/event for removal in 6 months.
      
      Re-name acpi_bus_generate_event() to acpi_bus_generate_proc_event()
      to make sure there is no confusion that it is for /proc/acpi/event only.
      
      Add CONFIG_ACPI_PROC_EVENT to allow removal of /proc/acpi/event.
      There is no functional change if CONFIG_ACPI_PROC_EVENT=y
      Signed-off-by: NLen Brown <len.brown@intel.com>
      14e04fb3
    • Z
      ACPI: don't duplicate input events on netlink · 962ce8ca
      Zhang Rui 提交于
      The previous events patch added a netlink event for every
      user of the legacy /proc/acpi/event interface.
      
      However, some users of /proc/acpi/event are really input events,
      and they already report their events via the input layer.
      
      Introduce a new interface, acpi_bus_generate_netlink_event(),
      which is explicitly called by devices that want to repoprt
      events via netlink.  This allows the input-like events
      to opt-out of generating netlink events.  In summary:
      
      events that are sent via netlink:
      	ac/battery/sbs
      	thermal
      	processor
      	thinkpad_acpi dock/bay
      
      events that are sent via input layer:
      	button
      	video hotkey
      	thinkpad_acpi hotkey
      	asus_acpi/asus-laptop hotkey
      	sonypi/sonylaptop
      Signed-off-by: NZhang Rui <rui.zhang@intel.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      962ce8ca
  29. 21 8月, 2007 1 次提交
  30. 15 8月, 2007 2 次提交