aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPawit Pornkitprasan <p.pawit@gmail.com>2012-07-16 00:35:47 +0700
committerPawit Pornkitprasan <p.pawit@gmail.com>2012-07-16 00:35:50 +0700
commit54d09f24d823eb43d58b66a5fd8c5105192877bb (patch)
treede26f084cdb94f88f0a6bbb808848b747b2b5488
parentf385c89f3b03e9ee69dd45b185bc790dc23e191c (diff)
downloadkernel_samsung_aries-54d09f24d823eb43d58b66a5fd8c5105192877bb.zip
kernel_samsung_aries-54d09f24d823eb43d58b66a5fd8c5105192877bb.tar.gz
kernel_samsung_aries-54d09f24d823eb43d58b66a5fd8c5105192877bb.tar.bz2
samsung_modemctl: fix crash on gcc 4.6
In gcc 4.3, when one declares an array with size 0, one block of memory is assigned making the code work. This is no longer the case with gcc 4.6. Change-Id: Ie4d04d4b55c768af6c088f4a1bd4fa294c2b5981
-rw-r--r--drivers/misc/samsung_modemctl/svnet/sipc4.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/samsung_modemctl/svnet/sipc4.c b/drivers/misc/samsung_modemctl/svnet/sipc4.c
index becf032..899bd69 100644
--- a/drivers/misc/samsung_modemctl/svnet/sipc4.c
+++ b/drivers/misc/samsung_modemctl/svnet/sipc4.c
@@ -211,7 +211,7 @@ extern unsigned int HWREV;
static DEFINE_MUTEX(pdp_mutex);
static struct net_device *pdp_devs[PDP_MAX];
static int pdp_cnt;
-unsigned long pdp_bitmap[PDP_MAX/BITS_PER_LONG];
+unsigned long pdp_bitmap[DIV_ROUND_UP(PDP_MAX, BITS_PER_LONG)];
static void clear_pdp_wq(struct work_struct *work);
static DECLARE_WORK(pdp_work, clear_pdp_wq);