diff options
author | Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> | 2011-02-02 01:27:07 -0500 |
---|---|---|
committer | Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> | 2011-05-25 11:04:34 -0400 |
commit | bd60299594fb1d28ae66563c9e76a0b89b0412cf (patch) | |
tree | be57b42058328220a29a03ab68970a3b2a12949d /arch/arm/mach-at91/at91sam9263_devices.c | |
parent | 1b021a3b23a40be89c4f3fbe6f4696aa15141f26 (diff) |
at91: switch to CLKDEV_LOOKUP
we do not change the clock naming convention so does not need to switch
the AVR32 yet
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>
Cc: Patrice Vilchez <patrice.vilchez@atmel.com>
Diffstat (limited to 'arch/arm/mach-at91/at91sam9263_devices.c')
-rw-r--r-- | arch/arm/mach-at91/at91sam9263_devices.c | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/arch/arm/mach-at91/at91sam9263_devices.c b/arch/arm/mach-at91/at91sam9263_devices.c index 47a9f965bbb5..ffe081b77ed0 100644 --- a/arch/arm/mach-at91/at91sam9263_devices.c +++ b/arch/arm/mach-at91/at91sam9263_devices.c | |||
@@ -308,7 +308,6 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) | |||
308 | } | 308 | } |
309 | 309 | ||
310 | mmc0_data = *data; | 310 | mmc0_data = *data; |
311 | at91_clock_associate("mci0_clk", &at91sam9263_mmc0_device.dev, "mci_clk"); | ||
312 | platform_device_register(&at91sam9263_mmc0_device); | 311 | platform_device_register(&at91sam9263_mmc0_device); |
313 | } else { /* MCI1 */ | 312 | } else { /* MCI1 */ |
314 | /* CLK */ | 313 | /* CLK */ |
@@ -339,7 +338,6 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) | |||
339 | } | 338 | } |
340 | 339 | ||
341 | mmc1_data = *data; | 340 | mmc1_data = *data; |
342 | at91_clock_associate("mci1_clk", &at91sam9263_mmc1_device.dev, "mci_clk"); | ||
343 | platform_device_register(&at91sam9263_mmc1_device); | 341 | platform_device_register(&at91sam9263_mmc1_device); |
344 | } | 342 | } |
345 | } | 343 | } |
@@ -686,7 +684,6 @@ void __init at91_add_device_spi(struct spi_board_info *devices, int nr_devices) | |||
686 | at91_set_B_periph(AT91_PIN_PA1, 0); /* SPI0_MOSI */ | 684 | at91_set_B_periph(AT91_PIN_PA1, 0); /* SPI0_MOSI */ |
687 | at91_set_B_periph(AT91_PIN_PA2, 0); /* SPI0_SPCK */ | 685 | at91_set_B_periph(AT91_PIN_PA2, 0); /* SPI0_SPCK */ |
688 | 686 | ||
689 | at91_clock_associate("spi0_clk", &at91sam9263_spi0_device.dev, "spi_clk"); | ||
690 | platform_device_register(&at91sam9263_spi0_device); | 687 | platform_device_register(&at91sam9263_spi0_device); |
691 | } | 688 | } |
692 | if (enable_spi1) { | 689 | if (enable_spi1) { |
@@ -694,7 +691,6 @@ void __init at91_add_device_spi(struct spi_board_info *devices, int nr_devices) | |||
694 | at91_set_A_periph(AT91_PIN_PB13, 0); /* SPI1_MOSI */ | 691 | at91_set_A_periph(AT91_PIN_PB13, 0); /* SPI1_MOSI */ |
695 | at91_set_A_periph(AT91_PIN_PB14, 0); /* SPI1_SPCK */ | 692 | at91_set_A_periph(AT91_PIN_PB14, 0); /* SPI1_SPCK */ |
696 | 693 | ||
697 | at91_clock_associate("spi1_clk", &at91sam9263_spi1_device.dev, "spi_clk"); | ||
698 | platform_device_register(&at91sam9263_spi1_device); | 694 | platform_device_register(&at91sam9263_spi1_device); |
699 | } | 695 | } |
700 | } | 696 | } |
@@ -941,8 +937,6 @@ static struct platform_device at91sam9263_tcb_device = { | |||
941 | 937 | ||
942 | static void __init at91_add_device_tc(void) | 938 | static void __init at91_add_device_tc(void) |
943 | { | 939 | { |
944 | /* this chip has one clock and irq for all three TC channels */ | ||
945 | at91_clock_associate("tcb_clk", &at91sam9263_tcb_device.dev, "t0_clk"); | ||
946 | platform_device_register(&at91sam9263_tcb_device); | 940 | platform_device_register(&at91sam9263_tcb_device); |
947 | } | 941 | } |
948 | #else | 942 | #else |
@@ -1171,12 +1165,10 @@ void __init at91_add_device_ssc(unsigned id, unsigned pins) | |||
1171 | case AT91SAM9263_ID_SSC0: | 1165 | case AT91SAM9263_ID_SSC0: |
1172 | pdev = &at91sam9263_ssc0_device; | 1166 | pdev = &at91sam9263_ssc0_device; |
1173 | configure_ssc0_pins(pins); | 1167 | configure_ssc0_pins(pins); |
1174 | at91_clock_associate("ssc0_clk", &pdev->dev, "pclk"); | ||
1175 | break; | 1168 | break; |
1176 | case AT91SAM9263_ID_SSC1: | 1169 | case AT91SAM9263_ID_SSC1: |
1177 | pdev = &at91sam9263_ssc1_device; | 1170 | pdev = &at91sam9263_ssc1_device; |
1178 | configure_ssc1_pins(pins); | 1171 | configure_ssc1_pins(pins); |
1179 | at91_clock_associate("ssc1_clk", &pdev->dev, "pclk"); | ||
1180 | break; | 1172 | break; |
1181 | default: | 1173 | default: |
1182 | return; | 1174 | return; |
@@ -1376,22 +1368,18 @@ void __init at91_register_uart(unsigned id, unsigned portnr, unsigned pins) | |||
1376 | case 0: /* DBGU */ | 1368 | case 0: /* DBGU */ |
1377 | pdev = &at91sam9263_dbgu_device; | 1369 | pdev = &at91sam9263_dbgu_device; |
1378 | configure_dbgu_pins(); | 1370 | configure_dbgu_pins(); |
1379 | at91_clock_associate("mck", &pdev->dev, "usart"); | ||
1380 | break; | 1371 | break; |
1381 | case AT91SAM9263_ID_US0: | 1372 | case AT91SAM9263_ID_US0: |
1382 | pdev = &at91sam9263_uart0_device; | 1373 | pdev = &at91sam9263_uart0_device; |
1383 | configure_usart0_pins(pins); | 1374 | configure_usart0_pins(pins); |
1384 | at91_clock_associate("usart0_clk", &pdev->dev, "usart"); | ||
1385 | break; | 1375 | break; |
1386 | case AT91SAM9263_ID_US1: | 1376 | case AT91SAM9263_ID_US1: |
1387 | pdev = &at91sam9263_uart1_device; | 1377 | pdev = &at91sam9263_uart1_device; |
1388 | configure_usart1_pins(pins); | 1378 | configure_usart1_pins(pins); |
1389 | at91_clock_associate("usart1_clk", &pdev->dev, "usart"); | ||
1390 | break; | 1379 | break; |
1391 | case AT91SAM9263_ID_US2: | 1380 | case AT91SAM9263_ID_US2: |
1392 | pdev = &at91sam9263_uart2_device; | 1381 | pdev = &at91sam9263_uart2_device; |
1393 | configure_usart2_pins(pins); | 1382 | configure_usart2_pins(pins); |
1394 | at91_clock_associate("usart2_clk", &pdev->dev, "usart"); | ||
1395 | break; | 1383 | break; |
1396 | default: | 1384 | default: |
1397 | return; | 1385 | return; |
@@ -1405,8 +1393,10 @@ void __init at91_register_uart(unsigned id, unsigned portnr, unsigned pins) | |||
1405 | 1393 | ||
1406 | void __init at91_set_serial_console(unsigned portnr) | 1394 | void __init at91_set_serial_console(unsigned portnr) |
1407 | { | 1395 | { |
1408 | if (portnr < ATMEL_MAX_UART) | 1396 | if (portnr < ATMEL_MAX_UART) { |
1409 | atmel_default_console_device = at91_uarts[portnr]; | 1397 | atmel_default_console_device = at91_uarts[portnr]; |
1398 | at91sam9263_set_console_clock(portnr); | ||
1399 | } | ||
1410 | } | 1400 | } |
1411 | 1401 | ||
1412 | void __init at91_add_device_serial(void) | 1402 | void __init at91_add_device_serial(void) |