Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Chung, ChiaHsuan (Tom)" <chiahsuan.chung@amd.com>
To: Alex Hung <alex.hung@amd.com>, igt-dev@lists.freedesktop.org
Subject: Re: [PATCH] tests/amdgpu/amd_hotplug: add missing include file fcntl.h
Date: Fri, 14 Mar 2025 15:57:24 +0800	[thread overview]
Message-ID: <535959ef-c399-415f-b5c8-c3a26a47a4d2@amd.com> (raw)
In-Reply-To: <20250314033249.2426485-1-alex.hung@amd.com>

Thank you so much.

Reviewed-by: Tom Chung <chiahsuan.chung@amd.com>

On 3/14/2025 11:32 AM, Alex Hung wrote:
> Add missing include file to fix cross-compilation errors:
>
> ../tests/amdgpu/amd_hotplug.c: In function ‘is_system_s2idle’:
> ../tests/amdgpu/amd_hotplug.c:110:7: error: implicit declaration of function ‘open’; did you mean ‘popen’? [-Werror=implicit-function-declaration]
>    fd = open(MEM_SLEEP_PATH, O_RDONLY);
>         ^~~~
>         popen
> ../tests/amdgpu/amd_hotplug.c:110:7: warning: nested extern declaration of ‘open’ [-Wnested-externs]
> ../tests/amdgpu/amd_hotplug.c:110:28: error: ‘O_RDONLY’ undeclared (first use in this function); did you mean ‘STA_RONLY’?
>    fd = open(MEM_SLEEP_PATH, O_RDONLY);
>                              ^~~~~~~~
>                              STA_RONLY
>
> Fixes: 6796e79abba2 ("tests/amdgpu/amd_hotplug: Check the suspend state after resume")
> Signed-off-by: Alex Hung <alex.hung@amd.com>
> ---
>   tests/amdgpu/amd_hotplug.c | 2 ++
>   1 file changed, 2 insertions(+)
>
> diff --git a/tests/amdgpu/amd_hotplug.c b/tests/amdgpu/amd_hotplug.c
> index ee3256c0b..bbd50452b 100644
> --- a/tests/amdgpu/amd_hotplug.c
> +++ b/tests/amdgpu/amd_hotplug.c
> @@ -20,6 +20,8 @@
>    * OTHER DEALINGS IN THE SOFTWARE.
>    */
>   
> +#include <fcntl.h>
> +
>   #include "igt.h"
>   #include "igt_amd.h"
>   

  reply	other threads:[~2025-03-14  7:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-14  3:32 [PATCH] tests/amdgpu/amd_hotplug: add missing include file fcntl.h Alex Hung
2025-03-14  7:57 ` Chung, ChiaHsuan (Tom) [this message]
2025-03-14 16:32   ` Kamil Konieczny
2025-03-14 18:49 ` ✓ Xe.CI.Full: success for " Patchwork
2025-03-14 23:38 ` ✗ Fi.CI.BAT: failure for tests/amdgpu/amd_hotplug: add missing include file fcntl.h (rev2) 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=535959ef-c399-415f-b5c8-c3a26a47a4d2@amd.com \
    --to=chiahsuan.chung@amd.com \
    --cc=alex.hung@amd.com \
    --cc=igt-dev@lists.freedesktop.org \
    /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