From: "Ye, Tony" <tony.ye@intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>,
"Robert M. Fosha" <robert.m.fosha@intel.com>,
igt-dev@lists.freedesktop.org
Cc: Sally Qi <feng.qi@intel.com>
Subject: Re: [igt-dev] [PATCH i-g-t v4] tests/i915/gem_huc_copy: Enable a HuC copy test
Date: Thu, 16 Jan 2020 15:59:08 -0800 [thread overview]
Message-ID: <5cbc0fc2-3c8a-fb32-8f05-779ead8e14f8@intel.com> (raw)
In-Reply-To: <a25f2fda-ffa8-b9f3-540d-4c23346114d8@intel.com>
On 1/16/2020 3:56 PM, Ye, Tony wrote:
> There are two issues with the HUC_STATUS query ioctl.
>
> 1. on a platform with huc supported, i915.enable_guc=0, got unexpected
> return value:
> ret=0, param.value=0, errno=ENODEV
it is ret=-1, param.value=0, errno=ENODEV, sorry for the typo.
>
> 2. the return value doesn't differentiate these two conditions:
> a. i915.enable_guc=0/1, huc is disabled, skip the huc_copy test;
> b. i915.enable_guc=2/3, huc load/authentication failed, fail huc_copy.
> A patch like this is required:
> https://patchwork.freedesktop.org/patch/306419/?series=61001&rev=1
>
> Regards,
> Tony
> On 1/10/2020 5:05 PM, Ye, Tony wrote:
>>
>>
>> On 1/10/2020 11:54 AM, Chris Wilson wrote:
>>> Quoting Ye, Tony (2020-01-10 19:51:58)
>>>>
>>>>
>>>> On 1/10/2020 10:28 AM, Chris Wilson wrote:
>>>>> Quoting Robert M. Fosha (2020-01-10 17:41:46)
>>>>>> +static bool
>>>>>> +check_huc_enabled(int fd)
>>>>>> +{
>>>>>> + int dir;
>>>>>> + dir = igt_sysfs_open_parameters(fd);
>>>>>> +
>>>>>> + if (dir < 0)
>>>>>> + return 0;
>>>>>> +
>>>>>> + if (igt_sysfs_get_u32(dir, "enable_guc") & 2)
>>>>>> + return 1;
>>>>>> + else
>>>>>> + return 0;
>>>>>
>>>>> No. If you have this in your userspace, please immediately remove it,
>>>>> and backport that to any and all stable branches and releases.
>>>>> -Chris
>>>>
>>>> The code is to skip the test when HuC is disabled by the enable_guc
>>>> module parameter. If HuC is disabled by the enable_guc param, then skip
>>>> the test. If the HuC failed to load due to a real error, then fail the
>>>> test.
>>>>
>>>> Could you suggest how to handle HUC_STATUS failure properly without
>>>> this
>>>> code?
>>>
>>> Look at the error code from querying HUC_STATUS.
>>> -Chris
>>
>> Agree that the check should be done via uAPI instead of the sysfs.
>> Thanks for the feedback.
>> Tony
>>>
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
next prev parent reply other threads:[~2020-01-16 23:59 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-19 23:50 [igt-dev] [PATCH i-g-t] tests/i915/gem_huc_copy: Enable a HuC copy test Robert M. Fosha
2019-12-20 0:34 ` [igt-dev] ✗ GitLab.Pipeline: warning for " Patchwork
2019-12-20 0:58 ` [igt-dev] ✓ Fi.CI.BAT: success " Patchwork
2019-12-20 22:11 ` [igt-dev] [PATCH i-g-t] " Antonio Argenziano
2019-12-20 22:41 ` [igt-dev] [PATCH i-g-t v2] " Robert M. Fosha
2019-12-23 22:19 ` [igt-dev] [PATCH i-g-t v3] " Robert M. Fosha
2020-01-10 17:41 ` [igt-dev] [PATCH i-g-t v4] " Robert M. Fosha
2020-01-10 18:28 ` Chris Wilson
2020-01-10 19:51 ` Ye, Tony
2020-01-10 19:54 ` Chris Wilson
2020-01-11 1:05 ` Ye, Tony
2020-01-16 23:56 ` Ye, Tony
2020-01-16 23:59 ` Ye, Tony [this message]
2020-04-14 21:24 ` [igt-dev] [PATCH i-g-t v5] " Robert M. Fosha
2020-05-08 16:31 ` Argenziano, Antonio
2019-12-20 23:19 ` [igt-dev] ✗ GitLab.Pipeline: failure for tests/i915/gem_huc_copy: Enable a HuC copy test (rev2) Patchwork
2019-12-21 0:38 ` [igt-dev] ✗ Fi.CI.BAT: " Patchwork
2019-12-21 3:18 ` [igt-dev] ✓ Fi.CI.IGT: success for tests/i915/gem_huc_copy: Enable a HuC copy test Patchwork
2019-12-23 23:28 ` [igt-dev] ✗ Fi.CI.BAT: failure for tests/i915/gem_huc_copy: Enable a HuC copy test (rev3) Patchwork
2020-01-10 19:14 ` [igt-dev] ✓ Fi.CI.BAT: success for tests/i915/gem_huc_copy: Enable a HuC copy test (rev4) Patchwork
2020-01-14 10:10 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2020-04-14 22:07 ` [igt-dev] ✓ Fi.CI.BAT: success for tests/i915/gem_huc_copy: Enable a HuC copy test (rev5) Patchwork
2020-04-15 12:30 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2020-06-18 16:41 ` [igt-dev] [PATCH i-g-t v6] tests/i915/gem_huc_copy: Enable a HuC copy test Robert M. Fosha
2020-06-23 17:36 ` Argenziano, Antonio
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=5cbc0fc2-3c8a-fb32-8f05-779ead8e14f8@intel.com \
--to=tony.ye@intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=feng.qi@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=robert.m.fosha@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