)]}'
{
  "commit": "ed3ee5cd0640979a200710b9eefa210a617b19ff",
  "tree": "0fc6bd37d6a15e06add67e2ddb9263e63f0ad64a",
  "parents": [
    "d17da65560f15f74f8efe321044b9cdf45e24c9b"
  ],
  "author": {
    "name": "Simon Glass",
    "email": "sjg@chromium.org",
    "time": "Mon Feb 27 10:52:36 2012 +0000"
  },
  "committer": {
    "name": "Albert ARIBAUD",
    "email": "albert.u.boot@aribaud.net",
    "time": "Thu Mar 29 08:12:47 2012 +0200"
  },
  "message": "fdt: Add basic support for decoding GPIO definitions\n\nThis adds some support into fdtdec for reading GPIO definitions from\nthe fdt. We permit up to FDT_GPIO_MAX GPIOs in the system. Each GPIO\nis of the form:\n\ngpio-function-name \u003d \u003cphandle gpio_num flags\u003e;\n\nwhere:\n\nphandle is a pointer to the GPIO node\ngpio_num is the number of the GPIO (0 to 223)\nflags is a flag, as follows:\n\n   bit    meaning\n   0      0\u003dpolarity normal, 1\u003dactive low (inverted)\n\nAn example is:\n\nenable-propounder-gpios \u003d \u003c\u0026gpio 43 0\u003e;\n\nwhich means that GPIO 43 is used to enable the propounder (setting the\nGPIO high), or that you can detect that the propounder is enabled by\nchecking if the GPIO is high (the fdt does not indicate input/output).\n\nTwo main functions are provided:\n\nfdtdec_decode_gpio() reads a GPIO property from an fdt node and decodes it\ninto a structure.\n\nfdtdec_setup_gpio() sets up the GPIO by calling gpio_request for you.\n\nBoth functions can cope with the property being missing, which is taken to\nmean that that GPIO function is not available or is not needed.\n\n[For reference, from Stephen Warren \u003cswarren@nvidia.com\u003e. It may be that\nwe add this extra complexity later if needed:\n\nThe correct way to parse such a GPIO property in general is:\n\n* Read the first cell.\n* Find the node referenced by the phandle (the controller).\n* Ensure property gpio-controller is present in the controller node.\n* Read property #gpio-cells from the controller node.\n* Extract #gpio-cells from the original property.\n* Keep processing more cells from the original property; there may be\nmultiple GPIOs listed.\n\nAccording to the binding documentation in the Linux kernel, Samsung\nExynos4 doesn\u0027t use this format, and while all other chips do have a\nflags cell, about 50% of the controllers indicate the cell is unused.\n]\n\nSigned-off-by: Simon Glass \u003csjg@chromium.org\u003e\nSigned-off-by: Tom Warren \u003ctwarren@nvidia.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "a4467000b7f42ef9be2ab452820e0e23636fd0f8",
      "old_mode": 33188,
      "old_path": "include/fdtdec.h",
      "new_id": "2f3842d9a306c28b05577c0c548995157259a971",
      "new_mode": 33188,
      "new_path": "include/fdtdec.h"
    },
    {
      "type": "modify",
      "old_id": "13bb47002e463e9e24af33b377b66380952088cf",
      "old_mode": 33188,
      "old_path": "lib/fdtdec.c",
      "new_id": "de83226ed1faf2d89b905791373323173db17ae0",
      "new_mode": 33188,
      "new_path": "lib/fdtdec.c"
    }
  ]
}
