1. 09 12月, 2006 1 次提交
  2. 02 12月, 2006 1 次提交
  3. 19 10月, 2006 2 次提交
    • H
      sysfs: update obsolete comment in sysfs_update_file · 97a50184
      Hidetoshi Seto 提交于
      And the obsolete comment should be updated (or totally removed).
      Signed-off-by: NHidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      97a50184
    • H
      sysfs: remove duplicated dput in sysfs_update_file · e4234451
      Hidetoshi Seto 提交于
      Following function can drops d_count twice against one reference
      by lookup_one_len.
      
      <SOURCE>
      /**
       * sysfs_update_file - update the modified timestamp on an object attribute.
       * @kobj: object we're acting for.
       * @attr: attribute descriptor.
       */
      int sysfs_update_file(struct kobject * kobj, const struct attribute * attr)
      {
              struct dentry * dir = kobj->dentry;
              struct dentry * victim;
              int res = -ENOENT;
      
              mutex_lock(&dir->d_inode->i_mutex);
              victim = lookup_one_len(attr->name, dir, strlen(attr->name));
              if (!IS_ERR(victim)) {
                      /* make sure dentry is really there */
                      if (victim->d_inode &&
                          (victim->d_parent->d_inode == dir->d_inode)) {
                              victim->d_inode->i_mtime = CURRENT_TIME;
                              fsnotify_modify(victim);
      
                              /**
                               * Drop reference from initial sysfs_get_dentry().
                               */
                              dput(victim);
                              res = 0;
                      } else
                              d_drop(victim);
      
                      /**
                       * Drop the reference acquired from sysfs_get_dentry() above.
                       */
                      dput(victim);
              }
              mutex_unlock(&dir->d_inode->i_mutex);
      
              return res;
      }
      </SOURCE>
      
      PCI-hotplug (drivers/pci/hotplug/pci_hotplug_core.c) is only user of
      this function. I confirmed that dentry of /sys/bus/pci/slots/XXX/*
      have negative d_count value.
      
      This patch removes unnecessary dput().
      Signed-off-by: NHidetoshi Seto <seto.hidetoshi@jp.fujitsu.com>
      Acked-by: NManeesh Soni <maneesh@in.ibm.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      e4234451
  4. 03 10月, 2006 1 次提交
  5. 15 4月, 2006 1 次提交
    • N
      [PATCH] sysfs: Allow sysfs attribute files to be pollable · 4508a7a7
      NeilBrown 提交于
      It works like this:
        Open the file
        Read all the contents.
        Call poll requesting POLLERR or POLLPRI (so select/exceptfds works)
        When poll returns,
           close the file and go to top of loop.
         or lseek to start of file and go back to the 'read'.
      
      Events are signaled by an object manager calling
         sysfs_notify(kobj, dir, attr);
      
      If the dir is non-NULL, it is used to find a subdirectory which
      contains the attribute (presumably created by sysfs_create_group).
      
      This has a cost of one int  per attribute, one wait_queuehead per kobject,
      one int per open file.
      
      The name "sysfs_notify" may be confused with the inotify
      functionality.  Maybe it would be nice to support inotify for sysfs
      attributes as well?
      
      This patch also uses sysfs_notify to allow /sys/block/md*/md/sync_action
      to be pollable
      Signed-off-by: NNeil Brown <neilb@suse.de>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      4508a7a7
  6. 03 4月, 2006 1 次提交
  7. 29 3月, 2006 1 次提交
  8. 21 3月, 2006 2 次提交
  9. 10 1月, 2006 1 次提交
  10. 30 7月, 2005 1 次提交
  11. 13 7月, 2005 1 次提交
    • R
      [PATCH] inotify · 0eeca283
      Robert Love 提交于
      inotify is intended to correct the deficiencies of dnotify, particularly
      its inability to scale and its terrible user interface:
      
              * dnotify requires the opening of one fd per each directory
                that you intend to watch. This quickly results in too many
                open files and pins removable media, preventing unmount.
              * dnotify is directory-based. You only learn about changes to
                directories. Sure, a change to a file in a directory affects
                the directory, but you are then forced to keep a cache of
                stat structures.
              * dnotify's interface to user-space is awful.  Signals?
      
      inotify provides a more usable, simple, powerful solution to file change
      notification:
      
              * inotify's interface is a system call that returns a fd, not SIGIO.
      	  You get a single fd, which is select()-able.
              * inotify has an event that says "the filesystem that the item
                you were watching is on was unmounted."
              * inotify can watch directories or files.
      
      Inotify is currently used by Beagle (a desktop search infrastructure),
      Gamin (a FAM replacement), and other projects.
      
      See Documentation/filesystems/inotify.txt.
      Signed-off-by: NRobert Love <rml@novell.com>
      Cc: John McCutchan <ttb@tentacle.dhs.org>
      Cc: Christoph Hellwig <hch@lst.de>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      0eeca283
  12. 24 6月, 2005 2 次提交
  13. 21 6月, 2005 2 次提交
  14. 01 5月, 2005 1 次提交
  15. 19 4月, 2005 1 次提交
  16. 17 4月, 2005 1 次提交
    • L
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds 提交于
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      
      Let it rip!
      1da177e4