From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kenneth Graunke Subject: Re: [PATCH] drm/i915: Add OACONTROL to the command parser register whitelist. Date: Wed, 26 Mar 2014 15:34:35 -0700 Message-ID: <533355FB.4010706@whitecape.org> References: <1395813123-2027-1-git-send-email-kenneth@whitecape.org> <20140326062123.GO26878@phenom.ffwll.local> <20140326160358.GA11367@bdvolkin-ubuntu-desktop> <20140326163820.GV26878@phenom.ffwll.local> <53331068.7090007@whitecape.org> <20140326182605.GA28133@bdvolkin-ubuntu-desktop> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0748188373==" Return-path: Received: from homiemail-a99.g.dreamhost.com (caiajhbdcbhh.dreamhost.com [208.97.132.177]) by gabe.freedesktop.org (Postfix) with ESMTP id 2CF886E7C2 for ; Wed, 26 Mar 2014 15:34:16 -0700 (PDT) In-Reply-To: <20140326182605.GA28133@bdvolkin-ubuntu-desktop> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" To: "Volkin, Bradley D" Cc: "intel-gfx@lists.freedesktop.org" List-Id: intel-gfx@lists.freedesktop.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --===============0748188373== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="5L7bh5fsWOo47H8hKD4m18f58561kkiNK" This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --5L7bh5fsWOo47H8hKD4m18f58561kkiNK Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 03/26/2014 11:26 AM, Volkin, Bradley D wrote: > On Wed, Mar 26, 2014 at 10:37:44AM -0700, Kenneth Graunke wrote: >> On 03/26/2014 09:38 AM, Daniel Vetter wrote: >>> On Wed, Mar 26, 2014 at 09:03:58AM -0700, Volkin, Bradley D wrote: >>>> On Tue, Mar 25, 2014 at 11:21:23PM -0700, Daniel Vetter wrote: >>>>> On Tue, Mar 25, 2014 at 10:52:03PM -0700, Kenneth Graunke wrote: >>>>>> Mesa needs to be able to write OACONTROL in order to expose the >>>>>> Observability Architecture's performance counters via OpenGL. >>>>>> >>>>>> Signed-off-by: Kenneth Graunke >>>>> >>>>> Thanks a lot for quickly tracking this down. Now when we've talked = about >>>>> OA a little while ago we concluded that mesa should clear OACONTROL= again >>>>> before the batch ends to make sure that userspace can't unduly obse= rve >>>>> other processes. So I think it'd be worth to keep track of this wit= h a >>>>> flag (set when OACONTROL is !=3D 0 and reset when the batch loads 0= ). Also >>>>> we need to make sure that userspace sets the right OACONTROL modes = (not >>>>> the one which streams into a global gtt buffer essentially). So som= e >>>>> additional work required. >>>> >>>> Ok, I'll look into this. And apologies for not catching it myself. >>>> >>>> If we have to do additional checks on fields within the registers th= en I >>>> suppose we'll need to limit those registers to MI_LOAD_REGISTER_IMM.= That >>>> might require separate whitelists for MI_LOAD_REGISTER_IMM/MEM. Not = the end >>>> of the world, but certainly some additional complexity. >>>> >>>> For the resetting check, are there other registers in the current li= st that >>>> should have this tracking? If so, is 0 the reset value in all cases?= >>>> >>>> Let me know if there is anything in the works that would require add= itional >>>> registers or different uses of any registers. >>> >>> Afaik there's no other register we want to reset again. I think all o= ther >>> register we might want to clear are already part of hw contexts, so n= o >>> chance to leak stuff (e.g. the streamout registers and a end-of-pipe >>> counters). Ken might know of something I've missed. >>> -Daniel >> >> Right, I think it's just OACONTROL. I don't think there's a need to >> filter particular values. >=20 > Sorry, I don't follow you here. Can you clarify what you mean r.e. filt= ering? Oh, I meant I don't think we need to do additional checks on "fields within the registers" (to quote your email) or restrict the values we can write to the registers. Just the ability to write the whole register to any arbitrary value should be sufficient. Thanks Brad! --Ken --5L7bh5fsWOo47H8hKD4m18f58561kkiNK Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.22 (GNU/Linux) iQIcBAEBAgAGBQJTM1YDAAoJEFtb2gcdScw44okP/2aGrerrODIsVxsFRXuzEqv/ INLMdpH3ujPRAl/BYH5KqtGRFxB2AyU1znFl6eRxoaQ91HgA61Y+QBrnrdG/ssCY l0lsuqT5nO28bCTl2hQJKj32fSyLbSwKRW+5wbqzD1odS+qIb7corxZNrvSGYgph xqnfyY8R/2nPd7/z6Nl/kjoZz4veb8WwaXS2BXcqPvsTkQv/ltnYF/PtTKeKlT2d 5IUULJNUVS0nm2M5//lpw2yWbq3xciFPDJ+arL+6t55fIDH+CrfiehvifqnGutGv a9nD1pRJ0iDGcLJLoRwXK3OMCR+s5KyXSb9s7BwCuWiA5fnc+dBvlu2hLvPrWmJ1 5xyJqMGdLZq1kjC79I2Imk8BdRW8mltkgdO2Z45n9jDFgkvmk+80TzSG7Vmr+i2h LwZNv/r1RZlCVVYi7aanAE25WL67LFnqIqtMh0FImj7PLX0Q0QUzzJl+FtYvXxOM /DGDcs7R7hMEGnPaEcyBs551cCLsAR3Fwmrdk6VWwWiqU9UgH/OfN0su2281+cwN mrGcH+atVyKNQDJJ8ZhGZYH8hrlWZZ8O9GAAE1k5Z5x7Ih6h2JAJpBdpD14097G/ wapbTqX648RliaCqzWf30u54YCXKqpBuAVF9LdCrId5dM1Q6j0BII960kLWZ64PK gmq+DOedXCPSsWWw4HjD =3gpT -----END PGP SIGNATURE----- --5L7bh5fsWOo47H8hKD4m18f58561kkiNK-- --===============0748188373== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/intel-gfx --===============0748188373==--