diff mbox

scripts/kvm/kvm_stat: fix tracepoint provider

Message ID 1463733756-2149-1-git-send-email-lvivier@redhat.com (mailing list archive)
State New, archived
Headers show

Commit Message

Laurent Vivier May 20, 2016, 8:42 a.m. UTC
tracepoint provider on ppc is broken since:

    fc116ef kvm_stat: Add RESET support for perf event ioctl

because the value used with ioctl() to reset the event queue is
not valid on ppc.

This patch defines the good value for ppc.

Signed-off-by: Laurent Vivier <lvivier@redhat.com>
---
 scripts/kvm/kvm_stat | 1 +
 1 file changed, 1 insertion(+)

Comments

Paolo Bonzini May 23, 2016, 1:51 p.m. UTC | #1
On 20/05/2016 10:42, Laurent Vivier wrote:
> tracepoint provider on ppc is broken since:
> 
>     fc116ef kvm_stat: Add RESET support for perf event ioctl
> 
> because the value used with ioctl() to reset the event queue is
> not valid on ppc.
> 
> This patch defines the good value for ppc.
> 
> Signed-off-by: Laurent Vivier <lvivier@redhat.com>
> ---
>  scripts/kvm/kvm_stat | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/scripts/kvm/kvm_stat b/scripts/kvm/kvm_stat
> index 78ffe83..c547c9b 100755
> --- a/scripts/kvm/kvm_stat
> +++ b/scripts/kvm/kvm_stat
> @@ -256,6 +256,7 @@ class ArchPPC(Arch):
>          self.ioctl_numbers = IOCTL_NUMBERS
>          self.ioctl_numbers['ENABLE'] = 0x20002400
>          self.ioctl_numbers['DISABLE'] = 0x20002401
> +        self.ioctl_numbers['RESET'] = 0x20002403
>  
>          # PPC comes in 32 and 64 bit and some generated ioctl
>          # numbers depend on the wordsize.
> 

I've queued http://permalink.gmane.org/gmane.comp.emulators.qemu/407322
- however, note that kvm_stat is moving to the kernel tree.

Thanks,

Paolo
Laurent Vivier May 23, 2016, 1:56 p.m. UTC | #2
On 23/05/2016 15:51, Paolo Bonzini wrote:
> 
> 
> On 20/05/2016 10:42, Laurent Vivier wrote:
>> tracepoint provider on ppc is broken since:
>>
>>     fc116ef kvm_stat: Add RESET support for perf event ioctl
>>
>> because the value used with ioctl() to reset the event queue is
>> not valid on ppc.
>>
>> This patch defines the good value for ppc.
>>
>> Signed-off-by: Laurent Vivier <lvivier@redhat.com>
>> ---
>>  scripts/kvm/kvm_stat | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/scripts/kvm/kvm_stat b/scripts/kvm/kvm_stat
>> index 78ffe83..c547c9b 100755
>> --- a/scripts/kvm/kvm_stat
>> +++ b/scripts/kvm/kvm_stat
>> @@ -256,6 +256,7 @@ class ArchPPC(Arch):
>>          self.ioctl_numbers = IOCTL_NUMBERS
>>          self.ioctl_numbers['ENABLE'] = 0x20002400
>>          self.ioctl_numbers['DISABLE'] = 0x20002401
>> +        self.ioctl_numbers['RESET'] = 0x20002403
>>  
>>          # PPC comes in 32 and 64 bit and some generated ioctl
>>          # numbers depend on the wordsize.
>>
> 
> I've queued http://permalink.gmane.org/gmane.comp.emulators.qemu/407322
> - however, note that kvm_stat is moving to the kernel tree.

Thanks, that's fine.

Laurent
diff mbox

Patch

diff --git a/scripts/kvm/kvm_stat b/scripts/kvm/kvm_stat
index 78ffe83..c547c9b 100755
--- a/scripts/kvm/kvm_stat
+++ b/scripts/kvm/kvm_stat
@@ -256,6 +256,7 @@  class ArchPPC(Arch):
         self.ioctl_numbers = IOCTL_NUMBERS
         self.ioctl_numbers['ENABLE'] = 0x20002400
         self.ioctl_numbers['DISABLE'] = 0x20002401
+        self.ioctl_numbers['RESET'] = 0x20002403
 
         # PPC comes in 32 and 64 bit and some generated ioctl
         # numbers depend on the wordsize.