memcg_subgroup_charge.sh 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. #!/bin/sh
  2. ################################################################################
  3. ## ##
  4. ## Copyright (c) 2009 FUJITSU LIMITED ##
  5. ## ##
  6. ## This program is free software; you can redistribute it and#or modify ##
  7. ## it under the terms of the GNU General Public License as published by ##
  8. ## the Free Software Foundation; either version 2 of the License, or ##
  9. ## (at your option) any later version. ##
  10. ## ##
  11. ## This program is distributed in the hope that it will be useful, but ##
  12. ## WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY ##
  13. ## or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License ##
  14. ## for more details. ##
  15. ## ##
  16. ## You should have received a copy of the GNU General Public License ##
  17. ## along with this program; if not, write to the Free Software Foundation, ##
  18. ## Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA ##
  19. ## ##
  20. ## Author: Li Zefan <lizf@cn.fujitsu.com> ##
  21. ## Restructure for LTP: Shi Weihua <shiwh@cn.fujitsu.com> ##
  22. ## Added memcg enable/disable functinality: Rishikesh K Rajak ##
  23. ## <risrajak@linux.vnet.ibm.com ##
  24. ## ##
  25. ################################################################################
  26. TCID="memcg_subgroup_charge"
  27. TST_TOTAL=3
  28. . memcg_lib.sh
  29. # Test that group and subgroup have no relationship
  30. testcase_1()
  31. {
  32. test_subgroup $PAGESIZES $((2*PAGESIZES))
  33. }
  34. testcase_2()
  35. {
  36. test_subgroup $PAGESIZES $PAGESIZES
  37. }
  38. testcase_3()
  39. {
  40. test_subgroup $PAGESIZES 0
  41. }
  42. run_tests
  43. tst_exit