Accepting request 349249 from filesystems

Automatic submission by obs-autosubmit

OBS-URL: https://build.opensuse.org/request/show/349249
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/vhba-kmp?expand=0&rev=11
This commit is contained in:
Dominique Leuenberger 2015-12-24 11:16:22 +00:00 committed by Git OBS Bridge
commit 8d02ab81c4
2 changed files with 31 additions and 7 deletions

View File

@ -1,23 +1,41 @@
From: Jan Engelhardt <jengelh@inai.de>
Date: 2015-11-23 23:33:05.117741396 +0100
vhba: add devname alias
Facililtate automatic loading of the kernel module on openSUSE
depmod scans the devname aliases and populates
/lib/modules/X/modules.devname, which udev uses to prepopulate /dev
so that, in turn, a program can open a dev node and thereby cause
/lib/modules/X/modules.devname if there is also a
{block,char}-major-* alias. udev uses this file then to prepopulate
/dev so that a program can open a device node and thereby trigger
autoloading.
This patch adds the devname (requirement 1), and assigns
a static number (requirement 2, for openSUSE only).
---
vhba.c | 1 +
1 file changed, 1 insertion(+)
vhba.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
Index: vhba-module-20140928/vhba.c
===================================================================
--- vhba-module-20140928.orig/vhba.c
+++ vhba-module-20140928/vhba.c
@@ -1069,3 +1069,4 @@ static void __exit vhba_exit(void)
@@ -954,7 +954,11 @@ static struct file_operations vhba_ctl_f
};
static struct miscdevice vhba_miscdev = {
- .minor = MISC_DYNAMIC_MINOR,
+ /* Facilitate autoload on openSUSE. The exact number does not matter,
+ * and may change over time, e.g. if "170" gets used by upstream.
+ * Of essence is that MISC_DYNAMIC_MINOR is to be avoided.
+ */
+ .minor = 170,
.name = "vhba_ctl",
.fops = &vhba_ctl_fops,
};
@@ -1069,3 +1073,5 @@ static void __exit vhba_exit(void)
module_init(vhba_init);
module_exit(vhba_exit);
+MODULE_ALIAS("devname:vhba");
+MODULE_ALIAS("devname:vhba_ctl");
+MODULE_ALIAS_MISCDEV(170);

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed Dec 9 17:19:01 UTC 2015 - jengelh@inai.de
- Improve autoloading by editing vhba-devname.diff to assign a
static misc number.
-------------------------------------------------------------------
Mon Nov 23 22:32:50 UTC 2015 - jengelh@inai.de