caif: Use link layer MTU instead of fixed MTU
[cascardo/linux.git] / net / caif / cfctrl.c
index 107c4b2..563145f 100644 (file)
@@ -19,7 +19,7 @@
 #ifdef CAIF_NO_LOOP
 static int handle_loop(struct cfctrl *ctrl,
                              int cmd, struct cfpkt *pkt){
-       return CAIF_FAILURE;
+       return -1;
 }
 #else
 static int handle_loop(struct cfctrl *ctrl,
@@ -395,7 +395,7 @@ static int cfctrl_recv(struct cflayer *layer, struct cfpkt *pkt)
        cmd = cmdrsp & CFCTRL_CMD_MASK;
        if (cmd != CFCTRL_CMD_LINK_ERR
            && CFCTRL_RSP_BIT != (CFCTRL_RSP_BIT & cmdrsp)) {
-               if (handle_loop(cfctrl, cmd, pkt) == CAIF_FAILURE)
+               if (handle_loop(cfctrl, cmd, pkt) != 0)
                        cmdrsp |= CFCTRL_ERR_BIT;
        }
 
@@ -647,6 +647,6 @@ found:
        default:
                break;
        }
-       return CAIF_SUCCESS;
+       return 0;
 }
 #endif