summaryrefslogtreecommitdiff
path: root/scripts/mod/file2alias.c
diff options
context:
space:
mode:
authorPrarit Bhargava <prarit@redhat.com>2015-09-10 10:17:59 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-09-21 05:30:09 +0300
commit59796edcf21c7c19d58a223001f9ed13746c51c2 (patch)
tree28b484ac7802cee5eaf31ca610d318b166d609e5 /scripts/mod/file2alias.c
parent6c56026bfbe3a4e11f35c612ff400345c8acb5f9 (diff)
downloadlinux-59796edcf21c7c19d58a223001f9ed13746c51c2.tar.xz
mei: make modules.alias UUID information easier to read
scripts/mod/file2alias.c:add_uuid() convert UUID into a single string which does not conform to the standard little endian UUID formatting. This patch changes add_uuid() to output same format as %pUL and modifies the mei driver to match the change. Signed-off-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'scripts/mod/file2alias.c')
-rw-r--r--scripts/mod/file2alias.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c
index 5f2088209132..fa79d113f34c 100644
--- a/scripts/mod/file2alias.c
+++ b/scripts/mod/file2alias.c
@@ -137,10 +137,12 @@ static inline void add_wildcard(char *str)
static inline void add_uuid(char *str, uuid_le uuid)
{
int len = strlen(str);
- int i;
- for (i = 0; i < 16; i++)
- sprintf(str + len + (i << 1), "%02x", uuid.b[i]);
+ sprintf(str + len, "%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x",
+ uuid.b[3], uuid.b[2], uuid.b[1], uuid.b[0],
+ uuid.b[5], uuid.b[4], uuid.b[7], uuid.b[6],
+ uuid.b[8], uuid.b[9], uuid.b[10], uuid.b[11],
+ uuid.b[12], uuid.b[13], uuid.b[14], uuid.b[15]);
}
/**