Allen Martin | ba4fb9b | 2013-01-29 13:51:28 +0000 | [diff] [blame] | 1 | /* |
| 2 | * NVIDIA Tegra SPI-SLINK controller |
| 3 | * |
| 4 | * Copyright 2010-2013 NVIDIA Corporation |
| 5 | * |
| 6 | * This software may be used and distributed according to the |
| 7 | * terms of the GNU Public License, Version 2, incorporated |
| 8 | * herein by reference. |
| 9 | * |
| 10 | * This program is free software; you can redistribute it and/or |
| 11 | * modify it under the terms of the GNU General Public License |
| 12 | * Version 2 as published by the Free Software Foundation. |
| 13 | * |
| 14 | * This program is distributed in the hope that it will be useful, |
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 17 | * GNU General Public License for more details. |
| 18 | * |
| 19 | * You should have received a copy of the GNU General Public License |
| 20 | * along with this program; if not, write to the Free Software |
| 21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, |
| 22 | * MA 02111-1307 USA |
| 23 | */ |
| 24 | |
Allen Martin | e8e99ab | 2013-03-16 18:58:03 +0000 | [diff] [blame] | 25 | #ifndef _TEGRA30_SPI_H_ |
| 26 | #define _TEGRA30_SPI_H_ |
Allen Martin | ba4fb9b | 2013-01-29 13:51:28 +0000 | [diff] [blame] | 27 | |
| 28 | #include <asm/types.h> |
| 29 | |
Allen Martin | b98691c | 2013-03-16 18:58:07 +0000 | [diff] [blame] | 30 | int tegra30_spi_init(int *node_list, int count); |
| 31 | int tegra30_spi_cs_is_valid(unsigned int bus, unsigned int cs); |
| 32 | struct spi_slave *tegra30_spi_setup_slave(unsigned int bus, unsigned int cs, |
| 33 | unsigned int max_hz, unsigned int mode); |
| 34 | void tegra30_spi_free_slave(struct spi_slave *slave); |
| 35 | int tegra30_spi_claim_bus(struct spi_slave *slave); |
| 36 | void tegra30_spi_cs_activate(struct spi_slave *slave); |
| 37 | void tegra30_spi_cs_deactivate(struct spi_slave *slave); |
| 38 | int tegra30_spi_xfer(struct spi_slave *slave, unsigned int bitlen, |
| 39 | const void *data_out, void *data_in, unsigned long flags); |
| 40 | |
Allen Martin | e8e99ab | 2013-03-16 18:58:03 +0000 | [diff] [blame] | 41 | #endif /* _TEGRA30_SPI_H_ */ |