All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sam Ravnborg <sam@ravnborg.org>
To: Adam Ford <aford173@gmail.com>
Cc: linux-kernel@vger.kernel.org, airlied@linux.ie,
	thierry.reding@gmail.com, adam.ford@logicpd.com,
	dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm/panel: simple: Add Ampire am800480b3tmqw
Date: Fri, 2 Nov 2018 17:34:49 +0100	[thread overview]
Message-ID: <20181102163449.GA25035@ravnborg.org> (raw)
In-Reply-To: <20181101125138.27848-1-aford173@gmail.com>

Hi Adam

On Thu, Nov 01, 2018 at 07:51:38AM -0500, Adam Ford wrote:
> This adds support for the Ampire am800480b3tmqw display,
> a 7" 24-bit RGB panel wtih 800x480 resolution.
> 
> Signed-off-by: Adam Ford <aford173@gmail.com>
> 
> diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/panel/panel-simple.c
> index 97964f7f2ace..71e878f63c5b 100644
> --- a/drivers/gpu/drm/panel/panel-simple.c
> +++ b/drivers/gpu/drm/panel/panel-simple.c
> @@ -436,6 +436,31 @@ static const struct panel_desc ampire_am800480r3tmqwa1h = {
>  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
>  };
>  
> +static const struct drm_display_mode ampire_am800480b3tmqw_mode = {
> +	.clock = 30000,
> +	.hdisplay = 800,
> +	.hsync_start = 800 + 210,
> +	.hsync_end = 800 + 210 + 46,
> +	.htotal = 800 + 210 + 46 + 0,
> +	.vdisplay = 480,
> +	.vsync_start = 480 + 22,
> +	.vsync_end = 480 + 22 + 23,
> +	.vtotal = 480 + 22 + 23 + 0,
> +	.vrefresh = 60,
> +	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
> +};
+1 to see .flags specified


> +
> +static const struct panel_desc ampire_am800480b3tmqw = {
> +	.modes = &ampire_am800480b3tmqw_mode,
> +	.num_modes = 1,
> +	.bpc = 6,
> +	.size = {
> +		.width = 152,
> +		.height = 91,
> +	},
> +	.bus_format = MEDIA_BUS_FMT_RBG888_1X24,
> +};
Likewise good to see .bus_format specified.

But .bus_flags are not specified. 

>From the header file:

<<<<<<<<<<<<<<<<<<<<
#define DRM_BUS_FLAG_DE_LOW             (1<<0)
#define DRM_BUS_FLAG_DE_HIGH            (1<<1)
/* drive data on pos. edge */
#define DRM_BUS_FLAG_PIXDATA_POSEDGE    (1<<2)
/* drive data on neg. edge */
#define DRM_BUS_FLAG_PIXDATA_NEGEDGE    (1<<3)
/* data is transmitted MSB to LSB on the bus */
#define DRM_BUS_FLAG_DATA_MSB_TO_LSB    (1<<4)
/* data is transmitted LSB to MSB on the bus */
#define DRM_BUS_FLAG_DATA_LSB_TO_MSB    (1<<5)
/* drive sync on pos. edge */
#define DRM_BUS_FLAG_SYNC_POSEDGE       (1<<6)
/* drive sync on neg. edge */
#define DRM_BUS_FLAG_SYNC_NEGEDGE       (1<<7)

        /**
         * @bus_flags: Additional information (like pixel signal polarity) for
         * the pixel data on the bus, using DRM_BUS_FLAGS\_ defines.
         */
        u32 bus_flags;
>>>>>>>>>>>>>>>><

Many panels leave out .bus_flags - and I wonder if this is
because default is OK or because most other panels does so.

I had problems with my display that the text looked blurred
when bus_flags was no specified (using defaults).
This was one issue I had when migrating from 4.4 kernel
to a recent kernel.

So therefore it would good to have .bus_flags specified too
if for nothing else then for documentation purposes.

	Sam

WARNING: multiple messages have this Message-ID (diff)
From: Sam Ravnborg <sam@ravnborg.org>
To: Adam Ford <aford173@gmail.com>
Cc: linux-kernel@vger.kernel.org, airlied@linux.ie,
	thierry.reding@gmail.com, adam.ford@logicpd.com,
	dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm/panel: simple: Add Ampire am800480b3tmqw
