RE: Regarding select() on PPC

3 messages, 3 authors, 2008-09-23 · open the first message on its own page

RE: Regarding select() on PPC

From: Sadashiiv, Halesh <hidden>
Date: 2008-09-22 15:16:14


The issue is found only in PPC32.

Please let me if the patch is applicable.
+++ arch/powerpc/kernel/syscalls.c      2008-09-22 20:47:23.885126056
+0530
@@ -211,6 +211,9 @@
 int
 ppc_select(int n, fd_set __user *inp, fd_set __user *outp, fd_set
__user *exp, struct timeval __user *tvp)
 {
+   if ( n < 0 )
+       return -EINVAL;
+
    if ( (unsigned long)n >=3D 4096 )
    {
        unsigned long __user *buffer =3D (unsigned long __user *)n;

Thanks,
Halesh

-----Original Message-----
From: Josh Boyer [mailto:<redacted>]
Sent: Friday, September 19, 2008 7:49 PM
To: Sadashiiv, Halesh
Cc: <redacted>
Subject: Re: Regarding select() on PPC

On Fri, Sep 19, 2008 at 07:00:07PM +0530, Sadashiiv, Halesh wrote:
quoted
quoted
For negetive value of n (first argument to select) select fails with
EINVAL
quoted
error,

But for the same when I tested for PowerPC it was giving EFAULT,
Its on 2.6.16 kernel.
2.6.16 is really old.  I tested your testcase on a 2.6.25 based kernel
on
a ppc64 machine and it seemed to work fine.

josh


-------------------------------------------------------------------
This email is confidential and intended only for the use of the =
individual or entity named above and may contain information that is =
privileged. If you are not the intended recipient, you are notified that =
any dissemination, distribution or copying of this email is strictly =
prohibited. If you have received this email in error, please notify us =
immediately by return email or telephone and destroy the original =
message. - This mail is sent via Sony Asia Pacific Mail Gateway.
-------------------------------------------------------------------

Re: Regarding select() on PPC

From: Josh Boyer <hidden>
Date: 2008-09-22 15:25:48

On Mon, Sep 22, 2008 at 08:45:52PM +0530, Sadashiiv, Halesh wrote:

The issue is found only in PPC32.

Please let me if the patch is applicable.
Well, no not really.  Mostly because of procedural issues than anything
else.  Read Documentation/SubmittingPatches in the kernel directory.

Also, there is a comment above this function that eludes to some issues
with select on ppc32.  You might want to ask the overall PowerPC maintainer
if that issue still exits.

josh

Re: Regarding select() on PPC

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2008-09-23 04:42:41

On Mon, 2008-09-22 at 11:24 -0400, Josh Boyer wrote:
On Mon, Sep 22, 2008 at 08:45:52PM +0530, Sadashiiv, Halesh wrote:
quoted

The issue is found only in PPC32.

Please let me if the patch is applicable.
Well, no not really.  Mostly because of procedural issues than anything
else.  Read Documentation/SubmittingPatches in the kernel directory.

Also, there is a comment above this function that eludes to some issues
with select on ppc32.  You might want to ask the overall PowerPC maintainer
if that issue still exits.
I have only half of this thread, what is the problem ?

Ben.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help