From: Sam Ravnborg <sam@ravnborg.org>
To: "Paweł Chmiel" <pawel.mikolaj.chmiel@gmail.com>
Cc: mark.rutland@arm.com, devicetree@vger.kernel.org,
airlied@linux.ie, linux-kernel@vger.kernel.org, krzk@kernel.org,
robh+dt@kernel.org, thierry.reding@gmail.com,
dri-devel@lists.freedesktop.org, m.szyprowski@samsung.com
Subject: Re: [PATCH v2 2/2] drm/panel: Add driver for Samsung S6E63M0 panel
Date: Fri, 1 Feb 2019 22:36:07 +0100 [thread overview]
Message-ID: <20190201213607.GA27951@ravnborg.org> (raw)
In-Reply-To: <20190201172852.4944-2-pawel.mikolaj.chmiel@gmail.com>
Hi Paweł
Looks good, thanks for addressing all the review feedback.
On Fri, Feb 01, 2019 at 06:28:52PM +0100, Paweł Chmiel wrote:
> This patch adds Samsung S6E63M0 AMOLED LCD panel driver, connected over
> spi. It's based on already removed, non dt s6e63m0 driver and
> panel-samsung-ld9040. It can be found for example in some of Samsung
> Aries based phones.
>
> Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
If you consider (do not change unless you think it better) the
following nits than you can add my:
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Sam
> diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig
> index 3f3537719beb..be05ed5218eb 100644
> --- a/drivers/gpu/drm/panel/Kconfig
> +++ b/drivers/gpu/drm/panel/Kconfig
> @@ -158,6 +158,13 @@ config DRM_PANEL_SAMSUNG_S6E63J0X03
> depends on BACKLIGHT_CLASS_DEVICE
> select VIDEOMODE_HELPERS
>
> +config DRM_PANEL_SAMSUNG_S6E63M0
> + tristate "Samsung S6E63M0 RGB/SPI panel"
> + depends on OF
> + depends on SPI
> + depends on BACKLIGHT_CLASS_DEVICE
> + select VIDEOMODE_HELPERS
With the use of display_mode the above "select VIDEOMODE_HELPERS"
is likely no longer required. Please check.
A help text would be nice.
> +
> config DRM_PANEL_SAMSUNG_S6E8AA0
> tristate "Samsung S6E8AA0 DSI video mode panel"
> depends on OF
> +#include <video/of_videomode.h>
> +#include <video/videomode.h>
Please check if these two files are required.
> +struct s6e63m0 {
> + struct device *dev;
> + struct drm_panel panel;
> + struct backlight_device *bl_dev;
> +
> + struct regulator_bulk_data supplies[2];
> + struct gpio_desc *reset_gpio;
> + struct videomode vm;
vm is no longer used - delete it.
> +
> + bool prepared;
> + bool enabled;
> +
> + /*
> + * This field is tested by functions directly accessing bus before
> + * transfer, transfer is skipped if it is set. In case of transfer
> + * failure or unexpected response the field is set to error value.
> + * Such construct allows to eliminate many checks in higher level
> + * functions.
> + */
> + int error;
> +};
> +
> +static int s6e63m0_get_modes(struct drm_panel *panel)
> +{
> + struct drm_connector *connector = panel->connector;
> + struct drm_display_mode *mode;
> +
> + mode = drm_mode_duplicate(panel->drm, &default_mode);
> + if (!mode) {
> + DRM_ERROR("failed to add mode %ux%ux@%u\n",
> + default_mode.hdisplay, default_mode.vdisplay,
> + default_mode.vrefresh);
I recall I have seen a generic way to print the above,
but I have failed to find it.
Maybe it is just my memory that fools me.
The above is fine.
> +
> + s6e63m0_backlight_register(ctx);
Is it correct that we continue even if we fail to register backlight?
> +
> + return 0;
> +}
> +
> +
> +static const struct of_device_id s6e63m0_of_match[] = {
> + { .compatible = "samsung,s6e63m0" },
> + { }
Add /* sentinel */ comment?
> +};
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
WARNING: multiple messages have this Message-ID (diff)
From: Sam Ravnborg <sam@ravnborg.org>
To: "Paweł Chmiel" <pawel.mikolaj.chmiel@gmail.com>
Cc: thierry.reding@gmail.com, mark.rutland@arm.com,
devicetree@vger.kernel.org, airlied@linux.ie,
linux-kernel@vger.kernel.org, krzk@kernel.org,
robh+dt@kernel.org, dri-devel@lists.freedesktop.org,
m.szyprowski@samsung.com
Subject: Re: [PATCH v2 2/2] drm/panel: Add driver for Samsung S6E63M0 panel
Date: Fri, 1 Feb 2019 22:36:07 +0100 [thread overview]
Message-ID: <20190201213607.GA27951@ravnborg.org> (raw)
In-Reply-To: <20190201172852.4944-2-pawel.mikolaj.chmiel@gmail.com>
Hi Paweł
Looks good, thanks for addressing all the review feedback.
On Fri, Feb 01, 2019 at 06:28:52PM +0100, Paweł Chmiel wrote:
> This patch adds Samsung S6E63M0 AMOLED LCD panel driver, connected over
> spi. It's based on already removed, non dt s6e63m0 driver and
> panel-samsung-ld9040. It can be found for example in some of Samsung
> Aries based phones.
>
> Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
If you consider (do not change unless you think it better) the
following nits than you can add my:
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Sam
> diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig
> index 3f3537719beb..be05ed5218eb 100644
> --- a/drivers/gpu/drm/panel/Kconfig
> +++ b/drivers/gpu/drm/panel/Kconfig
> @@ -158,6 +158,13 @@ config DRM_PANEL_SAMSUNG_S6E63J0X03
> depends on BACKLIGHT_CLASS_DEVICE
> select VIDEOMODE_HELPERS
>
> +config DRM_PANEL_SAMSUNG_S6E63M0
> + tristate "Samsung S6E63M0 RGB/SPI panel"
> + depends on OF
> + depends on SPI
> + depends on BACKLIGHT_CLASS_DEVICE
> + select VIDEOMODE_HELPERS
With the use of display_mode the above "select VIDEOMODE_HELPERS"
is likely no longer required. Please check.
A help text would be nice.
> +
> config DRM_PANEL_SAMSUNG_S6E8AA0
> tristate "Samsung S6E8AA0 DSI video mode panel"
> depends on OF
> +#include <video/of_videomode.h>
> +#include <video/videomode.h>
Please check if these two files are required.
> +struct s6e63m0 {
> + struct device *dev;
> + struct drm_panel panel;
> + struct backlight_device *bl_dev;
> +
> + struct regulator_bulk_data supplies[2];
> + struct gpio_desc *reset_gpio;
> + struct videomode vm;
vm is no longer used - delete it.
> +
> + bool prepared;
> + bool enabled;
> +
> + /*
> + * This field is tested by functions directly accessing bus before
> + * transfer, transfer is skipped if it is set. In case of transfer
> + * failure or unexpected response the field is set to error value.
> + * Such construct allows to eliminate many checks in higher level
> + * functions.
> + */
> + int error;
> +};
> +
> +static int s6e63m0_get_modes(struct drm_panel *panel)
> +{
> + struct drm_connector *connector = panel->connector;
> + struct drm_display_mode *mode;
> +
> + mode = drm_mode_duplicate(panel->drm, &default_mode);
> + if (!mode) {
> + DRM_ERROR("failed to add mode %ux%ux@%u\n",
> + default_mode.hdisplay, default_mode.vdisplay,
> + default_mode.vrefresh);
I recall I have seen a generic way to print the above,
but I have failed to find it.
Maybe it is just my memory that fools me.
The above is fine.
> +
> + s6e63m0_backlight_register(ctx);
Is it correct that we continue even if we fail to register backlight?
> +
> + return 0;
> +}
> +
> +
> +static const struct of_device_id s6e63m0_of_match[] = {
> + { .compatible = "samsung,s6e63m0" },
> + { }
Add /* sentinel */ comment?
> +};
next prev parent reply other threads:[~2019-02-01 21:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-02-01 17:28 [PATCH v2 1/2] dt-bindings: drm: panel: Add Samsung s6e63m0 panel documentation Paweł Chmiel
2019-02-01 17:28 ` [PATCH v2 2/2] drm/panel: Add driver for Samsung S6E63M0 panel Paweł Chmiel
2019-02-01 21:36 ` Sam Ravnborg [this message]
2019-02-01 21:36 ` Sam Ravnborg
2019-02-02 14:27 ` Paweł Chmiel
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=20190201213607.GA27951@ravnborg.org \
--to=sam@ravnborg.org \
--cc=airlied@linux.ie \
--cc=devicetree@vger.kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=krzk@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=m.szyprowski@samsung.com \
--cc=mark.rutland@arm.com \
--cc=pawel.mikolaj.chmiel@gmail.com \
--cc=robh+dt@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.