lkml.org 
[lkml]   [2021]   [Aug]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
SubjectRe: [PATCH kernel] KVM: PPC: Book3S HV: Make unique debugfs nodename
Date
Alexey Kardashevskiy <aik@ozlabs.ru> writes:

> On 07/07/2021 14:13, Alexey Kardashevskiy wrote:

> alternatively move this debugfs stuff under the platform-independent
> directory, how about that?

That's a good idea. I only now realized we have two separate directories
for the same guest:

$ ls /sys/kernel/debug/kvm/ | grep $pid
19062-11
vm19062

Looks like we would have to implement kvm_arch_create_vcpu_debugfs for
the vcpu information and add a similar hook for the vm.

>> ---
>> arch/powerpc/kvm/book3s_hv.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/arch/powerpc/kvm/book3s_hv.c b/arch/powerpc/kvm/book3s_hv.c
>> index 1d1fcc290fca..0223ddc0eed0 100644
>> --- a/arch/powerpc/kvm/book3s_hv.c
>> +++ b/arch/powerpc/kvm/book3s_hv.c
>> @@ -5227,7 +5227,7 @@ static int kvmppc_core_init_vm_hv(struct kvm *kvm)
>> /*
>> * Create a debugfs directory for the VM
>> */
>> - snprintf(buf, sizeof(buf), "vm%d", current->pid);
>> + snprintf(buf, sizeof(buf), "vm%d-lp%ld", current->pid, lpid);
>> kvm->arch.debugfs_dir = debugfs_create_dir(buf, kvm_debugfs_dir);
>> kvmppc_mmu_debugfs_init(kvm);
>> if (radix_enabled())
>>

\
 
 \ /
  Last update: 2021-08-18 00:22    [W:0.164 / U:0.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site