Date: Fri, 2 Nov 2018 17:34:49 +0100	[thread overview]
Message-ID: <20181102163449.GA25035@ravnborg.org> (raw)
In-Reply-To: <20181101125138.27848-1-aford173@gmail.com>

Hi Adam

On Thu, Nov 01, 2018 at 07:51:38AM -0500, Adam Ford wrote:
> This adds support for the Ampire am800480b3tmqw display,
> a 7" 24-bit RGB panel wtih 800x480 resolution.
> 
> Signed-off-by: Adam Ford <aford173@gmail.com>
> 
> diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/panel/panel-simple.c
> index 97964f7f2ace..71e878f63c5b 100644
> --- a/drivers/gpu/drm/panel/panel-simple.c
> +++ b/drivers/gpu/drm/panel/panel-simple.c
> @@ -436,6 +436,31 @@ static const struct panel_desc ampire_am800480r3tmqwa1h = {
>  	.bus_format = MEDIA_BUS_FMT_RGB666_1X18,
>  };
>  
> +static const struct drm_display_mode ampire_am800480b3tmqw_mode = {
> +	.clock = 30000,
> +	.hdisplay = 800,
> +	.hsync_start = 800 + 210,
> +	.hsync_end = 800 + 210 + 46,
> +	.htotal = 800 + 210 + 46 + 0,
> +	.vdisplay = 480,
> +	.vsync_start = 480 + 22,
> +	.vsync_end = 480 + 22 + 23,
> +	.vtotal = 480 + 22 + 23 + 0,
> +	.vrefresh = 60,
> +	.flags = DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_PVSYNC,
> +};
+1 to see .flags specified


> +
> +static const struct panel_desc ampire_am800480b3tmqw = {
> +	.modes = &ampire_am800480b3tmqw_mode,
> +	.num_modes = 1,
> +	.bpc = 6,
> +	.size = {
> +		.width = 152,
> +		.height = 91,
> +	},
> +	.bus_format = MEDIA_BUS_FMT_RBG888_1X24,
> +};
Likewise good to see .bus_format specified.

But .bus_flags are not specified. 

From the header file:

<<<<<<<<<<<<<<<<<<<<
#define DRM_BUS_FLAG_DE_LOW             (1<<0)
#define DRM_BUS_FLAG_DE_HIGH            (1<<1)
/* drive data on pos. edge */
#define DRM_BUS_FLAG_PIXDATA_POSEDGE    (1<<2)
/* drive data on neg. edge */
#define DRM_BUS_FLAG_PIXDATA_NEGEDGE    (1<<3)
/* data is transmitted MSB to LSB on the bus */
#define DRM_BUS_FLAG_DATA_MSB_TO_LSB    (1<<4)
/* data is transmitted LSB to MSB on the bus */
#define DRM_BUS_FLAG_DATA_LSB_TO_MSB    (1<<5)
/* drive sync on pos. edge */
#define DRM_BUS_FLAG_SYNC_POSEDGE       (1<<6)
/* drive sync on neg. edge */
#define DRM_BUS_FLAG_SYNC_NEGEDGE       (1<<7)

        /**
         * @bus_flags: Additional information (like pixel signal polarity) for
         * the pixel data on the bus, using DRM_BUS_FLAGS\_ defines.
         */
        u32 bus_flags;
>>>>>>>>>>>>>>>><

Many panels leave out .bus_flags - and I wonder if this is
because default is OK or because most other panels does so.

I had problems with my display that the text looked blurred
when bus_flags was no specified (using defaults).
This was one issue I had when migrating from 4.4 kernel
to a recent kernel.

So therefore it would good to have .bus_flags specified too
if for nothing else then for documentation purposes.

	Sam

  reply	other threads:[~2018-11-02 16:34 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-01 12:51 [PATCH] drm/panel: simple: Add Ampire am800480b3tmqw Adam Ford
2018-11-02 16:34 ` Sam Ravnborg [this message]
2018-11-02 16:34   ` Sam Ravnborg

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=20181102163449.GA25035@ravnborg.org \
    --to=sam@ravnborg.org \
    --cc=adam.ford@logicpd.com \
    --cc=aford173@gmail.com \
    --cc=airlied@linux.ie \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=thierry.reding@gmail.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.