[prev in list] [next in list] [prev in thread] [next in thread] 

List:       busybox
Subject:    Re: [PATCH 3/6] android: fix 'ionice', add ioprio defines
From:       Rich Felker <dalias () aerifal ! cx>
Date:       2012-05-28 23:33:10
Message-ID: 20120528233310.GJ163 () brightrain ! aerifal ! cx
[Download RAW message or body]

On Mon, May 28, 2012 at 11:44:31PM +0200, Tias Guns wrote:
> patch inspired by 'BusyBox Patch V1.0 (Vitaly Greck)'
> https://code.google.com/p/busybox-android/downloads/detail?name=patch_busybox
> 
> Signed-off-by: Tias Guns <tias@ulyssis.org>
> ---
>  include/platform.h |    2 ++
>  miscutils/ionice.c |    4 ++--
>  2 files changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/include/platform.h b/include/platform.h
> index f250624..ba534b2 100644
> --- a/include/platform.h
> +++ b/include/platform.h
> @@ -336,6 +336,8 @@ typedef unsigned smalluint;
>  
>  #if defined(ANDROID) || defined(__ANDROID__)
>  # define BB_ADDITIONAL_PATH ":/system/sbin:/system/bin:/system/xbin"
> +# define SYS_ioprio_set __NR_ioprio_set
> +# define SYS_ioprio_get __NR_ioprio_get
>  #endif
> [...]
>  static int ioprio_set(int which, int who, int ioprio)
>  {
> -	return syscall(SYS_ioprio_set, which, who, ioprio);
> +	return syscall(__NR_ioprio_set, which, who, ioprio);
>  }

Why are you both adding the SYS_ version of the syscall id, then also
changing the source not to use it? Either one change or the other
would make it work (and I'm not sure which is better) but there's
certainly no need for both...

Rich
_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic