setup.c (82ffd0454bd9bd57780966d47bfd56d579dd4fb3) | setup.c (68005b67d15a1ee5b5ddff965175728e65fa73e7) |
---|---|
1/* 2 * Copyright (C) 2006-2007 PA Semi, Inc 3 * 4 * Authors: Kip Walker, PA Semi 5 * Olof Johansson, PA Semi 6 * 7 * Maintained by: Olof Johansson <olof@lixom.net> 8 * --- 397 unchanged lines hidden (view full) --- 406 } 407 } 408 409out: 410 /* SRR1[62] is from MSR[62] if recoverable, so pass that back */ 411 return !!(srr1 & 0x2); 412} 413 | 1/* 2 * Copyright (C) 2006-2007 PA Semi, Inc 3 * 4 * Authors: Kip Walker, PA Semi 5 * Olof Johansson, PA Semi 6 * 7 * Maintained by: Olof Johansson <olof@lixom.net> 8 * --- 397 unchanged lines hidden (view full) --- 406 } 407 } 408 409out: 410 /* SRR1[62] is from MSR[62] if recoverable, so pass that back */ 411 return !!(srr1 & 0x2); 412} 413 |
414#ifdef CONFIG_PCMCIA 415static int pcmcia_notify(struct notifier_block *nb, unsigned long action, 416 void *data) 417{ 418 struct device *dev = data; 419 struct device *parent; 420 struct pcmcia_device *pdev = to_pcmcia_dev(dev); 421 422 /* We are only intereted in device addition */ 423 if (action != BUS_NOTIFY_ADD_DEVICE) 424 return 0; 425 426 parent = pdev->socket->dev.parent; 427 428 /* We know electra_cf devices will always have of_node set, since 429 * electra_cf is an of_platform driver. 430 */ 431 if (!parent->of_node) 432 return 0; 433 434 if (!of_device_is_compatible(parent->of_node, "electra-cf")) 435 return 0; 436 437 /* We use the direct ops for localbus */ 438 dev->dma_ops = &dma_nommu_ops; 439 440 return 0; 441} 442 443static struct notifier_block pcmcia_notifier = { 444 .notifier_call = pcmcia_notify, 445}; 446 447static inline void pasemi_pcmcia_init(void) 448{ 449 extern struct bus_type pcmcia_bus_type; 450 451 bus_register_notifier(&pcmcia_bus_type, &pcmcia_notifier); 452} 453 454#else 455 456static inline void pasemi_pcmcia_init(void) 457{ 458} 459 460#endif 461 462 | |
463static const struct of_device_id pasemi_bus_ids[] = { 464 /* Unfortunately needed for legacy firmwares */ 465 { .type = "localbus", }, 466 { .type = "sdc", }, 467 /* These are the proper entries, which newer firmware uses */ 468 { .compatible = "pasemi,localbus", }, 469 { .compatible = "pasemi,sdc", }, 470 {}, 471}; 472 473static int __init pasemi_publish_devices(void) 474{ | 414static const struct of_device_id pasemi_bus_ids[] = { 415 /* Unfortunately needed for legacy firmwares */ 416 { .type = "localbus", }, 417 { .type = "sdc", }, 418 /* These are the proper entries, which newer firmware uses */ 419 { .compatible = "pasemi,localbus", }, 420 { .compatible = "pasemi,sdc", }, 421 {}, 422}; 423 424static int __init pasemi_publish_devices(void) 425{ |
475 pasemi_pcmcia_init(); 476 | |
477 /* Publish OF platform devices for SDC and other non-PCI devices */ 478 of_platform_bus_probe(NULL, pasemi_bus_ids, NULL); 479 480 nemo_init_rtc(); 481 482 return 0; 483} 484machine_device_initcall(pasemi, pasemi_publish_devices); --- 39 unchanged lines hidden --- | 426 /* Publish OF platform devices for SDC and other non-PCI devices */ 427 of_platform_bus_probe(NULL, pasemi_bus_ids, NULL); 428 429 nemo_init_rtc(); 430 431 return 0; 432} 433machine_device_initcall(pasemi, pasemi_publish_devices); --- 39 unchanged lines hidden --- |