system.cc (7064:586b0e3a12b3) system.cc (7723:ee4ac00d0774)
1/*
2 * Copyright (c) 2004-2005 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

--- 63 unchanged lines hidden (view full) ---

72 if (!kernelSymtab->findAddress("swapper_pg_dir", KernelStart)) {
73 panic("Could not determine start location of kernel");
74 }
75
76 /**
77 * Since we aren't using a bootloader, we have to copy the
78 * kernel arguments directly into the kernel's memory.
79 */
1/*
2 * Copyright (c) 2004-2005 The Regents of The University of Michigan
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met: redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer;

--- 63 unchanged lines hidden (view full) ---

72 if (!kernelSymtab->findAddress("swapper_pg_dir", KernelStart)) {
73 panic("Could not determine start location of kernel");
74 }
75
76 /**
77 * Since we aren't using a bootloader, we have to copy the
78 * kernel arguments directly into the kernel's memory.
79 */
80 virtPort.writeBlob(CommandLine(), (uint8_t*)params()->boot_osflags.c_str(),
80 virtPort->writeBlob(CommandLine(), (uint8_t*)params()->boot_osflags.c_str(),
81 params()->boot_osflags.length()+1);
82
83 /**
84 * find the address of the est_cycle_freq variable and insert it
85 * so we don't through the lengthly process of trying to
86 * calculated it by using the PIT, RTC, etc.
87 */
88 if (kernelSymtab->findAddress("est_cycle_freq", addr))
81 params()->boot_osflags.length()+1);
82
83 /**
84 * find the address of the est_cycle_freq variable and insert it
85 * so we don't through the lengthly process of trying to
86 * calculated it by using the PIT, RTC, etc.
87 */
88 if (kernelSymtab->findAddress("est_cycle_freq", addr))
89 virtPort.write(addr, (uint64_t)(SimClock::Frequency /
89 virtPort->write(addr, (uint64_t)(SimClock::Frequency /
90 p->boot_cpu_frequency));
91
92
93 /**
94 * EV5 only supports 127 ASNs so we are going to tell the kernel that the
95 * paritiuclar EV6 we have only supports 127 asns.
96 * @todo At some point we should change ev5.hh and the palcode to support
97 * 255 ASNs.
98 */
99 if (kernelSymtab->findAddress("dp264_mv", addr))
90 p->boot_cpu_frequency));
91
92
93 /**
94 * EV5 only supports 127 ASNs so we are going to tell the kernel that the
95 * paritiuclar EV6 we have only supports 127 asns.
96 * @todo At some point we should change ev5.hh and the palcode to support
97 * 255 ASNs.
98 */
99 if (kernelSymtab->findAddress("dp264_mv", addr))
100 virtPort.write(addr + 0x18, LittleEndianGuest::htog((uint32_t)127));
100 virtPort->write(addr + 0x18, LittleEndianGuest::htog((uint32_t)127));
101 else
102 panic("could not find dp264_mv\n");
103
104#ifndef NDEBUG
105 kernelPanicEvent = addKernelFuncEvent<BreakPCEvent>("panic");
106 if (!kernelPanicEvent)
107 panic("could not find kernel symbol \'panic\'");
108

--- 87 unchanged lines hidden ---
101 else
102 panic("could not find dp264_mv\n");
103
104#ifndef NDEBUG
105 kernelPanicEvent = addKernelFuncEvent<BreakPCEvent>("panic");
106 if (!kernelPanicEvent)
107 panic("could not find kernel symbol \'panic\'");
108

--- 87 unchanged lines hidden ---