[PATCHv2, MIPS] Add support for O32 FPXX and program header based ABI information

Matthew Fortune Matthew.Fortune@imgtec.com
Thu May 15 08:38:00 GMT 2014


> On 14 May 2014 15:46, Matthew Fortune <Matthew.Fortune@imgtec.com> wrote:
> 
> Hi Matthew,
> > +/* Return nonzero iff ELF program headers are compatible with the
> running
> > +   host.  */
> > +static inline int
> > +elf_machine_phdr_check (const ElfW(Phdr) *phdr, ElfW(Half) phnum,
> > +                       char * buf, int len, int fd, struct link_map *
> map)
> > +{
> > +  return 1;
> > +}
> 
> I'm wondering whether the types could be improved here:
> 
> 1. Should it return bool?
> 2. Should buf be const?
> 3. Should len be ssize_t?
> 4. The spacing around '*' is inconsistent.

All good points. I knew I’d end up needing to change all the stubs again.
I think the answer is yes to all.  The types (except const'ness) were just
following the types of the data which are being passed in from dl-load and
also the convention used for return types of other hooks.

If I change the type of len then I expect I should change the type of the
original variable in dl-load as well.

Regards,
Matthew


More information about the Libc-alpha mailing list