]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
tipc: remove unused str2addr media callback
authorPatrick McHardy <kaber@trash.net>
Wed, 17 Apr 2013 06:18:25 +0000 (06:18 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 17 Apr 2013 18:18:33 +0000 (14:18 -0400)
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/bearer.h
net/tipc/eth_media.c

index 39f1192d04bff34dfd2295cbe99b491d603e7cbb..cc2d74e1f9f71252837cdbb6825f825e0d1606e5 100644 (file)
@@ -77,7 +77,6 @@ struct tipc_bearer;
  * @enable_bearer: routine which enables a bearer
  * @disable_bearer: routine which disables a bearer
  * @addr2str: routine which converts media address to string
- * @str2addr: routine which converts media address from string
  * @addr2msg: routine which converts media address to protocol message area
  * @msg2addr: routine which converts media address from protocol message area
  * @bcast_addr: media address used in broadcasting
@@ -94,7 +93,6 @@ struct tipc_media {
        int (*enable_bearer)(struct tipc_bearer *b_ptr);
        void (*disable_bearer)(struct tipc_bearer *b_ptr);
        int (*addr2str)(struct tipc_media_addr *a, char *str_buf, int str_size);
-       int (*str2addr)(struct tipc_media_addr *a, char *str_buf);
        int (*addr2msg)(struct tipc_media_addr *a, char *msg_area);
        int (*msg2addr)(struct tipc_media_addr *a, char *msg_area);
        struct tipc_media_addr bcast_addr;
index 2132c1ef2951aa3c907e0650805f41aa88448a9b..1bdc6df0a79efba75a36a189cd473090f73bfd67 100644 (file)
@@ -301,25 +301,6 @@ static int eth_addr2str(struct tipc_media_addr *a, char *str_buf, int str_size)
        return 0;
 }
 
-/**
- * eth_str2addr - convert string to Ethernet address
- */
-static int eth_str2addr(struct tipc_media_addr *a, char *str_buf)
-{
-       char mac[ETH_ALEN];
-       int r;
-
-       r = sscanf(str_buf, "%02x:%02x:%02x:%02x:%02x:%02x",
-                      (u32 *)&mac[0], (u32 *)&mac[1], (u32 *)&mac[2],
-                      (u32 *)&mac[3], (u32 *)&mac[4], (u32 *)&mac[5]);
-
-       if (r != ETH_ALEN)
-               return 1;
-
-       eth_media_addr_set(a, mac);
-       return 0;
-}
-
 /**
  * eth_str2addr - convert Ethernet address format to message header format
  */
@@ -351,7 +332,6 @@ static struct tipc_media eth_media_info = {
        .enable_bearer  = enable_bearer,
        .disable_bearer = disable_bearer,
        .addr2str       = eth_addr2str,
-       .str2addr       = eth_str2addr,
        .addr2msg       = eth_addr2msg,
        .msg2addr       = eth_msg2addr,
        .bcast_addr     = { { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff },