1 /*
2 * Intel Wireless Multicomm 3200 WiFi driver
3 *
4 * Copyright (C) 2009 Intel Corporation <ilw@linux.intel.com>
5 * Samuel Ortiz <samuel.ortiz@intel.com>
6 * Zhu Yi <yi.zhu@intel.com>
7 *
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License version
10 * 2 as published by the Free Software Foundation.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
20 * 02110-1301, USA.
21 *
22 */
23
24 #ifndef __IWM_BUS_H__
25 #define __IWM_BUS_H__
26
27 #include "iwm.h"
28
29 struct iwm_if_ops {
30 int (*enable)(struct iwm_priv *iwm);
31 int (*disable)(struct iwm_priv *iwm);
32 int (*send_chunk)(struct iwm_priv *iwm, u8* buf, int count);
33
34 void (*debugfs_init)(struct iwm_priv *iwm, struct dentry *parent_dir);
35 void (*debugfs_exit)(struct iwm_priv *iwm);
36
37 const char *umac_name;
38 const char *calib_lmac_name;
39 const char *lmac_name;
40 };
41
iwm_bus_send_chunk(struct iwm_priv * iwm,u8 * buf,int count)42 static inline int iwm_bus_send_chunk(struct iwm_priv *iwm, u8 *buf, int count)
43 {
44 return iwm->bus_ops->send_chunk(iwm, buf, count);
45 }
46
iwm_bus_enable(struct iwm_priv * iwm)47 static inline int iwm_bus_enable(struct iwm_priv *iwm)
48 {
49 return iwm->bus_ops->enable(iwm);
50 }
51
iwm_bus_disable(struct iwm_priv * iwm)52 static inline int iwm_bus_disable(struct iwm_priv *iwm)
53 {
54 return iwm->bus_ops->disable(iwm);
55 }
56
57 #endif
58