Linux Kernel
3.7.1
Main Page
Related Pages
Modules
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Groups
Pages
arch
powerpc
platforms
40x
walnut.c
Go to the documentation of this file.
1
/*
2
* Architecture- / platform-specific boot-time initialization code for
3
* IBM PowerPC 4xx based boards. Adapted from original
4
* code by Gary Thomas, Cort Dougan <
[email protected]
>, and Dan Malek
5
* <
[email protected]
>.
6
*
7
* Copyright(c) 1999-2000 Grant Erickson <
[email protected]
>
8
*
9
* Rewritten and ported to the merged powerpc tree:
10
* Copyright 2007 IBM Corporation
11
* Josh Boyer <
[email protected]
>
12
*
13
* 2002 (c) MontaVista, Software, Inc. This file is licensed under
14
* the terms of the GNU General Public License version 2. This program
15
* is licensed "as is" without any warranty of any kind, whether express
16
* or implied.
17
*/
18
19
#include <
linux/init.h
>
20
#include <
linux/of_platform.h
>
21
#include <linux/rtc.h>
22
23
#include <asm/machdep.h>
24
#include <asm/prom.h>
25
#include <
asm/udbg.h
>
26
#include <asm/time.h>
27
#include <
asm/uic.h
>
28
#include <asm/pci-bridge.h>
29
#include <
asm/ppc4xx.h
>
30
31
static
__initdata
struct
of_device_id
walnut_of_bus[] = {
32
{ .compatible =
"ibm,plb3"
, },
33
{ .compatible =
"ibm,opb"
, },
34
{ .compatible =
"ibm,ebc"
, },
35
{},
36
};
37
38
static
int
__init
walnut_device_probe(
void
)
39
{
40
of_platform_bus_probe(
NULL
, walnut_of_bus,
NULL
);
41
of_instantiate_rtc
();
42
43
return
0;
44
}
45
machine_device_initcall
(walnut, walnut_device_probe);
46
47
static
int
__init
walnut_probe(
void
)
48
{
49
unsigned
long
root
= of_get_flat_dt_root();
50
51
if
(!of_flat_dt_is_compatible(root,
"ibm,walnut"
))
52
return
0;
53
54
pci_set_flags(PCI_REASSIGN_ALL_RSRC);
55
56
return
1;
57
}
58
59
define_machine
(walnut) {
60
.name =
"Walnut"
,
61
.probe = walnut_probe,
62
.progress =
udbg_progress
,
63
.init_IRQ =
uic_init_tree
,
64
.get_irq =
uic_get_irq
,
65
.restart =
ppc4xx_reset_system
,
66
.calibrate_decr =
generic_calibrate_decr
,
67
};
Generated on Thu Jan 10 2013 13:14:37 for Linux Kernel by
1.8.2