diff options
author | Marc Zyngier <maz@misterjones.org> | 2010-03-29 04:57:56 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-03-31 02:51:09 -0400 |
commit | e446630c960946b5c1762e4eadb618becef599e7 (patch) | |
tree | 7dc73fc57fd1d38f309b208b6dadfddf248cb05f /arch/arm/mach-pxa/zeus.c | |
parent | 598ed9367a36ee1fd4ae3271a54a3547a33975a5 (diff) |
Add hotplug support to mcp251x driver
Chip model can now be selected directly by matching the modalias name
(instead of filling the .model field in platform_data), and allows the
module to be auto-loaded. Previous behaviour is of course still supported.
Convert the two in-tree users to this feature (icontrol & zeus).
Tested on an Zeus platform (mcp2515).
Signed-off-by: Marc Zyngier <maz@misterjones.org>
Acked-by: Christian Pellegrin <chripell@fsfe.org>
Cc: Edwin Peer <epeer@tmtservices.co.za>
Acked-by: Wolfgang Grandegger <wg@grandegger.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/arm/mach-pxa/zeus.c')
-rw-r--r-- | arch/arm/mach-pxa/zeus.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/arm/mach-pxa/zeus.c b/arch/arm/mach-pxa/zeus.c index 39896d883584..dbd256966379 100644 --- a/arch/arm/mach-pxa/zeus.c +++ b/arch/arm/mach-pxa/zeus.c | |||
@@ -414,15 +414,13 @@ static int zeus_mcp2515_transceiver_enable(int enable) | |||
414 | 414 | ||
415 | static struct mcp251x_platform_data zeus_mcp2515_pdata = { | 415 | static struct mcp251x_platform_data zeus_mcp2515_pdata = { |
416 | .oscillator_frequency = 16*1000*1000, | 416 | .oscillator_frequency = 16*1000*1000, |
417 | .model = CAN_MCP251X_MCP2515, | ||
418 | .board_specific_setup = zeus_mcp2515_setup, | 417 | .board_specific_setup = zeus_mcp2515_setup, |
419 | .transceiver_enable = zeus_mcp2515_transceiver_enable, | ||
420 | .power_enable = zeus_mcp2515_transceiver_enable, | 418 | .power_enable = zeus_mcp2515_transceiver_enable, |
421 | }; | 419 | }; |
422 | 420 | ||
423 | static struct spi_board_info zeus_spi_board_info[] = { | 421 | static struct spi_board_info zeus_spi_board_info[] = { |
424 | [0] = { | 422 | [0] = { |
425 | .modalias = "mcp251x", | 423 | .modalias = "mcp2515", |
426 | .platform_data = &zeus_mcp2515_pdata, | 424 | .platform_data = &zeus_mcp2515_pdata, |
427 | .irq = gpio_to_irq(ZEUS_CAN_GPIO), | 425 | .irq = gpio_to_irq(ZEUS_CAN_GPIO), |
428 | .max_speed_hz = 1*1000*1000, | 426 | .max_speed_hz = 1*1000*1000, |