xtensa-cvscommit Mailing List for xtensa (Page 5)
Brought to you by:
zankel
You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(18) |
Oct
(30) |
Nov
(18) |
Dec
(12) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(24) |
Feb
(38) |
Mar
(28) |
Apr
(27) |
May
(17) |
Jun
(6) |
Jul
(12) |
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
| 2004 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <jn...@us...> - 2003-02-28 01:53:27
|
Update of /cvsroot/xtensa/linux/include/asm-xtensa
In directory sc8-pr-cvs1:/tmp/cvs-serv6560/include/asm-xtensa
Modified Files:
assume.h page.h pgalloc.h pgtable.h shmparam.h
Log Message:
Added support for caches that have "ways" larger than PAGE_SIZE.
This was mostly copied from the sh-4 port which suffers from the
same feature. There are still some optimizations that can be done
with regard to defering some cache flusing, and reducing some complete
cache flushes to flushes of the appropriate cache lines.
When the cache way size is less than or equal to PAGE_SIZE, all
of these changes should be optimized away, and the port should run
exactly as it did prior to these changes.
Index: assume.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/assume.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** assume.h 15 Feb 2003 02:02:40 -0000 1.3
--- assume.h 28 Feb 2003 01:53:10 -0000 1.4
***************
*** 49,52 ****
--- 49,56 ----
#endif
+ /* 20feb2003 -- jn
+ * cache aliasing is now being supported, have fear.
+ */
+ #if 0
#if XCHAL_ICACHE_SIZE > (XCHAL_ICACHE_WAYS * PAGE_SIZE)
#error Cache aliasing not supported.
***************
*** 55,58 ****
--- 59,63 ----
#if XCHAL_DCACHE_SIZE > (XCHAL_DCACHE_WAYS * PAGE_SIZE)
#error Cache aliasing not supported.
+ #endif
#endif
Index: page.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/page.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** page.h 15 Feb 2003 02:02:40 -0000 1.3
--- page.h 28 Feb 2003 01:53:10 -0000 1.4
***************
*** 19,22 ****
--- 19,23 ----
#include <xtensa/config/core.h>
+ #include <asm/xtutil.h>
/* PAGE_SHIFT determines the page size */
***************
*** 25,30 ****
--- 26,40 ----
#define PAGE_MASK (~(PAGE_SIZE-1))
+
+
#ifdef __KERNEL__
+ #define XCDCACHE_WAY_SIZE (XCHAL_DCACHE_SIZE / XCHAL_DCACHE_WAYS)
+ #if ( XCDCACHE_WAY_SIZE > PAGE_SIZE)
+ #define XTENSA_CACHE_ALIAS 1
+ #else
+ #define XTENSA_CACHE_ALIAS 0
+ #endif
+
#ifndef _LANGUAGE_ASSEMBLY
***************
*** 38,43 ****
#define clear_page(page) clear_page_asm (page)
#define copy_page(to, from) copy_page_asm (to, from)
! #define clear_user_page(page, vaddr) clear_page(page)
! #define copy_user_page(to, from, vaddr) copy_page(to, from)
/*
--- 48,65 ----
#define clear_page(page) clear_page_asm (page)
#define copy_page(to, from) copy_page_asm (to, from)
!
!
! /* 19feb2003 --jn
! * Some Xtensa's can have cache alias problems, for those we have to
! * use the magical copy and clear user page functions.
! */
!
! #if XTENSA_CACHE_ALIAS
! extern void clear_user_page(void *to, unsigned long addr);
! extern void copy_user_page(void *to, void *from, unsigned long addr);
! #else
! #define clear_user_page(page, vaddr) clear_page(page)
! #define copy_user_page(to, from, vaddr) copy_page(to, from)
! #endif
/*
Index: pgalloc.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/pgalloc.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** pgalloc.h 15 Feb 2003 02:02:40 -0000 1.2
--- pgalloc.h 28 Feb 2003 01:53:10 -0000 1.3
***************
*** 17,20 ****
--- 17,21 ----
#include <linux/config.h>
+ #include <linux/mm.h>
/* TLB flushing:
***************
*** 210,213 ****
--- 211,271 ----
#endif
}
+
+
+ static inline int ptep_test_and_clear_young(pte_t *ptep)
+ {
+ pte_t pte = *ptep;
+ if (!pte_young(pte))
+ return 0;
+ set_pte(ptep, pte_mkold(pte));
+ return 1;
+ }
+
+ static inline int ptep_test_and_clear_dirty(pte_t *ptep)
+ {
+ pte_t pte = *ptep;
+ if (!pte_dirty(pte))
+ return 0;
+ set_pte(ptep, pte_mkclean(pte));
+ return 1;
+ }
+
+ #if XTENSA_CACHE_ALIAS
+ static inline pte_t ptep_get_and_clear(pte_t *ptep)
+ {
+ pte_t pte = *ptep;
+ pte_clear(ptep);
+ if (!pte_present(pte)) {
+ struct page *page = pte_page(pte);
+ if (VALID_PAGE(page) &&
+ (!page->mapping || !(page->mapping->i_mmap_shared))) {
+ clear_bit(PG_mapped, &page->flags);
+ }
+ }
+ return pte;
+ }
+ #else
+ static inline pte_t ptep_get_and_clear(pte_t *ptep)
+ {
+ pte_t pte = *ptep;
+ pte_clear(ptep);
+ return pte;
+ }
+ #endif
+
+ static inline void ptep_set_wrprotect(pte_t *ptep)
+ {
+ pte_t old_pte = *ptep;
+ set_pte(ptep, pte_wrprotect(old_pte));
+ }
+
+ static inline void ptep_mkdirty(pte_t *ptep)
+ {
+ pte_t old_pte = *ptep;
+ set_pte(ptep, pte_mkdirty(old_pte));
+ }
+
+ #define pte_same(A,B) (pte_val(A) == pte_val(B))
+
#endif /* __ASM_XTENSA_PGALLOC_H */
Index: pgtable.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/pgtable.h,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** pgtable.h 15 Feb 2003 02:02:40 -0000 1.7
--- pgtable.h 28 Feb 2003 01:53:10 -0000 1.8
***************
*** 25,28 ****
--- 25,50 ----
#include <linux/linkage.h>
#include <linux/config.h>
+ #include <linux/mm.h>
+
+
+
+ /* If the xtensa configuration has a cache-way larger than the
+ * page size, then we have to provide our own get_unmapped_area
+ * function to attempt to prevent cache aliasing problems
+ */
+
+ #if XTENSA_CACHE_ALIAS
+ /* We provide our own get_unmapped_area to avoid cache alias issue */
+ #define HAVE_ARCH_UNMAPPED_AREA
+ #define PG_mapped PG_arch_1
+
+ /* this is a mask of the naughty bits that can cause cache aliasing
+ * problems. Because xtensa has a configurable cache size we have to
+ * get funky.... Start with 0xffff_ffff and then mask off everything
+ * else that is not a problem...
+ */
+ #define XT_CACHE_WAYSIZE (XCHAL_DCACHE_SIZE / XCHAL_DCACHE_WAYS)
+ #define XT_CACHE_ALIAS_BITS (( (-1) & ~(PAGE_SIZE-1)) & (XT_CACHE_WAYSIZE-1))
+ #endif
***************
*** 31,35 ****
*/
! #if XCHAL_DCACHE_IS_WRITEBACK
extern void flush_cache_all(void);
--- 53,57 ----
*/
! #if ((XCHAL_DCACHE_IS_WRITEBACK > 0) || (XTENSA_CACHE_ALIAS > 0))
extern void flush_cache_all(void);
***************
*** 42,51 ****
extern void flush_page_to_ram(struct page *page);
- /* dcache aliasing isn't a problem, so this can be null. */
- #define flush_dcache_page(page) do { } while (0)
#else
! #define flush_dcache_page(page) do { } while (0)
#define flush_cache_all() do { } while (0)
#define flush_cache_mm(mm) do { } while (0)
--- 64,71 ----
extern void flush_page_to_ram(struct page *page);
#else
! //#define flush_dcache_page(page) do { } while (0)
#define flush_cache_all() do { } while (0)
#define flush_cache_mm(mm) do { } while (0)
***************
*** 53,63 ****
#define flush_cache_page(vma,page) do { } while (0)
#define flush_cache_sigtramp(addr) do { } while (0)
#define flush_page_to_ram(page) do { } while (0)
#define flush_icache_range(start, end) do { } while (0)
#define flush_icache_page(vma, page) do { } while (0)
- #define flush_icache_user_range(vma, page, addr, len) do { } while (0)
#endif
#endif /* !defined (_LANGUAGE_ASSEMBLY) */
--- 73,99 ----
#define flush_cache_page(vma,page) do { } while (0)
#define flush_cache_sigtramp(addr) do { } while (0)
+ #define flush_icache_user_range(vma, page, addr, len) do { } while (0)
+
#define flush_page_to_ram(page) do { } while (0)
#define flush_icache_range(start, end) do { } while (0)
#define flush_icache_page(vma, page) do { } while (0)
#endif
+
+ /* 19feb2003 -- jn
+ * enabling dcache aliasing, have fear....
+ */
+
+ #if XTENSA_CACHE_ALIAS
+ void flush_dcache_page(struct page *page);
+ // void xtensa_cache_init(void);
+ #else
+ #define flush_dcache_page(page) do { } while (0)
+ // #define xtensa_cache_init() do { } while (0)
+ #endif
+
+
+
#endif /* !defined (_LANGUAGE_ASSEMBLY) */
***************
*** 69,72 ****
--- 105,115 ----
#define WIRED_WAY_FOR_PAGE_TABLE 7
+ /* 27feb2003 -- jn
+ * I am hijacking way9 of the dtlb for the copy_user_page and clear_user_page
+ * functions.
+ */
+ #define WIRED_WAY_FOR_COPY_USER_PAGE 9
+
+
/* PMD_SHIFT determines the size of the area a second-level page table can map */
#define PMD_SHIFT 22
***************
*** 88,91 ****
--- 131,140 ----
#define FIRST_USER_PGD_NR 0
+ /* 27feb2003 -- jn
+ * When caches are aliasable, we need to reserve a small portion of
+ * virtual space for copy_user_page, and clear_user_page. This is
+ * used to reduce the amount of cache flushing required.
+ */
+
/*
* XTFIXME: The CHAL should provide memory-map info on local memories and
***************
*** 98,102 ****
/* 0xC0000000-0xC8000000 reserved for vmalloc; below allows guard memory */
! #define VMALLOC_START 0xC0010000
#define VMALLOC_VMADDR(x) ((unsigned long)(x))
#define VMALLOC_END 0xC7FF0000
--- 147,158 ----
/* 0xC0000000-0xC8000000 reserved for vmalloc; below allows guard memory */
! #if (XTENSA_CACHE_ALIAS)
! #define XTENSA_ALIAS_RESERVE_SIZE XCDCACHE_WAY_SIZE
! #define XTENSA_ALIAS_RESERVE_START 0xC0010000
! #define VMALLOC_START (XTENSA_ALIAS_RESERVE_START + XTENSA_ALIAS_RESERVE_SIZE)
! #else
! #define VMALLOC_START 0xC0010000
! #endif
!
#define VMALLOC_VMADDR(x) ((unsigned long)(x))
#define VMALLOC_END 0xC7FF0000
***************
*** 755,767 ****
* correct mapping. */
! extern inline void update_mmu_cache(struct vm_area_struct * vma,
! unsigned long address, pte_t pte)
! {
! invalidate_page_table();
! }
/* XTFIXME: Possible optimization opportunity here. */
! #include <asm-generic/pgtable.h>
--- 811,827 ----
* correct mapping. */
! extern void update_mmu_cache(struct vm_area_struct * vma,
! unsigned long address,
! pte_t pte);
/* XTFIXME: Possible optimization opportunity here. */
! //#include <asm-generic/pgtable.h>
! /* 27feb2003 jn
! * copied these into pgalloc.h to remove a circular
! * dependency.
! */
!
!
Index: shmparam.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/shmparam.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** shmparam.h 15 Feb 2003 02:02:40 -0000 1.2
--- shmparam.h 28 Feb 2003 01:53:10 -0000 1.3
***************
*** 10,15 ****
*/
- #define SHMLBA PAGE_SIZE /* attach addr a multiple of this */
#endif /* __ASM_XTENSA_SHMPARAM_H */
--- 10,32 ----
*/
+ #include <xtensa/config/core.h>
+ #include <asm/page.h>
+
+
+
+
+ /* 19feb2003 -- jn
+ *
+ * Xtensa can have variable size caches, and if
+ * the size of single way is larger than the page size,
+ * then we have to start worrying about cache aliasing
+ * problems (didn't they fix this problem like back in 1978?)
+ */
+ #if XTENSA_CACHE_ALIAS
+ #define SHMLBA XCDCACHE_WAY_SIZE
+ #else
+ #define SHMLBA PAGE_SIZE /* attach addr a multiple of this */
+ #endif
#endif /* __ASM_XTENSA_SHMPARAM_H */
|
|
From: <jn...@us...> - 2003-02-28 01:53:27
|
Update of /cvsroot/xtensa/linux/arch/xtensa/mm
In directory sc8-pr-cvs1:/tmp/cvs-serv6560/arch/xtensa/mm
Modified Files:
cache.c fault.c mmu.c
Log Message:
Added support for caches that have "ways" larger than PAGE_SIZE.
This was mostly copied from the sh-4 port which suffers from the
same feature. There are still some optimizations that can be done
with regard to defering some cache flusing, and reducing some complete
cache flushes to flushes of the appropriate cache lines.
When the cache way size is less than or equal to PAGE_SIZE, all
of these changes should be optimized away, and the port should run
exactly as it did prior to these changes.
Index: cache.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/mm/cache.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** cache.c 7 Feb 2003 01:49:06 -0000 1.4
--- cache.c 28 Feb 2003 01:53:09 -0000 1.5
***************
*** 32,42 ****
#include <linux/sched.h>
#include <linux/mm.h>
#include <asm/mmu_context.h>
#include <asm/pgtable.h>
#include <asm/system.h>
#include <xtensa/hal.h>
! #if XCHAL_DCACHE_IS_WRITEBACK
void flush_cache_all(void)
--- 32,47 ----
#include <linux/sched.h>
#include <linux/mm.h>
+ #include <linux/init.h>
#include <asm/mmu_context.h>
#include <asm/pgtable.h>
#include <asm/system.h>
#include <xtensa/hal.h>
+ #include <asm/page.h>
+
+
!
! #if (XCHAL_DCACHE_IS_WRITEBACK > 0) || (XTENSA_CACHE_ALIAS > 0)
void flush_cache_all(void)
***************
*** 110,113 ****
--- 115,119 ----
pte_t *ptep;
+
/*
* If owns no valid ASID yet, cannot possibly have gotten
***************
*** 168,176 ****
--- 174,234 ----
}
+
+ #endif /* #if XCHAL_DCACHE_IS_WRITEBACK */
+
+
+
+
+
+
+
+ /* 20feb2003 -- jn
+ * some subset of these functions need to be available when
+ * cache aliasing is a problem and when the cache is writeback.
+ */
+
+ #if (XTENSA_CACHE_ALIAS || XCHALDCACHE_IS_WRITEBACK)
+
+ void flush_page_to_ram (struct page *page)
+ {
+ unsigned long addr = (unsigned long) page_address(page);
+ unsigned long flags;
+ save_and_cli(flags);
+ xthal_dcache_region_writeback_inv((void *)addr, PAGE_SIZE);
+ restore_flags(flags);
+ }
+
+
+ void flush_dcache_page (struct page *page)
+ {
+ unsigned long addr = (unsigned long) page_address(page);
+ unsigned long flags;
+ save_and_cli(flags);
+ #if 1
+ #if defined(XCHALDCACHE_IS_WRITEBACK)
+ xthal_dcache_region_writeback_inv((void *)addr, PAGE_SIZE);
+ #else
+ xthal_dcache_region_invalidate((void *)addr, PAGE_SIZE);
+ #endif
+ #else
+ /* XTFIXME -- this is just a test, going to flush the entire cache
+ * cache and see if that makes it start working.
+ */
+ // printk("flush_dcache_page: addr=0x%08x\n", addr);
+ xthal_dcache_all_writeback_inv();
+ #endif
+
+ restore_flags(flags);
+ }
+
void flush_icache_range(unsigned long start, unsigned long end)
{
unsigned long flags;
save_and_cli(flags);
+ #if defined(XCHALDCACHE_IS_WRITEBACK)
xthal_dcache_region_writeback_inv((void *)start, end - start);
+ #else
+ xthal_dcache_region_invalidate((void*)start, end - start);
+ #endif
xthal_icache_region_invalidate((void *)start, end - start);
restore_flags(flags);
***************
*** 200,223 ****
}
! void flush_page_to_ram (struct page *page)
{
! unsigned long addr = (unsigned long) page_address(page);
! unsigned long flags;
! save_and_cli(flags);
! xthal_dcache_region_writeback_inv((void *)addr, PAGE_SIZE);
! restore_flags(flags);
}
! /* Define only if dcache aliasing is a problem. It currently is not. */
#if 0
! void flush_dcache_page (struct page *page)
{
! unsigned long addr = (unsigned long) page_address(page);
! unsigned long flags;
! save_and_cli(flags);
! xthal_dcache_region_writeback_inv((void *)addr, PAGE_SIZE);
! restore_flags(flags);
}
- #endif
! #endif /* #if XCHAL_DCACHE_IS_WRITEBACK */
--- 258,342 ----
}
! #endif
!
!
!
! /* 20feb2003 -- jn
! * When the cache has the aliasing feature enabled, then we need to
! * implement a couple of special functions to keep the world at
! * large in peace and harmony.
! */
! #if XTENSA_CACHE_ALIAS
!
! static struct semaphore dealias_page_sem;
!
! void clear_user_page(void *to, unsigned long address)
{
! if ( (( (unsigned long)to ^ address) & XT_CACHE_ALIAS_BITS) == 0) {
! clear_page(to);
! } else {
! struct page *topage = virt_to_page(to);
!
! unsigned long new_to = (XTENSA_ALIAS_RESERVE_START);
! unsigned long vpnval;
! pte_t pteval;
!
! new_to = new_to + (address & XT_CACHE_ALIAS_BITS);
! vpnval = new_to + WIRED_WAY_FOR_COPY_USER_PAGE;
! pteval = mk_pte( topage, PAGE_KERNEL);
! down(&dealias_page_sem);
! write_dtlb_entry(pteval, vpnval);
! clear_page((void *)new_to);
! up(&dealias_page_sem);
! }
}
!
!
!
!
! void copy_user_page(void *to, void *from, unsigned long address)
! {
! struct page *topage = virt_to_page(to);
!
!
! set_bit(PG_mapped, &topage->flags);
!
! if (( (address ^ (unsigned long)to) & XT_CACHE_ALIAS_BITS) == 0) {
! copy_page(to, from);
! } else {
#if 0
! copy_page(to, from);
! flush_cache_all();
! #else
! unsigned long new_to = (XTENSA_ALIAS_RESERVE_START);
! unsigned long vpnval;
! pte_t pteval;
!
! new_to = new_to + (address & XT_CACHE_ALIAS_BITS);
! vpnval = new_to + WIRED_WAY_FOR_COPY_USER_PAGE;
! pteval = mk_pte( topage, PAGE_KERNEL);
! down(&dealias_page_sem);
! write_dtlb_entry(pteval, vpnval);
! copy_page((void *)new_to, from);
! up(&dealias_page_sem);
! #endif
! }
! }
!
!
! /* Have to init some pages that can be used as to "de-alias" the cache */
!
! void __init xtensa_cache_init(void)
{
! sema_init(&dealias_page_sem, 1);
}
!
! #endif /* XTENSA_CACHE_ALIAS */
!
!
!
!
!
!
Index: fault.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/mm/fault.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** fault.c 13 Feb 2003 18:19:21 -0000 1.4
--- fault.c 28 Feb 2003 01:53:09 -0000 1.5
***************
*** 41,44 ****
--- 41,87 ----
+ /* flush_tlb_page
+ * This is used when a "page cache page" is updated
+ * and there is a cache alias in that page.
+ */
+
+
+ #if XTENSA_CACHE_ALIAS
+ /* There can exist an alias between a page of
+ * ptes, and the actual page table. This function
+ * needs to be called when a page table entry is changed.
+ * It will writeback the entry in the page of ptes, and
+ * then invalidate the area of the page table causing the
+ * the auto-refill hardware to reload the correct pte value.
+ */
+
+ static inline void flush_pte_from_cache(pte_t *ptep, unsigned long excvaddr)
+ {
+ unsigned long pte_addr = (unsigned long)ptep;
+ unsigned long ptevaddr = PGTABLE_START;
+
+ ptevaddr = ptevaddr + (excvaddr >> (PAGE_SHIFT-2) );
+ if ( (pte_addr ^ ptevaddr) & XT_CACHE_ALIAS_BITS ) {
+ unsigned long flags;
+
+ #if 0
+ save_and_cli(flags);
+ #if ( XCHAL_DCACHE_IS_WRITEBACK )
+ xthal_dcache_region_writeback(ptep, 4);
+ #endif
+ xthal_dcache_line_invalidate(ptevaddr);
+ restore_flags(flags);
+ #endif
+ save_and_cli(flags);
+ xthal_dcache_all_invalidate();
+ restore_flags(flags);
+ }
+ }
+
+ #else
+ #define flush_pte_from_cache(pte, excvaddr) do { } while(0);
+ #endif
+
+
/*
* do_page_fault() could handle:
***************
*** 107,112 ****
* pte_alloc() and get_pte_slow() for more details. */
! if (pte_none(*pte))
invalidate_itlb_mapping(address);
write = 2; /* i-fetch */
--- 150,156 ----
* pte_alloc() and get_pte_slow() for more details. */
! if (pte_none(*pte)) {
invalidate_itlb_mapping(address);
+ }
write = 2; /* i-fetch */
***************
*** 123,126 ****
--- 167,174 ----
pte_val(*pte) |= (_PAGE_ACCESSED | _PAGE_VALID);
invalidate_itlb_mapping(address);
+
+ /* XXX -- jn */
+ flush_pte_from_cache(pte, regs->excvaddr);
+ // flush_cache_all();
return;
}
***************
*** 138,141 ****
--- 186,193 ----
pte_val(*pte) |= (_PAGE_ACCESSED | _PAGE_VALID);
invalidate_dtlb_mapping(address);
+
+ /* xxx jn */
+ flush_pte_from_cache(pte, regs->excvaddr);
+ // flush_cache_all();
return;
}
***************
*** 144,148 ****
case XCHAL_EXCCAUSE_STORE_CACHE_ATTRIBUTE:
-
if (pte_present(*pte) && pte_write(*pte)) {
--- 196,199 ----
***************
*** 153,156 ****
--- 204,211 ----
pte_val(*pte) |= (_PAGE_ACCESSED | _PAGE_MODIFIED | _PAGE_VALID | _PAGE_DIRTY);
invalidate_dtlb_mapping(address);
+
+ /* xxx jn */
+ flush_pte_from_cache(pte, regs->excvaddr);
+ // flush_cache_all();
return;
}
***************
*** 164,169 ****
* get_pte_slow() for more details. */
! if (pte_none(*pte))
invalidate_dtlb_mapping(address);
/* XTFIXME: Use 3 for now, but is it correct? The
--- 219,226 ----
* get_pte_slow() for more details. */
! if (pte_none(*pte)) {
invalidate_dtlb_mapping(address);
+ }
+
/* XTFIXME: Use 3 for now, but is it correct? The
***************
*** 360,361 ****
--- 417,443 ----
}
+
+ void update_mmu_cache(struct vm_area_struct * vma,
+ unsigned long address,
+ pte_t pte)
+ {
+ #if (XTENSA_CACHE_ALIAS)
+ struct page *page;
+
+ page = pte_page(pte);
+ // flush_dcache_page(page);
+ // such a hack.... ick
+ flush_cache_all();
+ #if 0
+ if (VALID_PAGE(page) && !test_bit(PG_mapped, &page->flags)) {
+ flush_dcache_page(page);
+ set_bit(PG_mapped, &page->flags);
+ }
+ #endif
+ #endif
+
+ /* JN XTFIXME -- temporary hack */
+ /* not sure that this is required */
+ // flush_cache_all();
+ invalidate_page_table();
+ }
Index: mmu.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/mm/mmu.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** mmu.c 13 Feb 2003 18:19:22 -0000 1.5
--- mmu.c 28 Feb 2003 01:53:09 -0000 1.6
***************
*** 210,214 ****
** that information from the CHAL. */
! #define XT2000_MMU_DUMP 0
#if (XT2000_MMU_DUMP == 1)
--- 210,214 ----
** that information from the CHAL. */
! #define XT2000_MMU_DUMP 1
#if (XT2000_MMU_DUMP == 1)
|
Update of /cvsroot/xtensa/linux/include/asm-xtensa
In directory sc8-pr-cvs1:/tmp/cvs-serv28561/include/asm-xtensa
Modified Files:
a.out.h assume.h bootparam.h bugs.h cache.h cpextra.h delay.h
div64.h errno.h hardirq.h hdreg.h hw_irq.h ide.h io.h ioctl.h
ioctls.h ipc.h ipcbuf.h keyboard.h linux_logo.h machvec.h
mmu.h mmu_context.h module.h msgbuf.h page.h pci-bridge.h
pci.h pgalloc.h pgtable.h poll.h resource.h scatterlist.h
segment.h semaphore-helper.h sembuf.h serial.h shmbuf.h
shmparam.h smp.h socket.h spinlock.h system.h
Log Message:
A bug in assume.h (an incorrect #ifndef argument) prevented it from ever being processed. This led to some code cleanup so I could automate the detection of other, similar bugs. Meanwhile, I corrected filename omissions, GPL-statement omissions, and embarassing cut-and-paste errors in Xtensa code we derived from other architectures.
Index: a.out.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/a.out.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** a.out.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- a.out.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,5 ****
--- 2,13 ----
#define __ASM_XTENSA_A_OUT_H
+ /*
+ * include/asm-xtensa/a.out.h
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
+ */
+
struct exec
{
Index: assume.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/assume.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** assume.h 13 Feb 2003 19:35:06 -0000 1.2
--- assume.h 15 Feb 2003 02:02:40 -0000 1.3
***************
*** 1,4 ****
! #ifndef __ASM_XTENSA_ATOMIC_H
! #define __ASM_XTENSA_ATOMIC_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_ASSUME_H
! #define __ASM_XTENSA_ASSUME_H
/*
***************
*** 18,21 ****
--- 18,22 ----
#include <xtensa/config/core.h>
#include <xtensa/config/system.h>
+ #include <asm/pgtable.h>
***************
*** 56,59 ****
#endif
! #endif /* __ASM_XTENSA_ATOMIC_H */
--- 57,155 ----
#endif
+
+ /* Verify instruction/data ram/rom and xlmi don't overlay vmalloc space. */
+
+ #define __IN_VMALLOC(addr) ( ((addr) >= VMALLOC_START) && ((addr) < VMALLOC_END) )
+ #define __SPAN_VMALLOC(start,end) ( ((start) < VMALLOC_START) && ((end) >= VMALLOC_END) )
+ #define INSIDE_VMALLOC(start,end) \
+ ( __IN_VMALLOC((start)) || __IN_VMALLOC(end) || __SPAN_VMALLOC((start),(end)) )
+
+ #if XCHAL_NUM_INSTROM
+
+ # if XCHAL_NUM_INSTROM == 1
+ # if INSIDE_VMALLOC(XCHAL_INSTROM0_VADDR,XCHAL_INSTROM0_VADDR+XCHAL_INSTROM0_SIZE)
+ # error vmalloc range conflicts with instrom0
+ # endif
+ # endif
+
+ # if XCHAL_NUM_INSTROM == 2
+ # if INSIDE_VMALLOC(XCHAL_INSTROM1_VADDR,XCHAL_INSTROM1_VADDR+XCHAL_INSTROM1_SIZE)
+ # error vmalloc range conflicts with instrom1
+ # endif
+ # endif
+
+ #endif
+
+ #if XCHAL_NUM_INSTRAM
+
+ # if XCHAL_NUM_INSTRAM == 1
+ # if INSIDE_VMALLOC(XCHAL_INSTRAM0_VADDR,XCHAL_INSTRAM0_VADDR+XCHAL_INSTRAM0_SIZE)
+ # error vmalloc range conflicts with instram0
+ # endif
+ # endif
+
+ # if XCHAL_NUM_INSTRAM == 2
+ # if INSIDE_VMALLOC(XCHAL_INSTRAM1_VADDR,XCHAL_INSTRAM1_VADDR+XCHAL_INSTRAM1_SIZE)
+ # error vmalloc range conflicts with instram1
+ # endif
+ # endif
+
+ #endif
+
+ #if XCHAL_NUM_DATAROM
+
+ # if XCHAL_NUM_DATAROM == 1
+ # if INSIDE_VMALLOC(XCHAL_DATAROM0_VADDR,XCHAL_DATAROM0_VADDR+XCHAL_DATAROM0_SIZE)
+ # error vmalloc range conflicts with datarom0
+ # endif
+ # endif
+
+ # if XCHAL_NUM_DATAROM == 2
+ # if INSIDE_VMALLOC(XCHAL_DATAROM1_VADDR,XCHAL_DATAROM1_VADDR+XCHAL_DATAROM1_SIZE)
+ # error vmalloc range conflicts with datarom1
+ # endif
+ # endif
+
+ #endif
+
+ #if XCHAL_NUM_DATARAM
+
+ # if XCHAL_NUM_DATARAM == 1
+ # if INSIDE_VMALLOC(XCHAL_DATARAM0_VADDR,XCHAL_DATARAM0_VADDR+XCHAL_DATARAM0_SIZE)
+ # error vmalloc range conflicts with dataram0
+ # endif
+ # endif
+
+ # if XCHAL_NUM_DATARAM == 2
+ # if INSIDE_VMALLOC(XCHAL_DATARAM1_VADDR,XCHAL_DATARAM1_VADDR+XCHAL_DATARAM1_SIZE)
+ # error vmalloc range conflicts with dataram1
+ # endif
+ # endif
+
+ #endif
+
+ #if XCHAL_NUM_XLMI
+
+ # if XCHAL_NUM_XLMI == 1
+ # if INSIDE_VMALLOC(XCHAL_XLMI0_VADDR,XCHAL_XLMI0_VADDR+XCHAL_XLMI0_SIZE)
+ # error vmalloc range conflicts with xlmi0
+ # endif
+ # endif
+
+ # if XCHAL_NUM_XLMI == 2
+ # if INSIDE_VMALLOC(XCHAL_XLMI1_VADDR,XCHAL_XLMI1_VADDR+XCHAL_XLMI1_SIZE)
+ # error vmalloc range conflicts with xlmi1
+ # endif
+ # endif
+
+ #endif
+
+ #if (XCHAL_NUM_INSTROM > 2) || \
+ (XCHAL_NUM_INSTRAM > 2) || \
+ (XCHAL_NUM_DATARAM > 2) || \
+ (XCHAL_NUM_DATAROM > 2) || \
+ (XCHAL_NUM_XLMI > 2)
+ #error Insufficient checks on vmalloc above for more than 2 devices
+ #endif
! #endif /* __ASM_XTENSA_ASSUME_H */
Index: bootparam.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/bootparam.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** bootparam.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- bootparam.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,2 ****
--- 1,5 ----
+ #ifndef __ASM_XTENSA_BOOTPARAM_H
+ #define __ASM_XTENSA_BOOTPARAM_H
+
/*
* include/asm-xtensa/bootparam.h
***************
*** 13,19 ****
* Author: Chris Zankel <za...@te..., ch...@za...>
*/
-
- #ifndef __ASM_XTENSA_BOOTPARAM_H
- #define __ASM_XTENSA_BOOTPARAM_H
#define BP_VERSION 0x0001
--- 16,19 ----
Index: bugs.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/bugs.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** bugs.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- bugs.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 3,15 ****
/*
! * This is included by init/main.c to check for architecture-dependent bugs.
*
* Needs:
* void check_bugs(void);
*/
- /*
- * I don't know of any Xtensa Processor bugs yet.
- */
#include <asm/processor.h>
--- 3,21 ----
/*
! * include/asm-xtensa/bugs.h
! *
! * This is included by init/main.c to check for architecture-dependent
! * bugs.
*
* Needs:
* void check_bugs(void);
+ *
+ * Xtensa processors don't have any bugs. :)
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
*/
#include <asm/processor.h>
***************
*** 18,20 ****
--- 24,27 ----
{
}
+
#endif /* __ASM_XTENSA_BUGS_H */
Index: cache.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/cache.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** cache.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- cache.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef _ASM_CACHE_H
! #define _ASM_CACHE_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_CACHE_H
! #define __ASM_XTENSA_CACHE_H
/*
***************
*** 18,20 ****
#define SMP_CACHE_BYTES L1_CACHE_BYTES
! #endif /* _ASM_CACHE_H */
--- 18,20 ----
#define SMP_CACHE_BYTES L1_CACHE_BYTES
! #endif /* __ASM_XTENSA_CACHE_H */
Index: cpextra.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/cpextra.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** cpextra.h 7 Feb 2003 02:03:34 -0000 1.1
--- cpextra.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef _ASM_CPEXTRA_H
! #define _ASM_CPEXTRA_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_CPEXTRA_H
! #define __ASM_XTENSA_CPEXTRA_H
/*
***************
*** 34,36 ****
)
! #endif /* _ASM_CPEXTRA_H */
--- 34,36 ----
)
! #endif /* __ASM_XTENSA_CPEXTRA_H */
Index: delay.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/delay.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** delay.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- delay.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,2 ****
--- 1,5 ----
+ #ifndef __ASM_XTENSA_DELAY_H
+ #define __ASM_XTENSA_DELAY_H
+
/*
* include/asm-xtensa/delay.h
***************
*** 10,16 ****
*/
- #ifndef _ASM_DELAY_H
- #define _ASM_DELAY_H
-
#include <linux/config.h>
#include <asm/processor.h>
--- 13,16 ----
***************
*** 43,46 ****
}
! #endif /* _ASM_DELAY_H */
--- 43,46 ----
}
! #endif /* __ASM_XTENSA_DELAY_H */
Index: div64.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/div64.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** div64.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- div64.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef __ASM_XTENSA_DIV64
! #define __ASM_XTENSA_DIV64
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_DIV64_H
! #define __ASM_XTENSA_DIV64_H
/*
***************
*** 18,20 ****
__res; })
! #endif /* __ASM_XTENSA_DIV64 */
--- 18,20 ----
__res; })
! #endif /* __ASM_XTENSA_DIV64_H */
Index: errno.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/errno.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** errno.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- errno.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,5 ****
--- 2,13 ----
#define __ASM_XTENSA_ERRNO_H
+ /*
+ * include/asm-xtensa/errno.h
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
+ */
+
#define EPERM 1 /* Operation not permitted */
#define ENOENT 2 /* No such file or directory */
Index: hardirq.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/hardirq.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** hardirq.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- hardirq.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef _ASM_HARDIRQ_H
! #define _ASM_HARDIRQ_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_HARDIRQ_H
! #define __ASM_XTENSA_HARDIRQ_H
/*
***************
*** 53,55 ****
#endif /* CONFIG_SMP */
! #endif /* _ASM_HARDIRQ_H */
--- 53,55 ----
#endif /* CONFIG_SMP */
! #endif /* __ASM_XTENSA_HARDIRQ_H */
Index: hdreg.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/hdreg.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** hdreg.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- hdreg.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,2 ****
--- 1,5 ----
+ #ifndef __ASM_XTENSA_HDREG_H
+ #define __ASM_XTENSA_HDREG_H
+
/*
* linux/include/asm-xtensa/hdreg.h
***************
*** 4,10 ****
* Copyright (C) 1994-1996 Linus Torvalds & authors
*/
-
- #ifndef __ASM_XTENSA_HDREG_H
- #define __ASM_XTENSA_HDREG_H
typedef unsigned int ide_ioreg_t;
--- 7,10 ----
Index: hw_irq.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/hw_irq.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** hw_irq.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- hw_irq.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,16 ****
/*
! * This file is subject to the terms and conditions of the GNU General Public
! * License. See the file "COPYING" in the main directory of this archive
! * for more details.
*
! * Copyright (C) 2000, 2001 by Ralf Baechle
*/
- #ifndef _ASM_HW_IRQ_H
- #define _ASM_HW_IRQ_H
! /* This may not be apropriate for all machines, we'll see ... */
static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i)
{
}
! #endif /* _ASM_HW_IRQ_H */
--- 1,17 ----
+ #ifndef __ASM_XTENSA_HW_IRQ_H
+ #define __ASM_XTENSA_HW_IRQ_H
+
/*
! * include/asm-xtensa/hw_irq.h
*
! * This file is subject to the terms and conditions of the GNU General
! * Public License. See the file "COPYING" in the main directory of
! * this archive for more details.
*/
!
static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i)
{
}
! #endif /* __ASM_XTENSA_HW_IRQ_H */
Index: ide.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/ide.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** ide.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- ide.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
/*
! * linux/include/asm-sh/ide.h
*
* Copyright (C) 1994-1996 Linus Torvalds & authors
--- 1,7 ----
+ #ifndef __ASM_XTENSA_IDE_H
+ #define __ASM_XTENSA_IDE_H
+
/*
! * linux/include/asm-xtensa/ide.h
*
* Copyright (C) 1994-1996 Linus Torvalds & authors
***************
*** 9,15 ****
* In future, Xtensa code.
*/
-
- #ifndef __ASM_XTENSA_IDE_H
- #define __ASM_XTENSA_IDE_H
#ifdef __KERNEL__
--- 12,15 ----
Index: io.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/io.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** io.h 8 Jan 2003 23:32:28 -0000 1.2
--- io.h 15 Feb 2003 02:02:40 -0000 1.3
***************
*** 1,2 ****
--- 1,5 ----
+ #ifndef __ASM_XTENSA_IO_H
+ #define __ASM_XTENSA_IO_H
+
/*
* linux/include/asm-xtensa/io.h
***************
*** 12,18 ****
#ifdef __KERNEL__
- #ifndef __ASM_XTENSA_IO_H
- #define __ASM_XTENSA_IO_H
-
#include <linux/config.h>
#include <asm/byteorder.h>
--- 15,18 ----
***************
*** 144,150 ****
#endif
!
!
! #endif
! #endif
--- 144,148 ----
#endif
+ #endif /* __KERNEL__ */
! #endif /* __ASM_XTENSA_IO_H */
Index: ioctl.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/ioctl.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** ioctl.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- ioctl.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,9 ****
- /* $Id$
- *
- * linux/ioctl.h for Linux by H.H. Bergman.
- */
-
#ifndef __ASM_XTENSA_IOCTL_H
#define __ASM_XTENSA_IOCTL_H
/* ioctl command encoding: 32 bits total, command in lower 16 bits,
--- 1,14 ----
#ifndef __ASM_XTENSA_IOCTL_H
#define __ASM_XTENSA_IOCTL_H
+
+ /*
+ * include/asm-xtensa/ioctl.h
+ *
+ * by H.H. Bergman
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
+ */
/* ioctl command encoding: 32 bits total, command in lower 16 bits,
Index: ioctls.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/ioctls.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** ioctls.h 13 Sep 2002 22:44:39 -0000 1.2
--- ioctls.h 15 Feb 2003 02:02:40 -0000 1.3
***************
*** 2,5 ****
--- 2,14 ----
#define __ASM_XTENSA_IOCTLS_H
+ /*
+ * include/asm-xtensa/ioctls.h
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
+ */
+
+
#include <asm/ioctl.h>
Index: ipc.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/ipc.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** ipc.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- ipc.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,10 ****
#define __ASM_XTENSA_IPC_H
! /*
! * These are used to wrap system calls on x86.
*
! * See arch/i386/kernel/sys_i386.c for ugly details..
*/
struct ipc_kludge {
struct msgbuf *msgp;
--- 2,16 ----
#define __ASM_XTENSA_IPC_H
! /*
! * include/asm-xtensa/ipc.h
*
! * These are used to wrap system calls on Xtensa. See
! * arch/xtensa/kernel/ipc.c for ugly details..
! *
! * This file is subject to the terms and conditions of the GNU General
! * Public License. See the file "COPYING" in the main directory of
! * this archive for more details.
*/
+
struct ipc_kludge {
struct msgbuf *msgp;
Index: ipcbuf.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/ipcbuf.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** ipcbuf.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- ipcbuf.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,7 ****
! #ifndef __ASM_XTENSA_IPCBUF_H__
! #define __ASM_XTENSA_IPCBUF_H__
/*
! * The ipc64_perm structure for i386 architecture.
* Note extra padding because this structure is passed back and forth
* between kernel and user space.
--- 1,9 ----
! #ifndef __ASM_XTENSA_IPCBUF_H
! #define __ASM_XTENSA_IPCBUF_H
/*
! * include/asm-xtensa/ipcbuf.h
! *
! * The ipc64_perm structure for the Xtensa architecture.
* Note extra padding because this structure is passed back and forth
* between kernel and user space.
***************
*** 10,15 ****
--- 12,22 ----
* - 32-bit mode_t and seq
* - 2 miscellaneous 32-bit values
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
*/
+
struct ipc64_perm
{
***************
*** 27,29 ****
};
! #endif /* __ASM_XTENSA_IPCBUF_H__ */
--- 34,36 ----
};
! #endif /* __ASM_XTENSA_IPCBUF_H */
Index: keyboard.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/keyboard.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** keyboard.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- keyboard.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,2 ****
--- 1,5 ----
+ #ifndef __ASM_XTENSA_KEYBOARD_H
+ #define __ASM_XTENSA_KEYBOARD_H
+
/*
* linux/include/asm-xtensa/keyboard.h
***************
*** 4,10 ****
*/
- #ifndef __ASM_XTENSA_KEYBOARD_H
- #define __ASM_XTENSA_KEYBOARD_H
-
#ifdef __KERNEL__
--- 7,10 ----
***************
*** 84,86 ****
#endif /* __KERNEL__ */
! #endif /* __ASMPPC_KEYBOARD_H */
--- 84,86 ----
#endif /* __KERNEL__ */
! #endif /* __ASM_XTENSA_KEYBOARD_H */
Index: linux_logo.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/linux_logo.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** linux_logo.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- linux_logo.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,5 ****
! /* $Id$
! * include/asm-Xtensa/linux_logo.h: This is a linux logo
! * to be displayed on boot.
*
* Copyright (C) 1996 Larry Ewing (le...@is...)
--- 1,9 ----
! #ifndef __ASM_XTENSA_LINUX_LOGO_H
! #define __ASM_XTENSA_LINUX_LOGO_H
!
! /*
! * include/asm-xtensa/linux_logo.h
! *
! * This is a linux logo to be displayed on boot.
*
* Copyright (C) 1996 Larry Ewing (le...@is...)
***************
*** 17,20 ****
--- 21,28 ----
* Serial_console ascii image can be any size,
* but should contain %s to display the version
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
*/
***************
*** 47,48 ****
--- 55,58 ----
#endif
+
+ #endif /* __ASM_XTENSA_LINUX_LOGO_H */
Index: machvec.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/machvec.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** machvec.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- machvec.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,13 ****
/*
* (Virtual) Mach-Vectors for Xtensa
*
! * Copyright (C) 2001 Tensilica, Inc.
*
* Author: Christian Zankel <za...@te...> <ch...@za...>
- *
*/
-
- #ifndef __ASM_XTENSA_MACHVEC_H
- #define __ASM_XTENSA_MACHVEC_H
#include <linux/config.h>
--- 1,18 ----
+ #ifndef __ASM_XTENSA_MACHVEC_H
+ #define __ASM_XTENSA_MACHVEC_H
+
/*
+ * include/asm-xtensa/machvec.h
+ *
* (Virtual) Mach-Vectors for Xtensa
*
! * This file is subject to the terms and conditions of the GNU General
! * Public License. See the file "COPYING" in the main directory of
! * this archive for more details.
! *
! * Copyright (C) 2001 - 2003 Tensilica, Inc.
*
* Author: Christian Zankel <za...@te...> <ch...@za...>
*/
#include <linux/config.h>
Index: mmu.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/mmu.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** mmu.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- mmu.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef __MMU_H
! #define __MMU_H
/* Default "unsigned long" context */
--- 1,12 ----
! #ifndef __ASM_XTENSA_MMU_H
! #define __ASM_XTENSA_MMU_H
!
! /*
! * include/asm-xtensa/mmu.h
! *
! * This file is subject to the terms and conditions of the GNU General
! * Public License. See the file "COPYING" in the main directory of
! * this archive for more details.
! */
/* Default "unsigned long" context */
Index: mmu_context.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/mmu_context.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** mmu_context.h 13 Feb 2003 19:35:06 -0000 1.3
--- mmu_context.h 15 Feb 2003 02:02:40 -0000 1.4
***************
*** 1,4 ****
! #ifndef _ASM_MMU_CONTEXT_H
! #define _ASM_MMU_CONTEXT_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_MMU_CONTEXT_H
! #define __ASM_XTENSA_MMU_CONTEXT_H
/*
***************
*** 259,261 ****
}
! #endif /* _ASM_MMU_CONTEXT_H */
--- 259,261 ----
}
! #endif /* __ASM_XTENSA_MMU_CONTEXT_H */
Index: module.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/module.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** module.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- module.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef _ASM_XTENSA_MODULE_H
! #define _ASM_XTENSA_MODULE_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_MODULE_H
! #define __ASM_XTENSA_MODULE_H
/*
***************
*** 19,21 ****
#define arch_init_modules(x) do { } while (0)
! #endif /* _ASM_XTENSA_MODULE_H */
--- 19,21 ----
#define arch_init_modules(x) do { } while (0)
! #endif /* __ASM_XTENSA_MODULE_H */
Index: msgbuf.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/msgbuf.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** msgbuf.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- msgbuf.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,7 ****
#define __ASM_XTENSA_MSGBUF_H
! /*
! * The msqid64_ds structure for i386 architecture.
* Note extra padding because this structure is passed back and forth
* between kernel and user space.
--- 2,9 ----
#define __ASM_XTENSA_MSGBUF_H
! /*
! * include/asm-xtensa/msgbuf.h
! *
! * The msqid64_ds structure for the Xtensa architecture.
* Note extra padding because this structure is passed back and forth
* between kernel and user space.
***************
*** 10,13 ****
--- 12,19 ----
* - 64-bit time_t to solve y2038 problem
* - 2 miscellaneous 32-bit values
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
*/
Index: page.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/page.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** page.h 29 Oct 2002 01:20:33 -0000 1.2
--- page.h 15 Feb 2003 02:02:40 -0000 1.3
***************
*** 1,2 ****
--- 1,5 ----
+ #ifndef __ASM_XTENSA_PAGE_H
+ #define __ASM_XTENSA_PAGE_H
+
/*
* include/asm-xtensa/page.h
***************
*** 15,21 ****
*/
- #ifndef __ASM_PAGE_H
- #define __ASM_PAGE_H
-
#include <xtensa/config/core.h>
--- 18,21 ----
***************
*** 102,104 ****
#endif /* defined (__KERNEL__) */
! #endif /* __ASM_PAGE_H */
--- 102,104 ----
#endif /* defined (__KERNEL__) */
! #endif /* __ASM_XTENSA_PAGE_H */
Index: pci-bridge.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/pci-bridge.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** pci-bridge.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- pci-bridge.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,8 ****
/*
! * BK Id: SCCS/s.pci-bridge.h 1.13 06/05/01 22:20:49 paulus
*/
#ifdef __KERNEL__
- #ifndef _ASM_PCI_BRIDGE_H
- #define _ASM_PCI_BRIDGE_H
struct device_node;
--- 1,15 ----
+ #ifndef __ASM_XTENSA_PCI_BRIDGE_H
+ #define __ASM_XTENSA_PCI_BRIDGE_H
+
/*
! * include/asm-xtensa/pci-bridge.h
! *
! * This file is subject to the terms and conditions of the GNU General
! * Public License. See the file "COPYING" in the main directory of
! * this archive for more details.
*/
+
+
#ifdef __KERNEL__
struct device_node;
***************
*** 72,75 ****
int early_write_config_dword(struct pci_controller *hose, int bus, int dev_fn, int where, u32 val);
- #endif
#endif /* __KERNEL__ */
--- 79,83 ----
int early_write_config_dword(struct pci_controller *hose, int bus, int dev_fn, int where, u32 val);
#endif /* __KERNEL__ */
+
+ #endif /* __ASM_XTENSA_PCI_BRIDGE_H */
Index: pci.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/pci.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** pci.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- pci.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,2 ****
--- 1,5 ----
+ #ifndef __ASM_XTENSA_PCI_H
+ #define __ASM_XTENSA_PCI_H
+
/*
* linux/include/asm-xtensa/pci.h
***************
*** 11,17 ****
*/
- #ifndef __ASM_XTENSA_PCI_H
- #define __ASM_XTENSA_PCI_H
-
#ifdef __KERNEL__
--- 14,17 ----
***************
*** 210,214 ****
#endif /* __KERNEL__ */
-
#endif /* __ASM_XTENSA_PCI_H */
-
--- 210,212 ----
Index: pgalloc.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/pgalloc.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** pgalloc.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- pgalloc.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef _ASM_PGALLOC_H
! #define _ASM_PGALLOC_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_PGALLOC_H
! #define __ASM_XTENSA_PGALLOC_H
/*
***************
*** 211,213 ****
}
! #endif /* _ASM_PGALLOC_H */
--- 211,213 ----
}
! #endif /* __ASM_XTENSA_PGALLOC_H */
Index: pgtable.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/pgtable.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** pgtable.h 13 Feb 2003 19:35:06 -0000 1.6
--- pgtable.h 15 Feb 2003 02:02:40 -0000 1.7
***************
*** 1,4 ****
! #ifndef _ASM_PGTABLE_H
! #define _ASM_PGTABLE_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_PGTABLE_H
! #define __ASM_XTENSA_PGTABLE_H
/*
***************
*** 773,775 ****
#define pgtable_cache_init() do { } while (0)
! #endif /* _ASM_PGTABLE_H */
--- 773,775 ----
#define pgtable_cache_init() do { } while (0)
! #endif /* __ASM_XTENSA_PGTABLE_H */
Index: poll.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/poll.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** poll.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- poll.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,5 ****
--- 2,14 ----
#define __ASM_XTENSA_POLL_H
+ /*
+ * include/asm-xtensa/poll.h
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
+ */
+
+
#define POLLIN 0x0001
#define POLLPRI 0x0002
Index: resource.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/resource.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** resource.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- resource.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef _ASM_RESOURCE_H
! #define _ASM_RESOURCE_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_RESOURCE_H
! #define __ASM_XTENSA_RESOURCE_H
/*
***************
*** 57,59 ****
#endif /* __KERNEL__ */
! #endif /* _ASM_RESOURCE_H */
--- 57,59 ----
#endif /* __KERNEL__ */
! #endif /* __ASM_XTENSA_RESOURCE_H */
Index: scatterlist.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/scatterlist.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** scatterlist.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- scatterlist.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,5 ****
--- 2,14 ----
#define __ASM_XTENSA_SCATTERLIST_H
+ /*
+ * include/asm-xtensa/scatterlist.h
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
+ */
+
+
struct scatterlist {
char * address; /* Location data is to be transferred to */
Index: segment.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/segment.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** segment.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- segment.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,6 ****
! #ifndef _ASM_XTENSA_SEGMENT_H
! #define _ASM_XTENSA_SEGMENT_H
/* Only here because we have some old header files that expect it.. */
! #endif /* _ASM_XTENSA_SEGMENT_H */
--- 1,15 ----
! #ifndef __ASM_XTENSA_SEGMENT_H
! #define __ASM_XTENSA_SEGMENT_H
!
! /*
! * include/asm-xtensa/segment.h
! *
! * This file is subject to the terms and conditions of the GNU General
! * Public License. See the file "COPYING" in the main directory of
! * this archive for more details.
! */
!
/* Only here because we have some old header files that expect it.. */
! #endif
Index: semaphore-helper.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/semaphore-helper.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** semaphore-helper.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- semaphore-helper.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,4 ****
! #ifndef __ASM_SH_SEMAPHORE_HELPER_H
! #define __ASM_SH_SEMAPHORE_HELPER_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_SEMAPHORE_HELPER_H
! #define __ASM_XTENSA_SEMAPHORE_HELPER_H
/*
***************
*** 92,94 ****
}
! #endif /* __ASM_SH_SEMAPHORE_HELPER_H */
--- 92,94 ----
}
! #endif /* __ASM_XTENSA_SEMAPHORE_HELPER_H */
Index: sembuf.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/sembuf.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** sembuf.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- sembuf.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,7 ****
#define __ASM_XTENSA_SEMBUF_H
! /*
! * The semid64_ds structure for i386 architecture.
* Note extra padding because this structure is passed back and forth
* between kernel and user space.
--- 2,9 ----
#define __ASM_XTENSA_SEMBUF_H
! /*
! * include/asm-xtensa/sembuf.h
! *
! * The semid64_ds structure for Xtensa architecture.
* Note extra padding because this structure is passed back and forth
* between kernel and user space.
***************
*** 10,14 ****
--- 12,21 ----
* - 64-bit time_t to solve y2038 problem
* - 2 miscellaneous 32-bit values
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
*/
+
struct semid64_ds {
Index: serial.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/serial.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** serial.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- serial.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,2 ****
--- 1,5 ----
+ #ifndef __ASM_XTENSA_SERIAL_H
+ #define __ASM_XTENSA_SERIAL_H
+
/*
* include/asm-xtensa/serial.h
***************
*** 5,12 ****
*/
- #ifndef _ASM_SERIAL_H
- #define _ASM_SERIAL_H
-
#include <asm/platform/serial.h>
! #endif /* _ASM_SERIAL_H */
--- 8,12 ----
*/
#include <asm/platform/serial.h>
! #endif /* __ASM_XTENSA_SERIAL_H */
Index: shmbuf.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/shmbuf.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** shmbuf.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- shmbuf.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,7 ****
#define __ASM_XTENSA_SHMBUF_H
! /*
! * The shmid64_ds structure for i386 architecture.
* Note extra padding because this structure is passed back and forth
* between kernel and user space.
--- 2,9 ----
#define __ASM_XTENSA_SHMBUF_H
! /*
! * include/asm-xtensa/shmbuf.h
! *
! * The shmid64_ds structure for Xtensa architecture.
* Note extra padding because this structure is passed back and forth
* between kernel and user space.
***************
*** 10,14 ****
--- 12,21 ----
* - 64-bit time_t to solve y2038 problem
* - 2 miscellaneous 32-bit values
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
*/
+
struct shmid64_ds {
Index: shmparam.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/shmparam.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** shmparam.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- shmparam.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,5 ****
--- 2,14 ----
#define __ASM_XTENSA_SHMPARAM_H
+ /*
+ * include/asm-xtensa/shmparam.h
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
+ */
+
+
#define SHMLBA PAGE_SIZE /* attach addr a multiple of this */
Index: smp.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/smp.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** smp.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- smp.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 2,5 ****
--- 2,14 ----
#define __ASM_XTENSA_SMP_H
+ /*
+ * include/asm-xtensa/smp.h
+ *
+ * This file is subject to the terms and conditions of the GNU General
+ * Public License. See the file "COPYING" in the main directory of
+ * this archive for more details.
+ */
+
+
#define cpu_logical_map(cpu) (cpu)
Index: socket.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/socket.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** socket.h 26 Sep 2002 20:45:16 -0000 1.2
--- socket.h 15 Feb 2003 02:02:40 -0000 1.3
***************
*** 1,4 ****
! #ifndef _ASM_SOCKET_H
! #define _ASM_SOCKET_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_SOCKET_H
! #define __ASM_XTENSA_SOCKET_H
/*
***************
*** 72,74 ****
#endif
! #endif /* _ASM_SOCKET_H */
--- 72,74 ----
#endif
! #endif /* __ASM_XTENSA_SOCKET_H */
Index: spinlock.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/spinlock.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** spinlock.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- spinlock.h 15 Feb 2003 02:02:40 -0000 1.2
***************
*** 1,6 ****
! #ifndef _ASM_SPINLOCK_H
! #define _ASM_SPINLOCK_H
! #error Xtensa architecture port does not support SMP spin locks
! #endif /* _ASM_SPINLOCK_H */
--- 1,15 ----
! #ifndef __ASM_XTENSA_SPINLOCK_H
! #define __ASM_XTENSA_SPINLOCK_H
! /*
! * include/asm-xtensa/spinlock.h
! *
! * This file is subject to the terms and conditions of the GNU General
! * Public License. See the file "COPYING" in the main directory of
! * this archive for more details.
! */
!
! #error Xtensa port does not support SMP spin locks yet
!
! #endif
Index: system.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/system.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** system.h 13 Feb 2003 18:19:24 -0000 1.2
--- system.h 15 Feb 2003 02:02:40 -0000 1.3
***************
*** 1,4 ****
! #ifndef _ASM_SYSTEM_H
! #define _ASM_SYSTEM_H
/*
--- 1,4 ----
! #ifndef __ASM_XTENSA_SYSTEM_H
! #define __ASM_XTENSA_SYSTEM_H
/*
***************
*** 195,197 ****
__die_if_kernel(msg, regs, __FILE__ ":"__FUNCTION__, __LINE__)
! #endif /* _ASM_SYSTEM_H */
--- 195,197 ----
__die_if_kernel(msg, regs, __FILE__ ":"__FUNCTION__, __LINE__)
! #endif /* __ASM_XTENSA_SYSTEM_H */
|
|
From: <joe...@us...> - 2003-02-15 01:39:34
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel In directory sc8-pr-cvs1:/tmp/cvs-serv18680/arch/xtensa/kernel Modified Files: setup.c Log Message: Remove dead code. Index: setup.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/setup.c,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** setup.c 13 Feb 2003 18:19:21 -0000 1.7 --- setup.c 15 Feb 2003 01:39:31 -0000 1.8 *************** *** 34,41 **** #endif - #if 0 - #include <asm/io.h> - #endif - #include <asm/system.h> #include <asm/bootparam.h> --- 34,37 ---- |
|
From: <ma...@us...> - 2003-02-14 18:48:18
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel In directory sc8-pr-cvs1:/tmp/cvs-serv29532 Modified Files: process.c ptrace.c Log Message: Make ptrace and gregset properly reflect user PS value, ie. with PS.EXCM zero. The fact that PS.EXCM is left set in pt_regs is for convenience and efficiency of exception handlers, and does not reflect the value of PS while a user task is running. Leaving it set in gregset prevents GDB from doing task tracebacks (which are not done when PS.EXCM is set). Index: process.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/process.c,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** process.c 11 Feb 2003 07:19:38 -0000 1.9 --- process.c 14 Feb 2003 18:48:10 -0000 1.10 *************** *** 259,264 **** elfregs->cpuy = i; elfregs->pc = regs->pc; ! elfregs->ps = regs->ps; elfregs->exccause = regs->exccause; elfregs->excvaddr = regs->excvaddr; --- 259,267 ---- elfregs->cpuy = i; + /* Note: PS.EXCM is not set while user task is running; its + * being set in regs->ps is for exception handling convenience. */ + elfregs->pc = regs->pc; ! elfregs->ps = (regs->ps & ~XCHAL_PS_EXCM_MASK); elfregs->exccause = regs->exccause; elfregs->excvaddr = regs->excvaddr; *************** *** 307,312 **** int i, wb_offset; /* wb_offset must be signed */ regs->pc = elfregs->pc; ! regs->ps = elfregs->ps; regs->exccause = elfregs->exccause; regs->excvaddr = elfregs->excvaddr; --- 310,318 ---- int i, wb_offset; /* wb_offset must be signed */ + /* Note: PS.EXCM is not set while user task is running; it + * needs to be set in regs->ps is for exception handling convenience. */ + regs->pc = elfregs->pc; ! regs->ps = (elfregs->ps | XCHAL_PS_EXCM_MASK); regs->exccause = elfregs->exccause; regs->excvaddr = elfregs->excvaddr; Index: ptrace.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/ptrace.c,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** ptrace.c 7 Feb 2003 02:03:35 -0000 1.8 --- ptrace.c 14 Feb 2003 18:48:10 -0000 1.9 *************** *** 197,201 **** break; case REG_PS: ! tmp = regs->ps; break; case REG_WB: --- 197,203 ---- break; case REG_PS: ! /* Note: PS.EXCM is not set while user task is running; ! * its being set in regs is for exception handling convenience. */ ! tmp = (regs->ps & ~XCHAL_PS_EXCM_MASK); break; case REG_WB: |
|
From: <ma...@us...> - 2003-02-13 22:25:23
|
Update of /cvsroot/xtensa/linux/include/asm-xtensa
In directory sc8-pr-cvs1:/tmp/cvs-serv1831
Modified Files:
processor.h
Log Message:
Remove dead/commented-out code from asm-xtensa/processor.h.
Index: processor.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/processor.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** processor.h 7 Feb 2003 02:03:34 -0000 1.4
--- processor.h 13 Feb 2003 22:25:20 -0000 1.5
***************
*** 69,82 ****
#define current_text_addr() ({ void *pc; __asm__("movi %0, 1f\n1:":"=r" (pc)); pc; })
- #if 0 /* unused */
- /*
- * CPU type and hardware bug flags. Kept separately for each CPU.
- */
- enum cpu_type {
- CPU_T1040BE,
- CPU_T1040LE,
- CPU_XTENSA_NONE
- };
- #endif /*0*/
struct xtensa_cpuinfo {
--- 69,72 ----
***************
*** 90,98 ****
};
- #if XCHAL_EXTRA_SA_ALIGN < 16
- #define EXTRA_ALIGN 16
- #else
- #define EXTRA_ALIGN XCHAL_EXTRA_SA_ALIGN
- #endif
struct thread_struct {
--- 80,83 ----
***************
*** 126,171 ****
*/
! unsigned char* cpregs_ptr[XCHAL_CP_MAX];
/* Allocate storage for extra state and coprocessor state
* (probably only needs XCHAL_EXTRA_SA_ALIGN alignment, but bigger alignment is safe). */
unsigned char cpextra[TOTAL_CPEXTRA_SIZE]
__attribute__ ((aligned(XCHAL_CPEXTRA_SA_ALIGN)));
- /*unsigned char extra[(XCHAL_EXTRA_SA_SIZE+15)&0xfffffff0]
- __attribute__ ((aligned(EXTRA_ALIGN)));*/
-
- #if 0
- #if (XCHAL_CP_MASK & 1)
- #define __CP0SZ ((XCHAL_CP0_SA_SIZE + sizeof(unsigned) -1) / sizeof(unsigned))
- unsigned cp0_regs[__CP0SZ] __attribute__ ((aligned(16)));
- #endif
- #if (XCHAL_CP_MASK & 2)
- #define __CP1SZ ((XCHAL_CP1_SA_SIZE + sizeof(unsigned) -1) / sizeof(unsigned))
- unsigned cp1_regs[__CP1SZ] __attribute__ ((aligned(16)));
- #endif
- #if (XCHAL_CP_MASK & 4)
- #define __CP2SZ ((XCHAL_CP2_SA_SIZE + sizeof(unsigned) -1) / sizeof(unsigned))
- unsigned cp2_regs[__CP2SZ] __attribute__ ((aligned(16)));
- #endif
- #if (XCHAL_CP_MASK & 8)
- #define __CP3SZ ((XCHAL_CP3_SA_SIZE + sizeof(unsigned) -1) / sizeof(unsigned))
- unsigned cp3_regs[__CP3SZ] __attribute__ ((aligned(16)));
- #endif
- #if (XCHAL_CP_MASK & 16)
- #define __CP4SZ ((XCHAL_CP4_SA_SIZE + sizeof(unsigned) -1) / sizeof(unsigned))
- unsigned cp4_regs[__CP4SZ] __attribute__ ((aligned(16)));
- #endif
- #if (XCHAL_CP_MASK & 32)
- #define __CP5SZ ((XCHAL_CP5_SA_SIZE + sizeof(unsigned) -1) / sizeof(unsigned))
- unsigned cp5_regs[__CP5SZ] __attribute__ ((aligned(16)));
- #endif
- #if (XCHAL_CP_MASK & 64)
- #define __CP6SZ ((XCHAL_CP6_SA_SIZE + sizeof(unsigned) -1) / sizeof(unsigned))
- unsigned cp6_regs[__CP6SZ] __attribute__ ((aligned(16)));
- #endif
- #if (XCHAL_CP_MASK & 128)
- #define __CP7SZ ((XCHAL_CP7_SA_SIZE + sizeof(unsigned) -1) / sizeof(unsigned))
- unsigned cp7_regs[__CP7SZ] __attribute__ ((aligned(16)));
- #endif
- #endif /*0*/
};
--- 111,120 ----
*/
! unsigned char* cpregs_ptr[XCHAL_CP_MAX]; /* start of each CP save area within cpextra[] */
!
/* Allocate storage for extra state and coprocessor state
* (probably only needs XCHAL_EXTRA_SA_ALIGN alignment, but bigger alignment is safe). */
unsigned char cpextra[TOTAL_CPEXTRA_SIZE]
__attribute__ ((aligned(XCHAL_CPEXTRA_SA_ALIGN)));
};
|
|
From: <ma...@us...> - 2003-02-13 22:24:40
|
Update of /cvsroot/xtensa/linux/include/asm-xtensa In directory sc8-pr-cvs1:/tmp/cvs-serv1310 Modified Files: elf.h Log Message: Change elf_fpreg_t from double to unsigned int. Index: elf.h =================================================================== RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/elf.h,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** elf.h 7 Feb 2003 02:03:34 -0000 1.5 --- elf.h 13 Feb 2003 22:24:22 -0000 1.6 *************** *** 125,129 **** #define ELF_NFPREG ((TOTAL_FPREGS_SIZE + sizeof(elf_fpreg_t) - 1) / sizeof(elf_fpreg_t)) ! typedef double elf_fpreg_t; typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; --- 125,129 ---- #define ELF_NFPREG ((TOTAL_FPREGS_SIZE + sizeof(elf_fpreg_t) - 1) / sizeof(elf_fpreg_t)) ! typedef unsigned int elf_fpreg_t; typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG]; |
|
From: <joe...@us...> - 2003-02-13 19:35:43
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel
In directory sc8-pr-cvs1:/tmp/cvs-serv7485/arch/xtensa/kernel
Modified Files:
traps.c
Log Message:
XTFIXME cleanup. Also, move a few system-wide architecture checks to a common location (assume.h).
Index: traps.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/traps.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** traps.c 13 Feb 2003 18:19:21 -0000 1.9
--- traps.c 13 Feb 2003 19:35:05 -0000 1.10
***************
*** 213,223 ****
asm volatile (" wsr %0, " XTSTR(INTCLEAR) "\n"
: : "a" (mask) );
-
- /* The INTCLEAR register exists only with the Interrupt
- * Option. If it's missing, report an error. */
-
- #if ( ! XCHAL_HAVE_INTERRUPTS)
- #error What is Linux without interrupts?
- #endif
}
--- 213,216 ----
|
|
From: <joe...@us...> - 2003-02-13 19:35:11
|
Update of /cvsroot/xtensa/linux/include/asm-xtensa
In directory sc8-pr-cvs1:/tmp/cvs-serv7485/include/asm-xtensa
Modified Files:
assume.h mmu_context.h pgtable.h
Log Message:
XTFIXME cleanup. Also, move a few system-wide architecture checks to a common location (assume.h).
Index: assume.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/assume.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** assume.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- assume.h 13 Feb 2003 19:35:06 -0000 1.2
***************
*** 32,34 ****
--- 32,59 ----
#endif
+ #if ( ! XCHAL_HAVE_INTERRUPTS)
+ #error What is Linux without interrupts?
+ #endif
+
+ #if XCHAL_ICACHE_SIZE > 0
+ # if (XCHAL_ICACHE_SIZE % (XCHAL_ICACHE_LINESIZE*XCHAL_ICACHE_WAYS*4)) != 0
+ # error cache configuration outside expected/supported range!
+ # endif
+ #endif
+
+ #if XCHAL_DCACHE_SIZE > 0
+ # if (XCHAL_DCACHE_SIZE % (XCHAL_DCACHE_LINESIZE*XCHAL_DCACHE_WAYS*4)) != 0
+ # error cache configuration outside expected/supported range!
+ # endif
+ #endif
+
+ #if XCHAL_ICACHE_SIZE > (XCHAL_ICACHE_WAYS * PAGE_SIZE)
+ #error Cache aliasing not supported.
+
+ #endif
+ #if XCHAL_DCACHE_SIZE > (XCHAL_DCACHE_WAYS * PAGE_SIZE)
+ #error Cache aliasing not supported.
+ #endif
+
+
#endif /* __ASM_XTENSA_ATOMIC_H */
Index: mmu_context.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/mmu_context.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** mmu_context.h 20 Jan 2003 22:44:15 -0000 1.2
--- mmu_context.h 13 Feb 2003 19:35:06 -0000 1.3
***************
*** 29,55 ****
same number and just uses NTLB_ENTRIES for both tlbs. */
! /* XTFIXME: We assume several things about the MMU here that are
! really configurable, and the code should handle it as such. We
! need a more flexible method to handle this configurability. We
! should consider:
!
! o The number of indicies per way is configurable.
! o Indicies are always consecutive and numbered from zero.
! o The number of autorefill ways is configurable.
! o The autorefill ways are not necessarily contiguous.
! o The first autorefill way isn't necessarily way zero.
!
! Some ideas:
!
! Initialize an MMU data structure on startup that tells an accurate
! picture of the MMU layout. General functions would frequently
! refer to this data structure.
!
! Provide an abundance of small, flexible, inline functions that will
! do the required work correctly. Beware of unwieldy source code
! with too many #ifdef statements.
!
! [JET, 24 Jan 2002]
! */
#define INDICIES_PER_ARF_WAY 4
--- 29,36 ----
same number and just uses NTLB_ENTRIES for both tlbs. */
! /* XTFIXME: INDICES_PER_ARG_WAY is a parameter exposed on the GUI.
! This information really should be available from the CHAL. Current
! values are either 4 or 8. An incorrect setting results is simply
! suboptimal, not incorrect. */
#define INDICIES_PER_ARF_WAY 4
***************
*** 136,140 ****
#endif
! #if (USER_RING == 0)
#error The user and kernel rings really should not be equal.
#endif
--- 117,121 ----
#endif
! #if (USER_RING == KERNEL_RING)
#error The user and kernel rings really should not be equal.
#endif
Index: pgtable.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/pgtable.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** pgtable.h 17 Jan 2003 18:10:15 -0000 1.5
--- pgtable.h 13 Feb 2003 19:35:06 -0000 1.6
***************
*** 60,73 ****
#endif
-
- /* Check for cache aliasing, and kill the build if found. */
-
- #if XCHAL_ICACHE_SIZE > (XCHAL_ICACHE_WAYS * PAGE_SIZE)
- #error Cache aliasing not supported.
- #endif
- #if XCHAL_DCACHE_SIZE > (XCHAL_DCACHE_WAYS * PAGE_SIZE)
- #error Cache aliasing not supported.
- #endif
-
#endif /* !defined (_LANGUAGE_ASSEMBLY) */
--- 60,63 ----
|
|
From: <joe...@us...> - 2003-02-13 19:32:12
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel
In directory sc8-pr-cvs1:/tmp/cvs-serv6141/arch/xtensa/kernel
Modified Files:
head.S
Log Message:
Replace cache invalidation code with equivalent, succinct assembler macros. Also, some XTFIXME cleanup.
Index: head.S
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/head.S,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** head.S 29 Jan 2003 06:17:59 -0000 1.4
--- head.S 13 Feb 2003 19:32:02 -0000 1.5
***************
*** 26,30 ****
#define _ASMLANGUAGE 1
#define _LANGUAGE_ASSEMBLY 1
- #include <xtensa/config/specreg.h>
#include <xtensa/cacheasm.h>
#include <linux/config.h>
--- 26,29 ----
***************
*** 124,129 ****
movi a0, 0
- /* XTFIXME: Is there a CACHEATTR register here? */
-
#if XCHAL_HAVE_SPECULATION
wsr a0, AV+0 // make all registers invalid
--- 123,126 ----
***************
*** 138,142 ****
wsr a0, IBREAKENABLE
wsr a0, ICOUNT
- /* XTFIXME: Hard-coded 15 below should come from the CHAL. */
movi a0, 15
wsr a0, ICOUNTLEVEL
--- 135,138 ----
***************
*** 189,195 ****
#endif
rsync
-
- #else /* XCHAL_HAVE_WINDOWED */
- #error Linux requires the Window Register Option
#endif /* XCHAL_HAVE_WINDOWED */
--- 185,188 ----
***************
*** 303,352 ****
rsync
! /* XTFIXME: use macro invalidate_i{i|d}cache(a0, a7) */
!
! #ifndef CYGPKG_HAL_XTENSA_CACHE_DEFINED
!
! /*
! * Initialize the caches.
! */
!
! #if XCHAL_ICACHE_SIZE > 0
! #if (XCHAL_ICACHE_SIZE % (XCHAL_ICACHE_LINESIZE*XCHAL_ICACHE_WAYS*4)) != 0
! #error cache configuration outside expected/supported range!
! #endif
!
! movi a0, 0
! movi a7, XCHAL_ICACHE_SIZE / XCHAL_ICACHE_WAYS
! 1: iii a0, 0*XCHAL_ICACHE_LINESIZE
! iii a0, 1*XCHAL_ICACHE_LINESIZE
! iii a0, 2*XCHAL_ICACHE_LINESIZE
! iii a0, 3*XCHAL_ICACHE_LINESIZE
! addi a0, a0, 4*XCHAL_ICACHE_LINESIZE
! blt a0, a7, 1b
!
! isync
!
! #endif
!
! #if XCHAL_DCACHE_SIZE > 0
! #if (XCHAL_DCACHE_SIZE % (XCHAL_DCACHE_LINESIZE*XCHAL_DCACHE_WAYS*4)) != 0
! #error cache configuration outside expected/supported range!
! #endif
!
! movi a0, 0
! movi a7, XCHAL_DCACHE_SIZE / XCHAL_DCACHE_WAYS
! 1: dii a0, 0*XCHAL_DCACHE_LINESIZE
! dii a0, 1*XCHAL_DCACHE_LINESIZE
! dii a0, 2*XCHAL_DCACHE_LINESIZE
! dii a0, 3*XCHAL_DCACHE_LINESIZE
! addi a0, a0, 4*XCHAL_DCACHE_LINESIZE
! blt a0, a7, 1b
!
! memw
! isync
! #endif
!
! #endif /* CYGPKG_HAL_XTENSA_CACHE_DEFINED */
/*
* Unpack some data
--- 296,307 ----
rsync
! /* Initialize the caches.
! * Does not include flushing writeback d-cache.
! * a6, a7 are just working registers (clobbered).
! */
+ icache_reset a6, a7
+ dcache_reset a6, a7
+
/*
* Unpack some data
|
|
From: <joe...@us...> - 2003-02-13 18:20:09
|
Update of /cvsroot/xtensa/linux/arch/xtensa/mm In directory sc8-pr-cvs1:/tmp/cvs-serv6671/arch/xtensa/mm Modified Files: fault.c init.c mmu.c Log Message: Documentation updates only, focused on removing many XTFIXME comments that no longer apply, are already resolved, were erroneous, etc. Index: fault.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/mm/fault.c,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** fault.c 13 Feb 2003 00:17:21 -0000 1.3 --- fault.c 13 Feb 2003 18:19:21 -0000 1.4 *************** *** 259,263 **** address, regs->pc, - /* XTFIXME: Shouldn't the 0xC0000000 value come from the CHAL? */ (regs->aregs[0] & 0x3FFFFFFF) | (regs->pc & 0xC0000000), write); --- 259,262 ---- Index: init.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/mm/init.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** init.c 28 Nov 2002 00:40:49 -0000 1.4 --- init.c 13 Feb 2003 18:19:21 -0000 1.5 *************** *** 292,300 **** /* ! * The plain and boring version for Xtensa. No cache flushing ! * stuff is implemented because Xtensa currently has ! * physically tagged caches; and even though it has ! * virtually indexed caches, configurations are currently ! * constrained to avoid aliasing issues. [XTFIXME!!!] */ p = (unsigned long *) page; --- 292,299 ---- /* ! * No cache flushing stuff is implemented because Xtensa ! * currently has physically tagged caches; and even though it ! * has virtually indexed caches, configurations are currently ! * constrained to avoid aliasing issues. */ p = (unsigned long *) page; Index: mmu.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/mm/mmu.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** mmu.c 20 Jan 2003 22:44:16 -0000 1.4 --- mmu.c 13 Feb 2003 18:19:22 -0000 1.5 *************** *** 139,143 **** ! /* XTFIXME: This handler should be ported to assembly for speed! */ /* XTFIXME: This handler, plus the do_page_fault() handler, should --- 139,145 ---- ! /* XTFIXME: This handler should be ported to assembly for speed! I ! think one exists, but is disabled. Need to compare functionality ! and ensure the assembly version isn't outdated. */ /* XTFIXME: This handler, plus the do_page_fault() handler, should |
|
From: <joe...@us...> - 2003-02-13 18:20:08
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel In directory sc8-pr-cvs1:/tmp/cvs-serv6671/arch/xtensa/kernel Modified Files: handlers.S setup.c traps.c Log Message: Documentation updates only, focused on removing many XTFIXME comments that no longer apply, are already resolved, were erroneous, etc. Index: handlers.S =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/handlers.S,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** handlers.S 13 Feb 2003 00:17:21 -0000 1.13 --- handlers.S 13 Feb 2003 18:19:20 -0000 1.14 *************** *** 66,71 **** */ - /* XTFIXME: There are several "#if 0" statements in this file. - Most of them, we should either enable or delete. */ #define _ASMLANGUAGE --- 66,69 ---- *************** *** 161,166 **** addi a0, a1, -(16+PT_SIZE) - /* XTFIXME: Should we do any stack ptr checking here? */ - doubleram_common: --- 159,162 ---- *************** *** 1177,1209 **** s32i a3, a1, PT_EXCVADDR ! /* XTFIXME: The following documentation is outdated. Need to update. */ ! ! // (Misc notes:) ! // PS combinations: ! // WINM EXCM WOE What ! // 0 0 0 non-windowed ABI context (task or handler ...) ! // 0 0 1 windowed ABI context (task or handler ...) ! // 0 1 0 exception occurred in non-windowed context ! // 0 1 1 exception occurred in windowed context ! // 1 0 0 (should never occur) ! // 1 0 1 window exception occurred ! // 1 1 0 (should never occur) ! // 1 1 1 exception in window exception handler ! ! // Okay, exception state is saved, stack frame is ready, a1 is valid, ! // we can set PS to exit the exception critical section (potentially ! // enabling level-1 interrupts) and allow window exceptions to occur. ! // ! // Set PS as follows: ! // INTLEVEL = max(INTLEVEL,1) ! // EXCM = 0 ! // PROGSTACK (UM) = 0 (we'd have to preserve it if staying on user stack!) ! // RING = 0 ! // OWB = 0 (don't care) ! // CALLINC = 0 (don't care) ! // WOE = 1 ! // WINM = 0 ! // Unless the cause is an interrupt, then we also set intlevel to 1. ! // rsr a3, PS movi a2, 1 --- 1173,1191 ---- s32i a3, a1, PT_EXCVADDR ! /* Okay, exception state is saved, stack frame is ready, a1 is valid, ! * we can set PS to exit the exception critical section (potentially ! * enabling level-1 interrupts) and allow window exceptions to occur. ! * ! * Set PS as follows: ! * INTLEVEL = max(INTLEVEL,1) ! * EXCM = 0 ! * UM = 0 (we'd have to preserve it if staying on user stack!) ! * RING = 0 ! * OWB = 0 (don't care) ! * CALLINC = 0 (don't care) ! * WOE = 1 ! * ! * Unless the cause is an interrupt, then we also set intlevel to 1. ! */ rsr a3, PS movi a2, 1 *************** *** 1626,1630 **** l32i a3, a1, PT_AREG3 // restore a3 - .global excdone // XTFIXME: label for development excdone: --- 1608,1611 ---- Index: setup.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/setup.c,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** setup.c 11 Feb 2003 07:20:50 -0000 1.6 --- setup.c 13 Feb 2003 18:19:21 -0000 1.7 *************** *** 119,123 **** meminfo_t *mi = (meminfo_t*)(tag->data); - /* XTFIXME: only CONVENTIONAL (SDRAM) supported? */ if (mi->type != MEMORY_TYPE_CONVENTIONAL) return -1; --- 119,122 ---- Index: traps.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/traps.c,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** traps.c 11 Feb 2003 07:22:25 -0000 1.8 --- traps.c 13 Feb 2003 18:19:21 -0000 1.9 *************** *** 284,288 **** regs->excvaddr, regs->pc, - /* XTFIXME: Shouldn't the 0xC0000000 value come from the CHAL? */ (regs->aregs[0] & 0x3FFFFFFF) | (regs->pc & 0xC0000000) ); #endif --- 284,287 ---- |
|
From: <joe...@us...> - 2003-02-13 18:19:27
|
Update of /cvsroot/xtensa/linux/include/asm-xtensa
In directory sc8-pr-cvs1:/tmp/cvs-serv6671/include/asm-xtensa
Modified Files:
system.h
Log Message:
Documentation updates only, focused on removing many XTFIXME comments that no longer apply, are already resolved, were erroneous, etc.
Index: system.h
===================================================================
RCS file: /cvsroot/xtensa/linux/include/asm-xtensa/system.h,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** system.h 28 Aug 2002 16:11:31 -0000 1.1.1.1
--- system.h 13 Feb 2003 18:19:24 -0000 1.2
***************
*** 61,68 ****
}
- #define save_flage( m ) _save_flags( &m )
- #if 0 /* XTFIXME: Why? */
- extern __inline__ unsigned long save_flags( int *a )
- #endif
#define save_flags(x) \
{ \
--- 61,64 ----
|
|
From: <joe...@us...> - 2003-02-13 18:19:27
|
Update of /cvsroot/xtensa/linux/drivers/net
In directory sc8-pr-cvs1:/tmp/cvs-serv6671/drivers/net
Modified Files:
xtsonic.c
Log Message:
Documentation updates only, focused on removing many XTFIXME comments that no longer apply, are already resolved, were erroneous, etc.
Index: xtsonic.c
===================================================================
RCS file: /cvsroot/xtensa/linux/drivers/net/xtsonic.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** xtsonic.c 12 Feb 2003 20:17:51 -0000 1.4
--- xtsonic.c 13 Feb 2003 18:19:23 -0000 1.5
***************
*** 158,162 ****
SONIC_WRITE(SONIC_IMR,0);
- /* XTFIXME [jet] How about doing this only once on startup? */
xtboard_set_nsdelay_func(&delay_10us);
--- 158,161 ----
***************
*** 164,168 ****
xtboard_get_ether_addr(dev->dev_addr);
} else {
! /* XTFIXME [kcc] Bogus ethernet address */
dev->dev_addr[0]=0x0;
dev->dev_addr[1]=0x1;
--- 163,167 ----
xtboard_get_ether_addr(dev->dev_addr);
} else {
! /* Bogus ethernet address */
dev->dev_addr[0]=0x0;
dev->dev_addr[1]=0x1;
***************
*** 171,175 ****
dev->dev_addr[4]=0x4;
dev->dev_addr[5]=0x5;
! printk("Bogus ");
}
--- 170,174 ----
dev->dev_addr[4]=0x4;
dev->dev_addr[5]=0x5;
! printk("WARNING: Bogus ");
}
|
|
From: <joe...@us...> - 2003-02-13 18:19:27
|
Update of /cvsroot/xtensa/linux/arch/xtensa/platform-iss
In directory sc8-pr-cvs1:/tmp/cvs-serv6671/arch/xtensa/platform-iss
Modified Files:
console.c io.c
Log Message:
Documentation updates only, focused on removing many XTFIXME comments that no longer apply, are already resolved, were erroneous, etc.
Index: console.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/platform-iss/console.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** console.c 28 Aug 2002 16:10:14 -0000 1.1.1.1
--- console.c 13 Feb 2003 18:19:22 -0000 1.2
***************
*** 162,169 ****
* tmp_buf, if necessary. */
! #if 0 // XTFIXME
struct async_struct *info;
int retval;
! #endif // XTFIXME
int line;
unsigned long page;
--- 162,169 ----
* tmp_buf, if necessary. */
! #if __DISABLE_FOR_ISS
struct async_struct *info;
int retval;
! #endif // __DISABLE_FOR_ISS
int line;
unsigned long page;
***************
*** 175,179 ****
return -ENODEV;
}
! #if 0 // XTFIXME
retval = get_async_struct(line, &info);
if (retval) {
--- 175,179 ----
return -ENODEV;
}
! #if __DISABLE_FOR_ISS
retval = get_async_struct(line, &info);
if (retval) {
***************
*** 187,195 ****
return -ENODEV;
}
! #endif // XTFIXME
printk("rs_open %s\n", tty->driver.name);
! #if 0 // XTFIXME
#ifdef SERIAL_DEBUG_OPEN
printk("rs_open %s%d, count = %d\n", tty->driver.name, info->line,
--- 187,195 ----
return -ENODEV;
}
! #endif // __DISABLE_FOR_ISS
printk("rs_open %s\n", tty->driver.name);
! #if __DISABLE_FOR_ISS
#ifdef SERIAL_DEBUG_OPEN
printk("rs_open %s%d, count = %d\n", tty->driver.name, info->line,
***************
*** 199,203 ****
info->tty->low_latency = (info->flags & ASYNC_LOW_LATENCY) ? 1 : 0;
#endif
! #endif // XTFIXME
if (!tmp_buf) {
--- 199,203 ----
info->tty->low_latency = (info->flags & ASYNC_LOW_LATENCY) ? 1 : 0;
#endif
! #endif // __DISABLE_FOR_ISS
if (!tmp_buf) {
***************
*** 213,217 ****
}
! #if 0 // XTFIXME
/*
* If the port is the middle of closing, bail out now
--- 213,217 ----
}
! #if __DISABLE_FOR_ISS
/*
* If the port is the middle of closing, bail out now
***************
*** 271,275 ****
#endif
! #endif // XTFIXME
return 0;
--- 271,275 ----
#endif
! #endif // __DISABLE_FOR_ISS
return 0;
***************
*** 403,409 ****
int *eof, void *data)
{
! #if 0 // XTFIXME
int i, l;
! #endif // XTFIXME
int len = 0;
off_t begin = 0;
--- 403,409 ----
int *eof, void *data)
{
! #if __DISABLE_FOR_ISS
int i, l;
! #endif // __DISABLE_FOR_ISS
int len = 0;
off_t begin = 0;
***************
*** 411,415 ****
len += sprintf(page, "serinfo:1.0 iss driver stub:%s%s revision:%s\n",
serial_version, LOCAL_VERSTRING, serial_revdate);
! #if 0 // XTFIXME
for (i = 0; i < NR_PORTS && len < 4000; i++) {
l = line_info(page + len, &rs_table[i]);
--- 411,415 ----
len += sprintf(page, "serinfo:1.0 iss driver stub:%s%s revision:%s\n",
serial_version, LOCAL_VERSTRING, serial_revdate);
! #if __DISABLE_FOR_ISS
for (i = 0; i < NR_PORTS && len < 4000; i++) {
l = line_info(page + len, &rs_table[i]);
***************
*** 427,431 ****
return 0;
*start = page + (off-begin);
! #endif // XTFIXME
return ((count < begin+len-off) ? count : begin+len-off);
}
--- 427,431 ----
return 0;
*start = page + (off-begin);
! #endif // __DISABLE_FOR_ISS
return ((count < begin+len-off) ? count : begin+len-off);
}
***************
*** 438,442 ****
int __init rs_init(void)
{
! #if 0 // XTFIXME
int i;
struct serial_state * state;
--- 438,442 ----
int __init rs_init(void)
{
! #if __DISABLE_FOR_ISS
int i;
struct serial_state * state;
***************
*** 468,472 ****
#endif
! #endif // XTFIXME
show_serial_version();
--- 468,472 ----
#endif
! #endif // __DISABLE_FOR_ISS
show_serial_version();
***************
*** 544,548 ****
panic("Couldn't register callout driver\n");
! #if 0 // XTFIXME
for (i = 0, state = rs_table; i < NR_PORTS; i++,state++) {
state->magic = SSTATE_MAGIC;
--- 544,548 ----
panic("Couldn't register callout driver\n");
! #if __DISABLE_FOR_ISS
for (i = 0, state = rs_table; i < NR_PORTS; i++,state++) {
state->magic = SSTATE_MAGIC;
***************
*** 591,595 ****
#endif
! #endif // XTFIXME
return 0;
--- 591,595 ----
#endif
! #endif // __DISABLE_FOR_ISS
return 0;
Index: io.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/platform-iss/io.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** io.c 28 Aug 2002 16:10:14 -0000 1.1.1.1
--- io.c 13 Feb 2003 18:19:22 -0000 1.2
***************
*** 1,3 ****
! #ifdef XTFIXME /* this file isn't really needed right now... */
#include <asm/io.h>
--- 1,5 ----
! /* This file isn't really needed right now. */
!
! #if 0
#include <asm/io.h>
***************
*** 27,30 ****
/*#error Need I/O ports to specific hardware!*/
! #endif /*XTFIXME*/
--- 29,32 ----
/*#error Need I/O ports to specific hardware!*/
! #endif
|
|
From: <joe...@us...> - 2003-02-13 18:19:26
|
Update of /cvsroot/xtensa/linux/arch/xtensa/platform-xt2000
In directory sc8-pr-cvs1:/tmp/cvs-serv6671/arch/xtensa/platform-xt2000
Modified Files:
time.c
Log Message:
Documentation updates only, focused on removing many XTFIXME comments that no longer apply, are already resolved, were erroneous, etc.
Index: time.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/platform-xt2000/time.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** time.c 28 Aug 2002 16:10:14 -0000 1.1.1.1
--- time.c 13 Feb 2003 18:19:23 -0000 1.2
***************
*** 294,305 ****
CLOCK_TICK_RATE = measure_sys_clk();
! /* XTFIXME This may need to change for multiprocessor systems */
boot_cpu_data.udelay_val = CLOCK_TICK_RATE/1000000;
ticks = do_getrtctime();
! /* Wait until the clock changes before setting the time
! This puts Linux time within one jiffie of the actual clock. */
do {
xtime.tv_sec = do_getrtctime();
} while (xtime.tv_sec==ticks);
xtime.tv_usec = 0;
xthal_set_ccompare(LINUX_TIMER, xthal_get_ccount() + LINUX_TIMER_INTERVAL);
--- 294,309 ----
CLOCK_TICK_RATE = measure_sys_clk();
! /* This may need to change for multiprocessor systems. */
!
boot_cpu_data.udelay_val = CLOCK_TICK_RATE/1000000;
ticks = do_getrtctime();
!
! /* Wait until the clock changes before setting the time.
! * This puts Linux time within one jiffie of the actual clock. */
!
do {
xtime.tv_sec = do_getrtctime();
} while (xtime.tv_sec==ticks);
+
xtime.tv_usec = 0;
xthal_set_ccompare(LINUX_TIMER, xthal_get_ccount() + LINUX_TIMER_INTERVAL);
|
|
From: <joe...@us...> - 2003-02-13 00:17:24
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel In directory sc8-pr-cvs1:/tmp/cvs-serv2110/arch/xtensa/kernel Modified Files: handlers.S vectors.S sys.S Log Message: Replace "program mode / stacked mode" terminology with "user mode / kernel mode" terminology. Mostly comment updates. Macro replacements are synonyms. Index: handlers.S =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/handlers.S,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** handlers.S 11 Feb 2003 07:24:35 -0000 1.12 --- handlers.S 13 Feb 2003 00:17:21 -0000 1.13 *************** *** 5,14 **** * exceptions (by cause) to C handlers. * ! * There are different default handlers for user (program), ! * kernel (stacked), and double exception vectors. * ! * This file is subject to the terms and conditions of the GNU General Public ! * License. See the file "COPYING" in the main directory of this archive ! * for more details. * * Copyright (C) 2001 - 2003 Tensilica Inc. --- 5,14 ---- * exceptions (by cause) to C handlers. * ! * There are different default handlers for user, kernel, and double ! * exception vectors. * ! * This file is subject to the terms and conditions of the GNU General ! * Public License. See the file "COPYING" in the main directory of ! * this archive for more details. * * Copyright (C) 2001 - 2003 Tensilica Inc. *************** *** 144,149 **** rsr a0, PS // get PS /* slot */ ! //bbsi.l a0, PS_WOE_SHIFT, fatal... // check for unusual case ! bbci.l a0, PS_PROGSTACK_SHIFT, doubleram_kernel // stacked (kernel) mode? /* User mode, so switch stack pointers. Get pointer --- 144,149 ---- rsr a0, PS // get PS /* slot */ ! //bbsi.l a0, PS_WOE_SHIFT, fatal... // check for unusual case ! bbci.l a0, PS_UM_SHIFT, doubleram_kernel // branch if kernel mode /* User mode, so switch stack pointers. Get pointer *************** *** 179,183 **** movi a0, EXCTYPE_DOUBLE_KERNEL ! bbci.l a0, PS_PROGSTACK_SHIFT, 1f // branch if kernel mode movi a0, EXCTYPE_DOUBLE_USER 1: or a2, a2, a0 // add in window vector bit --- 179,183 ---- movi a0, EXCTYPE_DOUBLE_KERNEL ! bbci.l a0, PS_UM_SHIFT, 1f // branch if kernel mode movi a0, EXCTYPE_DOUBLE_USER 1: or a2, a2, a0 // add in window vector bit *************** *** 240,244 **** rsr a0, PS // get PS /* slot */ ! bbci.l a0, PS_PROGSTACK_SHIFT, 1f // stacked (kernel) mode? movi a0, EXCTYPE_USER // mark exception as "double-window-user" --- 240,244 ---- rsr a0, PS // get PS /* slot */ ! bbci.l a0, PS_UM_SHIFT, 1f // branch if kernel mode movi a0, EXCTYPE_USER // mark exception as "double-window-user" *************** *** 299,303 **** rsr a0, PS // get PS /* slot */ ! bbci.l a0, PS_PROGSTACK_SHIFT, 1f // stacked (kernel) mode? movi a0, EXCTYPE_USER // mark exception as "double-window-user" --- 299,303 ---- rsr a0, PS // get PS /* slot */ ! bbci.l a0, PS_UM_SHIFT, 1f // branch if kernel mode movi a0, EXCTYPE_USER // mark exception as "double-window-user" *************** *** 1303,1307 **** // If returning to kernel, skip softirq, reschedule, and signal checks l32i a3, a1, PT_PS ! bbci.l a3, PS_PROGSTACK_SHIFT, _excExitKernel // Check for softirq --- 1303,1307 ---- // If returning to kernel, skip softirq, reschedule, and signal checks l32i a3, a1, PT_PS ! bbci.l a3, PS_UM_SHIFT, _excExitKernel // Check for softirq *************** *** 2855,2859 **** wsr a2, DEPC // preserve a2 so we can use it rsr a0, PS // Check if in user or kernel mode ! extui a0, a0, PS_PROGSTACK_SHIFT, 1 bnez a0, 1f // jump if in user mode --- 2855,2859 ---- wsr a2, DEPC // preserve a2 so we can use it rsr a0, PS // Check if in user or kernel mode ! extui a0, a0, PS_UM_SHIFT, 1 bnez a0, 1f // jump if in user mode Index: vectors.S =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/vectors.S,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** vectors.S 11 Feb 2003 07:22:25 -0000 1.6 --- vectors.S 13 Feb 2003 00:17:21 -0000 1.7 *************** *** 2,13 **** * arch/xtensa/kernel/vectors.S * ! * vectors.S contains the Xtensa level-one exception vectors, ! * that dispatch exceptions (by cause) to exception mode handlers. ! * These are the user (program), kernel (stacked), and double ! * exception vectors. * ! * This file is subject to the terms and conditions of the GNU General Public ! * License. See the file "COPYING" in the main directory of this archive ! * for more details. * * Copyright (C) 2001 - 2003 Tensilica, Inc. --- 2,12 ---- * arch/xtensa/kernel/vectors.S * ! * vectors.S contains the Xtensa level-one exception vectors, that ! * dispatch exceptions (by cause) to exception mode handlers. These ! * are the user, kernel, and double exception vectors. * ! * This file is subject to the terms and conditions of the GNU General ! * Public License. See the file "COPYING" in the main directory of ! * this archive for more details. * * Copyright (C) 2001 - 2003 Tensilica, Inc. Index: sys.S =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/sys.S,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** sys.S 30 Jan 2003 23:55:27 -0000 1.2 --- sys.S 13 Feb 2003 00:17:21 -0000 1.3 *************** *** 274,278 **** rsr a0, PS ! bbci.l a0, PS_PROGSTACK_SHIFT, 1f // branch if kernel mode pdtlb a0, a1 --- 274,278 ---- rsr a0, PS ! bbci.l a0, PS_UM_SHIFT, 1f // branch if kernel mode pdtlb a0, a1 |
|
From: <joe...@us...> - 2003-02-13 00:17:24
|
Update of /cvsroot/xtensa/linux/arch/xtensa/mm In directory sc8-pr-cvs1:/tmp/cvs-serv2110/arch/xtensa/mm Modified Files: fault.c Log Message: Replace "program mode / stacked mode" terminology with "user mode / kernel mode" terminology. Mostly comment updates. Macro replacements are synonyms. Index: fault.c =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/mm/fault.c,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** fault.c 9 Sep 2002 22:23:54 -0000 1.2 --- fault.c 13 Feb 2003 00:17:21 -0000 1.3 *************** *** 183,188 **** * context, we must not take the fault.. */ - /* if (in_interrupt() || !mm || ??? (regs->ps & XCHAL_PS_PROGSTACK_MASK) == 0 ) */ - /* if (in_interrupt() || !mm || !user_mode(regs)) */ if ( in_interrupt() || !mm ) goto no_context; --- 183,186 ---- |
|
From: <jgr...@us...> - 2003-02-12 20:18:03
|
Update of /cvsroot/xtensa/linux/drivers/net
In directory sc8-pr-cvs1:/tmp/cvs-serv22759
Modified Files:
jazzsonic.c macsonic.c sonic.c sonic.h xtsonic.c
Log Message:
Modify SONIC network drivers to use explicit 32-bit mode indication
for clarity.
Index: jazzsonic.c
===================================================================
RCS file: /cvsroot/xtensa/linux/drivers/net/jazzsonic.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** jazzsonic.c 28 Aug 2002 16:10:43 -0000 1.1.1.1
--- jazzsonic.c 12 Feb 2003 20:17:50 -0000 1.2
***************
*** 41,45 ****
#include <linux/skbuff.h>
! #define SREGS_PAD(n) u16 n;
#include "sonic.h"
--- 41,45 ----
#include <linux/skbuff.h>
! #define SONIC_MODE32
#include "sonic.h"
Index: macsonic.c
===================================================================
RCS file: /cvsroot/xtensa/linux/drivers/net/macsonic.c,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -C2 -d -r1.1.1.1 -r1.2
*** macsonic.c 28 Aug 2002 16:10:44 -0000 1.1.1.1
--- macsonic.c 12 Feb 2003 20:17:50 -0000 1.2
***************
*** 56,60 ****
#include <linux/module.h>
! #define SREGS_PAD(n) u16 n;
#include "sonic.h"
--- 56,60 ----
#include <linux/module.h>
! #define SONIC_MODE32
#include "sonic.h"
Index: sonic.c
===================================================================
RCS file: /cvsroot/xtensa/linux/drivers/net/sonic.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** sonic.c 6 Feb 2003 01:23:48 -0000 1.2
--- sonic.c 12 Feb 2003 20:17:51 -0000 1.3
***************
*** 502,506 ****
SONIC_WRITE(SONIC_RWP, rra_end);
SONIC_WRITE(SONIC_URRA, lp->rra_laddr >> 16);
! SONIC_WRITE(SONIC_EOBC, (SONIC_RBSIZE - SONIC_MODESIZE) >> 1);
lp->cur_rra =
--- 502,506 ----
SONIC_WRITE(SONIC_RWP, rra_end);
SONIC_WRITE(SONIC_URRA, lp->rra_laddr >> 16);
! SONIC_WRITE(SONIC_EOBC, SONIC_EOBCSIZE >> 1);
lp->cur_rra =
Index: sonic.h
===================================================================
RCS file: /cvsroot/xtensa/linux/drivers/net/sonic.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** sonic.h 10 Feb 2003 21:56:10 -0000 1.5
--- sonic.h 12 Feb 2003 20:17:51 -0000 1.6
***************
*** 217,220 ****
--- 217,236 ----
#define SONIC_END_OF_LINKS 0x0001
+ /*
+ * The SONIC DP83934C datasheets recommend setting EOBC 2 or 4 bytes less
+ * than the buffer size (for 16-bit and 32-bit modes respectively)
+ * when buffering a single packet per RBA, as this driver does.
+ * And they indicate EOBC must be set to 1518 or 1520 for 16-bit
+ * and 32-bit modes respectively.
+ */
+ #ifdef SONIC_MODE32
+ #define SONIC_RBSIZE 1524
+ #define SONIC_EOBCSIZE 1520
+ #define SREGS_PAD(n) u16 n;
+ #else
+ #define SONIC_RBSIZE 1520
+ #define SONIC_EOBCSIZE 1518
+ #define SREGS_PAD(n)
+ #endif
#if defined(CONFIG_MACSONIC) || defined(__XTENSA_EB__)
***************
*** 435,452 ****
#define SONIC_NUM_TDS 16 /* number of transmit descriptors */
#endif
- /*
- * The SONIC DP83934C datasheets recommend setting EOBC 2 or 4 bytes less
- * than the buffer size (for 16-bit and 32-bit modes respectively)
- * when buffering a single packet per RBA, as this driver does.
- * And they indicate EOBC must be set to 1518 or 1520 for 16-bit
- * and 32-bit modes respectively. To test which case, construct
- * a small structure whose size depends on the mode (avoid using
- * sizeof structure directly, in case of padding).
- */
- struct _sonic_size_test1 { u16 dummy; };
- struct _sonic_size_test2 { u16 dummy; SREGS_PAD(pad); };
- #define SONIC_MODESIZE ((sizeof(struct _sonic_size_test2) \
- > sizeof(struct _sonic_size_test1)) ? 4 : 2) /* 2 or 4 */
- #define SONIC_RBSIZE ((SONIC_MODESIZE > 2) ? 1524 : 1520) /* size of one resource buffer */
#define SONIC_RDS_MASK (SONIC_NUM_RDS-1)
--- 451,454 ----
Index: xtsonic.c
===================================================================
RCS file: /cvsroot/xtensa/linux/drivers/net/xtsonic.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** xtsonic.c 6 Feb 2003 01:23:49 -0000 1.3
--- xtsonic.c 12 Feb 2003 20:17:51 -0000 1.4
***************
*** 37,41 ****
#include <xtensa/xtboard.h>
! #define SREGS_PAD(n) u16 n;
extern unsigned xtboard_nvram_valid(void);
--- 37,41 ----
#include <xtensa/xtboard.h>
! #define SONIC_MODE32
extern unsigned xtboard_nvram_valid(void);
|
|
From: <joe...@us...> - 2003-02-11 19:11:16
|
Update of /cvsroot/xtensa/linux/Documentation
In directory sc8-pr-cvs1:/tmp/cvs-serv1838/Documentation
Modified Files:
Configure.help
Log Message:
Minor documentation updates only.
Index: Configure.help
===================================================================
RCS file: /cvsroot/xtensa/linux/Documentation/Configure.help,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** Configure.help 25 Oct 2002 20:52:16 -0000 1.2
--- Configure.help 11 Feb 2003 19:11:11 -0000 1.3
***************
*** 238,251 ****
Xtensa processors are 32-bit RISC machines designed by Tensilica
primarily for embedded systems. These processors are both
! configurable and extensible. The Linux port supports all processor
! configurations and extensions, with reasonable minimum requirements.
! The Xtensa Linux project has a home page at
! <http://xtensa.sourceforge.net/>.
Xtensa processor configuration
CONFIG_XTENSA_CONFIG_LINUX_BE
! The linux_be processor configuration is a base Xtensa config
! supported in MontaVista Linux distributions. It contains no TIE,
! no coprocessors, and the following configuration options:
Code Density Option 2 Misc Special Registers
--- 238,252 ----
Xtensa processors are 32-bit RISC machines designed by Tensilica
primarily for embedded systems. These processors are both
! configurable and extensible. The Linux port to the Xtensa
! architecture supports all processor configurations and extensions,
! with reasonable minimum requirements. The Xtensa Linux project has
! a home page at <http://xtensa.sourceforge.net/>.
Xtensa processor configuration
CONFIG_XTENSA_CONFIG_LINUX_BE
! The linux_be processor configuration is a baseline Xtensa config
! supported in MontaVista Linux Professional Edition 3.0
! distributions. It contains no TIE, no coprocessors, and the
! following configuration options:
Code Density Option 2 Misc Special Registers
***************
*** 257,261 ****
17 Interrupts MMU w/ TLBs and Autorefill
3 Interrupt Levels 8 Autorefill Ways (I/D TLBs)
! 3 Timers
The linux_le processor configuration is the same as linux_be,
--- 258,262 ----
17 Interrupts MMU w/ TLBs and Autorefill
3 Interrupt Levels 8 Autorefill Ways (I/D TLBs)
! 3 Timers Unaligned Exceptions
The linux_le processor configuration is the same as linux_be,
***************
*** 266,273 ****
Your processor configuration must match exactly to what you select
! here. You can manually add your configuration (search the source
! tree for "CONFIG_XTENSA_CONFIG_LINUX_BE") or use Tensilica's
! script to install an overlay automatically for your processor
! configuration.
Xtensa system type
--- 267,272 ----
Your processor configuration must match exactly to what you select
! here. Also, you can manually add your configuration (search the
! source tree for "CONFIG_XTENSA_CONFIG_LINUX_BE").
Xtensa system type
|
|
From: <ma...@us...> - 2003-02-11 07:24:38
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel In directory sc8-pr-cvs1:/tmp/cvs-serv18526 Modified Files: handlers.S Log Message: Add kernel exception stack checking. To be conditionalized once things are a bit more stable and we tune for efficiency. Without this, looping exceptions can be difficult to diagnose. Index: handlers.S =================================================================== RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/handlers.S,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** handlers.S 7 Feb 2003 02:03:35 -0000 1.11 --- handlers.S 11 Feb 2003 07:24:35 -0000 1.12 *************** *** 12,16 **** * for more details. * ! * Copyright (C) 2001 - 2002 Tensilica Inc. * * Authors: Marc Gauthier <ma...@te...> <ma...@al...> --- 12,16 ---- * for more details. * ! * Copyright (C) 2001 - 2003 Tensilica Inc. * * Authors: Marc Gauthier <ma...@te...> <ma...@al...> *************** *** 427,430 **** --- 427,431 ---- + /* First-level exit handler for unhandled-late kernel exceptions. * *************** *** 1239,1242 **** --- 1240,1261 ---- ///* slot */ //s32i a2, a1, PT_CPENABLE + + #if 1 + /* Stack overflow check, for debugging: */ + _GET_CURRENT a2 + movi a3, TASK_STRUCT_SIZE + PT_SIZE // (could add sizeof(elf_fpregset_t) as well... + add a3, a2, a3 // a3 = stack overflow check boundary + bgeu a1, a3, 1f // stack ptr in seemingly reasonable distance? + movi a4, panic // too close to task struct for comfort, panic + movi a6, kern_stk_overflow_msg + mov a7, a1 // sp + mov a8, a3 // boundary + callx4 a4 // call panic(msg,sp,boundary) + j 1f // normally doesn't get here, but just in case... + //.rodata + kern_stk_overflow_msg: .asciz "kernel stack overflow (sp=0x%X boundary=0x%X)" + .text + 1: + #endif |
|
From: <ma...@us...> - 2003-02-11 07:22:27
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel
In directory sc8-pr-cvs1:/tmp/cvs-serv17976
Modified Files:
traps.c vectors.S
Log Message:
Add missing coprocessor exception names.
Plus minor fix to critical panic code for non-XT2000 targets.
Index: traps.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/traps.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** traps.c 7 Feb 2003 02:03:35 -0000 1.7
--- traps.c 11 Feb 2003 07:22:25 -0000 1.8
***************
*** 106,109 ****
--- 106,117 ----
{ XCHAL_EXCCAUSE_LOAD_CACHE_ATTRIBUTE, "Load Cache Attribute Exception" },
{ XCHAL_EXCCAUSE_STORE_CACHE_ATTRIBUTE, "Store Cache Attribute Exception" },
+ { 32+0, "Coprocessor 0 Disabled Exception" },
+ { 32+1, "Coprocessor 1 Disabled Exception" },
+ { 32+2, "Coprocessor 2 Disabled Exception" },
+ { 32+3, "Coprocessor 3 Disabled Exception" },
+ { 32+4, "Coprocessor 4 Disabled Exception" },
+ { 32+5, "Coprocessor 5 Disabled Exception" },
+ { 32+6, "Coprocessor 6 Disabled Exception" },
+ { 32+7, "Coprocessor 7 Disabled Exception" },
{ XCHAL_EXCCAUSE_FLOATING_POINT, "Floating Point Exception" }
};
***************
*** 129,133 ****
panic("Caught unhandled exception - should not happen.\n"
! "\tEXCCAUSE is %x, %s", regs->exccause, str);
}
--- 137,141 ----
panic("Caught unhandled exception - should not happen.\n"
! "\tEXCCAUSE is %d, %s", regs->exccause, str);
}
Index: vectors.S
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/vectors.S,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** vectors.S 30 Jan 2003 23:55:26 -0000 1.5
--- vectors.S 11 Feb 2003 07:22:25 -0000 1.6
***************
*** 11,15 ****
* for more details.
*
! * Copyright (C) 2001 - 2002 Tensilica, Inc.
* Authors: Marc Gauthier <ma...@te...> <ma...@al...>
* Joe Taylor <jo...@te..., jo...@ya...>
--- 11,15 ----
* for more details.
*
! * Copyright (C) 2001 - 2003 Tensilica, Inc.
* Authors: Marc Gauthier <ma...@te...> <ma...@al...>
* Joe Taylor <jo...@te..., jo...@ya...>
***************
*** 290,296 ****
addi a3, a3, 4
bnez a4, 4b
- 9:
- j 9b /* loop forever */
#endif /* XT2000_SYSRST_VADDR */
--- 290,296 ----
addi a3, a3, 4
bnez a4, 4b
#endif /* XT2000_SYSRST_VADDR */
+
+ 9: j 9b /* loop forever */
|
|
From: <ma...@us...> - 2003-02-11 07:20:53
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel
In directory sc8-pr-cvs1:/tmp/cvs-serv17715
Modified Files:
setup.c
Log Message:
Make kernel traceback on panic more robust against corrupt/unclean stacks.
Index: setup.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/setup.c,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** setup.c 7 Feb 2003 02:03:35 -0000 1.5
--- setup.c 11 Feb 2003 07:20:50 -0000 1.6
***************
*** 247,258 ****
register unsigned current_retpc asm ("a0"); /* return address */
register unsigned *current_sp asm ("a1"); /* current stack pointer */
! unsigned retpc, next_retpc, *sp;
int i;
printk( "Call traceback:\n" );
xthal_window_spill(); /* save any live caller windows to stack */
sp = current_sp; /* start with current stack frame */
retpc = current_retpc; /* and current return address */
for( i = 0; i < MAX_TRACEBACK; i++ ) {
next_retpc = sp[-4]; /* a0 of caller */
sp = (unsigned*) sp[-3]; /* a1 of caller -- go to next caller */
--- 247,265 ----
register unsigned current_retpc asm ("a0"); /* return address */
register unsigned *current_sp asm ("a1"); /* current stack pointer */
! unsigned retpc, next_retpc, upperpc, *sp, *prevsp;
int i;
printk( "Call traceback:\n" );
xthal_window_spill(); /* save any live caller windows to stack */
+ upperpc = ((unsigned)&xtensa_panic_event) & 0xC0000000; /* upper 2 bits of PC */
sp = current_sp; /* start with current stack frame */
+ prevsp = sp - 1;
retpc = current_retpc; /* and current return address */
for( i = 0; i < MAX_TRACEBACK; i++ ) {
+ if( ((unsigned)sp & 3) != 0 || sp <= prevsp || sp > __KSTK_TOS(current) ) {
+ printk( " (stack pointer out of range or unaligned)\n" );
+ break;
+ }
+ prevsp = sp;
next_retpc = sp[-4]; /* a0 of caller */
sp = (unsigned*) sp[-3]; /* a1 of caller -- go to next caller */
***************
*** 261,265 ****
break;
}
! printk( " SP=%08X PC=%08X\n", (unsigned) sp, retpc );
retpc = next_retpc;
}
--- 268,273 ----
break;
}
! printk( " SP=%08X PC=%08X\n",
! (unsigned) sp, ((retpc & 0x3FFFFFFF) | upperpc) );
retpc = next_retpc;
}
|
|
From: <ma...@us...> - 2003-02-11 07:19:41
|
Update of /cvsroot/xtensa/linux/arch/xtensa/kernel
In directory sc8-pr-cvs1:/tmp/cvs-serv17288
Modified Files:
process.c
Log Message:
Enable coprocessors before saving their state for core dumps and ptrace.
Index: process.c
===================================================================
RCS file: /cvsroot/xtensa/linux/arch/xtensa/kernel/process.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** process.c 7 Feb 2003 02:03:35 -0000 1.8
--- process.c 11 Feb 2003 07:19:38 -0000 1.9
***************
*** 360,363 ****
--- 360,364 ----
for (i = 0; i < XCHAL_CP_MAX; i++) {
if (tsk == coproc_owners[i]) {
+ xthal_validate_cp( i ); /* ensure CP is accessible */
xthal_save_cpregs( tsk->thread.cpregs_ptr[i], i );
coproc_owners[i] = 0;
***************
*** 402,405 ****
--- 403,407 ----
for (i = 0; i < XCHAL_CP_MAX; i++) {
if (tsk == coproc_owners[i]) {
+ /*xthal_validate_cp( i );*/ /* ensure CP is accessible */
/*xthal_save_cpregs( tsk->thread.cpregs_ptr[i], i );*/
coproc_owners[i] = 0;
|
|
From: <ma...@us...> - 2003-02-10 21:56:13
|
Update of /cvsroot/xtensa/linux/drivers/net
In directory sc8-pr-cvs1:/tmp/cvs-serv6053
Modified Files:
sonic.h
Log Message:
Fix SONIC buffer size back to 1520 for 16-bit Sonic configurations,
as Joe G pointed out. Also make code slighly more robust against
structure padding by the compiler.
There really ought to be a proper macro defined by target-specific
Sonic drivers indicating whether 32-bit or 16-bit mode is used,
in addition to or rather than the SREGS_PAD() hack.
That involves modifying other driver files, so not done for now.
Index: sonic.h
===================================================================
RCS file: /cvsroot/xtensa/linux/drivers/net/sonic.h,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** sonic.h 6 Feb 2003 01:23:49 -0000 1.4
--- sonic.h 10 Feb 2003 21:56:10 -0000 1.5
***************
*** 441,449 ****
* And they indicate EOBC must be set to 1518 or 1520 for 16-bit
* and 32-bit modes respectively. To test which case, construct
! * a small structure whose size (2 or 4 bytes) depends on the mode:
*/
! struct _sonic_size_test { u16 dummy; SREGS_PAD(pad); };
! #define SONIC_MODESIZE sizeof(struct _sonic_size_test) /* 2 or 4 */
! #define SONIC_RBSIZE ((SONIC_MODESIZE > 2) ? 1524 : 1518) /* size of one resource buffer */
#define SONIC_RDS_MASK (SONIC_NUM_RDS-1)
--- 441,452 ----
* And they indicate EOBC must be set to 1518 or 1520 for 16-bit
* and 32-bit modes respectively. To test which case, construct
! * a small structure whose size depends on the mode (avoid using
! * sizeof structure directly, in case of padding).
*/
! struct _sonic_size_test1 { u16 dummy; };
! struct _sonic_size_test2 { u16 dummy; SREGS_PAD(pad); };
! #define SONIC_MODESIZE ((sizeof(struct _sonic_size_test2) \
! > sizeof(struct _sonic_size_test1)) ? 4 : 2) /* 2 or 4 */
! #define SONIC_RBSIZE ((SONIC_MODESIZE > 2) ? 1524 : 1520) /* size of one resource buffer */
#define SONIC_RDS_MASK (SONIC_NUM_RDS-1)
|