xref: /openbmc/linux/drivers/s390/char/hmcdrv_cache.h (revision e8f6f3b4)
1 /*
2  *    SE/HMC Drive (Read) Cache Functions
3  *
4  *    Copyright IBM Corp. 2013
5  *    Author(s): Ralf Hoppe (rhoppe@de.ibm.com)
6  */
7 
8 #ifndef __HMCDRV_CACHE_H__
9 #define __HMCDRV_CACHE_H__
10 
11 #include <linux/mmzone.h>
12 #include "hmcdrv_ftp.h"
13 
14 #define HMCDRV_CACHE_SIZE_DFLT	(MAX_ORDER_NR_PAGES * PAGE_SIZE / 2UL)
15 
16 typedef ssize_t (*hmcdrv_cache_ftpfunc)(const struct hmcdrv_ftp_cmdspec *ftp,
17 					size_t *fsize);
18 
19 ssize_t hmcdrv_cache_cmd(const struct hmcdrv_ftp_cmdspec *ftp,
20 			 hmcdrv_cache_ftpfunc func);
21 int hmcdrv_cache_startup(size_t cachesize);
22 void hmcdrv_cache_shutdown(void);
23 
24 #endif	 /* __HMCDRV_CACHE_H__ */
25