summaryrefslogtreecommitdiffstats
path: root/scripts/mod
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2011-08-25 11:28:11 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2011-08-25 11:28:11 -0700
commitebf16e38515188b61962ba84b59e898ad64ffff6 (patch)
tree01c552060330e0e512236295ca96c71d6f47642b /scripts/mod
parent2e2c1d17abc3953239bc05ac586eab9f2f14bfda (diff)
Staging: hv: file2alias: fix up alias creation logic for hv_vmbus_device_id
When I added the driver_data field to hv_vmbus_device_id, I forgot to take into the account how the alias was created, so it would append the kernel pointer to the end of the alias, which is not correct. This changes how the hv_vmbus_device_id alias is created to proper account for the driver_data field. As no module yet uses this alias, it is safe to fix this up at this point in the commit stream. Cc: K. Y. Srinivasan <kys@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'scripts/mod')
-rw-r--r--scripts/mod/file2alias.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c
index b74d21ab91f..f936d1fa969 100644
--- a/scripts/mod/file2alias.c
+++ b/scripts/mod/file2alias.c
@@ -745,9 +745,9 @@ static int do_vmbus_entry(const char *filename, struct hv_vmbus_device_id *id,
char *alias)
{
int i;
- char guid_name[((sizeof(struct hv_vmbus_device_id) + 1)) * 2];
+ char guid_name[((sizeof(id->guid) + 1)) * 2];
- for (i = 0; i < (sizeof(struct hv_vmbus_device_id) * 2); i += 2)
+ for (i = 0; i < (sizeof(id->guid) * 2); i += 2)
sprintf(&guid_name[i], "%02x", id->guid[i/2]);
strcpy(alias, "vmbus:");