servo_wp_hooks_jaq.sh 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #!/bin/sh
  2. #
  3. # Copyright (C) 2016 Google Inc.
  4. #
  5. # This program is free software; you can redistribute it and/or modify
  6. # it under the terms of the GNU General Public License as published by
  7. # the Free Software Foundation; either version 2 of the License, or
  8. # (at your option) any later version.
  9. #
  10. # This program is distributed in the hope that it will be useful,
  11. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. # GNU General Public License for more details.
  14. #
  15. # You should have received a copy of the GNU General Public License
  16. # along with this program; if not, write to the Free Software
  17. # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  18. #
  19. wp_enable_hook(){
  20. local rc=0
  21. dut-control fw_wp_en:on fw_wp_vref:pp3300
  22. rc=$?
  23. return $rc
  24. }
  25. wp_on_hook(){
  26. local rc=0
  27. dut-control fw_wp:on fw_wp
  28. rc=$?
  29. return $rc
  30. }
  31. wp_off_hook(){
  32. local rc=0
  33. dut-control fw_wp:off fw_wp
  34. rc=$?
  35. return $rc
  36. }
  37. wp_disable_hook(){
  38. local rc=0
  39. dut-control fw_wp_en:off fw_wp_vref:off
  40. rc=$?
  41. return $rc
  42. }