agp_bridge_data::type is unused (and I cannot find when was used last).
Therefore, remove it.
Found by https://github.com/jirislaby/clang-struct.
Signed-off-by: Jiri Slaby (SUSE)
Cc: David Airlie
Cc: dri-devel@lists.freedesktop.org
---
drivers/char/agp/agp.h | 1 -
1 file changed, 1 deletion
t only for user fonts. Note the
later 'if' is now protected by 'old_userfont' and not 'old_data' as the
latter is always set now. (And it is supposed to be non-NULL. Otherwise
we would see the bug above again.)
Signed-off-by: Jiri Slaby (SUSE)
Fixes: a5a923038d70
Again, fbcon_getxy() is the same as the default implementation since the
softscroll removal in commit 50145474f6ef (fbcon: remove soft scrollback
code). Drop that.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel
llback code), both are always the same.
So remove fbcon_screen_pos() too.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/video/fbdev/core/fbcon.c | 6 --
1 file changed, 6 deletions(-)
d
Provided the font parameter of consw::con_font_set() is not supposed to
be changed, make it const.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc:
Both the mode_switch parameter and the return value (a redraw needed)
are true/false. So switch them to bool, so that users won't return
-Eerrors or anything else.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Ve
Use the new enum for VESA constants. This improves type checking in
consw::con_blank().
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-par...@vger.
Make parameters of consw::con_putc() saner:
* x and y are unsigned now, as they cannot be negative, and
* ca is made u16, as it is composed of two 8bit values (character and
attribute). See the con_putcs() hook, u16/ushort is worked on there.
And document the hook.
Signed-off-by: Jiri Slaby
The non-zero (true) return value from consw::con_switch() means a redraw
is needed. So make this return type a bool explicitly instead of int.
The latter might imply that -Eerrors are expected. They are not.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "
It's a name after all and that is not supposed to be changed. So make it
const to make this obvious.
Signed-off-by: Jiri Slaby (SUSE)
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-par...@vger.kernel.o
This is only a preparation for the following cleanup patch to make it
easier. Provided CM_ERASE is the only different, use 'if' instead of
'switch+case' in all those.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@l
The return value of consw::con_set_origin() is only true/false, meaining
if vc->vc_origin is set to vc->vc_screenbuf or not.
So switch the type and returned values accordingly.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
C
missing (NULL).
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-par...@vger.kernel.org
---
drivers/video/console/mdacon.c | 6 --
drivers/video/consol
t
the macros are kept too (they now expand to the enum constants), just in
case someone in userspace performs some #ifdeffery.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-ker...@vger.kernel.org
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: Thomas Zimme
There are VESA blanking constants defined in vesa.h. So use them in the
console code instead of constant values.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-par...@vger.
left in place -- they are
taken care of in the next patches.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-par...@vger.kernel.org
---
d
ew lines above. So what matters there (as in all
other blank implementations except vgacon) is if 'blank' is zero or not.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/tty/vt/vt.c| 2 +-
driver
The return value of con_debug_enter() and con_debug_leave() is ignored
on many fronts. So just don't propagate errors (the current
implementations return 0 anyway) and make the return type a void.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: lin
There is no difference between CM_MOVE and CM_DRAW. Either of them
enables the cursor. CM_ERASE then disables cursor.
So get rid of all of them and use simple "bool enable".
Note that this propagates down to the fbcon code.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
There is a switch decicing if cursor should be drawn or not. The whole
switch can be simplified to one line. Do this cleanup as a preparatory
work for the next patch. There, all the CM_* constants are removed.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb
set). So for
the worst case, full line, it is 1.
Therefore, there is no point in checking zero or negative values (width
is now unsigned anyway).
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.fre
The 'init' parameter of consw::con_init() is true for the first call of
the hook on a particular console. So make the parameter a bool.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Reviewed-by: Geert Uytterhoeven
Cc: Helge Deller
Cc: "James E.J. Bottomley"
C
display_desc is a pointer to a RO string. Instead, switch display_desc
to a static array as we are used to. It BTW saves unnecessary 8B on the
stack.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: Thomas Zimmermann
Jiri Slaby (SUSE) (47):
vgacon: inline vc_scrolldelta_helper() into vgacon_scrolldelta()
fbcon: make display_desc a static array in fbcon_startup()
tty: vt: fix 20 vs 0x20 typo in EScsiignore
tty: vt: expect valid vc when in tty ops
tty: vt: pass proper pointers from
, it is
now an inline calling a new __vc_resize() which implements the above.
This patch makes the situation much more obvious.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/tty/vt/vt.c
Since commit 74d58cd48a8f ("USB: sisusbvga: remove console support"),
vgacon_scrolldelta() is the only user of vc_scrolldelta_helper().
Inline the helper into vgacon_scrolldelta() and drop it.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc:
Provided the font parameter of consw::con_font_set() is not supposed to
be changed, make it const.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc:
Both the mode_switch parameter and the return value (a redraw needed)
are true/false. So switch them to bool, so that users won't return
-Eerrors or anything else.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Ve
kernel too. So protect
them using __KERNEL__. In the kernel case, include linux/console.h
instead. This header dependency is preexisting.
Alternatively, we could create a vesa.h header with that sole enum and
include it. If it turns out linux/console.h is too much for fb.h.
Signed-off-by: Jiri Slaby
There are VESA blanking constants defined in console.h already. So use
them in the console code instead of constant values.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc:
ew lines above. So what matters there (as in all
other blank implementations except vgacon) is if 'blank' is zero or not.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/tty/vt/vt.c| 2 +-
driver
Again, fbcon_getxy() is the same as the default implementation since the
softscroll removal in commit 50145474f6ef (fbcon: remove soft scrollback
code). Drop that.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel
There is a switch decicing if cursor should be drawn or not. The whole
switch can be simplified to one line. Do this cleanup as a preparatory
work for the next patch. There, all the CM_* constants are removed.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb
llback code), both are always the same.
So remove fbcon_screen_pos() too.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/video/fbdev/core/fbcon.c | 6 --
1 file changed, 6 deletions(-)
d
The return value of consw::con_set_origin() is only true/false, meaining
if vc->vc_origin is set to vc->vc_screenbuf or not.
So switch the type and returned values accordingly.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
C
Make parameters of consw::con_putc() saner:
* x and y are unsigned now, as they cannot be negative, and
* ca is made u16, as it is composed of two 8bit values (character and
attribute). See the con_putcs() hook, u16/ushort is worked on there.
And document the hook.
Signed-off-by: Jiri Slaby
It's a name after all and that is not supposed to be changed. So make it
const to make this obvious.
Signed-off-by: Jiri Slaby (SUSE)
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-par...@vger.kernel.o
The return value of con_debug_enter() and con_debug_leave() is ignored
on many fronts. So just don't propagate errors (the current
implementations return 0 anyway) and make the return type a void.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: lin
The non-zero (true) return value from consw::con_switch() means a redraw
is needed. So make this return type a bool explicitly instead of int.
The latter might imply that -Eerrors are expected. They are not.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "
There is no difference between CM_MOVE and CM_DRAW. Either of them
enables the cursor. CM_ERASE then disables cursor.
So get rid of all of them and use simple "bool enable".
Note that this propagates down to the fbcon code.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
This is only a preparation for the following cleanup patch to make it
easier. Provided CM_ERASE is the only different, use 'if' instead of
'switch+case' in all those.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@l
missing (NULL).
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-par...@vger.kernel.org
---
drivers/video/console/mdacon.c | 6 --
drivers/video/consol
set). So for
the worst case, full line, it is 1.
Therefore, there is no point in checking zero or negative values (width
is now unsigned anyway).
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.fre
left in place -- they are
taken care of in the next patches.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: linux-par...@vger.kernel.org
---
d
The 'init' parameter of consw::con_init() is true for the first call of
the hook on a particular console. So make the parameter a bool.
And document the hook.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: "James E.J. Bottomley"
Cc: Daniel Vetter
Cc: linux-fb..
Cc: "James E.J. Bottomley"
Cc: Jonathan Corbet
Cc: linux-...@vger.kernel.org
Cc: linux-fb...@vger.kernel.org
Cc: linux-par...@vger.kernel.org
Cc: Martin Hostettler
Jiri Slaby (SUSE) (45):
vgacon: inline vc_scrolldelta_helper() into vgacon_scrolldelta()
fbcon: make display_desc a st
Since commit 74d58cd48a8f ("USB: sisusbvga: remove console support"),
vgacon_scrolldelta() is the only user of vc_scrolldelta_helper().
Inline the helper into vgacon_scrolldelta() and drop it.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc:
, it is
now an inline calling a new __vc_resize() which implements the above.
This patch makes the situation much more obvious.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: Daniel Vetter
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/tty/vt/vt.c
display_desc is a pointer to a RO string. Instead, switch display_desc
to a static array as we are used to. It BTW saves unnecessary 8B on the
stack.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
The parameter is unused.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Daniel Vetter
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/video/fbdev/core/fbcon.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/drivers/video/fbdev
There are many places c->vc_cell_height is used in the code of
vgacon_cursor(). Caching the value to a local variable makes the code
much easier to follow.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/vi
sticon_set_def_font() always returns 0, so make it void. And remove an
unused 'op' parameter.
Signed-off-by: Jiri Slaby (SUSE)
Cc: "James E.J. Bottomley"
Cc: Helge Deller
Cc: linux-par...@vger.kernel.org
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.or
xpos is unused, remove it.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/video/console/vgacon.c | 25 ++---
1 file changed, 10 insertions(+), 15 deletions(-)
diff --git a/drivers/video
The return value is neither used, nor vgacon_doresize() returns an
error. So change the reurn type to void.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/video/console/vgacon.c | 3 +--
1 file changed, 1
Most of the forward declarations in vgacon are not needed. Drop them.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/video/console/vgacon.c | 10 +-
1 file changed, 1 insertion(+), 9 deletions(-)
diff
Switch vgacon_scrolldelta() and vgacon_restore_screen() positions, so
that the former is not needed to be forward-declared.
Signed-off-by: Jiri Slaby (SUSE)
Cc: Helge Deller
Cc: linux-fb...@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
---
drivers/video/console/vgacon.c | 12
dri-devel@lists.freedesktop.org
Cc: nouv...@lists.freedesktop.org
Cc: linux-ker...@vger.kernel.org
Signed-off-by: Jiri Slaby (SUSE)
---
Notes:
[v2] switch to uint instead of to enum
drivers/gpu/drm/nouveau/dispnv50/wndw.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/gp
dri-devel@lists.freedesktop.org
Cc: nouv...@lists.freedesktop.org
Cc: linux-ker...@vger.kernel.org
Signed-off-by: Jiri Slaby (SUSE)
---
Notes:
[v2] switch to uint instead of to enum
drivers/gpu/drm/nouveau/dispnv50/wndw.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/gp
dri-devel@lists.freedesktop.org
Cc: nouv...@lists.freedesktop.org
Cc: linux-ker...@vger.kernel.org
Signed-off-by: Jiri Slaby (SUSE)
---
drivers/gpu/drm/nouveau/dispnv50/wndw.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/dispnv50/wndw.h
b/drivers/gpu/drm/no
Cc: intel-...@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Jiri Slaby (SUSE)
---
Notes:
[v2] fixed e-mail setup
drivers/gpu/drm/i915/display/intel_pipe_crc.c | 1 -
drivers/gpu/drm/i915/i915_irq.c | 1 -
2 files changed, 2 deletions(-)
diff --git a/drive
;
Cc: "Pan, Xinhui"
Cc: David Airlie
Cc: Daniel Vetter
Cc: amd-...@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Jiri Slaby (SUSE)
---
.../drm/amd/display/dc/clk_mgr/dcn21/rn_clk_mgr_vbios_smu.h | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
dri-devel@lists.freedesktop.org
Cc: nouv...@lists.freedesktop.org
Cc: linux-ker...@vger.kernel.org
Signed-off-by: Jiri Slaby (SUSE)
---
drivers/gpu/drm/nouveau/dispnv50/wndw.h | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/dispnv50/wndw.h
b/drivers/gpu/drm/no
Cc: intel-...@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Signed-off-by: Jiri Slaby (SUSE)
---
drivers/gpu/drm/i915/display/intel_pipe_crc.c | 1 -
drivers/gpu/drm/i915/i915_irq.c | 1 -
2 files changed, 2 deletions(-)
diff --git a/drivers/gpu/drm/i915/display/intel_pip
Cc: Jani Nikula
Cc: Joonas Lahtinen
Cc: Rodrigo Vivi
Cc: Tvrtko Ursulin
Cc: David Airlie
Cc: Daniel Vetter
Cc: intel-...@lists.freedesktop.org
Cc: dri-devel@lists.freedesktop.org
Reported-by: Martin Liška
Signed-off-by: Jiri Slaby (SUSE)
---
drivers/gpu/drm/i915/display/intel_backlight.c | 2 +-
64 matches
Mail list logo