Discussion:
[ORLinux] [PATCH] openrisc: Support both old (or32) and new (or1k) toolchain
Stefan Kristiansson
2014-09-22 02:53:35 UTC
Permalink
ping ... comments / feedback anyone ?
Guenter
FWIW, I've tested this and it works fine.

Stefan
The output file format for openrisc has changed from "elf32-or32"
to "elf32-or1k" when using the or1k instead of the older or32 toochain.
Select the correct output format automatically to be able to compile
the kernel with both toolchain variants.
Cc: Stefan Kristiansson <stefan.kristiansson at saunalahti.fi>
Signed-off-by: Guenter Roeck <linux at roeck-us.net>
---
Candidate for -stable ?
arch/openrisc/kernel/vmlinux.lds.S | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/arch/openrisc/kernel/vmlinux.lds.S b/arch/openrisc/kernel/vmlinux.lds.S
index 2d69a85..1c5d21a 100644
--- a/arch/openrisc/kernel/vmlinux.lds.S
+++ b/arch/openrisc/kernel/vmlinux.lds.S
@@ -30,7 +30,13 @@
#include <asm/cache.h>
#include <asm-generic/vmlinux.lds.h>
-OUTPUT_FORMAT("elf32-or32", "elf32-or32", "elf32-or32")
+#ifdef __OR1K__
+#define __OUTPUT_FORMAT "elf32-or1k"
+#else
+#define __OUTPUT_FORMAT "elf32-or32"
+#endif
+
+OUTPUT_FORMAT(__OUTPUT_FORMAT, __OUTPUT_FORMAT, __OUTPUT_FORMAT)
jiffies = jiffies_64 + 4;
SECTIONS
Jonas Bonn
2014-09-22 06:23:41 UTC
Permalink
Hi Guenter,
Post by Stefan Kristiansson
ping ... comments / feedback anyone ?
Guenter
FWIW, I've tested this and it works fine.
Thanks, the patch is fine... will apply. It's a nice solution to an
icky problem...

/Jonas
Hi Stefan,
Great, thanks a lot for testing. Any idea if Jonas is available to
send it upstream,
or should I try to send it to Linus directly ?
Jonas Bonn
2014-09-22 06:24:01 UTC
Permalink
Hi Stefan,
Great, thanks a lot for testing. Any idea if Jonas is available to
send it upstream,
or should I try to send it to Linus directly ?
Hi Guenter,

Dropping LKML here...

This has largely been a "hobby" project with just a few commercial
excursions; there's not a lot of manpower in the project and the
bandwidth that people can allocate the project isn't always that
large... which is the case for me right now.

I'd be interested to hear what your interest in OpenRISC is. Given that
the patch is trivial and there are more important issues with the
kernel, why the urgency? If you have a serious project that's using
OpenRISC, it would be good to know about it so that I can allocate time
accordingly and give you the bandwidth you deserve.

Best regards,
Jonas
Thanks,
Guenter
Post by Stefan Kristiansson
Stefan
The output file format for openrisc has changed from "elf32-or32"
to "elf32-or1k" when using the or1k instead of the older or32 toochain.
Select the correct output format automatically to be able to compile
the kernel with both toolchain variants.
Cc: Stefan Kristiansson <stefan.kristiansson at saunalahti.fi>
Signed-off-by: Guenter Roeck <linux at roeck-us.net>
---
Candidate for -stable ?
arch/openrisc/kernel/vmlinux.lds.S | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/arch/openrisc/kernel/vmlinux.lds.S
b/arch/openrisc/kernel/vmlinux.lds.S
index 2d69a85..1c5d21a 100644
--- a/arch/openrisc/kernel/vmlinux.lds.S
+++ b/arch/openrisc/kernel/vmlinux.lds.S
@@ -30,7 +30,13 @@
#include <asm/cache.h>
#include <asm-generic/vmlinux.lds.h>
-OUTPUT_FORMAT("elf32-or32", "elf32-or32", "elf32-or32")
+#ifdef __OR1K__
+#define __OUTPUT_FORMAT "elf32-or1k"
+#else
+#define __OUTPUT_FORMAT "elf32-or32"
+#endif
+
+OUTPUT_FORMAT(__OUTPUT_FORMAT, __OUTPUT_FORMAT, __OUTPUT_FORMAT)
jiffies = jiffies_64 + 4;
SECTIONS
Stefan Kristiansson
2014-09-23 04:58:50 UTC
Permalink
Post by Jonas Bonn
Hi Stefan,
Great, thanks a lot for testing. Any idea if Jonas is available to
send it upstream,
or should I try to send it to Linus directly ?
Hi Guenter,
Dropping LKML here...
This has largely been a "hobby" project with just a few commercial
excursions; there's not a lot of manpower in the project and the
bandwidth that people can allocate the project isn't always that
large... which is the case for me right now.
Another thought: If you are busy, maybe Stefan would be willing to help
out as additional architecture maintainer ?
Sure, I don't have any reservations against giving Jonas a helping hand
at the times he's busy, if he accepts it.

Stefan

Loading...