lkml.org 
[lkml]   [2006]   [Nov]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] spi: check platform_device_register_simple() error
Date
On Sunday 26 November 2006 9:09 pm, Akinobu Mita wrote:
> This patch checks the return value of platform_device_register_simple().
>
> Cc: David Brownell <dbrownell@users.sourceforge.net>
> Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>

Acked-by: David Brownell <dbrownell@users.sourceforge.net>

... thanks, good catch.


>
> ---
> drivers/spi/spi_butterfly.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> Index: work-fault-inject/drivers/spi/spi_butterfly.c
> ===================================================================
> --- work-fault-inject.orig/drivers/spi/spi_butterfly.c
> +++ work-fault-inject/drivers/spi/spi_butterfly.c
> @@ -250,6 +250,8 @@ static void butterfly_attach(struct parp
> * setting up a platform device like this is an ugly kluge...
> */
> pdev = platform_device_register_simple("butterfly", -1, NULL, 0);
> + if (IS_ERR(pdev))
> + return;
>
> master = spi_alloc_master(&pdev->dev, sizeof *pp);
> if (!master) {
>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-11-27 20:21    [W:3.115 / U:0.004 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site