Rev 3940 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3940 | Rev 3973 | ||
---|---|---|---|
Line 24... | Line 24... | ||
24 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
24 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
25 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
25 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
26 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
27 | */ |
27 | */ |
28 | 28 | ||
29 | /** @addtogroup ppc32mm |
29 | /** @addtogroup ppc32mm |
30 | * @{ |
30 | * @{ |
31 | */ |
31 | */ |
32 | /** @file |
32 | /** @file |
33 | */ |
33 | */ |
34 | 34 | ||
35 | #include <genarch/mm/page_pt.h> |
35 | #include <genarch/mm/page_pt.h> |
36 | #include <mm/frame.h> |
36 | #include <mm/frame.h> |
37 | #include <mm/as.h> |
37 | #include <mm/as.h> |
38 | #include <align.h> |
38 | #include <align.h> |
39 | #include <config.h> |
39 | #include <config.h> |
40 | #include <ddi/ddi.h> |
- | |
41 | - | ||
42 | /** Physical memory area for devices. */ |
- | |
43 | static parea_t dev_area; |
- | |
44 | 40 | ||
45 | void page_arch_init(void) |
41 | void page_arch_init(void) |
46 | { |
42 | { |
47 | if (config.cpu_active == 1) |
43 | if (config.cpu_active == 1) |
48 | page_mapping_operations = &pt_mapping_operations; |
44 | page_mapping_operations = &pt_mapping_operations; |
Line 65... | Line 61... | ||
65 | last_frame = ALIGN_UP(last_frame + size, FRAME_SIZE); |
61 | last_frame = ALIGN_UP(last_frame + size, FRAME_SIZE); |
66 | 62 | ||
67 | return virtaddr; |
63 | return virtaddr; |
68 | } |
64 | } |
69 | 65 | ||
70 | void hw_area(void) |
- | |
71 | { |
- | |
72 | dev_area.pbase = end_frame; |
- | |
73 | dev_area.frames = SIZE2FRAMES(0xffffffff - end_frame); |
- | |
74 | ddi_parea_register(&dev_area); |
- | |
75 | } |
- | |
76 | - | ||
77 | /** @} |
66 | /** @} |
78 | */ |
67 | */ |