#include <linux/atomic.h>
#include <linux/firmware.h>
#include <linux/jiffies.h>
#include <linux/mmc/card.h>
#include <linux/mmc/sdio_func.h>
#include <linux/module.h>
#include <linux/workqueue.h>
#include "ks_wlan.h"
#include "ks_hostif.h"
#define ROM_FILE …
#define SDIO_VENDOR_ID_KS_CODE_A …
#define SDIO_VENDOR_ID_KS_CODE_B …
#define SDIO_DEVICE_ID_KS_7010 …
#define READ_STATUS_REG …
#define WRITE_STATUS_REG …
enum reg_status_type { … };
#define READ_INDEX_REG …
#define READ_DATA_SIZE_REG …
#define WRITE_INDEX_REG …
#define WSTATUS_RSIZE_REG …
#define WSTATUS_MASK …
#define RSIZE_MASK …
#define INT_ENABLE_REG …
#define INT_PENDING_REG …
#define INT_GCR_B …
#define INT_GCR_A …
#define INT_WRITE_STATUS …
#define INT_WRITE_INDEX …
#define INT_WRITE_SIZE …
#define INT_READ_STATUS …
#define INT_READ_INDEX …
#define INT_READ_SIZE …
#define GCR_A_REG …
enum gen_com_reg_a { … };
#define GCR_B_REG …
enum gen_com_reg_b { … };
#define WAKEUP_REG …
#define WAKEUP_REQ …
#define DATA_WINDOW …
#define WINDOW_SIZE …
#define KS7010_IRAM_ADDRESS …
#define KS7010_IO_BLOCK_SIZE …
struct ks_sdio_card { … };
static struct sdio_func *ks7010_to_func(struct ks_wlan_private *priv)
{ … }
static int ks7010_sdio_readb(struct ks_wlan_private *priv,
u32 address, u8 *byte)
{ … }
static int ks7010_sdio_read(struct ks_wlan_private *priv, u32 address,
u8 *buffer, unsigned int length)
{ … }
static int ks7010_sdio_writeb(struct ks_wlan_private *priv,
u32 address, u8 byte)
{ … }
static int ks7010_sdio_write(struct ks_wlan_private *priv, u32 address,
u8 *buffer, unsigned int length)
{ … }
static void ks_wlan_hw_sleep_doze_request(struct ks_wlan_private *priv)
{ … }
static void ks_wlan_hw_sleep_wakeup_request(struct ks_wlan_private *priv)
{ … }
void ks_wlan_hw_wakeup_request(struct ks_wlan_private *priv)
{ … }
static void _ks_wlan_hw_power_save(struct ks_wlan_private *priv)
{ … }
int ks_wlan_hw_power_save(struct ks_wlan_private *priv)
{ … }
static int enqueue_txdev(struct ks_wlan_private *priv, unsigned char *p,
unsigned long size,
void (*complete_handler)(struct ks_wlan_private *priv,
struct sk_buff *skb),
struct sk_buff *skb)
{ … }
static int write_to_device(struct ks_wlan_private *priv, u8 *buffer,
unsigned long size)
{ … }
static void tx_device_task(struct ks_wlan_private *priv)
{ … }
int ks_wlan_hw_tx(struct ks_wlan_private *priv, void *p, unsigned long size,
void (*complete_handler)(struct ks_wlan_private *priv,
struct sk_buff *skb),
struct sk_buff *skb)
{ … }
static void rx_event_task(struct tasklet_struct *t)
{ … }
static void ks_wlan_hw_rx(struct ks_wlan_private *priv, size_t size)
{ … }
static void ks7010_rw_function(struct work_struct *work)
{ … }
static void ks_sdio_interrupt(struct sdio_func *func)
{ … }
static int trx_device_init(struct ks_wlan_private *priv)
{ … }
static void trx_device_exit(struct ks_wlan_private *priv)
{ … }
static int ks7010_sdio_update_index(struct ks_wlan_private *priv, u32 index)
{ … }
#define ROM_BUFF_SIZE …
static int ks7010_sdio_data_compare(struct ks_wlan_private *priv, u32 address,
u8 *data, unsigned int size)
{ … }
static int ks7010_copy_firmware(struct ks_wlan_private *priv,
const struct firmware *fw_entry)
{ … }
static int ks7010_upload_firmware(struct ks_sdio_card *card)
{ … }
static void ks7010_sme_enqueue_events(struct ks_wlan_private *priv)
{ … }
static void ks7010_card_init(struct ks_wlan_private *priv)
{ … }
static void ks7010_init_defaults(struct ks_wlan_private *priv)
{ … }
static int ks7010_sdio_setup_irqs(struct sdio_func *func)
{ … }
static void ks7010_sdio_init_irqs(struct sdio_func *func,
struct ks_wlan_private *priv)
{ … }
static void ks7010_private_init(struct ks_wlan_private *priv,
struct ks_sdio_card *card,
struct net_device *netdev)
{ … }
static int ks7010_sdio_probe(struct sdio_func *func,
const struct sdio_device_id *device)
{ … }
static int send_stop_request(struct sdio_func *func)
{ … }
static void ks7010_sdio_remove(struct sdio_func *func)
{ … }
static const struct sdio_device_id ks7010_sdio_ids[] = …;
MODULE_DEVICE_TABLE(sdio, ks7010_sdio_ids);
static struct sdio_driver ks7010_sdio_driver = …;
module_sdio_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;
MODULE_FIRMWARE(…);