Re: svn commit: r211221 - head/usr.sbin/acpi/acpidump

2010-08-13 Thread Bruce Evans
On Fri, 13 Aug 2010, [utf-8] Dag-Erling Sm??rgrav wrote: Bruce Evans writes: - `platform_class' has type uint16_t. u_int is larger than that on all supported machines, and also on unsupported ones with 16-31 bit u_ints. Thus the cast has almost no effect, and has no effect on the result.

Re: svn commit: r211221 - head/usr.sbin/acpi/acpidump

2010-08-13 Thread Dag-Erling Smørgrav
Bruce Evans writes: > - `platform_class' has type uint16_t. u_int is larger than that on all > supported machines, and also on unsupported ones with 16-31 bit u_ints. > Thus the cast has almost no effect, and has no effect on the result. you have to cast it to *something*, unless you're will

Re: svn commit: r211221 - head/usr.sbin/acpi/acpidump

2010-08-13 Thread Bruce Evans
On Thu, 12 Aug 2010, John Baldwin wrote: Dag-Erling Sm??rgrav wrote: John Baldwin writes: Dag-Erling Sm??rgrav writes: Oops, I replied to the commit mail for the round after this before noticing this thread. Slightly better: printf("\tClass %u Base Address 0x%jx Length %ju\n\n",

Re: svn commit: r211221 - head/usr.sbin/acpi/acpidump

2010-08-12 Thread John Baldwin
Dag-Erling Smørgrav wrote: John Baldwin writes: Dag-Erling Smørgrav writes: Slightly better: printf("\tClass %u Base Address 0x%jx Length %ju\n\n", (unsigned int)tcpa->platform_class, (uintmax_t)paddr, (uintmax_t)len); but it would probably be easier to define paddr and

Re: svn commit: r211221 - head/usr.sbin/acpi/acpidump

2010-08-12 Thread Dag-Erling Smørgrav
John Baldwin writes: > Dag-Erling Smørgrav writes: > > Slightly better: > > > > printf("\tClass %u Base Address 0x%jx Length %ju\n\n", > > (unsigned int)tcpa->platform_class, (uintmax_t)paddr, > > (uintmax_t)len); > > > > but it would probably be easier to define paddr and len as uns

Re: svn commit: r211221 - head/usr.sbin/acpi/acpidump

2010-08-12 Thread John Baldwin
Dag-Erling Smørgrav wrote: Takanori Watanabe writes: - printf("\tClass %d Base Address 0x%jx Length %llu\n\n", + printf("\tClass %d Base Address 0x%jx Length %" PRIu64 "\n\n", tcpa->platform_class, paddr, len); This is just as wrong as the previous attempt. 1) platfor

Re: svn commit: r211221 - head/usr.sbin/acpi/acpidump

2010-08-12 Thread Dag-Erling Smørgrav
Takanori Watanabe writes: > - printf("\tClass %d Base Address 0x%jx Length %llu\n\n", > + printf("\tClass %d Base Address 0x%jx Length %" PRIu64 "\n\n", > tcpa->platform_class, paddr, len); This is just as wrong as the previous attempt. 1) platform_class is not an int. 2) paddr

svn commit: r211221 - head/usr.sbin/acpi/acpidump

2010-08-12 Thread Takanori Watanabe
Author: takawata Date: Thu Aug 12 13:58:46 2010 New Revision: 211221 URL: http://svn.freebsd.org/changeset/base/211221 Log: Fix breakage on 64bit architecture by using inttypes.h macro. Modified: head/usr.sbin/acpi/acpidump/acpi.c Modified: head/usr.sbin/acpi/acpidump/acpi.c