)]}'
{
  "commit": "d82b35186eaa816267f044bd70cc0acb3c7971a3",
  "tree": "e8de56c122fd8040086e974895afbb8299045c0f",
  "parents": [
    "4ef7229ffa93695e346d510b871452811509ea65"
  ],
  "author": {
    "name": "Mark Gross",
    "email": "mgross@linux.intel.com",
    "time": "Mon Feb 04 22:30:08 2008 -0800"
  },
  "committer": {
    "name": "Linus Torvalds",
    "email": "torvalds@woody.linux-foundation.org",
    "time": "Tue Feb 05 09:44:22 2008 -0800"
  },
  "message": "pm qos infrastructure and interface\n\nThe following patch is a generalization of the latency.c implementation done\nby Arjan last year.  It provides infrastructure for more than one parameter,\nand exposes a user mode interface for processes to register pm_qos\nexpectations of processes.\n\nThis interface provides a kernel and user mode interface for registering\nperformance expectations by drivers, subsystems and user space applications on\none of the parameters.\n\nCurrently we have {cpu_dma_latency, network_latency, network_throughput} as\nthe initial set of pm_qos parameters.\n\nThe infrastructure exposes multiple misc device nodes one per implemented\nparameter.  The set of parameters implement is defined by pm_qos_power_init()\nand pm_qos_params.h.  This is done because having the available parameters\nbeing runtime configurable or changeable from a driver was seen as too easy to\nabuse.\n\nFor each parameter a list of performance requirements is maintained along with\nan aggregated target value.  The aggregated target value is updated with\nchanges to the requirement list or elements of the list.  Typically the\naggregated target value is simply the max or min of the requirement values\nheld in the parameter list elements.\n\n\u003eFrom kernel mode the use of this interface is simple:\n\npm_qos_add_requirement(param_id, name, target_value):\n\n  Will insert a named element in the list for that identified PM_QOS\n  parameter with the target value.  Upon change to this list the new target is\n  recomputed and any registered notifiers are called only if the target value\n  is now different.\n\npm_qos_update_requirement(param_id, name, new_target_value):\n\n  Will search the list identified by the param_id for the named list element\n  and then update its target value, calling the notification tree if the\n  aggregated target is changed.  with that name is already registered.\n\npm_qos_remove_requirement(param_id, name):\n\n  Will search the identified list for the named element and remove it, after\n  removal it will update the aggregate target and call the notification tree\n  if the target was changed as a result of removing the named requirement.\n\n\u003eFrom user mode:\n\n  Only processes can register a pm_qos requirement.  To provide for\n  automatic cleanup for process the interface requires the process to register\n  its parameter requirements in the following way:\n\n  To register the default pm_qos target for the specific parameter, the\n  process must open one of /dev/[cpu_dma_latency, network_latency,\n  network_throughput]\n\n  As long as the device node is held open that process has a registered\n  requirement on the parameter.  The name of the requirement is\n  \"process_\u003cPID\u003e\" derived from the current-\u003epid from within the open system\n  call.\n\n  To change the requested target value the process needs to write a s32\n  value to the open device node.  This translates to a\n  pm_qos_update_requirement call.\n\n  To remove the user mode request for a target value simply close the device\n  node.\n\n[akpm@linux-foundation.org: fix warnings]\n[akpm@linux-foundation.org: fix build]\n[akpm@linux-foundation.org: fix build again]\n[akpm@linux-foundation.org: coding-style fixes]\nSigned-off-by: mark gross \u003cmgross@linux.intel.com\u003e\nCc: \"John W. Linville\" \u003clinville@tuxdriver.com\u003e\nCc: Len Brown \u003clenb@kernel.org\u003e\nCc: Jaroslav Kysela \u003cperex@suse.cz\u003e\nCc: Takashi Iwai \u003ctiwai@suse.de\u003e\nCc: Arjan van de Ven \u003carjan@infradead.org\u003e\nCc: Venki Pallipadi \u003cvenkatesh.pallipadi@intel.com\u003e\nCc: Adam Belay \u003cabelay@novell.com\u003e\nSigned-off-by: Andrew Morton \u003cakpm@linux-foundation.org\u003e\nSigned-off-by: Linus Torvalds \u003ctorvalds@linux-foundation.org\u003e\n",
  "tree_diff": [
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "49adb1a3351487d992aeb922a34604b46691a7c5",
      "new_mode": 33188,
      "new_path": "Documentation/pm_qos_interface.txt"
    },
    {
      "type": "modify",
      "old_id": "d2fabe7863a96345e096f5a644c111436a492819",
      "old_mode": 33188,
      "old_path": "drivers/cpuidle/cpuidle.c",
      "new_id": "2a98d99cbd46075707c15572dff6ace4e6c602c3",
      "new_mode": 33188,
      "new_path": "drivers/cpuidle/cpuidle.c"
    },
    {
      "type": "modify",
      "old_id": "eb666ecae7c913a769529a9b0debef857947103d",
      "old_mode": 33188,
      "old_path": "drivers/cpuidle/governors/ladder.c",
      "new_id": "ba7b9a6b17a13678896bd1390b1d4823504b641a",
      "new_mode": 33188,
      "new_path": "drivers/cpuidle/governors/ladder.c"
    },
    {
      "type": "modify",
      "old_id": "299d45c3bdd28c6f6111dde39080c76c51dfb172",
      "old_mode": 33188,
      "old_path": "drivers/cpuidle/governors/menu.c",
      "new_id": "78d77c5dc35c3ec00b261fa39a7e3aa89271a957",
      "new_mode": 33188,
      "new_path": "drivers/cpuidle/governors/menu.c"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "2e4e97bd19f73ad9a2db3d43fef923a7af7e28af",
      "new_mode": 33188,
      "new_path": "include/linux/pm_qos_params.h"
    },
    {
      "type": "modify",
      "old_id": "db9af707ff5bbf828174381cf64c65684978bf53",
      "old_mode": 33188,
      "old_path": "kernel/Makefile",
      "new_id": "8331243a4e5ebd1fb286fd9a69a87021b5362da5",
      "new_mode": 33188,
      "new_path": "kernel/Makefile"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "0afe32be4c8530851a912dde00a6ed5c0f24cf49",
      "new_mode": 33188,
      "new_path": "kernel/pm_qos_params.c"
    }
  ]
}
