The of_register_spi_devices() was not called after registering the spi master.
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): 200809242257.13832.david-b-yBeKhBN/[email protected]
Grant Likely
Acked-byQuoted 2 lines · David Brownell
From: Stefano Babic <[email protected]>
Patch is missing a description of why it is needed. I may understand it, but will the next person?
Quoted 1 line
Signed-off-by Stefano Babic <[email protected]>
Also, some trivial whitespace irregularities in this patch, but otherwise...
Quoted 17 lines
--- drivers/spi/mpc52xx_psc_spi.c | 14 ++++++++++++-- 1 files changed, 12 insertions(+), 2 deletions(-)drivers/spi/mpc52xx_psc_spi.c +1
-0@@ -18,6 +18,7 @@#if defined(CONFIG_PPC_MERGE )#include <linux/of_platform.h> +#include <linux/of_spi.h> #else #include <linux/platform_device.h> #endif
drivers/spi/mpc52xx_psc_spi.c static int __init mpc52xx_psc_spi_do_probe(struct device *dev, u32 regaddr, · line 444
Quoted 6 lines
drivers/spi/mpc52xx_psc_spi.c +2
-1@@ -439,8 +440,10 @@ static int __init mpc52xx_psc_spi_do_probe(struct device *dev, u32 regaddr, } ret =spi_register_master (master); -if (ret <0 ) +if (ret <0 ) { +dev_err (dev,"spi_register_master FAILED\n" );
need space after ','
Quoted 15 lines
drivers/spi/mpc52xx_psc_spi.c +3
-0goto unreg_master; + }return ret;@@ -524,6 +527,8 @@ static int __init mpc52xx_psc_spi_of_probe(struct of_device *op,const u32 *regaddr_p;u64 regaddr64, size64;s16 id =-1 ; +struct spi_master *master; +int ret; regaddr_p =of_get_address (op->node,0 , &size64,NULL );if (!regaddr_p) {
drivers/spi/mpc52xx_psc_spi.c static int __init mpc52xx_psc_spi_of_probe(struct of_device *op, · line 553
Quoted 5 lines
drivers/spi/mpc52xx_psc_spi.c +1
-1@@ -545,8 +550,13 @@ static int __init mpc52xx_psc_spi_of_probe(struct of_device *op, id = *psc_nump +1 ; } - return mpc52xx_psc_spi_do_probe(&op->dev, (u32)regaddr64, (u32)size64, + ret=mpc52xx_psc_spi_do_probe(&op->dev, (u32)regaddr64, (u32)size64,
need space both before and after '='.
drivers/spi/mpc52xx_psc_spi.c static int __init mpc52xx_psc_spi_of_probe(struct of_device *op, · line 556
Quoted 3 lines
drivers/spi/mpc52xx_psc_spi.c +2
-0irq_of_parse_and_map(op->node, 0), id); +if (ret==0 ) { + master=spi_busnum_to_master (id);
Again, need space before and after '=' and '=='
Personally, I'd do this logic the other way around by putting of_register_spi_devices() in the main flow of code and go on an abort path if mpc52xx_psc_spi_do_probe() != 0; but I'm not concerned enough about it to care or withhold my ack.
Quoted 22 lines
drivers/spi/mpc52xx_psc_spi.c +3
-0+of_register_spi_devices (master, op->node); + } +return (ret); } static int __exit mpc52xx_psc_spi_of_remove(struct of_device *op)Signature · 15 lines
1.5.4.3 ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ spi-devel-general mailing list spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org https://lists.sourceforge.net/lists/listinfo/spi-devel-general -------------------------------------------------------
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
A message that is not in the archive (sent off-list or not yet received): 20080925161657.GA15138-s3s/[email protected]
Quoted 6 lines · Grant Likely
Quoted 2 lines · David Brownell
From: Stefano Babic <[email protected]>
Patch is missing a description of why it is needed. I may understand it, but will the next person?
Sorry, I have used another time git-send-email with wrong parameters...and with two different mail addresses,too.
Quoted 1 line
Also, some trivial whitespace irregularities in this patch, but otherwise...
Sorry about that.
Quoted 4 lines
Personally, I'd do this logic the other way around by putting
of_register_spi_devices()in the main flow of code and go on an abort path ifmpc52xx_psc_spi_do_probe()!= 0; but I'm not concerned enough about it to care or withhold my ack.
I agree with you, I do not know why I did this time in this way...I will resubmit the patch with the corrections.
Signature · 11 lines
stefano <[email protected]> GPG Key: 0x55814DDE Fingerprint 4E85 2A66 4CBA 497A 2A7B D3BF 5973 F216 5581 4DDE ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/