[PATCH 5/5] user: ppc: Add "hello world" test for libcflat

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Deepa Srinivasan <deepas@xxxxxxxxxx>

Add a test program ("hello world") to exercise printf() in libcflat.

Signed-off-by: Deepa Srinivasan <deepas@xxxxxxxxxx>
Signed-off-by: Hollis Blanchard <hollisb@xxxxxxxxxx>
---
 user/config-powerpc.mak        |    3 ++-
 user/test/powerpc/helloworld.c |   27 +++++++++++++++++++++++++++
 2 files changed, 29 insertions(+), 1 deletions(-)
 create mode 100644 user/test/powerpc/helloworld.c

diff --git a/user/config-powerpc.mak b/user/config-powerpc.mak
index 79af245..dd7ef54 100644
--- a/user/config-powerpc.mak
+++ b/user/config-powerpc.mak
@@ -17,7 +17,8 @@ simpletests := \
 
 # theses tests use cstart.o, libcflat, and libgcc
 tests := \
-	test/powerpc/exit.bin
+	test/powerpc/exit.bin \
+	test/powerpc/helloworld.bin
 
 include config-powerpc-$(PROCESSOR).mak
 
diff --git a/user/test/powerpc/helloworld.c b/user/test/powerpc/helloworld.c
new file mode 100644
index 0000000..f8630f7
--- /dev/null
+++ b/user/test/powerpc/helloworld.c
@@ -0,0 +1,27 @@
+/*
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License, version 2, as
+ * published by the Free Software Foundation;
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
+ *
+ * Copyright IBM Corp. 2008
+ *
+ * Authors: Deepa Srinivasan <deepas@xxxxxxxxxx>
+ */
+
+#include "libcflat.h"
+
+int main()
+{
+	printf("Hello World\n");
+
+	return 1;
+}
-- 
1.5.6.5

--
To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [KVM Development]     [KVM ARM]     [KVM ia64]     [Linux Virtualization]     [Linux USB Devel]     [Linux Video]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux