Index: arch/ia64/_link.ld
===================================================================
--- arch/ia64/_link.ld	(revision 2a0047fcb720d09f996a192519ef268a7c44731a)
+++ arch/ia64/_link.ld	(revision 2217ac34c226498d3ab724730de0fb6fa4beda69)
@@ -1,2 +1,11 @@
+/*
+ *  IA-64 linker script
+ *
+ *  It is ELF format, but its only section looks like this:
+ *  kernel text
+ *  kernel data
+ *
+ */
+
 OUTPUT_FORMAT(elf64-ia64-little)
 ENTRY(kernel_image_start)
@@ -4,5 +13,8 @@
 SECTIONS {
     .image 0x0000000000001000: AT (0x0000000000001000) { 
-	    *(.text .stub .text.* .gnu.linkonce.t.*)
+	    ktext_start = .;
+	    *(.text .text.* )
+	    ktext_end = .;
+	    kdata_start = .;
 	    *(.interp)
 	    *(.hash)
@@ -69,4 +81,21 @@
 	    *(.bss .bss.* .gnu.linkonce.b.*)
 	    *(COMMON)
+	    kdata_end = .;
     }
+
+    . = ABSOLUTE(hardcoded_ktext_size);
+    .patch_1 : {
+        LONG(ktext_end - ktext_start);
+    }
+
+    . = ABSOLUTE(hardcoded_kdata_size);
+    .patch_2 : {
+        LONG(kdata_end - kdata_start);
+    }
+
+    . = ABSOLUTE(hardcoded_load_address);
+    .patch_3 : {
+        QUAD(0x0000000000001000);
+    }
+
 }
Index: arch/ia64/src/putchar.c
===================================================================
--- arch/ia64/src/putchar.c	(revision 2a0047fcb720d09f996a192519ef268a7c44731a)
+++ arch/ia64/src/putchar.c	(revision 2217ac34c226498d3ab724730de0fb6fa4beda69)
@@ -29,6 +29,17 @@
 #include <putchar.h>
 #include <arch/types.h>
+#include <arch/ski/ski.h>
 
 void putchar(char ch)
 {
+	__asm__ (
+		"mov r15=%0\n"
+		"mov r32=%1\n"		/* r32 is in0 */
+		"break 0x80000\n"	/* modifies r8 */
+		:
+		: "i" (SKI_CONSOLE_PUTC), "r" (ch)
+		: "r15", "in0", "r8"
+	);
+	
+	if (ch == '\n') putchar('\r');
 }
Index: arch/ia64/src/start.S
===================================================================
--- arch/ia64/src/start.S	(revision 2a0047fcb720d09f996a192519ef268a7c44731a)
+++ arch/ia64/src/start.S	(revision 2217ac34c226498d3ab724730de0fb6fa4beda69)
@@ -33,16 +33,16 @@
 .global kernel_image_start
 
+stack0:
 kernel_image_start:
 	# initialize gp (Global Pointer) register
-	mov r1=0x1000
+	mov r1=kernel_image_start;
 
-	# initialize Ski console using SSC (Simulator System Sall)
+	# set stack pointer to some sane value
+	mov r12=stack0
+	
+	# initialize Ski console using SSC (Simulator System Call)
 	mov r15=SKI_CONSOLE_INIT
 	break 0x80000
 
 0:
-	mov r15=SKI_CONSOLE_PUTC
-	mov r32='.'
-	break 0x80000
-
 	br 0b
Index: src/Makefile.config
===================================================================
--- src/Makefile.config	(revision 2a0047fcb720d09f996a192519ef268a7c44731a)
+++ src/Makefile.config	(revision 2217ac34c226498d3ab724730de0fb6fa4beda69)
@@ -1,6 +1,6 @@
 ARCH=ia32
 #ARCH=mips
+#ARCH=ia64
 #ARCH=powerpc
-#ARCH=ia64
 #ARCH=amd64
 
Index: src/main/main.c
===================================================================
--- src/main/main.c	(revision 2a0047fcb720d09f996a192519ef268a7c44731a)
+++ src/main/main.c	(revision 2217ac34c226498d3ab724730de0fb6fa4beda69)
@@ -64,5 +64,5 @@
  * the linker with appropriate sizes and addresses.
  */
-__u32 hardcoded_load_address = 0;
+__address hardcoded_load_address = 0;
 __u32 hardcoded_ktext_size = 0;
 __u32 hardcoded_kdata_size = 0;
