From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Sat, 14 Mar 2020 00:21:39 +0200 From: Andi Shyti Message-ID: <20200313222139.GC3001@intel.intel> References: <20200311093448.4103262-1-chris@chris-wilson.co.uk> <20200311093448.4103262-2-chris@chris-wilson.co.uk> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20200311093448.4103262-2-chris@chris-wilson.co.uk> Subject: Re: [igt-dev] [Intel-gfx] [PATCH i-g-t 2/5] lib/i915: Dynamic subtest constructor for sysfs/engines List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" To: Chris Wilson Cc: igt-dev@lists.freedesktop.org, intel-gfx@lists.freedesktop.org List-ID: Hi Chris, > + lseek(engines, 0, SEEK_SET); > + while ((len = syscall(SYS_getdents64, engines, buf, sizeof(buf))) > 0) { > + void *ptr = buf; > + > + while (len) { > + struct linux_dirent64 { > + ino64_t d_ino; > + off64_t d_off; > + unsigned short d_reclen; > + unsigned char d_type; > + char d_name[]; > + } *de = ptr; it's unfortunate to be in the situation of doing this, But I don't see better alternative, it needs to be fixed in the glibc :( Reviewed-by: Andi Shyti Thanks, Andi _______________________________________________ igt-dev mailing list igt-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/igt-dev