]> xenbits.xensource.com Git - people/royger/xen.git/commitdiff
xsm: fix clang build
authorRoger Pau Monné <roger.pau@citrix.com>
Tue, 11 Sep 2018 09:01:13 +0000 (11:01 +0200)
committerJan Beulich <jbeulich@suse.com>
Tue, 11 Sep 2018 09:01:13 +0000 (11:01 +0200)
ebitmap.c:244:32: error: invalid conversion specifier 'Z' [-Werror,-Wformat-invalid-specifier]
               "match my size %Zd (high bit was %d)\n", mapunit,
                              ~^
ebitmap.c:245:16: error: format specifies type 'int' but the argument has type 'unsigned long'
      [-Werror,-Wformat]
               sizeof(u64) * 8, e->highbit);
               ^~~~~~~~~~~~~~~
ebitmap.c:245:33: error: data argument not used by format string [-Werror,-Wformat-extra-args]
               sizeof(u64) * 8, e->highbit);

Use %zd instead of %Zd, which is compliant with C99.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Wei Liu <wei.liu2@citrix.com>
Acked-by: Daniel De Graaf <dgdegra@tycho.nsa.gov>
xen/xsm/flask/ss/ebitmap.c

index bb3ec8e7c96b6b14f5eb8d59e7129147b2c6f0de..e1d0a586a7b16c93aaba77cbda3058daa0c2050e 100644 (file)
@@ -241,7 +241,7 @@ int ebitmap_read(struct ebitmap *e, void *fp)
     if ( mapunit != sizeof(u64) * 8 )
     {
         printk(KERN_ERR "Flask: ebitmap: map size %u does not "
-               "match my size %Zd (high bit was %d)\n", mapunit,
+               "match my size %zd (high bit was %d)\n", mapunit,
                sizeof(u64) * 8, e->highbit);
         goto bad;
     }