aboutsummaryrefslogtreecommitdiff
path: root/drivers/ide/mips
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2008-09-27 19:32:16 +0200
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-09-27 19:32:16 +0200
commit3d977760b9478538821a75dd5eb74d0f2a2b01e3 (patch)
treec09535aa83b4f7b617b59f7d4b83fabbf78c502a /drivers/ide/mips
parent6ef190cc92e33565accff6a320f0e7d90480bfe7 (diff)
Swarm: Fix crash due to missing initialization
If things are just right this will result in the hws[0]->parent being passed to ide_host_add() being non-zero and an ooops a little later. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/mips')
-rw-r--r--drivers/ide/mips/swarm.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/ide/mips/swarm.c b/drivers/ide/mips/swarm.c
index badf79fc9e3..39c9ee99585 100644
--- a/drivers/ide/mips/swarm.c
+++ b/drivers/ide/mips/swarm.c
@@ -107,6 +107,7 @@ static int __devinit swarm_ide_probe(struct device *dev)
base = ioremap(offset, size);
+ memset(&hw, 0, sizeof(hw));
for (i = 0; i <= 7; i++)
hw.io_ports_array[i] =
(unsigned long)(base + ((0x1f0 + i) << 5));