lkml.org 
[lkml]   [2015]   [Feb]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v6 2/2] fbcon: expose cursor blink interval via sysfs
On 30/01/15 11:40, Scot Doyle wrote:
> fbcon toggles cursor display state every 200 milliseconds when blinking.
> Since users prefer different toggle intervals, expose the interval via
> /sys/class/graphics/fbcon/cursor_blink_ms so that it may be customized.
>
> Values written to the interface set the approximate time interval in
> milliseconds between cursor toggles, from 1 to 32767. Since the interval
> is stored internally as a number of jiffies, the millisecond value read
> from the interface may not exactly match the entered value.
>
> An outstanding blink timer is reset after a new value is entered.
>
> If the cursor blink is disabled, either via the 'cursor_blink' boolean
> setting or some other mechanism, the 'cursor_blink_ms' setting may still
> be modified. The new value will be used if the blink is reactivated.
>
> Signed-off-by: Scot Doyle <lkml14@scotdoyle.com>
> ---
> drivers/video/console/fbcon.c | 65 +++++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 65 insertions(+)
>
> diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c
> index 7a2030b..7baa333 100644
> --- a/drivers/video/console/fbcon.c
> +++ b/drivers/video/console/fbcon.c
> @@ -3495,11 +3495,76 @@ err:
> return count;
> }
>
> +static ssize_t show_cursor_blink_ms(struct device *device,
> + struct device_attribute *attr, char *buf)
> +{
> + struct fbcon_ops *ops;
> + int idx, ms = -1;
> +
> + if (fbcon_has_exited)
> + return -ENODEV;
> +
> + console_lock();
> + idx = con2fb_map[fg_console];
> +
> + if (idx != -1 && registered_fb[idx] != NULL) {
> + ops = ((struct fb_info *)registered_fb[idx])->fbcon_par;

I don't think the above typecast is needed. I can remove the typecast
when applying to my tree.

So queuing for 3.21. Thanks!

Tomi


[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2015-02-20 13:21    [W:0.067 / U:0.052 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site