From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by gabe.freedesktop.org (Postfix) with ESMTPS id 78EA76ECF2 for ; Fri, 4 Sep 2020 23:34:23 +0000 (UTC) Date: Fri, 04 Sep 2020 16:34:18 -0700 Message-ID: <87zh655d6t.wl-ashutosh.dixit@intel.com> From: "Dixit, Ashutosh" In-Reply-To: <20200904162026.10956-1-ashutosh.dixit@intel.com> References: <20200904162026.10956-1-ashutosh.dixit@intel.com> MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Subject: Re: [igt-dev] [PATCH i-g-t 1/2] lib/ioctl_wrappers: Keep IGT working without pread/pwrite ioctls 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: igt-dev@lists.freedesktop.org List-ID: On Fri, 04 Sep 2020 09:20:25 -0700, Ashutosh Dixit wrote: > > The general direction at this time is to phase out pread/write ioctls > and not support them in future products. This means IGT must be > modified to handle the absence of pread/write ioctls. This patch does > this as follows: > > * __gem_read, gem_read, __gem_write and gem_write calls which are > wrappers around the pread/pwrite ioctls have been renamed to > __gem_pread, gem_pread, __gem_pwrite and gem_pwrite. These will now > only be used where the pread/pwrite ioctls must absolutely be used, > such as tests which test these ioctls or must otherwise only use the > pread/pwrite ioctl's. It seemed to me that these new functions (__gem_pread, gem_pread, __gem_pwrite and gem_pwrite) were not needed after all since the callers of these functions would anyway have to call gem_require_pread_pwrite() to skip when the pread/pwrite ioctls were unavailable. Therefore gem_require_pread_pwrite() itself indicates that only the pread/pwrite ioctls must be used. Therefore I have dropped __gem_pread, gem_pread, __gem_pwrite and gem_pwrite in v2. This results in further simplification and also the two previous patches have been squashed into a single patch in v2. > * The new gem_read and gem_write function calls are now treated as > general purpose calls to read/write to a gem object. They now try > doing the read/write using the pread/pwrite ioctls first but when > these ioctls are unavailable they fall back to doing the read/write > using a combination of mmap and memcpy. _______________________________________________ igt-dev mailing list igt-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/igt-dev