/* Nios-sim - one simple NIOSII simulator only for personal interest and fun. Copyright (C) 2010 chysun2000@gmail.com This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ #ifndef __NOR_FLASH_H__ #define __NOR_FLASH_H__ #include #include #include "io_device.h" #define NOR_FLASH_OPS_CNT (10) struct nor_flash_operations{ uint32_t addr; uint32_t value; }; #define STATUS_READ (0) #define STATUS_WRITE (1) #define STATUS_CHIP_ERASE (2) #define STATUS_SECTION_ERASE (3) #define NOR_FLASH_BASE_ADDR (0x0000) #define NOR_FLASH_SIZE (0x400000) #define NOR_FLASH_BUS_WIDTH (8) struct nor_flash_core_hw { struct nor_flash_operations ops[10]; uint32_t phys_base_addr; uint32_t size; uint32_t status; uint8_t * mem_base_addr; uint32_t bus_width; }; extern struct io_device nor_flash_core; extern uint8_t * nor_flash_mem_addr(void); #endif /* end of nor_flash.h */ summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVignesh R <vigneshr@ti.com>2016-04-25 15:14:00 +0530
committerMark Brown <broonie@kernel.org>2016-04-25 18:55:57 +0100
commit0569a88f3d1ffed94b15569d53872f16e2351099 (patch)
tree5e7497a4ef4d1a75c6feced072337ca824e1db8c /Documentation
parentd7e2ee257038baeb03baef602500368a51ee9eef (diff)
spi: return error if kmap'd buffers passed to spi_map_buf()
Current spi_map_buf() implementation supports creates sg_table for vmalloc'd and kmalloc'd buffers. Therefore return error if kmap'd buffer (or any other buffer) is passed to spi_map_buf(). Signed-off-by: Vignesh R <vigneshr@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'Documentation')