Changeset 2057572 in mainline for kernel/arch/sparc64/include/mm
- Timestamp:
- 2007-03-27T23:40:25Z (18 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 399ece9
- Parents:
- 8d37a06
- Location:
- kernel/arch/sparc64/include/mm
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/arch/sparc64/include/mm/as.h
r8d37a06 r2057572 82 82 83 83 #ifdef CONFIG_TSB 84 # include <arch/mm/tsb.h> 85 # define as_invalidate_translation_cache(as, page, cnt) tsb_invalidate(as, page, cnt) 84 #include <arch/mm/tsb.h> 85 #define as_invalidate_translation_cache(as, page, cnt) \ 86 tsb_invalidate((as), (page), (cnt)) 86 87 #else 87 # 88 #define as_invalidate_translation_cache(as, page, cnt) 88 89 #endif 89 90 -
kernel/arch/sparc64/include/mm/cache.h
r8d37a06 r2057572 44 44 dcache_flush_tag(PAGE_COLOR((p)), ADDR2PFN((f))); 45 45 46 /**47 * Enumerations to differentiate among different scopes of D-Cache48 * invalidation.49 */50 typedef enum {51 DCACHE_INVL_INVALID,52 DCACHE_INVL_ALL,53 DCACHE_INVL_COLOR,54 DCACHE_INVL_FRAME55 } dcache_invalidate_type_t;56 57 /**58 * Number of messages that can be queued in the cpu_arch_t structure at a time.59 */60 #define DCACHE_MSG_QUEUE_LEN 1061 62 /** D-cache shootdown message type. */63 typedef struct {64 dcache_invalidate_type_t type;65 int color;66 uintptr_t frame;67 } dcache_shootdown_msg_t;68 69 46 extern void dcache_flush(void); 70 47 extern void dcache_flush_color(int c); 71 48 extern void dcache_flush_tag(int c, pfn_t tag); 72 73 #ifdef CONFIG_SMP74 extern void dcache_shootdown_start(dcache_invalidate_type_t type, int color,75 uintptr_t frame);76 extern void dcache_shootdown_finalize(void);77 extern void dcache_shootdown_ipi_recv(void);78 #else79 #define dcache_shootdown_start(t, c, f)80 #define dcache_shootdown_finalize()81 #define dcache_shootdown_ipi_recv()82 #endif /* CONFIG_SMP */83 49 84 50 #endif -
kernel/arch/sparc64/include/mm/frame.h
r8d37a06 r2057572 36 36 #define KERN_sparc64_FRAME_H_ 37 37 38 #define FRAME_WIDTH 13 /* 8K */ 38 /* 39 * Page size supported by the MMU. 40 * For 8K there is the nasty illegal virtual aliasing problem. 41 * Therefore, the kernel uses 8K only internally on the TLB and TSB levels. 42 */ 43 #define MMU_FRAME_WIDTH 13 /* 8K */ 44 #define MMU_FRAME_SIZE (1 << MMU_FRAME_WIDTH) 45 46 /* 47 * Page size exported to the generic memory management subsystems. 48 * This page size is not directly supported by the MMU, but we can emulate 49 * each 16K page with a pair of adjacent 8K pages. 50 */ 51 #define FRAME_WIDTH 14 /* 16K */ 39 52 #define FRAME_SIZE (1 << FRAME_WIDTH) 40 53 -
kernel/arch/sparc64/include/mm/page.h
r8d37a06 r2057572 38 38 #include <arch/mm/frame.h> 39 39 40 /* 41 * On the TLB and TSB level, we still use 8K pages, which are supported by the 42 * MMU. 43 */ 44 #define MMU_PAGE_WIDTH MMU_FRAME_WIDTH 45 #define MMU_PAGE_SIZE MMU_FRAME_SIZE 46 47 /* 48 * On the page table level, we use 16K pages. 16K pages are not supported by 49 * the MMU but we emulate them with pairs of 8K pages. 50 */ 40 51 #define PAGE_WIDTH FRAME_WIDTH 41 52 #define PAGE_SIZE FRAME_SIZE 42 53 43 #define PAGE_COLOR_BITS 1 /**< 14 - 13; 2^14 == 16K == alias boundary. */ 54 #define MMU_PAGES_PER_PAGE (1 << (PAGE_WIDTH - MMU_PAGE_WIDTH)) 55 56 /* 57 * With 16K pages, there is only one page color. 58 */ 59 #define PAGE_COLOR_BITS 0 /**< 14 - 14; 2^14 == 16K == alias boundary. */ 44 60 45 61 #ifdef KERNEL -
kernel/arch/sparc64/include/mm/tsb.h
r8d37a06 r2057572 113 113 114 114 extern void tsb_invalidate(struct as *as, uintptr_t page, count_t pages); 115 extern void itsb_pte_copy(struct pte *t );116 extern void dtsb_pte_copy(struct pte *t, bool ro);115 extern void itsb_pte_copy(struct pte *t, index_t index); 116 extern void dtsb_pte_copy(struct pte *t, index_t index, bool ro); 117 117 118 118 #endif /* !def __ASM__ */
Note:
See TracChangeset
for help on using the changeset viewer.