)]}'
{
  "log": [
    {
      "commit": "e50c1f609c63223adaa38f5a79b18759a00adf72",
      "tree": "0a8b2f19e873413500b232aa21bc251520770b7c",
      "parents": [
        "dbee8a0affd5e6eaa5d7c816c4bc233f6f110f50"
      ],
      "author": {
        "name": "Amerigo Wang",
        "email": "amwang@redhat.com",
        "time": "Tue May 24 17:13:11 2011 -0700"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Wed May 25 08:39:44 2011 -0700"
      },
      "message": "fscache: remove dead code under CONFIG_WORKQUEUE_DEBUGFS\n\nThere is no CONFIG_WORKQUEUE_DEBUGFS any more, so this code is dead.\n\nSigned-off-by: WANG Cong \u003camwang@redhat.com\u003e\nCc: David Howells \u003cdhowells@redhat.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "ba28b93a5227cc69ec811507f7d85ac25fa20fe2",
      "tree": "1ae3a8d6b19528277f5a622705b633a43f5218b8",
      "parents": [
        "acda4721ae876dedab3fef04bbd8020bfa67ff0a"
      ],
      "author": {
        "name": "Akshat Aranya",
        "email": "aranya@nec-labs.com",
        "time": "Fri Jan 14 16:00:47 2011 +0000"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Fri Jan 14 09:23:36 2011 -0800"
      },
      "message": "FS-Cache: Fix operation handling\n\nfscache_submit_exclusive_op() adds an operation to the pending list if\nother operations are pending.  Fix the check for pending ops as n_ops\nmust be greater than 0 at the point it is checked as it is incremented\nimmediately before under lock.\n\nSigned-off-by: Akshat Aranya \u003caranya@nec-labs.com\u003e\nSigned-off-by: David Howells \u003cdhowells@redhat.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "8af7c12436803291c90295259db23d371a7ad9cc",
      "tree": "5e75360876ac5783a3e64bd35a1715847d90e9ce",
      "parents": [
        "8b8edefa2fffbff97f9eec8b70e78ae23abad1a0"
      ],
      "author": {
        "name": "Tejun Heo",
        "email": "tj@kernel.org",
        "time": "Tue Jul 20 22:09:01 2010 +0200"
      },
      "committer": {
        "name": "Tejun Heo",
        "email": "tj@kernel.org",
        "time": "Thu Jul 22 22:58:47 2010 +0200"
      },
      "message": "fscache: convert operation to use workqueue instead of slow-work\n\nMake fscache operation to use only workqueue instead of combination of\nworkqueue and slow-work.  FSCACHE_OP_SLOW is dropped and\nFSCACHE_OP_FAST is renamed to FSCACHE_OP_ASYNC and uses newly added\nfscache_op_wq workqueue to execute op-\u003eprocessor().\nfscache_operation_init_slow() is dropped and fscache_operation_init()\nnow takes @processor argument directly.\n\n* Unbound workqueue is used.\n\n* fscache_retrieval_work() is no longer necessary as OP_ASYNC now does\n  the equivalent thing.\n\n* sysctl fscache.operation_max_active added to control concurrency.\n  The default value is nr_cpus clamped between 2 and\n  WQ_UNBOUND_MAX_ACTIVE.\n\n* debugfs support is dropped for now.  Tracing API based debug\n  facility is planned to be added.\n\nSigned-off-by: Tejun Heo \u003ctj@kernel.org\u003e\nAcked-by: David Howells \u003cdhowells@redhat.com\u003e\n"
    },
    {
      "commit": "5a0e3ad6af8660be21ca98a971cd00f331318c05",
      "tree": "5bfb7be11a03176a87296a43ac6647975c00a1d1",
      "parents": [
        "ed391f4ebf8f701d3566423ce8f17e614cde9806"
      ],
      "author": {
        "name": "Tejun Heo",
        "email": "tj@kernel.org",
        "time": "Wed Mar 24 17:04:11 2010 +0900"
      },
      "committer": {
        "name": "Tejun Heo",
        "email": "tj@kernel.org",
        "time": "Tue Mar 30 22:02:32 2010 +0900"
      },
      "message": "include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h\n\npercpu.h is included by sched.h and module.h and thus ends up being\nincluded when building most .c files.  percpu.h includes slab.h which\nin turn includes gfp.h making everything defined by the two files\nuniversally available and complicating inclusion dependencies.\n\npercpu.h -\u003e slab.h dependency is about to be removed.  Prepare for\nthis change by updating users of gfp and slab facilities include those\nheaders directly instead of assuming availability.  As this conversion\nneeds to touch large number of source files, the following script is\nused as the basis of conversion.\n\n  http://userweb.kernel.org/~tj/misc/slabh-sweep.py\n\nThe script does the followings.\n\n* Scan files for gfp and slab usages and update includes such that\n  only the necessary includes are there.  ie. if only gfp is used,\n  gfp.h, if slab is used, slab.h.\n\n* When the script inserts a new include, it looks at the include\n  blocks and try to put the new include such that its order conforms\n  to its surrounding.  It\u0027s put in the include block which contains\n  core kernel includes, in the same order that the rest are ordered -\n  alphabetical, Christmas tree, rev-Xmas-tree or at the end if there\n  doesn\u0027t seem to be any matching order.\n\n* If the script can\u0027t find a place to put a new include (mostly\n  because the file doesn\u0027t have fitting include block), it prints out\n  an error message indicating which .h file needs to be added to the\n  file.\n\nThe conversion was done in the following steps.\n\n1. The initial automatic conversion of all .c files updated slightly\n   over 4000 files, deleting around 700 includes and adding ~480 gfp.h\n   and ~3000 slab.h inclusions.  The script emitted errors for ~400\n   files.\n\n2. Each error was manually checked.  Some didn\u0027t need the inclusion,\n   some needed manual addition while adding it to implementation .h or\n   embedding .c file was more appropriate for others.  This step added\n   inclusions to around 150 files.\n\n3. The script was run again and the output was compared to the edits\n   from #2 to make sure no file was left behind.\n\n4. Several build tests were done and a couple of problems were fixed.\n   e.g. lib/decompress_*.c used malloc/free() wrappers around slab\n   APIs requiring slab.h to be added manually.\n\n5. The script was run on all .h files but without automatically\n   editing them as sprinkling gfp.h and slab.h inclusions around .h\n   files could easily lead to inclusion dependency hell.  Most gfp.h\n   inclusion directives were ignored as stuff from gfp.h was usually\n   wildly available and often used in preprocessor macros.  Each\n   slab.h inclusion directive was examined and added manually as\n   necessary.\n\n6. percpu.h was updated not to include slab.h.\n\n7. Build test were done on the following configurations and failures\n   were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my\n   distributed build env didn\u0027t work with gcov compiles) and a few\n   more options had to be turned off depending on archs to make things\n   build (like ipr on powerpc/64 which failed due to missing writeq).\n\n   * x86 and x86_64 UP and SMP allmodconfig and a custom test config.\n   * powerpc and powerpc64 SMP allmodconfig\n   * sparc and sparc64 SMP allmodconfig\n   * ia64 SMP allmodconfig\n   * s390 SMP allmodconfig\n   * alpha SMP allmodconfig\n   * um on x86_64 SMP allmodconfig\n\n8. percpu.h modifications were reverted so that it could be applied as\n   a separate patch and serve as bisection point.\n\nGiven the fact that I had only a couple of failures from tests on step\n6, I\u0027m fairly confident about the coverage of this conversion patch.\nIf there is a breakage, it\u0027s likely to be something in one of the arch\nheaders which should be easily discoverable easily on most builds of\nthe specific arch.\n\nSigned-off-by: Tejun Heo \u003ctj@kernel.org\u003e\nGuess-its-ok-by: Christoph Lameter \u003ccl@linux-foundation.org\u003e\nCc: Ingo Molnar \u003cmingo@redhat.com\u003e\nCc: Lee Schermerhorn \u003cLee.Schermerhorn@hp.com\u003e\n"
    },
    {
      "commit": "a53f4f9efaeb1d87cfae066346979d4d70e1abe9",
      "tree": "d774e3c010b96bc71226d5aedd1df04462629db5",
      "parents": [
        "88be12c440cfa2fa3f5be83507360aac9ea1c54e"
      ],
      "author": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Mon Mar 29 13:08:52 2010 +0100"
      },
      "committer": {
        "name": "Linus Torvalds",
        "email": "torvalds@linux-foundation.org",
        "time": "Mon Mar 29 09:14:47 2010 -0700"
      },
      "message": "SLOW_WORK: CONFIG_SLOW_WORK_PROC should be CONFIG_SLOW_WORK_DEBUG\n\nCONFIG_SLOW_WORK_PROC was changed to CONFIG_SLOW_WORK_DEBUG, but not in all\ninstances.  Change the remaining instances.  This makes the debugfs file\ndisplay the time mark and the owner\u0027s description again.\n\nSigned-off-by: David Howells \u003cdhowells@redhat.com\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n"
    },
    {
      "commit": "e3d4d28b1c8cc7c26536a50b43d86ccd39878550",
      "tree": "23f6dacd5ffdf6c6d01c411517855a41405381b9",
      "parents": [
        "285e728b0ac55b53a673114096168d6f74930167"
      ],
      "author": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:11:32 2009 +0000"
      },
      "committer": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:11:32 2009 +0000"
      },
      "message": "FS-Cache: Handle read request vs lookup, creation or other cache failure\n\nFS-Cache doesn\u0027t correctly handle the netfs requesting a read from the cache\non an object that failed or was withdrawn by the cache.  A trace similar to\nthe following might be seen:\n\n\tCacheFiles: Lookup failed error -105\n\t[exe   ] unexpected submission OP165afe [OBJ6cac OBJECT_LC_DYING]\n\t[exe   ] objstate\u003dOBJECT_LC_DYING [OBJECT_LC_DYING]\n\t[exe   ] objflags\u003d0\n\t[exe   ] objevent\u003d9 [fffffffffffffffb]\n\t[exe   ] ops\u003d0 inp\u003d0 exc\u003d0\n\tPid: 6970, comm: exe Not tainted 2.6.32-rc6-cachefs #50\n\tCall Trace:\n\t [\u003cffffffffa0076477\u003e] fscache_submit_op+0x3ff/0x45a [fscache]\n\t [\u003cffffffffa0077997\u003e] __fscache_read_or_alloc_pages+0x187/0x3c4 [fscache]\n\t [\u003cffffffffa00b6480\u003e] ? nfs_readpage_from_fscache_complete+0x0/0x66 [nfs]\n\t [\u003cffffffffa00b6388\u003e] __nfs_readpages_from_fscache+0x7e/0x176 [nfs]\n\t [\u003cffffffff8108e483\u003e] ? __alloc_pages_nodemask+0x11c/0x5cf\n\t [\u003cffffffffa009d796\u003e] nfs_readpages+0x114/0x1d7 [nfs]\n\t [\u003cffffffff81090314\u003e] __do_page_cache_readahead+0x15f/0x1ec\n\t [\u003cffffffff81090228\u003e] ? __do_page_cache_readahead+0x73/0x1ec\n\t [\u003cffffffff810903bd\u003e] ra_submit+0x1c/0x20\n\t [\u003cffffffff810906bb\u003e] ondemand_readahead+0x227/0x23a\n\t [\u003cffffffff81090762\u003e] page_cache_sync_readahead+0x17/0x19\n\t [\u003cffffffff8108a99e\u003e] generic_file_aio_read+0x236/0x5a0\n\t [\u003cffffffffa00937bd\u003e] nfs_file_read+0xe4/0xf3 [nfs]\n\t [\u003cffffffff810b2fa2\u003e] do_sync_read+0xe3/0x120\n\t [\u003cffffffff81354cc3\u003e] ? _spin_unlock_irq+0x2b/0x31\n\t [\u003cffffffff8104c0f1\u003e] ? autoremove_wake_function+0x0/0x34\n\t [\u003cffffffff811848e5\u003e] ? selinux_file_permission+0x5d/0x10f\n\t [\u003cffffffff81352bdb\u003e] ? thread_return+0x3e/0x101\n\t [\u003cffffffff8117d7b0\u003e] ? security_file_permission+0x11/0x13\n\t [\u003cffffffff810b3b06\u003e] vfs_read+0xaa/0x16f\n\t [\u003cffffffff81058df0\u003e] ? trace_hardirqs_on_caller+0x10c/0x130\n\t [\u003cffffffff810b3c84\u003e] sys_read+0x45/0x6c\n\t [\u003cffffffff8100ae2b\u003e] system_call_fastpath+0x16/0x1b\n\nThe object state might also be OBJECT_DYING or OBJECT_WITHDRAWING.\n\nThis should be handled by simply rejecting the new operation with ENOBUFS.\nThere\u0027s no need to log an error for it.  Events of this type now appear in the\nstats file under Ops:rej.\n\nSigned-off-by: David Howells \u003cdhowells@redhat.com\u003e\n"
    },
    {
      "commit": "5753c441889253e4323eee85f791a1d64cf08196",
      "tree": "55a0de053d0593d96e99710f978277df668412d1",
      "parents": [
        "b34df792b4e9e311db47fad27949095d0629c197"
      ],
      "author": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:11:19 2009 +0000"
      },
      "committer": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:11:19 2009 +0000"
      },
      "message": "FS-Cache: Permit cache retrieval ops to be interrupted in the initial wait phase\n\nPermit the operations to retrieve data from the cache or to allocate space in\nthe cache for future writes to be interrupted whilst they\u0027re waiting for\npermission for the operation to proceed.  Typically this wait occurs whilst the\ncache object is being looked up on disk in the background.\n\nIf an interruption occurs, and the operation has not yet been given the\ngo-ahead to run, the operation is dequeued and cancelled, and control returns\nto the read operation of the netfs routine with none of the requested pages\nhaving been read or in any way marked as known by the cache.\n\nThis means that the initial wait is done interruptibly rather than\nuninterruptibly.\n\nIn addition, extra stats values are made available to show the number of ops\ncancelled and the number of cache space allocations interrupted.\n\nSigned-off-by: David Howells \u003cdhowells@redhat.com\u003e\n"
    },
    {
      "commit": "4fbf4291aa15926cd4fdca0ffe9122e89d0459db",
      "tree": "ec2195c39ef8117acea598af4a5c20c77f67aa0b",
      "parents": [
        "440f0affe247e9990c8f8778f1861da4fd7d5e50"
      ],
      "author": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:11:04 2009 +0000"
      },
      "committer": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:11:04 2009 +0000"
      },
      "message": "FS-Cache: Allow the current state of all objects to be dumped\n\nAllow the current state of all fscache objects to be dumped by doing:\n\n\tcat /proc/fs/fscache/objects\n\nBy default, all objects and all fields will be shown.  This can be restricted\nby adding a suitable key to one of the caller\u0027s keyrings (such as the session\nkeyring):\n\n\tkeyctl add user fscache:objlist \"\u003crestrictions\u003e\" @s\n\nThe \u003crestrictions\u003e are:\n\n\tK\tShow hexdump of object key (don\u0027t show if not given)\n\tA\tShow hexdump of object aux data (don\u0027t show if not given)\n\nAnd paired restrictions:\n\n\tC\tShow objects that have a cookie\n\tc\tShow objects that don\u0027t have a cookie\n\tB\tShow objects that are busy\n\tb\tShow objects that aren\u0027t busy\n\tW\tShow objects that have pending writes\n\tw\tShow objects that don\u0027t have pending writes\n\tR\tShow objects that have outstanding reads\n\tr\tShow objects that don\u0027t have outstanding reads\n\tS\tShow objects that have slow work queued\n\ts\tShow objects that don\u0027t have slow work queued\n\nIf neither side of a restriction pair is given, then both are implied.  For\nexample:\n\n\tkeyctl add user fscache:objlist KB @s\n\nshows objects that are busy, and lists their object keys, but does not dump\ntheir auxiliary data.  It also implies \"CcWwRrSs\", but as \u0027B\u0027 is given, \u0027b\u0027 is\nnot implied.\n\nSigned-off-by: David Howells \u003cdhowells@redhat.com\u003e\n"
    },
    {
      "commit": "440f0affe247e9990c8f8778f1861da4fd7d5e50",
      "tree": "0012732ac8af0245005403d9a3b0a2b1209edf32",
      "parents": [
        "3bde31a4ac225cb5805be02eff6eaaf7e0766ccd"
      ],
      "author": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:11:01 2009 +0000"
      },
      "committer": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:11:01 2009 +0000"
      },
      "message": "FS-Cache: Annotate slow-work runqueue proc lines for FS-Cache work items\n\nAnnotate slow-work runqueue proc lines for FS-Cache work items.  Objects\ninclude the object ID and the state.  Operations include the object ID, the\noperation ID and the operation type and state.\n\nSigned-off-by: David Howells \u003cdhowells@redhat.com\u003e\n"
    },
    {
      "commit": "3d7a641e544e428191667e8b1f83f96fa46dbd65",
      "tree": "172aa672eca96b94f5531885b82abb82b43c7d8a",
      "parents": [
        "66b00a7c93ec782d118d2c03bd599cfd041e80a1"
      ],
      "author": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:10:23 2009 +0000"
      },
      "committer": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Thu Nov 19 18:10:23 2009 +0000"
      },
      "message": "SLOW_WORK: Wait for outstanding work items belonging to a module to clear\n\nWait for outstanding slow work items belonging to a module to clear when\nunregistering that module as a user of the facility.  This prevents the put_ref\ncode of a work item from being taken away before it returns.\n\nSigned-off-by: David Howells \u003cdhowells@redhat.com\u003e\n"
    },
    {
      "commit": "952efe7b7840e1c726ae88222245e4efe6bd88f3",
      "tree": "fed43da6709707d0eb51b8695b6b382a221e99bd",
      "parents": [
        "ccc4fc3d11e91477036d1f82bfa2d442f6ce77f0"
      ],
      "author": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Fri Apr 03 16:42:39 2009 +0100"
      },
      "committer": {
        "name": "David Howells",
        "email": "dhowells@redhat.com",
        "time": "Fri Apr 03 16:42:39 2009 +0100"
      },
      "message": "FS-Cache: Add and document asynchronous operation handling\n\nAdd and document asynchronous operation handling for use by FS-Cache\u0027s data\nstorage and retrieval routines.\n\nThe following documentation is added to:\n\n\tDocumentation/filesystems/caching/operations.txt\n\n\t\t       \u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\n\t\t       ASYNCHRONOUS OPERATIONS HANDLING\n\t\t       \u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\n\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\nOVERVIEW\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\n\nFS-Cache has an asynchronous operations handling facility that it uses for its\ndata storage and retrieval routines.  Its operations are represented by\nfscache_operation structs, though these are usually embedded into some other\nstructure.\n\nThis facility is available to and expected to be be used by the cache backends,\nand FS-Cache will create operations and pass them off to the appropriate cache\nbackend for completion.\n\nTo make use of this facility, \u003clinux/fscache-cache.h\u003e should be #included.\n\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\nOPERATION RECORD INITIALISATION\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\n\nAn operation is recorded in an fscache_operation struct:\n\n\tstruct fscache_operation {\n\t\tunion {\n\t\t\tstruct work_struct fast_work;\n\t\t\tstruct slow_work slow_work;\n\t\t};\n\t\tunsigned long\t\tflags;\n\t\tfscache_operation_processor_t processor;\n\t\t...\n\t};\n\nSomeone wanting to issue an operation should allocate something with this\nstruct embedded in it.  They should initialise it by calling:\n\n\tvoid fscache_operation_init(struct fscache_operation *op,\n\t\t\t\t    fscache_operation_release_t release);\n\nwith the operation to be initialised and the release function to use.\n\nThe op-\u003eflags parameter should be set to indicate the CPU time provision and\nthe exclusivity (see the Parameters section).\n\nThe op-\u003efast_work, op-\u003eslow_work and op-\u003eprocessor flags should be set as\nappropriate for the CPU time provision (see the Parameters section).\n\nFSCACHE_OP_WAITING may be set in op-\u003eflags prior to each submission of the\noperation and waited for afterwards.\n\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\nPARAMETERS\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\n\nThere are a number of parameters that can be set in the operation record\u0027s flag\nparameter.  There are three options for the provision of CPU time in these\noperations:\n\n (1) The operation may be done synchronously (FSCACHE_OP_MYTHREAD).  A thread\n     may decide it wants to handle an operation itself without deferring it to\n     another thread.\n\n     This is, for example, used in read operations for calling readpages() on\n     the backing filesystem in CacheFiles.  Although readpages() does an\n     asynchronous data fetch, the determination of whether pages exist is done\n     synchronously - and the netfs does not proceed until this has been\n     determined.\n\n     If this option is to be used, FSCACHE_OP_WAITING must be set in op-\u003eflags\n     before submitting the operation, and the operating thread must wait for it\n     to be cleared before proceeding:\n\n\t\twait_on_bit(\u0026op-\u003eflags, FSCACHE_OP_WAITING,\n\t\t\t    fscache_wait_bit, TASK_UNINTERRUPTIBLE);\n\n (2) The operation may be fast asynchronous (FSCACHE_OP_FAST), in which case it\n     will be given to keventd to process.  Such an operation is not permitted\n     to sleep on I/O.\n\n     This is, for example, used by CacheFiles to copy data from a backing fs\n     page to a netfs page after the backing fs has read the page in.\n\n     If this option is used, op-\u003efast_work and op-\u003eprocessor must be\n     initialised before submitting the operation:\n\n\t\tINIT_WORK(\u0026op-\u003efast_work, do_some_work);\n\n (3) The operation may be slow asynchronous (FSCACHE_OP_SLOW), in which case it\n     will be given to the slow work facility to process.  Such an operation is\n     permitted to sleep on I/O.\n\n     This is, for example, used by FS-Cache to handle background writes of\n     pages that have just been fetched from a remote server.\n\n     If this option is used, op-\u003eslow_work and op-\u003eprocessor must be\n     initialised before submitting the operation:\n\n\t\tfscache_operation_init_slow(op, processor)\n\nFurthermore, operations may be one of two types:\n\n (1) Exclusive (FSCACHE_OP_EXCLUSIVE).  Operations of this type may not run in\n     conjunction with any other operation on the object being operated upon.\n\n     An example of this is the attribute change operation, in which the file\n     being written to may need truncation.\n\n (2) Shareable.  Operations of this type may be running simultaneously.  It\u0027s\n     up to the operation implementation to prevent interference between other\n     operations running at the same time.\n\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\nPROCEDURE\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\n\nOperations are used through the following procedure:\n\n (1) The submitting thread must allocate the operation and initialise it\n     itself.  Normally this would be part of a more specific structure with the\n     generic op embedded within.\n\n (2) The submitting thread must then submit the operation for processing using\n     one of the following two functions:\n\n\tint fscache_submit_op(struct fscache_object *object,\n\t\t\t      struct fscache_operation *op);\n\n\tint fscache_submit_exclusive_op(struct fscache_object *object,\n\t\t\t\t\tstruct fscache_operation *op);\n\n     The first function should be used to submit non-exclusive ops and the\n     second to submit exclusive ones.  The caller must still set the\n     FSCACHE_OP_EXCLUSIVE flag.\n\n     If successful, both functions will assign the operation to the specified\n     object and return 0.  -ENOBUFS will be returned if the object specified is\n     permanently unavailable.\n\n     The operation manager will defer operations on an object that is still\n     undergoing lookup or creation.  The operation will also be deferred if an\n     operation of conflicting exclusivity is in progress on the object.\n\n     If the operation is asynchronous, the manager will retain a reference to\n     it, so the caller should put their reference to it by passing it to:\n\n\tvoid fscache_put_operation(struct fscache_operation *op);\n\n (3) If the submitting thread wants to do the work itself, and has marked the\n     operation with FSCACHE_OP_MYTHREAD, then it should monitor\n     FSCACHE_OP_WAITING as described above and check the state of the object if\n     necessary (the object might have died whilst the thread was waiting).\n\n     When it has finished doing its processing, it should call\n     fscache_put_operation() on it.\n\n (4) The operation holds an effective lock upon the object, preventing other\n     exclusive ops conflicting until it is released.  The operation can be\n     enqueued for further immediate asynchronous processing by adjusting the\n     CPU time provisioning option if necessary, eg:\n\n\top-\u003eflags \u0026\u003d ~FSCACHE_OP_TYPE;\n\top-\u003eflags |\u003d ~FSCACHE_OP_FAST;\n\n     and calling:\n\n\tvoid fscache_enqueue_operation(struct fscache_operation *op)\n\n     This can be used to allow other things to have use of the worker thread\n     pools.\n\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\nASYNCHRONOUS CALLBACK\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\n\nWhen used in asynchronous mode, the worker thread pool will invoke the\nprocessor method with a pointer to the operation.  This should then get at the\ncontainer struct by using container_of():\n\n\tstatic void fscache_write_op(struct fscache_operation *_op)\n\t{\n\t\tstruct fscache_storage *op \u003d\n\t\t\tcontainer_of(_op, struct fscache_storage, op);\n\t...\n\t}\n\nThe caller holds a reference on the operation, and will invoke\nfscache_put_operation() when the processor function returns.  The processor\nfunction is at liberty to call fscache_enqueue_operation() or to take extra\nreferences.\n\nSigned-off-by: David Howells \u003cdhowells@redhat.com\u003e\nAcked-by: Steve Dickson \u003csteved@redhat.com\u003e\nAcked-by: Trond Myklebust \u003cTrond.Myklebust@netapp.com\u003e\nAcked-by: Al Viro \u003cviro@zeniv.linux.org.uk\u003e\nTested-by: Daire Byrne \u003cDaire.Byrne@framestore.com\u003e\n"
    }
  ]
}
