]> Pileus Git - ~andy/linux/blobdiff - drivers/staging/sbe-2t3e3/dc.c
Merge branch 'next' of git://git.monstr.eu/linux-2.6-microblaze
[~andy/linux] / drivers / staging / sbe-2t3e3 / dc.c
index daadd6ea4978fffc0c7ee0a3dec3ececbcddbc8a..f207b9e015cec162a10a5a63b72c0bc970e66de2 100644 (file)
@@ -315,20 +315,17 @@ static int dc_init_descriptor_list(struct channel *sc)
        struct sk_buff *m;
 
        if (sc->ether.rx_ring == NULL)
-               sc->ether.rx_ring = kzalloc(SBE_2T3E3_RX_DESC_RING_SIZE *
+               sc->ether.rx_ring = kcalloc(SBE_2T3E3_RX_DESC_RING_SIZE,
                                            sizeof(t3e3_rx_desc_t), GFP_KERNEL);
-       if (sc->ether.rx_ring == NULL) {
-               dev_err(&sc->pdev->dev, "SBE 2T3E3: no buffer space for RX ring\n");
+       if (sc->ether.rx_ring == NULL)
                return -ENOMEM;
-       }
 
        if (sc->ether.tx_ring == NULL)
-               sc->ether.tx_ring = kzalloc(SBE_2T3E3_TX_DESC_RING_SIZE *
+               sc->ether.tx_ring = kcalloc(SBE_2T3E3_TX_DESC_RING_SIZE,
                                            sizeof(t3e3_tx_desc_t), GFP_KERNEL);
        if (sc->ether.tx_ring == NULL) {
                kfree(sc->ether.rx_ring);
                sc->ether.rx_ring = NULL;
-               dev_err(&sc->pdev->dev, "SBE 2T3E3: no buffer space for RX ring\n");
                return -ENOMEM;
        }