KVM: s390: Module autoloading.
PATCH 1/1 KVM: s390: Module autoloading.
This patch enables automatically loading the kvm module when /dev/kvm is opened, allowing distros to stop loading the module statically.
I think it is trivial enough for 3.10; otherwise, please queue this for 3.11.
Cornelia Huck (1):
KVM: s390: Add "devname:kvm" alias.
arch/s390/kvm/kvm-s390.c | 9 +++++++++ 1 file changed, 9 insertions(+)
Signature · 1 line
1.8.1.6
PATCH 1/1 KVM: s390: Add "devname:kvm" alias.
Providing a "devname:kvm" module alias enables automatic loading of the kvm module when /dev/kvm is opened.
--- arch/s390/kvm/kvm-s390.c | 9 +++++++++ 1 file changed, 9 insertions(+)
arch/s390/kvm/kvm-s390.c +9 -0
@@ -1138,3 +1138,12 @@ static void __exit kvm_s390_exit(void)module_init (kvm_s390_init);module_exit (kvm_s390_exit); + +/* +* Enable autoloading of the kvm module. +* Note that we add the module alias here instead of virt/kvm/kvm_main.c +* since x86 takes a different approach. +*/ +#include <linux/miscdevice.h> +MODULE_ALIAS_MISCDEV (KVM_MINOR ); +MODULE_ALIAS ("devname:kvm" );
Signature · 1 line
1.8.1.6
Paolo Bonzini
maintainerRe: [PATCH] KVM: s390: Add "devname:kvm" alias.
Il 27/05/2013 18:42, Cornelia Huck ha scritto:
Quoted 16 lines
Providing a "devname:kvm" module alias enables automatic loading of the kvm module when
/dev/kvmis opened.Signed-off-by Cornelia Huck <[email protected]>--- arch/s390/kvm/kvm-s390.c | 9 +++++++++ 1 file changed, 9 insertions(+)arch/s390/kvm/kvm-s390.c +0
-0@@ -1138,3 +1138,12 @@ static void __exit kvm_s390_exit(void)module_init (kvm_s390_init);
arch/s390/kvm/kvm-s390.c static void __exit kvm_s390_exit(void) · line 1149
Quoted 10 lines
arch/s390/kvm/kvm-s390.c +9
-0module_exit (kvm_s390_exit); + +/* +* Enable autoloading of the kvm module. +* Note that we add the module alias here instead of virt/kvm/kvm_main.c +* since x86 takes a different approach. +*/ +#include <linux/miscdevice.h> +MODULE_ALIAS_MISCDEV (KVM_MINOR ); +MODULE_ALIAS ("devname:kvm" );
Looks good for 3.10. Should I take this since Alex is on holiday, or should I wait for him to come back?
Paolo
Re: [PATCH] KVM: s390: Add "devname:kvm" alias.
Quoted 2 lines · Paolo Bonzini
Looks good for 3.10. Should I take this since Alex is on holiday, or should I wait for him to come back?
let me refer to
http://permalink.gmane.org/gmane.comp.emulators.kvm.devel/104230
;-)
Christian
Re: [PATCH] KVM: s390: Add "devname:kvm" alias.
In reply to Cornelia HuckIl 27/05/2013 18:42, Cornelia Huck ha scritto:
Quoted 16 lines
Providing a "devname:kvm" module alias enables automatic loading of the kvm module when
/dev/kvmis opened.Signed-off-by Cornelia Huck <[email protected]>--- arch/s390/kvm/kvm-s390.c | 9 +++++++++ 1 file changed, 9 insertions(+)arch/s390/kvm/kvm-s390.c +0
-0@@ -1138,3 +1138,12 @@ static void __exit kvm_s390_exit(void)module_init (kvm_s390_init);
arch/s390/kvm/kvm-s390.c static void __exit kvm_s390_exit(void) · line 1149
Quoted 10 lines
arch/s390/kvm/kvm-s390.c +9
-0module_exit (kvm_s390_exit); + +/* +* Enable autoloading of the kvm module. +* Note that we add the module alias here instead of virt/kvm/kvm_main.c +* since x86 takes a different approach. +*/ +#include <linux/miscdevice.h> +MODULE_ALIAS_MISCDEV (KVM_MINOR ); +MODULE_ALIAS ("devname:kvm" );
Applied, thanks.
Paolo
Paolo Bonzini
maintainerRe: [PATCH] KVM: s390: Add "devname:kvm" alias.
Il 28/05/2013 12:44, Paolo Bonzini ha scritto:
Quoted 15 lines
Il 27/05/2013 18:42, Cornelia Huck ha scritto:
Quoted 14 lines
Providing a "devname:kvm" module alias enables automatic loading of the kvm module when
/dev/kvmis opened.Signed-off-by Cornelia Huck <[email protected]>--- arch/s390/kvm/kvm-s390.c | 9 +++++++++ 1 file changed, 9 insertions(+)arch/s390/kvm/kvm-s390.c +0
-0@@ -1138,3 +1138,12 @@ static void __exit kvm_s390_exit(void)
Quoted 14 lines
arch/s390/kvm/kvm-s390.c static void __exit kvm_s390_exit(void) · line 1149
Quoted 12 lines
arch/s390/kvm/kvm-s390.c +9
-0module_init (kvm_s390_init);module_exit (kvm_s390_exit); + +/* +* Enable autoloading of the kvm module. +* Note that we add the module alias here instead of virt/kvm/kvm_main.c +* since x86 takes a different approach. +*/ +#include <linux/miscdevice.h> +MODULE_ALIAS_MISCDEV (KVM_MINOR ); +MODULE_ALIAS ("devname:kvm" );Applied, thanks.
After discussion with Gleb, we have decided to postpone this patch to 3.11. Thanks for your understanding. :)
I'll push pending patches to master and queue soon.
Paolo