kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
From: masneyb@onstation.org (Brian Masney)
To: kernelnewbies@lists.kernelnewbies.org
Subject: How to control power of a device from sysfs ?
Date: Mon, 5 Dec 2016 05:29:14 -0500	[thread overview]
Message-ID: <20161205102914.GA23211@basecamp.onstation.org> (raw)
In-Reply-To: <CAJ2oMh+HuJhWHGqATxi27W_=kj2R=8XOw0NLW0tc6HY4HJZPqg@mail.gmail.com>

On Mon, Dec 05, 2016 at 09:26:27AM +0200, Ran Shalit wrote:
> Hello,
> 
> I am trying to turn off screen using sysfs entries,
> but I'm having some difficulties with it:
> 
> 1.
> command:
> echo 0 > /sys/devices/platform/s5p-dsim.0/ea8061/backlight/panel/brightness
> result:
> screen is dimmed - BUT not turned off
> 
> 2.
> command:
> cat
> /sys/devices/platform/s5p-dsim.0/ea8061/backlight/panel/actual_brightness
> 20
> 
> This strengthen the fast that we didn't turned off brightness completely
> 
> 3. In this point I though that maybe I can turn off the whole brightness
> device
> 
> ls /sys/devices/platform/s5p-dsim.0/ea8061/backlight/panel/
>                     actual_brightness
> auto_brightness
> bl_power
> brightness
> device
> dimming
> max_brightness
> power
> subsystem
> type
> uevent
> 
> I made some trials , but didn't made it turned off yet.
> Is there any idea if it's possible to turn it off completely ?

If the driver supports power management, then you can control the power
state with the power/runtime_status sysfs entry. Some of the sysfs
entries in the power/ directory are documented in
Documentation/ABI/testing/sysfs-devices-power.

Brian

      parent reply	other threads:[~2016-12-05 10:29 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-05  7:26 How to control power of a device from sysfs ? Ran Shalit
2016-12-05  8:24 ` Umair Khan
2016-12-05  8:48   ` Ran Shalit
2016-12-05 10:29 ` Brian Masney [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161205102914.GA23211@basecamp.onstation.org \
    --to=masneyb@onstation.org \
    --cc=kernelnewbies@lists.kernelnewbies.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).