On 18/03/2008, Jeff Dike <[EMAIL PROTECTED]> wrote:
> I just noticed something.  I forgot to pass down the ioctl argument.
>  See if the patch below makes any differece.
I applied your last patch to my kernel tree doing nothing else before but...

I had problems during compilation:

# make linux ARCH=um
  SYMLINK arch/um/include/kern_constants.h
  SYMLINK arch/um/include/sysdep
make[1]: `arch/um/sys-x86_64/user-offsets.s' is up to date.
  CHK     arch/um/include/user_constants.h
  CHK     include/linux/version.h
  CHK     include/linux/utsrelease.h
  CALL    scripts/checksyscalls.sh
  CHK     include/linux/compile.h
  CC      arch/um/drivers/ubd_kern.o
arch/um/drivers/ubd_kern.c: In function 'path_requires_switch':
arch/um/drivers/ubd_kern.c:1203: error: case label not within a switch statement
arch/um/drivers/ubd_kern.c:1204: error: 'ubd_dev' undeclared (first
use in this function)
arch/um/drivers/ubd_kern.c:1204: error: (Each undeclared identifier is
reported only once
arch/um/drivers/ubd_kern.c:1204: error: for each function it appears in.)
arch/um/drivers/ubd_kern.c:1206: error: 'arg' undeclared (first use in
this function)
make[1]: *** [arch/um/drivers/ubd_kern.o] Error 1
make: *** [arch/um/drivers] Error 2

Is it a my own mistake?

>
>
>  > And the directory /proc/3/ exists on the host.
>
>
> /proc/3 is irrelevant.  You want /proc/<eject-pid>/3.
OK, now I understand.

Thank you,

Flavio

>
>
>                             Jeff
>
>  --
>  Work email - jdike at linux dot intel dot com
>
>
> Index: linux-2.6.22/arch/um/drivers/ubd_kern.c
>  ===================================================================
>  --- linux-2.6.22.orig/arch/um/drivers/ubd_kern.c        2008-03-06 
> 08:57:08.000000000 -0500
>
> +++ linux-2.6.22/arch/um/drivers/ubd_kern.c     2008-03-18 11:29:55.000000000 
> -0400
>
> @@ -1162,6 +1162,10 @@ static int ubd_ioctl(struct inode * inod
>                 if(copy_to_user((char __user *) arg, &volume, sizeof(volume)))
>                         return -EFAULT;
>                 return 0;
>  +       case CDROMEJECT:
>  +               if (ubd_dev->fd == -1)
>  +                       return -ENXIO;
>
> +               return os_ioctl_generic(ubd_dev->fd, CDROMEJECT, arg);
>         }
>         return -EINVAL;
>   }
>

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
User-mode-linux-user mailing list
User-mode-linux-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/user-mode-linux-user

Reply via email to