All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@linux.intel.com>
To: ville.syrjala@linux.intel.com, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH i-g-t] tests/drv_module_reload_basic: Leave	basic breadcrumbs in dmesg
Date: Thu, 06 Oct 2016 15:17:45 +0300	[thread overview]
Message-ID: <87fuo9r7rq.fsf@intel.com> (raw)
In-Reply-To: <1475755697-30886-1-git-send-email-ville.syrjala@linux.intel.com>

On Thu, 06 Oct 2016, ville.syrjala@linux.intel.com wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>
> Leave the normal "executing" and "exiting" breadcrumbs into dmesg when
> running the test.
>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
>  tests/drv_module_reload_basic | 27 +++++++++++++++++++++++++++
>  1 file changed, 27 insertions(+)
>
> diff --git a/tests/drv_module_reload_basic b/tests/drv_module_reload_basic
> index 93cf7c005638..4c75f0e9614a 100755
> --- a/tests/drv_module_reload_basic
> +++ b/tests/drv_module_reload_basic
> @@ -6,6 +6,33 @@
>  #
>  
>  SOURCE_DIR="$( dirname "${BASH_SOURCE[0]}" )"
> +
> +NAME=$(basename "$0")
> +
> +KERN_EMER="<0>"
> +KERN_ALERT="<1>"
> +KERN_CRIT="<2>"
> +KERN_ERR="<3>"
> +KERN_WARNING="<4>"
> +KERN_NOTICE="<5>"
> +KERN_INFO="<6>"
> +KERN_DEBUG="<7>"
> +
> +function kmsg()
> +{
> +	echo "$1" > /dev/kmsg
> +}
> +

Seems like these would belong in drm_lib.sh. Or do you really need to do
the kmsg *before* sourcing drm_lib.sh?

BR,
Jani.

> +function finish()
> +{
> +	exitcode=$?
> +	kmsg "$KERN_INFO$NAME: exiting, ret=$exitcode"
> +	exit $exitcode
> +}
> +trap finish EXIT
> +
> +kmsg "$KERN_INFO$NAME: executing"
> +
>  . $SOURCE_DIR/drm_lib.sh
>  
>  # no other drm service should be running, so we can just unbind

-- 
Jani Nikula, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2016-10-06 12:17 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-06 12:08 [PATCH i-g-t] tests/drv_module_reload_basic: Leave basic breadcrumbs in dmesg ville.syrjala
2016-10-06 12:17 ` Jani Nikula [this message]
2016-10-06 12:37   ` Ville Syrjälä
2016-10-06 13:37     ` Ville Syrjälä

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=87fuo9r7rq.fsf@intel.com \
    --to=jani.nikula@linux.intel.com \
    --cc=intel-gfx@lists.freedesktop.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 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.