From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by gabe.freedesktop.org (Postfix) with ESMTPS id 672E410E0E2 for ; Fri, 9 Jun 2023 05:58:19 +0000 (UTC) Message-ID: Date: Fri, 9 Jun 2023 11:27:52 +0530 Content-Language: en-US To: "Modem, Bhanuprakash" , References: <20230606080208.2683342-1-kunal1.joshi@intel.com> <20230606080208.2683342-5-kunal1.joshi@intel.com> From: "Joshi, Kunal1" In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit MIME-Version: 1.0 Subject: Re: [igt-dev] [PATCH i-g-t 4/5] RFC lib/ioctl_wrappers: GEM_SET_DOMAIN ioctl not supported on xe List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" List-ID: On 6/8/2023 5:12 PM, Modem, Bhanuprakash wrote: > Hi Kunal, > > On Tue-06-06-2023 01:32 pm, Kunal Joshi wrote: >> xe doesn't support GEM_SET_DOMAIN ioctl >> >> Signed-off-by: Kunal Joshi >> --- >>   lib/ioctl_wrappers.c | 7 ++++++- >>   1 file changed, 6 insertions(+), 1 deletion(-) >> >> diff --git a/lib/ioctl_wrappers.c b/lib/ioctl_wrappers.c >> index ebd8a2f3..1180d4c6 100644 >> --- a/lib/ioctl_wrappers.c >> +++ b/lib/ioctl_wrappers.c >> @@ -534,7 +534,12 @@ int __gem_set_domain(int fd, uint32_t handle, >> uint32_t read, uint32_t write) >>    */ >>   void gem_set_domain(int fd, uint32_t handle, uint32_t read, >> uint32_t write) >>   { >> -    int ret = __gem_set_domain(fd, handle, read, write); >> +    int ret; >> + >> +    if (is_xe_device(fd)) >> +        return; >> + >> +    ret = __gem_set_domain(fd, handle, read, write); > > I think this must be handled in test level. Instead of modifying the > helper don't call it in case of Xe. >     igt_assert_eq(gem_wait(fd, handle, 0), 0); I think it will be good if we can place it here Also some library helpers calls this i think will have to place checks there too But let me know your thoughts Thanks and Regards Kunal Joshi