Linux Framebuffer Layer development
 help / color / mirror / Atom feed
From: Helge Deller <deller@gmx.de>
To: Thomas Zimmermann <tzimmermann@suse.de>,
	adaplas@gmail.com, michal.simek@amd.com
Cc: linux-fbdev@vger.kernel.org
Subject: Re: [PATCH 1/5] fbdev/au1100fb: Use FB blanking constants
Date: Sun, 18 Oct 2026 15:52:43 +0200	[thread overview]
Message-ID: <3ae4590b-c420-480f-a6a2-79700bf20a1a@gmx.de> (raw)
In-Reply-To: <20261009161814.120480-2-tzimmermann@suse.de>

Hi Thomas,

On 10/9/26 18:05, Thomas Zimmermann wrote:
> Fbdev and its drivers use FB_BLANK constants for controlling the
> display's blanking state. Semantics differ to similar VESA blanking
> constants.
> 
> Replace the VESA constants in au1100fb with FB_BLANK.

I understand that this series drops the VESA constants.
That seems logical and correct, but....

  
> Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
> ---
>   drivers/video/fbdev/au1100fb.c | 18 +++++++++---------
>   1 file changed, 9 insertions(+), 9 deletions(-)
> 
> diff --git a/drivers/video/fbdev/au1100fb.c b/drivers/video/fbdev/au1100fb.c
> index 39f86ffb1ae3..6c375f389fbd 100644
> --- a/drivers/video/fbdev/au1100fb.c
> +++ b/drivers/video/fbdev/au1100fb.c
> @@ -424,15 +424,15 @@ static int au1100fb_fb_blank(int blank_mode, struct fb_info *fbi)
>   
>   	switch (blank_mode) {
>   
> -	case VESA_NO_BLANKING:
> +	case FB_BLANK_UNBLANK:
>   		/* Turn on panel */
>   		fbdev->regs->lcd_control |= LCD_CONTROL_GO;
>   		wmb(); /* drain writebuffer */
>   		break;
> -
> -	case VESA_VSYNC_SUSPEND:
> -	case VESA_HSYNC_SUSPEND:
> -	case VESA_POWERDOWN:
> +	case FB_BLANK_NORMAL:
> +	case FB_BLANK_VSYNC_SUSPEND:
> +	case FB_BLANK_HSYNC_SUSPEND:
> +	case FB_BLANK_POWERDOWN:
I don't understand (this is not the fault of this/your patch),
how this enum in fb.h works:

enum {
         /* screen: unblanked, hsync: on,  vsync: on */
         FB_BLANK_UNBLANK       = VESA_NO_BLANKING,

         /* screen: blanked,   hsync: on,  vsync: on */
         FB_BLANK_NORMAL        = VESA_NO_BLANKING + 1,

         /* screen: blanked,   hsync: on,  vsync: off */
         FB_BLANK_VSYNC_SUSPEND = VESA_VSYNC_SUSPEND + 1,

         /* screen: blanked,   hsync: off, vsync: on */
         FB_BLANK_HSYNC_SUSPEND = VESA_HSYNC_SUSPEND + 1,

         /* screen: blanked,   hsync: off, vsync: off */
         FB_BLANK_POWERDOWN     = VESA_POWERDOWN + 1


In vesa.h we have:
/* VESA Blanking Levels */
enum vesa_blank_mode {
         VESA_NO_BLANKING        = 0,
#define VESA_NO_BLANKING        VESA_NO_BLANKING
         VESA_VSYNC_SUSPEND      = 1,
#define VESA_VSYNC_SUSPEND      VESA_VSYNC_SUSPEND
         VESA_HSYNC_SUSPEND      = 2,
#define VESA_HSYNC_SUSPEND      VESA_HSYNC_SUSPEND
         VESA_POWERDOWN          = VESA_VSYNC_SUSPEND | VESA_HSYNC_SUSPEND,
#define VESA_POWERDOWN          VESA_POWERDOWN
         VESA_BLANK_MAX          = VESA_POWERDOWN,


for example this one:
         /* screen: blanked,   hsync: on,  vsync: off */
         FB_BLANK_VSYNC_SUSPEND = VESA_VSYNC_SUSPEND + 1,
which is effectively:
         FB_BLANK_VSYNC_SUSPEND = VESA_HSYNC_SUSPEND,
which seems wrong.

Am I missing something?

Helge

  reply	other threads:[~2026-10-18 13:52 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-09 16:05 [PATCH 0/5] fbdev: Remove use of VESA constants Thomas Zimmermann
2026-10-09 16:05 ` [PATCH 1/5] fbdev/au1100fb: Use FB blanking constants Thomas Zimmermann
2026-10-18 13:52   ` Helge Deller [this message]
2026-10-19  7:24     ` Thomas Zimmermann
2026-10-09 16:05 ` [PATCH 2/5] fbdev/i810fb: " Thomas Zimmermann
2026-10-09 16:05 ` [PATCH 3/5] fbdev/sa1100fb: Remove comment on VESA DPMS modes Thomas Zimmermann
2026-10-09 16:05 ` [PATCH 4/5] fbdev/platinumfb: Use FB blanking constants Thomas Zimmermann
2026-10-09 16:05 ` [PATCH 5/5] fbdev/xilinxfb: " Thomas Zimmermann

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=3ae4590b-c420-480f-a6a2-79700bf20a1a@gmx.de \
    --to=deller@gmx.de \
    --cc=adaplas@gmail.com \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=michal.simek@amd.com \
    --cc=tzimmermann@suse.de \
    /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