]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/net/ppp_mppe.c
forcedeth: fix checksum feature in mcp65
[linux-2.6-omap-h63xx.git] / drivers / net / ppp_mppe.c
index e7a0eb4fca6031bdffd8e279935cadee395f9183..d5bdd25746591a8b0bb47b2dca226b3fbca34fcf 100644 (file)
@@ -200,7 +200,7 @@ static void *mppe_alloc(unsigned char *options, int optlen)
            || options[0] != CI_MPPE || options[1] != CILEN_MPPE)
                goto out;
 
-       state = (struct ppp_mppe_state *) kmalloc(sizeof(*state), GFP_KERNEL);
+       state = kmalloc(sizeof(*state), GFP_KERNEL);
        if (state == NULL)
                goto out;
 
@@ -710,8 +710,8 @@ static struct compressor ppp_mppe = {
 static int __init ppp_mppe_init(void)
 {
        int answer;
-       if (!(crypto_alg_available("ecb(arc4)", 0) &&
-             crypto_alg_available("sha1", 0)))
+       if (!(crypto_has_blkcipher("ecb(arc4)", 0, CRYPTO_ALG_ASYNC) &&
+             crypto_has_hash("sha1", 0, CRYPTO_ALG_ASYNC)))
                return -ENODEV;
 
        sha_pad = kmalloc(sizeof(struct sha_pad), GFP_KERNEL);