Re: [03/12] driver core fixes: fixup platform_device_register_simple()

From: Dmitry Torokhov
Date: Wed Sep 13 2006 - 22:31:30 EST


Hi,

On Wednesday 13 September 2006 12:38, Cornelia Huck wrote:
> From: Cornelia Huck <cornelia.huck@xxxxxxxxxx>
>
> Remember to remove allocated resources if platform_device_add() fails.
> Introduce a helper function platform_device_del_resources() for this,
> which can also be used by platform_device_del().
>

platform_device_add() already releases all resources in case of failure.
Memory allocated for resource structures is released by
platform_device_release(). I do not think this patch is needed.

As fas as platform_device_register_somple() goes it should just die and
users should be converted to platofrm_device_alloc/add.

--
Dmitry
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/