OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [linux/] [linux-2.4/] [arch/] [ia64/] [kernel/] [machvec.c] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1275 phoenix
#include <linux/config.h>
2
 
3
#ifdef CONFIG_IA64_GENERIC
4
 
5
#include <linux/kernel.h>
6
#include <linux/string.h>
7
 
8
#include <asm/page.h>
9
#include <asm/machvec.h>
10
 
11
struct ia64_machine_vector ia64_mv;
12
 
13
/*
14
 * Most platforms use this routine for mapping page frame addresses
15
 * into a memory map index.
16
 */
17
unsigned long
18
map_nr_dense (void *addr)
19
{
20
        return MAP_NR_DENSE(addr);
21
}
22
 
23
static struct ia64_machine_vector *
24
lookup_machvec (const char *name)
25
{
26
        extern struct ia64_machine_vector machvec_start[];
27
        extern struct ia64_machine_vector machvec_end[];
28
        struct ia64_machine_vector *mv;
29
 
30
        for (mv = machvec_start; mv < machvec_end; ++mv)
31
                if (strcmp (mv->name, name) == 0)
32
                        return mv;
33
 
34
        return 0;
35
}
36
 
37
void
38
machvec_init (const char *name)
39
{
40
        struct ia64_machine_vector *mv;
41
 
42
        mv = lookup_machvec(name);
43
        if (!mv) {
44
                panic("generic kernel failed to find machine vector for platform %s!", name);
45
        }
46
        ia64_mv = *mv;
47
        printk(KERN_INFO "booting generic kernel on platform %s\n", name);
48
}
49
 
50
#endif /* CONFIG_IA64_GENERIC */
51
 
52
void
53
machvec_noop (void)
54
{
55
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.