Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
iorpc_usb_host.c
Go to the documentation of this file.
1 /*
2  * Copyright 2012 Tilera Corporation. All Rights Reserved.
3  *
4  * This program is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU General Public License
6  * as published by the Free Software Foundation, version 2.
7  *
8  * This program is distributed in the hope that it will be useful, but
9  * WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or
11  * NON INFRINGEMENT. See the GNU General Public License for
12  * more details.
13  */
14 
15 /* This file is machine-generated; DO NOT EDIT! */
16 #include "gxio/iorpc_usb_host.h"
17 
20 };
21 
23  int inter_y, int inter_ipi, int inter_event)
24 {
25  struct cfg_interrupt_param temp;
26  struct cfg_interrupt_param *params = &temp;
27 
28  params->interrupt.kernel.x = inter_x;
29  params->interrupt.kernel.y = inter_y;
30  params->interrupt.kernel.ipi = inter_ipi;
31  params->interrupt.kernel.event = inter_event;
32 
33  return hv_dev_pwrite(context->fd, 0, (HV_VirtAddr) params,
34  sizeof(*params), GXIO_USB_HOST_OP_CFG_INTERRUPT);
35 }
36 
38 
40  HV_PTE pte;
41  unsigned int flags;
42 };
43 
45  HV_PTE pte, unsigned int flags)
46 {
47  struct register_client_memory_param temp;
49 
50  params->pte = pte;
51  params->flags = flags;
52 
53  return hv_dev_pwrite(context->fd, 0, (HV_VirtAddr) params,
54  sizeof(*params),
56 }
57 
59 
60 struct get_mmio_base_param {
61  HV_PTE base;
62 };
63 
65 {
66  int __result;
67  struct get_mmio_base_param temp;
68  struct get_mmio_base_param *params = &temp;
69 
70  __result =
71  hv_dev_pread(context->fd, 0, (HV_VirtAddr) params, sizeof(*params),
73  *base = params->base;
74 
75  return __result;
76 }
77 
79 
81  unsigned long offset;
82  unsigned long size;
83 };
84 
86  unsigned long offset, unsigned long size)
87 {
88  struct check_mmio_offset_param temp;
90 
91  params->offset = offset;
92  params->size = size;
93 
94  return hv_dev_pwrite(context->fd, 0, (HV_VirtAddr) params,
95  sizeof(*params),
97 }
98