Stefan Reinauer ([email protected]) just uploaded a new patch set to 
gerrit, which you can find at http://review.coreboot.org/1053

-gerrit

commit 88a1ccfa55bad83429c09acdb3cb6e2aa84cb03e
Author: Stefan Reinauer <[email protected]>
Date:   Thu May 24 13:36:30 2012 -0700

    nvramtool: use C99 PRIx64 / PRId64 for uint64_t variables
    
    In printf/printk, using %lld or %ld for uint64_t will warn on either
    64bit or 32bit machines.  However, C99 defines PRIx64 / PRId64 to
    provide the right modifiers for printing uint64_t variables. Use them
    instead.
    
    Change-Id: I68df5d069a1e99d1a75885173ddfd7815197afea
    Signed-off-by: Stefan Reinauer <[email protected]>
---
 util/nvramtool/lbtable.c |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/util/nvramtool/lbtable.c b/util/nvramtool/lbtable.c
index 71c3244..83597e4 100644
--- a/util/nvramtool/lbtable.c
+++ b/util/nvramtool/lbtable.c
@@ -29,6 +29,8 @@
  *  51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 \*****************************************************************************/
 
+#include <stdint.h>
+#include <inttypes.h>
 #include <arpa/inet.h>
 #include <string.h>
 #include <sys/mman.h>
@@ -655,10 +657,10 @@ static void memory_print_fn(const struct lb_record *rec)
                start = unpack_lb64(ranges[i].start);
                end = start + size - 1;
                printf("%s memory:\n"
-                      "    from physical addresses 0x%016llx to 0x%016llx\n"
-                      "    size is 0x%016llx bytes (%lld in decimal)\n",
-                      mem_type, start, end, size,
-                      (unsigned long long)size);
+                      "    from physical addresses 0x%016" PRIx64
+                      " to 0x%016" PRIx64 "\n    size is 0x%016" PRIx64
+                      " bytes (%" PRId64 " in decimal)\n",
+                      mem_type, start, end, size, size);
 
                if (++i >= entries)
                        break;

-- 
coreboot mailing list: [email protected]
http://www.coreboot.org/mailman/listinfo/coreboot

Reply via email to