Strict Standards: Declaration of action_plugin_importoldchangelog::register() should be compatible with DokuWiki_Action_Plugin::register($controller) in /DISK2/WWW/pavel-rimsky.cz/helenos/lib/plugins/importoldchangelog/action.php on line 8 Strict Standards: Declaration of action_plugin_importoldindex::register() should be compatible with DokuWiki_Action_Plugin::register($controller) in /DISK2/WWW/pavel-rimsky.cz/helenos/lib/plugins/importoldindex/action.php on line 0 Deprecated: Function split() is deprecated in /DISK2/WWW/pavel-rimsky.cz/helenos/inc/auth.php on line 154 Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /DISK2/WWW/pavel-rimsky.cz/helenos/inc/auth.php on line 456 Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /DISK2/WWW/pavel-rimsky.cz/helenos/inc/auth.php on line 456 Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /DISK2/WWW/pavel-rimsky.cz/helenos/inc/auth.php on line 453 Index: kernel/arch/sparc64/include/regdef.h =================================================================== --- kernel/arch/sparc64/include/regdef.h (revision 3477) +++ kernel/arch/sparc64/include/regdef.h (working copy) @@ -59,8 +59,8 @@ * The following definitions concern the UPA_CONFIG register on US and the * FIREPLANE_CONFIG register on US3. */ -#define UPA_CONFIG_MID_SHIFT 17 -#define UPA_CONFIG_MID_MASK 0x1f +#define ICBUS_CONFIG_MID_SHIFT 17 +#define ICBUS_CONFIG_MID_MASK 0x1f #endif Index: kernel/arch/sparc64/include/interrupt.h =================================================================== --- kernel/arch/sparc64/include/interrupt.h (revision 3467) +++ kernel/arch/sparc64/include/interrupt.h (working copy) @@ -40,7 +40,7 @@ #include #define IVT_ITEMS 15 -#define IVT_FIRST 1 +#define IVT_FIRST 1 // co to je? /* This needs to be defined for inter-architecture API portability. */ #define VECTOR_TLB_SHOOTDOWN_IPI 0 @@ -55,16 +55,19 @@ uint64_t tstate; } istate_t; +// nastavi adresu, kam se vratit po obslouzeni preruseni static inline void istate_set_retaddr(istate_t *istate, uintptr_t retaddr) { istate->tpc = retaddr; } +// vrati 1 <==> preruseny kod byl userspacovsky static inline int istate_from_uspace(istate_t *istate) { return !(istate->tstate & TSTATE_PRIV_BIT); } +// zjisti, kde byl preruseny kod, kdyz byl prerusen static inline unative_t istate_get_pc(istate_t *istate) { return istate->tpc; Index: kernel/arch/sparc64/include/stack.h =================================================================== --- kernel/arch/sparc64/include/stack.h (revision 3467) +++ kernel/arch/sparc64/include/stack.h (working copy) @@ -1,3 +1,4 @@ +// podivej se, co je to SPARC compliance definition /* * Copyright (c) 2005 Jakub Jermar * All rights reserved. Index: kernel/arch/sparc64/include/arch.h =================================================================== --- kernel/arch/sparc64/include/arch.h (revision 3477) +++ kernel/arch/sparc64/include/arch.h (working copy) @@ -41,7 +41,7 @@ #define ASI_AIUS 0x11 /** Access to secondary context with user privileges. */ #define ASI_NUCLEUS_QUAD_LDD 0x24 /** ASI for 16-byte atomic loads. */ #define ASI_DCACHE_TAG 0x47 /** ASI D-Cache Tag. */ -#define ASI_UPA_CONFIG 0x4a /** ASI of the UPA_CONFIG/FIREPLANE_CONFIG register. */ +#define ASI_ICBUS_CONFIG 0x4a /** ASI of the UPA_CONFIG/FIREPLANE_CONFIG register. */ #define NWINDOWS 8 /** Number of register window sets. */ Index: kernel/arch/sparc64/include/asm.h =================================================================== --- kernel/arch/sparc64/include/asm.h (revision 3477) +++ kernel/arch/sparc64/include/asm.h (working copy) @@ -364,9 +364,9 @@ * Value of the UPA_CONFIG register in US, * value of the FIREPLANE_CONFIG on US3. */ -static inline uint64_t upa_config_read(void) +static inline uint64_t icbus_config_read(void) { - return asi_u64_read(ASI_UPA_CONFIG, 0); + return asi_u64_read(ASI_ICBUS_CONFIG, 0); } extern void cpu_halt(void); Index: kernel/arch/sparc64/include/register.h =================================================================== --- kernel/arch/sparc64/include/register.h (revision 3477) +++ kernel/arch/sparc64/include/register.h (working copy) @@ -123,7 +123,7 @@ * processor version to version. The format defined here * is the common subset for all supported processor versions. */ -union upa_config { +union icbus_config { uint64_t value; struct { uint64_t : 34; @@ -132,7 +132,7 @@ unsigned pcap : 17; /**< Processor capabilities. */ } __attribute__ ((packed)); }; -typedef union upa_config upa_config_t; +typedef union icbus_config icbus_config_t; #endif Index: kernel/arch/sparc64/include/cpu.h =================================================================== --- kernel/arch/sparc64/include/cpu.h (revision 3477) +++ kernel/arch/sparc64/include/cpu.h (working copy) @@ -52,7 +52,10 @@ #define IMPL_ULTRASPARCII 0x11 #define IMPL_ULTRASPARCII_I 0x12 #define IMPL_ULTRASPARCII_E 0x13 -#define IMPL_ULTRASPARCIII 0x15 +#define IMPL_ULTRASPARCIII 0x14 +#define IMPL_ULTRASPARCIII_PLUS 0x15 +#define IMPL_ULTRASPARCIII_I 0x16 +#define IMPL_ULTRASPARCIV 0x18 #define IMPL_ULTRASPARCIV_PLUS 0x19 #define IMPL_SPARC64V 0x5 Index: kernel/arch/sparc64/src/cpu/cpu.c =================================================================== --- kernel/arch/sparc64/src/cpu/cpu.c (revision 3467) +++ kernel/arch/sparc64/src/cpu/cpu.c (working copy) @@ -47,10 +47,10 @@ ofw_tree_node_t *node; uint32_t mid; uint32_t clock_frequency = 0; - upa_config_t upa_config; + icbus_config_t icbus_config; - upa_config.value = upa_config_read(); - CPU->arch.mid = upa_config.mid; + icbus_config.value = icbus_config_read(); + CPU->arch.mid = icbus_config.mid; /* * Detect processor frequency. Index: kernel/arch/sparc64/src/start.S =================================================================== --- kernel/arch/sparc64/src/start.S (revision 3467) +++ kernel/arch/sparc64/src/start.S (working copy) @@ -301,9 +301,9 @@ * Read MID from the processor. */ 1: - ldxa [%g0] ASI_UPA_CONFIG, %g1 - srlx %g1, UPA_CONFIG_MID_SHIFT, %g1 - and %g1, UPA_CONFIG_MID_MASK, %g1 + ldxa [%g0] ASI_ICBUS_CONFIG, %g1 + srlx %g1, ICBUS_CONFIG_MID_SHIFT, %g1 + and %g1, ICBUS_CONFIG_MID_MASK, %g1 #ifdef CONFIG_SMP /* Index: boot/genarch/balloc.h =================================================================== --- boot/genarch/balloc.h (revision 3467) +++ boot/genarch/balloc.h (working copy) @@ -40,11 +40,7 @@ * machines so that it can fit into 128 kB. This is a workaround how * to get rid of the memory claiming failure. */ -#if defined (SMART_FIRMWARE) - #define BALLOC_MAX_SIZE (128 * 1024) -#else - #define BALLOC_MAX_SIZE (1024 * 1024) -#endif +#define BALLOC_MAX_SIZE (128 * 1024) typedef struct { uintptr_t base; Index: boot/genarch/ofw_tree.c =================================================================== --- boot/genarch/ofw_tree.c (revision 3467) +++ boot/genarch/ofw_tree.c (working copy) @@ -219,28 +219,27 @@ ofw_tree_node_t *ofw_tree_build(void) { ofw_tree_node_t *root; - -#if defined (SMART_FIRMWARE) + phandle ssm_node; ofw_tree_node_t *ssm; -#endif root = ofw_tree_node_alloc(); if (root) ofw_tree_node_process(root, NULL, ofw_root); -#if defined (SMART_FIRMWARE) /* * The firmware client interface does not automatically include the * "ssm" node in the list of children of "/". A nasty yet working * solution is to explicitly stick "ssm" to the OFW tree. */ - ssm = ofw_tree_node_alloc(); - if (ssm) { - ofw_tree_node_process(ssm, root, ofw_find_device("/ssm@0,0")); - ssm->peer = root->child; - root->child = ssm; + ssm_node = ofw_find_device("/ssm@0,0"); + if (ssm_node != -1) { + ssm = ofw_tree_node_alloc(); + if (ssm) { + ofw_tree_node_process(ssm, root, ofw_find_device("/ssm@0,0")); + ssm->peer = root->child; + root->child = ssm; + } } -#endif return root; } Index: boot/boot.config =================================================================== --- boot/boot.config (revision 3467) +++ boot/boot.config (working copy) @@ -83,7 +83,5 @@ @ "fat" FAT16 image ! RDFMT (choice) -# OpenFirmware implementation -@ "open_boot" OpenBoot (Sun Microsystems) -@ "smart_firmware" SmartFirmware (CodeGen) -! [ARCH=sparc64] OFW_IMPLEMENTATION (choice) \ No newline at end of file +# Preserve A.OUT header in isofs.b +! [ARCH=sparc64] CONFIG_AOUT_ISOFS_B (y/n) \ No newline at end of file Index: boot/arch/sparc64/Makefile.inc =================================================================== --- boot/arch/sparc64/Makefile.inc (revision 3467) +++ boot/arch/sparc64/Makefile.inc (working copy) @@ -28,13 +28,11 @@ TMP=distroot -ifeq ($(OFW_IMPLEMENTATION),smart_firmware) - DEFS += -DSMART_FIRMWARE +ifeq ($(CONFIG_AOUT_ISOFS_B),n) SILO_PACKAGE=silo.patched.tar.gz endif -ifeq ($(OFW_IMPLEMENTATION),open_boot) - DEFS += -DOPEN_BOOT +ifeq ($(CONFIG_AOUT_ISOFS_B),y) SILO_PACKAGE=silo.tar.gz endif Index: boot/arch/sparc64/loader/asm.S =================================================================== --- boot/arch/sparc64/loader/asm.S (revision 3467) +++ boot/arch/sparc64/loader/asm.S (working copy) @@ -108,15 +108,36 @@ */ /* - * US-III processors have a write-invalidate cache, so flushing it is - * not required. We only use the FLUSH instruction to flush the - * pipeline. - */ -#ifdef US - call icache_flush -#endif + * US3 processors have a write-invalidate cache, so explicitly + * invalidating it is not required. Whether to invalidate I-cache + * or not is decided according to the value of the ver.impl bits + * in the Version register. + */ + sethi 0x40000, %g0 +! the lowest/greatest value of ver.impl for US3 +#define FIRST_US3_CPU 0x14 +#define LAST_US3_CPU 0x19 + rdpr %ver, %g2 ! autodetect CPU using the Version register + sllx %g2, 16, %g2 ! extract ver.impl bits + srlx %g2, 48, %g2 + addcc %g2, -FIRST_US3_CPU, %g0 ! flush if ver.impl < FISRT_US3_CPU + bl 0f + nop + addcc %g2, -LAST_US3_CPU, %g0 ! flush if ver.impl > LAST_US3_CPU + bg 0f + nop + ba 1f + nop +0: + call icache_flush + nop +1: - membar #StoreStore + membar #StoreStore + + /* + * Flush the instruction pipeline. + */ flush %i7 mov %o0, %l1 @@ -143,7 +164,6 @@ retl ! SF Erratum #51 nop - .global ofw ofw: save %sp, -STACK_WINDOW_SAVE_AREA_SIZE, %sp Index: boot/arch/sparc64/loader/ofwarch.c =================================================================== --- boot/arch/sparc64/loader/ofwarch.c (revision 3467) +++ boot/arch/sparc64/loader/ofwarch.c (working copy) @@ -56,23 +56,19 @@ return flag != -1; } -/* - * Node among whose children the CPU nodes are located. - */ -#if defined (OPEN_BOOT) -#define CPUS_PARENT_NODE ofw_root -#elif defined (SMART_FIRMWARE) -#define CPUS_PARENT_NODE ofw_find_device("/ssm@0,0") -#endif - - int ofw_cpu(void) { char type_name[BUF_SIZE]; - phandle node; - node = ofw_get_child_node(CPUS_PARENT_NODE); + phandle ssm; + ssm = ofw_find_device("/ssm@0,0"); + if (ssm == -1) { + node = ofw_get_child_node(ofw_root); + } else { + node = ofw_get_child_node(ssm); + } + if (node == 0 || node == -1) { printf("Could not find any child nodes of the root node.\n"); return 0; @@ -82,9 +78,9 @@ asm volatile ("ldxa [%1] %2, %0\n" : "=r" (current_mid) - : "r" (0), "i" (ASI_UPA_CONFIG)); - current_mid >>= UPA_CONFIG_MID_SHIFT; - current_mid &= UPA_CONFIG_MID_MASK; + : "r" (0), "i" (ASI_ICBUS_CONFIG)); + current_mid >>= ICBUS_CONFIG_MID_SHIFT; + current_mid &= ICBUS_CONFIG_MID_MASK; int cpus; Index: boot/arch/sparc64/loader/register.h =================================================================== --- boot/arch/sparc64/loader/register.h (revision 3467) +++ boot/arch/sparc64/loader/register.h (working copy) @@ -33,8 +33,8 @@ #define PSTATE_PRIV_BIT 4 #define PSTATE_AM_BIT 8 -#define ASI_UPA_CONFIG 0x4a -#define UPA_CONFIG_MID_SHIFT 17 -#define UPA_CONFIG_MID_MASK 0x1f +#define ASI_ICBUS_CONFIG 0x4a +#define ICBUS_CONFIG_MID_SHIFT 17 +#define ICBUS_CONFIG_MID_MASK 0x1f #endif Index: boot/arch/ppc32/Makefile.inc =================================================================== --- boot/arch/ppc32/Makefile.inc (revision 3467) +++ boot/arch/ppc32/Makefile.inc (working copy) @@ -26,8 +26,6 @@ # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # -DEFS += -DSMART_FIRMWARE - build: $(BASE)/image.boot $(BASE)/image.boot: depend arch/$(ARCH)/loader/image.boot