Re: [PATCH] Adding backlight support for the i915 driver.

2015-03-31 Thread Ranjan1018 .
2015-03-27 16:53 GMT+01:00 Hans Petter Selasky h...@selasky.org:

 On 03/27/15 16:01, Ranjan1018 . wrote:

 This  patch exposes the backlight support  via a sysctl:

 set the backlight to 10%:

 # sysctl hw.dri.0.i915_backlight=10

 hw.dri.0.i915_backlight: 25 - 10

 set the backlight to 50%:

 # sysctl hw.dri.0.i915_backlight=50

 hw.dri.0.i915_backlight: 10 - 50

 decrease  the current backlight value:

 # sysctl hw.dri.0.i915_backlight=-1000

 hw.dri.0.i915_backlight: 50 - 43

 increment the current backlight value:

 # sysctl hw.dri.0.i915_backlight=1000

 hw.dri.0.i915_backlight: 43 - 51

 # sysctl hw.dri.0.i915_backlight=1000

 hw.dri.0.i915_backlight: 51 - 60

 I am running this path on for about a week without issue.

 This path can be found at:
 https://github.com/maurizio-emmex/i915_backlight_freebsd

 I thank Elizabeth Myers, elizabeth at interlinked dot me, for the idea of
 adding the backlight support for the i915 driver and for the original
 patch.

 Regards,
 Maurizio


 Maybe you want to use CTLFLAG_RWTUN so that it also can be set from
 /boot/loader.conf ?

 --HPS


The ability to set the backlight at startup may be useful. With this new
patch I expose two ways to do this:
- with the tunable drm.i915.init_backlight in /boot/loader.conf, just
after the driver initialization (eg.  drm.i915.init_backlight=20)
- with the OID hw.dri.0.i915_backlight in /etc/sysctl.conf as suggested
by Hans
I don’t know if setting the backlight with the tunable
drm.i915.init_backlight is useful, but I have already written the code
and is simple to remove it.
The patch file is i915_backlight.patch at
https://github.com/maurizio-emmex/i915_backlight_freebsd

Regards,
Maurizio
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org

[PATCH] Adding backlight support for the i915 driver.

2015-03-27 Thread Ranjan1018 .
This  patch exposes the backlight support  via a sysctl:

set the backlight to 10%:

# sysctl hw.dri.0.i915_backlight=10

hw.dri.0.i915_backlight: 25 - 10

set the backlight to 50%:

# sysctl hw.dri.0.i915_backlight=50

hw.dri.0.i915_backlight: 10 - 50

decrease  the current backlight value:

# sysctl hw.dri.0.i915_backlight=-1000

hw.dri.0.i915_backlight: 50 - 43

increment the current backlight value:

# sysctl hw.dri.0.i915_backlight=1000

hw.dri.0.i915_backlight: 43 - 51

# sysctl hw.dri.0.i915_backlight=1000

hw.dri.0.i915_backlight: 51 - 60

I am running this path on for about a week without issue.

This path can be found at:
https://github.com/maurizio-emmex/i915_backlight_freebsd

I thank Elizabeth Myers, elizabeth at interlinked dot me, for the idea of
adding the backlight support for the i915 driver and for the original patch.

Regards,
Maurizio
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org


Re: [PATCH] Adding backlight support for the i915 driver.

2015-03-27 Thread Hans Petter Selasky

On 03/27/15 16:01, Ranjan1018 . wrote:

This  patch exposes the backlight support  via a sysctl:

set the backlight to 10%:

# sysctl hw.dri.0.i915_backlight=10

hw.dri.0.i915_backlight: 25 - 10

set the backlight to 50%:

# sysctl hw.dri.0.i915_backlight=50

hw.dri.0.i915_backlight: 10 - 50

decrease  the current backlight value:

# sysctl hw.dri.0.i915_backlight=-1000

hw.dri.0.i915_backlight: 50 - 43

increment the current backlight value:

# sysctl hw.dri.0.i915_backlight=1000

hw.dri.0.i915_backlight: 43 - 51

# sysctl hw.dri.0.i915_backlight=1000

hw.dri.0.i915_backlight: 51 - 60

I am running this path on for about a week without issue.

This path can be found at:
https://github.com/maurizio-emmex/i915_backlight_freebsd

I thank Elizabeth Myers, elizabeth at interlinked dot me, for the idea of
adding the backlight support for the i915 driver and for the original patch.

Regards,
Maurizio


Maybe you want to use CTLFLAG_RWTUN so that it also can be set from 
/boot/loader.conf ?


--HPS
___
freebsd-current@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to freebsd-current-unsubscr...@freebsd.org