public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: "Randy.Dunlap" <rdunlap@xenotime.net>
Cc: akpm@osdl.org, ralf@linux-mips.org,
	erik_frederiksen@pmc-sierra.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] consistently use MAX_ERRNO in __syscall_return
Date: Mon, 03 Jul 2006 09:09:15 -0700	[thread overview]
Message-ID: <44A9412B.1070602@zytor.com> (raw)
In-Reply-To: <20060703084233.0fc3921a.rdunlap@xenotime.net>

Randy.Dunlap wrote:
>>>>  
>>>>  #define NR_syscalls 318
>>>> +#include <linux/err.h>
>>> include/linux/err.h: Assembler messages:
>>> include/linux/err.h:20: Error: no such instruction: `static inline void *ERR_PTR(long error)'
>>> include/linux/err.h:21: Error: junk at end of line, first unrecognized character is `{'
>>> include/linux/err.h:22: Error: no such instruction: `return (void *)error'
>>> include/linux/err.h:23: Error: junk at end of line, first unrecognized character is `}'
>>> include/linux/err.h:25: Error: no such instruction: `static inline long PTR_ERR(const void *ptr)'
>>> include/linux/err.h:26: Error: junk at end of line, first unrecognized character is `{'
>>> include/linux/err.h:27: Error: no such instruction: `return (long)ptr'
>>> include/linux/err.h:28: Error: junk at end of line, first unrecognized character is `}'
>>> include/linux/err.h:30: Error: no such instruction: `static inline long IS_ERR(const void *ptr)'
>>> include/linux/err.h:31: Error: junk at end of line, first unrecognized character is `{'
>>> include/linux/err.h:32: Error: no such instruction: `return unlikely(((unsigned long)ptr)>=(unsigned long)-4095)'
>>> include/linux/err.h:33: Error: junk at end of line, first unrecognized character is `}'
>>> distcc[7619] ERROR: compile (null) on localhost failed
>>> make[1]: *** [arch/i386/kernel/vsyscall-sysenter.o] Error 1
>>> make: *** [arch/i386/kernel/vsyscall-sysenter.o] Error 2
> 
> Built for me on i386 and x86_64.
> 
>> unlikely() shouldn't be used in code exported to user space.  At least 
>> one architecture simply open-codes the __builtin_expect(); or we could
>> introduce __likely() and __unlikely() for the benefit of userspace.
> 
> How did you determine that this had something to do with
> userspace?
> 

The vsyscalls are userspace code.  Doesn't mean they operate by 
userspace naming rules, of course, but still...

	-hpa

  reply	other threads:[~2006-07-03 16:09 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-28 20:57 IS_ERR Threshold Value Erik Frederiksen
2006-06-28 21:08 ` Randy.Dunlap
2006-06-28 22:39   ` H. Peter Anvin
2006-06-29 18:10   ` Ralf Baechle
2006-07-01 18:44     ` Randy.Dunlap
2006-07-01 22:23       ` H. Peter Anvin
2006-07-02 16:15         ` Ralf Baechle
2006-07-02 17:40           ` H. Peter Anvin
2006-07-02 18:22           ` Randy.Dunlap
2006-07-02 18:27         ` [PATCH] consistently use MAX_ERRNO in __syscall_return Randy.Dunlap
2006-07-03  7:39           ` Andrew Morton
2006-07-03 15:03             ` H. Peter Anvin
2006-07-03 15:42               ` Randy.Dunlap
2006-07-03 16:09                 ` H. Peter Anvin [this message]
2006-10-16 19:31     ` IS_ERR Threshold Value Andreas Mohr
2006-10-18 12:47       ` Jan Engelhardt
2006-06-28 22:41 ` Nathan Scott
2006-06-28 23:13   ` Erik Frederiksen
2006-06-28 23:22     ` Randy.Dunlap
2006-06-28 23:23     ` Nathan Scott

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=44A9412B.1070602@zytor.com \
    --to=hpa@zytor.com \
    --cc=akpm@osdl.org \
    --cc=erik_frederiksen@pmc-sierra.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ralf@linux-mips.org \
    --cc=rdunlap@xenotime.net \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox