Re: [ALSA STABLE 3/3] a few more -- unregister platform device again if probe was unsuccessful
- From: Ingo Oeser <ioe-lkml@xxxxxxxxxx>
- Date: Thu, 13 Apr 2006 11:26:34 +0200
Hi Rene,
On Thursday, 13. April 2006 03:46, you wrote:
And finally, unregister on probe failure for sound/drivers,
sound/arm/sa11xx-uda1341.c and sound/ppc/powermac.c.
sound/arm/sa11xx-uda1341.c | 14 +++++++++-----
sound/drivers/dummy.c | 4 ++++
sound/drivers/mpu401/mpu401.c | 4 ++++
sound/drivers/mtpav.c | 14 +++++++++-----
sound/drivers/serial-u16550.c | 4 ++++
sound/drivers/virmidi.c | 4 ++++
sound/ppc/powermac.c | 14 +++++++++-----
7 files changed, 43 insertions(+), 15 deletions(-)
This is inserting lots of duplicate and control heavy code.
It looks like the same pattern and is using just platform_xxx funxtions.
Any counter-examples with a different pattern, which you converted in
a different manner?
Wouldn't it be more useful to do these checks in
platform_register_simple() and return the proper error value there?
Or just create a small helper, if this have to be done seperate.
Greg, what do you think here?
Regards
Ingo Oeser
-
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/
- Follow-Ups:
- References:
- Prev by Date: Re: 2.6.17-rc1 did break XFS
- Next by Date: Re: PROBLEM: pthread-safety bug in write(2) on Linux 2.6.x
- Previous by thread: [ALSA STABLE 3/3] a few more -- unregister platform device again if probe was unsuccessful
- Next by thread: Re: [ALSA STABLE 3/3] a few more -- unregister platform device again if probe was unsuccessful
- Index(es):