caif: code cleanup

Cleanup of new CAIF code.
  * make local functions static
  * remove code that is never used
  * expand get_caif_conf() since wrapper is no longer needed
  * make args to comparison functions const
  * rename connect_req_to_link_param to keep exported names
    consistent

Compile tested only.

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Sjur Brændeland <sjur.brandeland@stericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Stephen Hemminger
2011-04-11 10:43:50 +00:00
committed by David S. Miller
parent 1c01a80cfe
commit 73d6ac633c
12 changed files with 30 additions and 416 deletions
-35
View File
@@ -71,41 +71,6 @@ int cfmuxl_set_uplayer(struct cflayer *layr, struct cflayer *up, u8 linkid)
return 0;
}
bool cfmuxl_is_phy_inuse(struct cflayer *layr, u8 phyid)
{
struct list_head *node;
struct cflayer *layer;
struct cfmuxl *muxl = container_obj(layr);
bool match = false;
spin_lock(&muxl->receive_lock);
list_for_each(node, &muxl->srvl_list) {
layer = list_entry(node, struct cflayer, node);
if (cfsrvl_phyid_match(layer, phyid)) {
match = true;
break;
}
}
spin_unlock(&muxl->receive_lock);
return match;
}
u8 cfmuxl_get_phyid(struct cflayer *layr, u8 channel_id)
{
struct cflayer *up;
int phyid;
struct cfmuxl *muxl = container_obj(layr);
spin_lock(&muxl->receive_lock);
up = get_up(muxl, channel_id);
if (up != NULL)
phyid = cfsrvl_getphyid(up);
else
phyid = 0;
spin_unlock(&muxl->receive_lock);
return phyid;
}
int cfmuxl_set_dnlayer(struct cflayer *layr, struct cflayer *dn, u8 phyid)
{
struct cfmuxl *muxl = (struct cfmuxl *) layr;