On Monday 23 July 2007, llandre wrote:
> The probe function is not invoked because the controller does not allow 
> to reach the max_speed_hz.
> I did not realize this before because, even if the debug messages were 
> enabled, I did not see any warning message about this.

I want to be sure I understand this correctly.  You're saying that
the call to spi_setup() inside of spi_new_device() failed silently?
And thus the scan_boardinfo() failed?

If so, I'm thinking the following patch would help ... right?

--- g26.orig/drivers/spi/spi.c  2007-07-24 06:27:04.000000000 -0700
+++ g26/drivers/spi/spi.c       2007-07-24 06:26:39.000000000 -0700
@@ -325,9 +325,17 @@ static void scan_boardinfo(struct spi_ma
                unsigned                n;
 
                for (n = bi->n_board_info; n > 0; n--, chip++) {
+                       int     status;
+
                        if (chip->bus_num != master->bus_num)
                                continue;
-                       (void) spi_new_device(master, chip);
+                       status = spi_new_device(master, chip);
+                       if (status < 0)
+                               dev_err(master->cdev.dev,
+                                       "can't create spi_device, err %d; "
+                                       "chipselect %d, modalias %s\n",
+                                       status, chip->chip_select,
+                                       chip->modalias);
                }
        }
        mutex_unlock(&board_lock);




-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
spi-devel-general mailing list
spi-devel-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/spi-devel-general

Reply via email to