Skip to contentSkip to conversation

mpc83xx SPI driver never calls its probe function

DISCUSSION Joakim Tjernlund 2 participants 2 messages Nov 2, 2006 – Mar 6, 2009

lore
Share & tools
lore
#0 lore raw

I am trying to get the driver/spi/spi_mpc83xx.c driver going and I am stuck.

I have tried to add spi_board_info and a platform_device:

static struct fsl_spi_platform_data bcm_platform_data = {
.initial_spmode = 0,
.bus_num = 1,
.max_chipselect = 1,
/* board specific information */
.activate_cs = bcm_cs_activate, .deactivate_cs = bcm_cs_deactivate,
.sysclk = 266,
};

static struct spi_board_info spi_board_info[] __initdata = { {
    .modalias    = "bcm5322",
    .platform_data    = &bcm_platform_data,
    .max_speed_hz    = 120000,
    .bus_num    = 1,
    .chip_select    = 0,
},

};

struct platform_device bcm_5322 = {
    .name        = "bcm5322",
    .id        = 1,
    .dev        = {
        .platform_data = &bcm_platform_data,
    },
};

and register that with
platform_device_register(&bcm_5322); spi_register_board_info(spi_board_info, ARRAY_SIZE(spi_board_info))

I also got a protocol driver that does:
static struct spi_driver bcm_driver = {
.driver = {
.name = "bcm5322",
.owner = THIS_MODULE,
},
.probe = bcm_probe,
.remove = __devexit_p(bcm_remove),
};
and then calls spi_register_driver(&bcm_driver);
and I can't get the into the *probe functions. No matter what combination I try,
the *probe functions for both the protocol driver and the spi_mpc83xx driver are
never called.

I need some advice on how to enable my
protocol driver and the spi_mpc83xx driver.

Jocke

#1 lore raw

MC Technology GMBH - Re: mpc83xx SPI driver never calls its probe function

Hello Joakim,
I found your question - but it seems you got never an answer?
I have the same problem too with AT91RM9200 - etwarm_board - Kernel 2.6.18. Please send me an answer or some informations - what ever had you found out.

Steffen Kutsche
MC Technology GmbH, Berlin