mailing list of musl libc
 help / color / mirror / code / Atom feed
From: Szabolcs Nagy <nsz@port70.net>
To: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi>
Cc: musl@lists.openwall.com
Subject: Re: [PATCH] add or1k (OpenRISC 1000) architecture port
Date: Thu, 17 Jul 2014 00:51:59 +0200	[thread overview]
Message-ID: <20140716225158.GC9928@port70.net> (raw)
In-Reply-To: <1405533357-7898-1-git-send-email-stefan.kristiansson@saunalahti.fi>

* Stefan Kristiansson <stefan.kristiansson@saunalahti.fi> [2014-07-16 20:55:57 +0300]:
> With the exception of a fenv implementation, the port is fully featured.

i assume or1k is soft-float only

(for a working soft-float fenv musl will need cooperation with libgcc)

> The port has been tested in or1ksim, the golden reference functional
> simulator for OpenRISC 1000.
> It passes all libc-test tests (except the math tests that
> requires a fenv implementation).

nice

can i ask what version of the kernel headers did you use
to prepare the bits headers?

> +++ b/arch/or1k/bits/syscall.h
> @@ -0,0 +1,523 @@
...
> +#define __NR_kcmp 272
> +#define __NR_finit_module 273
> +#define __NR_syscalls 274

other archs don't define __NR_syscalls for the number of syscalls
(but it does not hurt)

...
> +#define SYS_kcmp __NR_kcmp
> +#define SYS_finit_module __NR_finit_module
> +#define SYS_syscalls __NR_syscalls

the syscall numbers after this are out-of-order
(this will be confusing when new syscalls will be added)

i'd prefer if __NR_* and SYS_* were in the same order
(can be fixed after the great commit)

> +#define SYS_fcntl64 __NR_fcntl64
> +#define SYS_statfs64 __NR_statfs64
> +#define SYS_fstatfs64 __NR_fstatfs64
...


> +++ b/configure
> @@ -250,6 +250,7 @@ x86_64-x32*|x32*|x86_64*x32) ARCH=x32 ;;
>  x86_64*) ARCH=x86_64 ;;
>  mips*) ARCH=mips ;;
>  microblaze*) ARCH=microblaze ;;
> +or1k*) ARCH=or1k ;;

i assume or1k is the official name all toolchain things use

> +++ b/include/elf.h
> @@ -209,7 +209,7 @@ typedef struct {
>  #define EM_MN10300	89
>  #define EM_MN10200	90
>  #define EM_PJ		91
> -#define EM_OPENRISC	92
> +#define EM_OR1K		92

glibc has EM_OPENRISC defined since 2001 and
the binutils i have here seems to use the same name

is this change official?

> +#define R_OR1K_NONE		0
> +#define R_OR1K_32		1
> +#define R_OR1K_16		2
...

ditto, i don't see these in binutils, but i guess
it's a new elf platform


  reply	other threads:[~2014-07-16 22:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-16 17:55 Stefan Kristiansson
2014-07-16 22:51 ` Szabolcs Nagy [this message]
2014-07-16 23:29   ` Rich Felker
2014-07-17  3:46   ` Stefan Kristiansson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140716225158.GC9928@port70.net \
    --to=nsz@port70.net \
    --cc=musl@lists.openwall.com \
    --cc=stefan.kristiansson@saunalahti.fi \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).