main.c (43a8bc5a53c78b69b99824c9f38c333cea024c8a) main.c (cd70f6a48b3fbb841a127361ee4ac0752f9d29a2)
1/*
2 * This file is part of wl1271
3 *
4 * Copyright (C) 2008-2010 Nokia Corporation
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * version 2 as published by the Free Software Foundation.

--- 17 unchanged lines hidden (view full) ---

26
27#include <linux/wl12xx.h>
28
29#include "../wlcore/wlcore.h"
30#include "../wlcore/debug.h"
31#include "../wlcore/io.h"
32#include "../wlcore/acx.h"
33#include "../wlcore/tx.h"
1/*
2 * This file is part of wl1271
3 *
4 * Copyright (C) 2008-2010 Nokia Corporation
5 *
6 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License
8 * version 2 as published by the Free Software Foundation.

--- 17 unchanged lines hidden (view full) ---

26
27#include <linux/wl12xx.h>
28
29#include "../wlcore/wlcore.h"
30#include "../wlcore/debug.h"
31#include "../wlcore/io.h"
32#include "../wlcore/acx.h"
33#include "../wlcore/tx.h"
34#include "../wlcore/rx.h"
34#include "../wlcore/boot.h"
35
36#include "reg.h"
37
38#define WL12XX_TX_HW_BLOCK_SPARE_DEFAULT 1
39#define WL12XX_TX_HW_BLOCK_GEM_SPARE 2
40#define WL12XX_TX_HW_BLOCK_SIZE 252
41

--- 687 unchanged lines hidden (view full) ---

729 "tx_fill_hdr: pad: %d hlid: %d len: %d life: %d mem: %d",
730 pad, desc->hlid,
731 le16_to_cpu(desc->length),
732 le16_to_cpu(desc->life_time),
733 desc->wl127x_mem.total_mem_blocks);
734 }
735}
736
35#include "../wlcore/boot.h"
36
37#include "reg.h"
38
39#define WL12XX_TX_HW_BLOCK_SPARE_DEFAULT 1
40#define WL12XX_TX_HW_BLOCK_GEM_SPARE 2
41#define WL12XX_TX_HW_BLOCK_SIZE 252
42

--- 687 unchanged lines hidden (view full) ---

730 "tx_fill_hdr: pad: %d hlid: %d len: %d life: %d mem: %d",
731 pad, desc->hlid,
732 le16_to_cpu(desc->length),
733 le16_to_cpu(desc->life_time),
734 desc->wl127x_mem.total_mem_blocks);
735 }
736}
737
738static enum wl_rx_buf_align
739wl12xx_get_rx_buf_align(struct wl1271 *wl, u32 rx_desc)
740{
741 if (rx_desc & RX_BUF_UNALIGNED_PAYLOAD)
742 return WLCORE_RX_BUF_UNALIGNED;
743
744 return WLCORE_RX_BUF_ALIGNED;
745}
746
737static bool wl12xx_mac_in_fuse(struct wl1271 *wl)
738{
739 bool supported = false;
740 u8 major, minor;
741
742 if (wl->chip.id == CHIP_ID_1283_PG20) {
743 major = WL128X_PG_GET_MAJOR(wl->hw_pg_ver);
744 minor = WL128X_PG_GET_MINOR(wl->hw_pg_ver);

--- 55 unchanged lines hidden (view full) ---

800static struct wlcore_ops wl12xx_ops = {
801 .identify_chip = wl12xx_identify_chip,
802 .boot = wl12xx_boot,
803 .trigger_cmd = wl12xx_trigger_cmd,
804 .ack_event = wl12xx_ack_event,
805 .calc_tx_blocks = wl12xx_calc_tx_blocks,
806 .set_tx_desc_blocks = wl12xx_set_tx_desc_blocks,
807 .set_tx_desc_data_len = wl12xx_set_tx_desc_data_len,
747static bool wl12xx_mac_in_fuse(struct wl1271 *wl)
748{
749 bool supported = false;
750 u8 major, minor;
751
752 if (wl->chip.id == CHIP_ID_1283_PG20) {
753 major = WL128X_PG_GET_MAJOR(wl->hw_pg_ver);
754 minor = WL128X_PG_GET_MINOR(wl->hw_pg_ver);

--- 55 unchanged lines hidden (view full) ---

810static struct wlcore_ops wl12xx_ops = {
811 .identify_chip = wl12xx_identify_chip,
812 .boot = wl12xx_boot,
813 .trigger_cmd = wl12xx_trigger_cmd,
814 .ack_event = wl12xx_ack_event,
815 .calc_tx_blocks = wl12xx_calc_tx_blocks,
816 .set_tx_desc_blocks = wl12xx_set_tx_desc_blocks,
817 .set_tx_desc_data_len = wl12xx_set_tx_desc_data_len,
818 .get_rx_buf_align = wl12xx_get_rx_buf_align,
808 .get_pg_ver = wl12xx_get_pg_ver,
809 .get_mac = wl12xx_get_mac,
810};
811
812struct wl12xx_priv {
813};
814
815static int __devinit wl12xx_probe(struct platform_device *pdev)

--- 61 unchanged lines hidden ---
819 .get_pg_ver = wl12xx_get_pg_ver,
820 .get_mac = wl12xx_get_mac,
821};
822
823struct wl12xx_priv {
824};
825
826static int __devinit wl12xx_probe(struct platform_device *pdev)

--- 61 unchanged lines hidden ---