Here''s a small set of tests I''ve written for the balloon driver. I''m sure there''s more that could be tested, but it''s a start. Can/should these go in the tests directory? Here''s a brief description of each and a tarball since it would be cumbersome to send them all inline: balloon01: Test read from /proc/xen/balloon balloon02: Echo a number higher than current requested allocation to /proc/xen/balloon, cat balloon and see that requested target changed. balloon03: Echo a number lower than current requested allocation to /proc/xen/balloon, cat balloon and see that requested target changed. balloon04: Allocate some memory for the domain, then use /proc/xen/balloon to reduce available memory to less than what is allocated balloon05: Try to give /proc/xen/balloon a value larger than the available RAM in the system. balloon06: Try to give /proc/xen/balloon a value way too low, such as 4k balloon07: Open /proc/xen/balloon as non-root user, expect -EACCES balloon08: Write 1 byte to /proc/xen/balloon, expect -EBADMSG balloon09: Write >64 bytes to /proc/xen/balloon, expect -EFBIG Thanks, Paul Larson _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
> sure there''s more that could be tested, but it''s a start. Can/should > these go in the tests directory? >PLEASE.> Here''s a brief description of each and a tarball since it would be > cumbersome to send them all inline: > > balloon01: Test read from /proc/xen/balloon > balloon02: Echo a number higher than current requested allocation to > /proc/xen/balloon, cat balloon and see that requested target changed. > balloon03: Echo a number lower than current requested allocation to > /proc/xen/balloon, cat balloon and see that requested target changed. > balloon04: Allocate some memory for the domain, then use > /proc/xen/balloon to reduce available memory to less than what is allocated > balloon05: Try to give /proc/xen/balloon a value larger than the > available RAM in the system. > balloon06: Try to give /proc/xen/balloon a value way too low, such as 4k > balloon07: Open /proc/xen/balloon as non-root user, expect -EACCES > balloon08: Write 1 byte to /proc/xen/balloon, expect -EBADMSG > balloon09: Write >64 bytes to /proc/xen/balloon, expect -EFBIG > > Thanks, > Paul Larson > > > > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xensource.com > http://lists.xensource.com/xen-devel > > > >_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel