colibri_t20-common.c 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /*
  2. * Copyright (C) 2012 Lucas Stach
  3. *
  4. * This program is free software; you can redistribute it and/or
  5. * modify it under the terms of the GNU General Public License as
  6. * published by the Free Software Foundation; either version 2 of
  7. * the License, or (at your option) any later version.
  8. *
  9. * This program is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. */
  15. #include <common.h>
  16. #include <asm/arch/clock.h>
  17. #include <asm/arch/funcmux.h>
  18. #include <asm/arch/pinmux.h>
  19. #include <asm/arch-tegra/board.h>
  20. #include "colibri_t20-common.h"
  21. #ifdef CONFIG_USB_EHCI_TEGRA
  22. void colibri_t20_common_pin_mux_usb(void)
  23. {
  24. /* module internal USB bus to connect ethernet chipset */
  25. funcmux_select(PERIPH_ID_USB2, FUNCMUX_USB2_ULPI);
  26. /* ULPI reference clock output */
  27. pinmux_set_func(PINGRP_CDEV2, PMUX_FUNC_PLLP_OUT4);
  28. pinmux_tristate_disable(PINGRP_CDEV2);
  29. /* PHY reset GPIO */
  30. pinmux_tristate_disable(PINGRP_UAC);
  31. /* VBus GPIO */
  32. pinmux_tristate_disable(PINGRP_DTE);
  33. }
  34. #endif
  35. #ifdef CONFIG_TEGRA_NAND
  36. void pin_mux_nand(void)
  37. {
  38. funcmux_select(PERIPH_ID_NDFLASH, FUNCMUX_NDFLASH_KBC_8_BIT);
  39. }
  40. #endif