18c2ecf20Sopenharmony_ci/*****************************************************************************
28c2ecf20Sopenharmony_ci *
38c2ecf20Sopenharmony_ci *     Author: Xilinx, Inc.
48c2ecf20Sopenharmony_ci *
58c2ecf20Sopenharmony_ci *     This program is free software; you can redistribute it and/or modify it
68c2ecf20Sopenharmony_ci *     under the terms of the GNU General Public License as published by the
78c2ecf20Sopenharmony_ci *     Free Software Foundation; either version 2 of the License, or (at your
88c2ecf20Sopenharmony_ci *     option) any later version.
98c2ecf20Sopenharmony_ci *
108c2ecf20Sopenharmony_ci *     XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
118c2ecf20Sopenharmony_ci *     AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
128c2ecf20Sopenharmony_ci *     SOLUTIONS FOR XILINX DEVICES.  BY PROVIDING THIS DESIGN, CODE,
138c2ecf20Sopenharmony_ci *     OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
148c2ecf20Sopenharmony_ci *     APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
158c2ecf20Sopenharmony_ci *     THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
168c2ecf20Sopenharmony_ci *     AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
178c2ecf20Sopenharmony_ci *     FOR YOUR IMPLEMENTATION.  XILINX EXPRESSLY DISCLAIMS ANY
188c2ecf20Sopenharmony_ci *     WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
198c2ecf20Sopenharmony_ci *     IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
208c2ecf20Sopenharmony_ci *     REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
218c2ecf20Sopenharmony_ci *     INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
228c2ecf20Sopenharmony_ci *     FOR A PARTICULAR PURPOSE.
238c2ecf20Sopenharmony_ci *
248c2ecf20Sopenharmony_ci *     (c) Copyright 2007-2008 Xilinx Inc.
258c2ecf20Sopenharmony_ci *     All rights reserved.
268c2ecf20Sopenharmony_ci *
278c2ecf20Sopenharmony_ci *     You should have received a copy of the GNU General Public License along
288c2ecf20Sopenharmony_ci *     with this program; if not, write to the Free Software Foundation, Inc.,
298c2ecf20Sopenharmony_ci *     675 Mass Ave, Cambridge, MA 02139, USA.
308c2ecf20Sopenharmony_ci *
318c2ecf20Sopenharmony_ci *****************************************************************************/
328c2ecf20Sopenharmony_ci
338c2ecf20Sopenharmony_ci#ifndef XILINX_FIFO_ICAP_H_	/* prevent circular inclusions */
348c2ecf20Sopenharmony_ci#define XILINX_FIFO_ICAP_H_	/* by using protection macros */
358c2ecf20Sopenharmony_ci
368c2ecf20Sopenharmony_ci#include <linux/types.h>
378c2ecf20Sopenharmony_ci#include <linux/cdev.h>
388c2ecf20Sopenharmony_ci#include <linux/platform_device.h>
398c2ecf20Sopenharmony_ci
408c2ecf20Sopenharmony_ci#include <asm/io.h>
418c2ecf20Sopenharmony_ci#include "xilinx_hwicap.h"
428c2ecf20Sopenharmony_ci
438c2ecf20Sopenharmony_ci/* Reads integers from the device into the storage buffer. */
448c2ecf20Sopenharmony_ciint fifo_icap_get_configuration(
458c2ecf20Sopenharmony_ci		struct hwicap_drvdata *drvdata,
468c2ecf20Sopenharmony_ci		u32 *FrameBuffer,
478c2ecf20Sopenharmony_ci		u32 NumWords);
488c2ecf20Sopenharmony_ci
498c2ecf20Sopenharmony_ci/* Writes integers to the device from the storage buffer. */
508c2ecf20Sopenharmony_ciint fifo_icap_set_configuration(
518c2ecf20Sopenharmony_ci		struct hwicap_drvdata *drvdata,
528c2ecf20Sopenharmony_ci		u32 *FrameBuffer,
538c2ecf20Sopenharmony_ci		u32 NumWords);
548c2ecf20Sopenharmony_ci
558c2ecf20Sopenharmony_ciu32 fifo_icap_get_status(struct hwicap_drvdata *drvdata);
568c2ecf20Sopenharmony_civoid fifo_icap_reset(struct hwicap_drvdata *drvdata);
578c2ecf20Sopenharmony_civoid fifo_icap_flush_fifo(struct hwicap_drvdata *drvdata);
588c2ecf20Sopenharmony_ci
598c2ecf20Sopenharmony_ci#endif
60