source: rtems/c/src/lib/libbsp/lm32/shared/milkymist_pfpu/milkymist_pfpu.h @ c499856

4.115
Last change on this file since c499856 was c499856, checked in by Chris Johns <chrisj@…>, on 03/20/14 at 21:10:47

Change all references of rtems.com to rtems.org.

  • Property mode set to 100644
File size: 1.4 KB
Line 
1/**
2 * @file
3 * @ingroup lm32_milkymist_pfpu lm32_milkymist_shared
4 * @brief Milkymist PFPU driver
5 */
6
7/*  milkymist_pfpu.h
8 *
9 *  Milkymist PFPU driver for RTEMS
10 *
11 *  The license and distribution terms for this file may be
12 *  found in the file LICENSE in this distribution or at
13 *  http://www.rtems.org/license/LICENSE.
14 *
15 *  COPYRIGHT (c) 2010 Sebastien Bourdeauducq
16 */
17
18/**
19 * @defgroup lm32_milkymist_pfpu Milkymist PFPU
20 * @ingroup lm32_milkymist_shared
21 * @brief Milkymist PFPU driver
22 * @{
23 */
24
25#ifndef __MILKYMIST_PFPU_H_
26#define __MILKYMIST_PFPU_H_
27
28#ifdef __cplusplus
29extern "C" {
30#endif
31
32/* Ioctls */
33#define PFPU_EXECUTE       0x4600
34
35#define PFPU_PROGSIZE              (2048)
36#define PFPU_REG_COUNT           (128)
37
38struct pfpu_td {
39        unsigned int *output;
40        unsigned int hmeshlast;
41        unsigned int vmeshlast;
42        unsigned int *program;
43        unsigned int progsize;
44        float *registers;
45        /** @brief shall we update the "registers" array after completion */
46        bool update;
47        /** @brief shall we invalidate L1 data cache after completion */
48        bool invalidate;
49};
50
51rtems_device_driver pfpu_initialize(
52  rtems_device_major_number major,
53  rtems_device_minor_number minor,
54  void *arg
55);
56
57rtems_device_driver pfpu_control(
58  rtems_device_major_number major,
59  rtems_device_minor_number minor,
60  void *arg
61);
62
63#define PFPU_DRIVER_TABLE_ENTRY {pfpu_initialize, \
64NULL, NULL, NULL, NULL, pfpu_control}
65
66/** @} */
67
68#ifdef __cplusplus
69}
70#endif
71
72#endif /* __MILKYMIST_PFPU_H_ */
Note: See TracBrowser for help on using the repository browser.