[Intel-gfx] [PATCH] pm_rps: Improve file I/O and restore utilities

Jeff McGee jeff.mcgee at intel.com
Fri Jan 10 21:50:52 CET 2014


On Fri, Jan 10, 2014 at 06:38:59PM +0100, Daniel Vetter wrote:
> On Fri, Jan 10, 2014 at 11:20:42AM -0600, jeff.mcgee at intel.com wrote:
> > From: Jeff McGee <jeff.mcgee at intel.com>
> > 
> > Use unbuffered file I/O to simplify and ensure proper sysfs access.
> > Bionic C library may not re-read a read-only file unless unbuffered,
> > which results in failure to monitor changes in gt_cur_freq_mhz.
> > 
> > Adapt do_writeval to assert that no write error occurs when we expect
> > none.
> > 
> > Expand use of restore_assert macro to ensure that original min/max
> > frequencies are always in place after a test failure.
> 
> The above three changs should be split into three patches, so that in case
> something blows up we don't have to dig out the test functionality changes
> from the switch to raw io.
> 
> Also I think we should replace restore_assert with an igt cleanup handler.
> Those are a bit more robust and will also clean up even when the test
> process has caught a signal.
> 
> See igt_install_exit_handler. there's already plenty of examples all over
> the tree.
> 
> Thanks, Daniel
> -- 
> Daniel Vetter
> Software Engineer, Intel Corporation
> +41 (0) 79 365 57 48 - http://blog.ffwll.ch

I agree. New patches coming. Thanks

Jeff



More information about the Intel-gfx mailing list