From: Hans Verkuil <hansverk@cisco.com>
To: Ville Syrjala <ville.syrjala@linux.intel.com>,
dri-devel@lists.freedesktop.org
Cc: intel-gfx@lists.freedesktop.org,
Hans Verkuil <hans.verkuil@cisco.com>,
linux-media@vger.kernel.org
Subject: Re: [PATCH 03/18] video/hdmi: Constify infoframe passed to the log functions
Date: Fri, 21 Sep 2018 10:06:39 +0200 [thread overview]
Message-ID: <2bb731e1-e42a-2016-cd66-bd1757ae8489@cisco.com> (raw)
In-Reply-To: <20180920185145.1912-4-ville.syrjala@linux.intel.com>
On 09/20/18 20:51, Ville Syrjala wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>
> The log functions don't modify the passed in infoframe so make it const.
>
> Cc: Thierry Reding <thierry.reding@gmail.com>
> Cc: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Hans Verkuil <hans.verkuil@cisco.com>
Thanks,
Hans
> Cc: linux-media@vger.kernel.org
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
> drivers/video/hdmi.c | 22 +++++++++++-----------
> include/linux/hdmi.h | 2 +-
> 2 files changed, 12 insertions(+), 12 deletions(-)
>
> diff --git a/drivers/video/hdmi.c b/drivers/video/hdmi.c
> index b5d491014b0b..53e7ee2c83fc 100644
> --- a/drivers/video/hdmi.c
> +++ b/drivers/video/hdmi.c
> @@ -471,7 +471,7 @@ static const char *hdmi_infoframe_type_get_name(enum hdmi_infoframe_type type)
>
> static void hdmi_infoframe_log_header(const char *level,
> struct device *dev,
> - struct hdmi_any_infoframe *frame)
> + const struct hdmi_any_infoframe *frame)
> {
> hdmi_log("HDMI infoframe: %s, version %u, length %u\n",
> hdmi_infoframe_type_get_name(frame->type),
> @@ -673,10 +673,10 @@ hdmi_content_type_get_name(enum hdmi_content_type content_type)
> */
> static void hdmi_avi_infoframe_log(const char *level,
> struct device *dev,
> - struct hdmi_avi_infoframe *frame)
> + const struct hdmi_avi_infoframe *frame)
> {
> hdmi_infoframe_log_header(level, dev,
> - (struct hdmi_any_infoframe *)frame);
> + (const struct hdmi_any_infoframe *)frame);
>
> hdmi_log(" colorspace: %s\n",
> hdmi_colorspace_get_name(frame->colorspace));
> @@ -750,12 +750,12 @@ static const char *hdmi_spd_sdi_get_name(enum hdmi_spd_sdi sdi)
> */
> static void hdmi_spd_infoframe_log(const char *level,
> struct device *dev,
> - struct hdmi_spd_infoframe *frame)
> + const struct hdmi_spd_infoframe *frame)
> {
> u8 buf[17];
>
> hdmi_infoframe_log_header(level, dev,
> - (struct hdmi_any_infoframe *)frame);
> + (const struct hdmi_any_infoframe *)frame);
>
> memset(buf, 0, sizeof(buf));
>
> @@ -886,10 +886,10 @@ hdmi_audio_coding_type_ext_get_name(enum hdmi_audio_coding_type_ext ctx)
> */
> static void hdmi_audio_infoframe_log(const char *level,
> struct device *dev,
> - struct hdmi_audio_infoframe *frame)
> + const struct hdmi_audio_infoframe *frame)
> {
> hdmi_infoframe_log_header(level, dev,
> - (struct hdmi_any_infoframe *)frame);
> + (const struct hdmi_any_infoframe *)frame);
>
> if (frame->channels)
> hdmi_log(" channels: %u\n", frame->channels - 1);
> @@ -949,12 +949,12 @@ hdmi_3d_structure_get_name(enum hdmi_3d_structure s3d_struct)
> static void
> hdmi_vendor_any_infoframe_log(const char *level,
> struct device *dev,
> - union hdmi_vendor_any_infoframe *frame)
> + const union hdmi_vendor_any_infoframe *frame)
> {
> - struct hdmi_vendor_infoframe *hvf = &frame->hdmi;
> + const struct hdmi_vendor_infoframe *hvf = &frame->hdmi;
>
> hdmi_infoframe_log_header(level, dev,
> - (struct hdmi_any_infoframe *)frame);
> + (const struct hdmi_any_infoframe *)frame);
>
> if (frame->any.oui != HDMI_IEEE_OUI) {
> hdmi_log(" not a HDMI vendor infoframe\n");
> @@ -984,7 +984,7 @@ hdmi_vendor_any_infoframe_log(const char *level,
> */
> void hdmi_infoframe_log(const char *level,
> struct device *dev,
> - union hdmi_infoframe *frame)
> + const union hdmi_infoframe *frame)
> {
> switch (frame->any.type) {
> case HDMI_INFOFRAME_TYPE_AVI:
> diff --git a/include/linux/hdmi.h b/include/linux/hdmi.h
> index a577d4ae2570..bce1abb1fe57 100644
> --- a/include/linux/hdmi.h
> +++ b/include/linux/hdmi.h
> @@ -335,6 +335,6 @@ hdmi_infoframe_pack(union hdmi_infoframe *frame, void *buffer, size_t size);
> int hdmi_infoframe_unpack(union hdmi_infoframe *frame,
> const void *buffer, size_t size);
> void hdmi_infoframe_log(const char *level, struct device *dev,
> - union hdmi_infoframe *frame);
> + const union hdmi_infoframe *frame);
>
> #endif /* _DRM_HDMI_H */
>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2018-09-21 8:06 UTC|newest]
Thread overview: 69+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-20 18:51 [PATCH 00/18] drm/i915: Infoframe precompute/check Ville Syrjala
2018-09-20 18:51 ` [PATCH 01/18] video/hdmi: Constify 'buffer' to the unpack functions Ville Syrjala
2018-09-21 8:03 ` Hans Verkuil
2018-09-20 18:51 ` [PATCH 02/18] video/hdmi: Pass buffer size to infoframe " Ville Syrjala
2018-09-21 8:06 ` Hans Verkuil
2018-09-20 18:51 ` [PATCH 03/18] video/hdmi: Constify infoframe passed to the log functions Ville Syrjala
2018-09-21 8:06 ` Hans Verkuil [this message]
2018-09-20 18:51 ` [PATCH 04/18] video/hdmi: Constify infoframe passed to the pack functions Ville Syrjala
2018-09-21 8:24 ` Hans Verkuil
2018-09-21 14:30 ` Ville Syrjälä
2018-09-21 14:33 ` [PATCH v3 " Ville Syrjala
2018-10-01 19:10 ` Ville Syrjälä
2018-10-02 6:37 ` Hans Verkuil
2018-09-20 18:51 ` [PATCH 05/18] video/hdmi: Add an enum for HDMI packet types Ville Syrjala
2018-09-21 8:41 ` Hans Verkuil
2018-09-21 14:01 ` Ville Syrjälä
2018-09-21 14:12 ` Hans Verkuil
2018-09-21 15:07 ` Ville Syrjälä
2018-12-20 11:27 ` Sharma, Shashank
2018-09-20 18:51 ` [PATCH 06/18] video/hdmi: Handle the MPEG Source infoframe Ville Syrjala
2018-09-21 8:28 ` Hans Verkuil
2018-09-21 13:53 ` Ville Syrjälä
2018-09-21 15:09 ` [PATCH v2 " Ville Syrjala
2018-09-20 18:51 ` [PATCH 07/18] video/hdmi: Handle the NTSC VBI infoframe Ville Syrjala
2018-09-21 8:30 ` Hans Verkuil
2018-09-21 13:54 ` Ville Syrjälä
2018-09-21 15:10 ` [PATCH v2 " Ville Syrjala
2018-09-20 18:51 ` [PATCH 08/18] drm/i915: Use memmove() for punching the hole into infoframes Ville Syrjala
2018-09-21 13:52 ` Daniel Vetter
2018-09-20 18:51 ` [PATCH 09/18] drm/i915: Pass intel_encoder to infoframe functions Ville Syrjala
2018-09-21 13:59 ` Daniel Vetter
2018-09-21 15:03 ` Ville Syrjälä
2018-09-20 18:51 ` [PATCH 10/18] drm/i915: Add the missing HDMI gamut metadata packet stuff Ville Syrjala
2018-09-21 14:15 ` [Intel-gfx] " Daniel Vetter
2018-09-20 18:51 ` [PATCH 11/18] drm/i915: Return the mask of enabled infoframes from ->inforame_enabled() Ville Syrjala
2018-09-24 15:51 ` Daniel Vetter
2018-09-24 16:36 ` [Intel-gfx] " Ville Syrjälä
2018-10-01 6:55 ` Daniel Vetter
2018-10-01 19:29 ` Ville Syrjälä
2018-09-20 18:51 ` [PATCH 12/18] drm/i915: Store mask of enabled infoframes in the crtc state Ville Syrjala
2018-09-24 15:51 ` [Intel-gfx] " Daniel Vetter
2018-09-20 18:51 ` [PATCH 13/18] drm/i915: Precompute HDMI infoframes Ville Syrjala
2018-09-24 15:58 ` Daniel Vetter
2018-09-24 16:42 ` Ville Syrjälä
2018-09-20 18:51 ` [PATCH 14/18] drm/i915: Read out " Ville Syrjala
2018-09-24 16:08 ` Daniel Vetter
2018-09-24 16:52 ` Ville Syrjälä
2018-09-20 18:51 ` [PATCH 15/18] drm/i915/sdvo: Precompute " Ville Syrjala
2018-09-20 18:51 ` [PATCH 16/18] drm/i915/sdvo: Read out " Ville Syrjala
2018-09-24 16:10 ` [Intel-gfx] " Daniel Vetter
2018-09-24 17:13 ` Ville Syrjälä
2018-10-01 6:59 ` Daniel Vetter
2018-10-01 13:35 ` Ville Syrjälä
2018-10-01 16:48 ` Daniel Vetter
2018-09-20 18:51 ` [PATCH 17/18] drm/i915: Check infoframe state in intel_pipe_config_compare() Ville Syrjala
2018-09-24 16:12 ` Daniel Vetter
2018-10-01 20:35 ` [Intel-gfx] " Ville Syrjälä
2018-10-02 8:16 ` Daniel Vetter
2018-09-20 18:51 ` [PATCH 18/18] drm/i915: Include infoframes in the crtc state dump Ville Syrjala
2018-09-24 16:14 ` [Intel-gfx] " Daniel Vetter
2018-09-20 19:02 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915: Infoframe precompute/check Patchwork
2018-09-20 19:12 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-09-20 19:26 ` ✓ Fi.CI.BAT: success " Patchwork
2018-09-20 22:30 ` ✓ Fi.CI.IGT: " Patchwork
2018-09-21 14:40 ` ✗ Fi.CI.BAT: failure for drm/i915: Infoframe precompute/check (rev2) Patchwork
2018-09-21 15:25 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915: Infoframe precompute/check (rev4) Patchwork
2018-09-21 15:35 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-09-21 15:46 ` ✓ Fi.CI.BAT: success " Patchwork
2018-09-21 17:04 ` ✓ Fi.CI.IGT: " Patchwork
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=2bb731e1-e42a-2016-cd66-bd1757ae8489@cisco.com \
--to=hansverk@cisco.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=hans.verkuil@cisco.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=linux-media@vger.kernel.org \
--cc=ville.syrjala@linux.intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox