diff options
author | Ashwin <ashwin.bhat@broadcom.com> | 2014-09-17 15:49:57 -0700 |
---|---|---|
committer | Dmitry Shmidt <dimitrysh@google.com> | 2014-12-03 13:55:07 -0800 |
commit | 1a98081b29afa74fb3af0699a2c2f0100257f3d5 (patch) | |
tree | bb6d69bc3594bf0b904e228f3c21c04c8c754661 /bcmdhd/dhdutil | |
parent | 7e51d96ef515696224fc7f6d8063d20e8f68a33d (diff) | |
download | hardware_broadcom_wlan-1a98081b29afa74fb3af0699a2c2f0100257f3d5.zip hardware_broadcom_wlan-1a98081b29afa74fb3af0699a2c2f0100257f3d5.tar.gz hardware_broadcom_wlan-1a98081b29afa74fb3af0699a2c2f0100257f3d5.tar.bz2 |
dhdutil: Fix issue with dhd_upload which causes kernel panic
Bug: 18608773
Change-Id: I6cc6a8a36c5ba386171bd7285d4d4729f44ad9e1
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Diffstat (limited to 'bcmdhd/dhdutil')
-rw-r--r-- | bcmdhd/dhdutil/dhdu.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bcmdhd/dhdutil/dhdu.c b/bcmdhd/dhdutil/dhdu.c index 6b2007c..2c628c2 100644 --- a/bcmdhd/dhdutil/dhdu.c +++ b/bcmdhd/dhdutil/dhdu.c @@ -2154,7 +2154,7 @@ dhd_upload(void *dhd, cmd_t *cmd, char **argv) ramsize = *(uint32*)buf; if (!ramsize) - ramsize = start + size; + ramsize = size; if ((fp = fopen(fname, "wb")) == NULL) { fprintf(stderr, "%s: Could not open %s: %s\n", @@ -2165,7 +2165,7 @@ dhd_upload(void *dhd, cmd_t *cmd, char **argv) /* default size to full RAM */ if (!size) - size = ramsize - start; + size = ramsize; /* read memory and write to file */ while (size) { |