if (impd1) kfree(impd1); 
kfree(impd1); 
static int impd1_probe(struct lm_device *dev){	struct impd1_module *impd1;	int i, ret;	if (dev->id != module_id)		return -EINVAL;	if (!request_mem_region(dev->resource.start, SZ_4K, "LM registers"))		return -EBUSY;	impd1 = kmalloc(sizeof(struct impd1_module), GFP_KERNEL);	if (!impd1) {		ret = -ENOMEM;		goto release_lm;	}	memset(impd1, 0, sizeof(struct impd1_module));	impd1->base = ioremap(dev->resource.start, SZ_4K);	if (!impd1->base) {		ret = -ENOMEM;		goto free_impd1;	}	lm_set_drvdata(dev, impd1);	printk("IM-PD1 found at 0x%08lx\n", dev->resource.start);	for (i = 0; i < ARRAY_SIZE(impd1->vcos); i++) {		impd1->vcos[i].owner = THIS_MODULE,		impd1->vcos[i].name = impd1_vconames[i],		impd1->vcos[i].params = &impd1_vco_params,		impd1->vcos[i].data = impd1,		impd1->vcos[i].setvco = impd1_setvco;		clk_register(&impd1->vcos[i]);	}	for (i = 0; i < ARRAY_SIZE(impd1_devs); i++) {		struct impd1_device *idev = impd1_devs + i;		struct amba_device *d;		unsigned long pc_base;		pc_base = dev->resource.start + idev->offset;		d = kmalloc(sizeof(struct amba_device), GFP_KERNEL);		if (!d)			continue;		memset(d, 0, sizeof(struct amba_device));		snprintf(d->dev.bus_id, sizeof(d->dev.bus_id),			 "lm%x:%5.5lx", dev->id, idev->offset >> 12);		d->dev.parent	= &dev->dev;		d->res.start	= dev->resource.start + idev->offset;		d->res.end	= d->res.start + SZ_4K - 1;		d->res.flags	= IORESOURCE_MEM;		d->irq[0]	= dev->irq;		d->irq[1]	= dev->irq;		d->periphid	= idev->id;		d->dev.platform_data = idev->platform_data;		ret = amba_device_register(d, &dev->resource);		if (ret) {			printk("unable to register device %s: %d\n",				d->dev.bus_id, ret);			kfree(d);		}	}	return 0; free_impd1:	if (impd1 && impd1->base)		iounmap(impd1->base);	if (impd1)		kfree(impd1); release_lm:	release_mem_region(dev->resource.start, SZ_4K);	return ret;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/b2325fe1b7e5654fac9e9419423aa2c58a3dbd83/impd1.c/buggy/arch/arm/mach-integrator/impd1.c