<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 2021-11-25 2:03 a.m., Christian
      König wrote:<br>
    </div>
    <blockquote type="cite" cite="mid:a832f0bc-fcb1-4e13-3cf7-c598e96a665b@gmail.com">Am
      24.11.21 um 21:20 schrieb Felix Kuehling:
      <br>
      <blockquote type="cite">Am 2021-11-24 um 10:23 a.m. schrieb philip
        yang:
        <br>
        <blockquote type="cite">
          <blockquote type="cite">
            <blockquote type="cite">     #define
              amdgpu_ih_get_wptr(adev, ih)
              <br>
              (adev)->irq.ih_funcs->get_wptr((adev), (ih))
              <br>
                 #define amdgpu_ih_decode_iv(adev, iv) \
              <br>
                     (adev)->irq.ih_funcs->decode_iv((adev), (ih),
              (iv))
              <br>
              +#define amdgpu_ih_decode_iv_ts(adev, ih, rptr, offset) \
              <br>
              +   
              (WARN_ON_ONCE(!(adev)->irq.ih_funcs->decode_iv_ts) ?
              0 : \
              <br>
            </blockquote>
            Please drop that WARN_ON_ONCE here.
            <br>
            <br>
          </blockquote>
          Agree, will drop it.
          <br>
          <br>
        </blockquote>
        I suggested this. We're assuming that this function will never
        be called
        <br>
        on hardware that doesn't support time stamps, and that all
        hardware with
        <br>
        time stamps will implement the decode_iv_ts function. But it's
        good to
        <br>
        get a log message if that assumption is ever broken, rather than
        just
        <br>
        silently getting wrong results.
        <br>
      </blockquote>
      <br>
      Well exactly that's the point, you won't get wrong results but a
      NULL pointer exception instead.
      <br>
      <br>
      So we already have a backtrace in the logs.
      <br>
    </blockquote>
    <p>The check will avoid NULL pointer access backtrace, so WARNING
      backtrace is obvious, useful for future chips to implement
      decode_iv_ts interface or use the helper function.</p>
    <p>Regards,</p>
    <p>Philip<br>
    </p>
    <blockquote type="cite" cite="mid:a832f0bc-fcb1-4e13-3cf7-c598e96a665b@gmail.com">
      <br>
      Regards,
      <br>
      Christian.
      <br>
      <br>
      <blockquote type="cite">
        <br>
        Regards,
        <br>
           Felix
        <br>
        <br>
        <br>
        <blockquote type="cite">Regards,
          <br>
          <br>
          Philip
          <br>
          <br>
        </blockquote>
      </blockquote>
      <br>
    </blockquote>
  </body>
</html>