Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 102500
b: refs/heads/master
c: d4100dd
h: refs/heads/master
v: v3
  • Loading branch information
Ron Rindjunsky authored and John W. Linville committed May 7, 2008
1 parent 2501258 commit d49a656
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fcf623df17197adf10e22ddeba90c56504edce0f
refs/heads/master: d4100dd985dcc13cc7bd1712ce10dea51b7c8261
25 changes: 25 additions & 0 deletions trunk/drivers/net/wireless/iwlwifi/iwl-5000.c
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,29 @@ static int iwl5000_hw_set_hw_params(struct iwl_priv *priv)

return 0;
}

static int iwl5000_alloc_shared_mem(struct iwl_priv *priv)
{
priv->shared_virt = pci_alloc_consistent(priv->pci_dev,
sizeof(struct iwl5000_shared),
&priv->shared_phys);
if (!priv->shared_virt)
return -ENOMEM;

memset(priv->shared_virt, 0, sizeof(struct iwl5000_shared));

return 0;
}

static void iwl5000_free_shared_mem(struct iwl_priv *priv)
{
if (priv->shared_virt)
pci_free_consistent(priv->pci_dev,
sizeof(struct iwl5000_shared),
priv->shared_virt,
priv->shared_phys);
}

static struct iwl_hcmd_ops iwl5000_hcmd = {
};

Expand All @@ -303,6 +326,8 @@ static struct iwl_hcmd_utils_ops iwl5000_hcmd_utils = {

static struct iwl_lib_ops iwl5000_lib = {
.set_hw_params = iwl5000_hw_set_hw_params,
.alloc_shared_mem = iwl5000_alloc_shared_mem,
.free_shared_mem = iwl5000_free_shared_mem,
.apm_ops = {
.init = iwl5000_apm_init,
.set_pwr_src = iwl4965_set_pwr_src,
Expand Down

0 comments on commit d49a656

Please sign in to comment.