{"action":"created","issue":{"url":"https://api.github.com/repos/raspberrypi/linux/issues/1031","labels_url":"https://api.github.com/repos/raspberrypi/linux/issues/1031/labels{/name}","comments_url":"https://api.github.com/repos/raspberrypi/linux/issues/1031/comments","events_url":"https://api.github.com/repos/raspberrypi/linux/issues/1031/events","html_url":"https://github.com/raspberrypi/linux/issues/1031","id":90159252,"number":1031,"title":"Support gpio-poweroff driver to allow switching off power","user":{"login":"brycewilkins","id":13003844,"avatar_url":"https://avatars.githubusercontent.com/u/13003844?v=3","gravatar_id":"","url":"https://api.github.com/users/brycewilkins","html_url":"https://github.com/brycewilkins","followers_url":"https://api.github.com/users/brycewilkins/followers","following_url":"https://api.github.com/users/brycewilkins/following{/other_user}","gists_url":"https://api.github.com/users/brycewilkins/gists{/gist_id}","starred_url":"https://api.github.com/users/brycewilkins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brycewilkins/subscriptions","organizations_url":"https://api.github.com/users/brycewilkins/orgs","repos_url":"https://api.github.com/users/brycewilkins/repos","events_url":"https://api.github.com/users/brycewilkins/events{/privacy}","received_events_url":"https://api.github.com/users/brycewilkins/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-06-22T17:19:48Z","updated_at":"2015-06-24T16:54:26Z","closed_at":null,"body":"I tried to use the device tree GPIO binding gpio-poweroff to switch off power to the Raspberry Pi (via an on/off push-button controller) once the system reaches 'halt' state.  Please see these links for info:\r\nhttps://github.com/raspberrypi/linux/blob/rpi-4.0.y/Documentation/devicetree/bindings/gpio/gpio-poweroff.txt\r\nand\r\nhttps://www.raspberrypi.org/forums/viewtopic.php?f=107&t=113789.\r\n\r\nIt did not work because the standard Raspberry Pi configurations do not include the gpio-poweroff driver which must be enabled using the POWER_RESET and POWER_RESET_GPIO flags.  I would like to request these additions.\r\n\r\nI believe this would be an excellent feature to have support for as it will allow the RPi to actually switch off the power to a system it is controlling once it reaches a shutdown state.  Currently the RPi enters a low-power shutdown state, but circuitry controlling the power (and anything connected to it) remains on.\r\n\r\nAs the gpio-poweroff driver would only be enabled by a device tree overlay it will not cause any conflict/incompatibility with existing systems.\r\n\r\nThank you!"},"comment":{"url":"https://api.github.com/repos/raspberrypi/linux/issues/comments/114940385","html_url":"https://github.com/raspberrypi/linux/issues/1031#issuecomment-114940385","issue_url":"https://api.github.com/repos/raspberrypi/linux/issues/1031","id":114940385,"user":{"login":"brycewilkins","id":13003844,"avatar_url":"https://avatars.githubusercontent.com/u/13003844?v=3","gravatar_id":"","url":"https://api.github.com/users/brycewilkins","html_url":"https://github.com/brycewilkins","followers_url":"https://api.github.com/users/brycewilkins/followers","following_url":"https://api.github.com/users/brycewilkins/following{/other_user}","gists_url":"https://api.github.com/users/brycewilkins/gists{/gist_id}","starred_url":"https://api.github.com/users/brycewilkins/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brycewilkins/subscriptions","organizations_url":"https://api.github.com/users/brycewilkins/orgs","repos_url":"https://api.github.com/users/brycewilkins/repos","events_url":"https://api.github.com/users/brycewilkins/events{/privacy}","received_events_url":"https://api.github.com/users/brycewilkins/received_events","type":"User","site_admin":false},"created_at":"2015-06-24T16:54:26Z","updated_at":"2015-06-24T16:54:26Z","body":"@popcornmix Unfortunately no success yet, here is what I did.  \r\n\r\n- Ran rpi-update and got the 4.0.6 kernel\r\n- Recompile dt-blob.dts to /boot/dt-blob.bin\r\n- Recompile my power-off DT overlay and put in /boot/overlays/\r\n\r\nPlease see my thread in raspberrypi.org forum for details (link in original post above).  \r\n\r\nI put an oscilloscope on GPIO 26 which I'm using as the power-off control signal.  The pin goes high during boot when dt-blob.bin is loaded, but when I execute \"shutdown -h now\" or \"poweroff\" the pin remains high after the 'halt' state.  (At the end of shutdown the Raspberry Pi green \"disk activity\" LED blinks a few times then stays off, while the red \"power\" LED stays on.)\r\n\r\nThe overlay seems to be loaded as I have directory /proc/device-tree/soc/gpio/power_ctrl/ and files within, but I wonder if the fragment@0 is correct.\r\n\r\nHow can I help to get it working?  Thank you!"}}