aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd/maps/integrator-flash.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mtd/maps/integrator-flash.c')
-rw-r--r--drivers/mtd/maps/integrator-flash.c20
1 files changed, 9 insertions, 11 deletions
diff --git a/drivers/mtd/maps/integrator-flash.c b/drivers/mtd/maps/integrator-flash.c
index d14a0185b8f4..fe738fd8d6f8 100644
--- a/drivers/mtd/maps/integrator-flash.c
+++ b/drivers/mtd/maps/integrator-flash.c
@@ -1,28 +1,28 @@
1/*====================================================================== 1/*======================================================================
2 2
3 drivers/mtd/maps/integrator-flash.c: ARM Integrator flash map driver 3 drivers/mtd/maps/integrator-flash.c: ARM Integrator flash map driver
4 4
5 Copyright (C) 2000 ARM Limited 5 Copyright (C) 2000 ARM Limited
6 Copyright (C) 2003 Deep Blue Solutions Ltd. 6 Copyright (C) 2003 Deep Blue Solutions Ltd.
7 7
8 This program is free software; you can redistribute it and/or modify 8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by 9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2 of the License, or 10 the Free Software Foundation; either version 2 of the License, or
11 (at your option) any later version. 11 (at your option) any later version.
12 12
13 This program is distributed in the hope that it will be useful, 13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of 14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details. 16 GNU General Public License for more details.
17 17
18 You should have received a copy of the GNU General Public License 18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software 19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 20 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 21
22 This is access code for flashes using ARM's flash partitioning 22 This is access code for flashes using ARM's flash partitioning
23 standards. 23 standards.
24 24
25 $Id: integrator-flash.c,v 1.18 2004/11/01 13:26:15 rmk Exp $ 25 $Id: integrator-flash.c,v 1.20 2005/11/07 11:14:27 gleixner Exp $
26 26
27======================================================================*/ 27======================================================================*/
28 28
@@ -148,8 +148,7 @@ static int armflash_probe(struct device *_dev)
148 del_mtd_partitions(info->mtd); 148 del_mtd_partitions(info->mtd);
149 map_destroy(info->mtd); 149 map_destroy(info->mtd);
150 } 150 }
151 if (info->parts) 151 kfree(info->parts);
152 kfree(info->parts);
153 152
154 no_device: 153 no_device:
155 iounmap(base); 154 iounmap(base);
@@ -176,8 +175,7 @@ static int armflash_remove(struct device *_dev)
176 del_mtd_partitions(info->mtd); 175 del_mtd_partitions(info->mtd);
177 map_destroy(info->mtd); 176 map_destroy(info->mtd);
178 } 177 }
179 if (info->parts) 178 kfree(info->parts);
180 kfree(info->parts);
181 179
182 iounmap(info->map.virt); 180 iounmap(info->map.virt);
183 release_resource(info->res); 181 release_resource(info->res);