public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Petri Latvala <petri.latvala@intel.com>
To: Mika Kahola <mika.kahola@intel.com>
Cc: igt-dev@lists.freedesktop.org
Subject: Re: [igt-dev] [PATCH i-g-t] tests/kms_prime: Fix compiler warning
Date: Wed, 18 Sep 2019 13:35:26 +0300	[thread overview]
Message-ID: <20190918103526.GV4019@platvala-desk.ger.corp.intel.com> (raw)
In-Reply-To: <20190918095919.12423-1-mika.kahola@intel.com>

On Wed, Sep 18, 2019 at 12:59:19PM +0300, Mika Kahola wrote:
> Fix compiler warning about
> 
> ../tests/kms_prime.c: In function ‘setup_display’:
> ../tests/kms_prime.c:74:2: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
>   igt_output_t *output = igt_get_single_output_for_pipe(display, pipe);
> 
> Signed-off-by: Mika Kahola <mika.kahola@intel.com>

Reviewed-by: Petri Latvala <petri.latvala@intel.com>


> ---
>  tests/kms_prime.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/tests/kms_prime.c b/tests/kms_prime.c
> index 17599573..3241c514 100644
> --- a/tests/kms_prime.c
> +++ b/tests/kms_prime.c
> @@ -69,9 +69,11 @@ static bool has_prime_export(int fd)
>  static igt_output_t *setup_display(int importer_fd, igt_display_t *display,
>  				   enum pipe pipe)
>  {
> +	igt_output_t *output;
> +
>  	igt_display_require(display, importer_fd);
>  	igt_skip_on(pipe >= display->n_pipes);
> -	igt_output_t *output = igt_get_single_output_for_pipe(display, pipe);
> +	output = igt_get_single_output_for_pipe(display, pipe);
>  
>  	igt_require_f(output, "No connector found for pipe %s\n",
>  		      kmstest_pipe_name(pipe));
> -- 
> 2.17.1
> 
> _______________________________________________
> igt-dev mailing list
> igt-dev@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/igt-dev
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

  reply	other threads:[~2019-09-18 10:35 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-18  9:59 [igt-dev] [PATCH i-g-t] tests/kms_prime: Fix compiler warning Mika Kahola
2019-09-18 10:35 ` Petri Latvala [this message]
2019-09-23 10:51   ` Kahola, Mika
2019-09-18 12:18 ` [igt-dev] ✓ Fi.CI.BAT: success for " 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=20190918103526.GV4019@platvala-desk.ger.corp.intel.com \
    --to=petri.latvala@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=mika.kahola@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