Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

atm: iphase: fix a 64 bit bug

The code assumes that there is 4 bytes in a pointer and it doesn't
allocate enough memory.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Dan Carpenter and committed by
David S. Miller
92291c95 c860e997

+1 -1
+1 -1
drivers/atm/iphase.c
··· 1618 1618 skb_queue_head_init(&iadev->rx_dma_q); 1619 1619 iadev->rx_free_desc_qhead = NULL; 1620 1620 1621 - iadev->rx_open = kcalloc(4, iadev->num_vc, GFP_KERNEL); 1621 + iadev->rx_open = kcalloc(iadev->num_vc, sizeof(void *), GFP_KERNEL); 1622 1622 if (!iadev->rx_open) { 1623 1623 printk(KERN_ERR DEV_LABEL "itf %d couldn't get free page\n", 1624 1624 dev->number);