From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefan Roese Date: Thu, 9 Jul 2009 07:00:19 +0200 Subject: [U-Boot] [PATCH] ppc4xx: Enable support for 64bit printf on all PPC4xx variants In-Reply-To: <4A551B4E.6010102@gmail.com> References: <1246873688-25113-1-git-send-email-sr@denx.de> <4A550B66.1090506@freescale.com> <4A551B4E.6010102@gmail.com> Message-ID: <200907090700.19816.sr@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Thursday 09 July 2009 00:18:54 Jerry Van Baren wrote: > Regardless of the in/out debate, we should print a warning if %ll is > used but not supported. I would suggest simply printing the "%lld" (or > whatever the format is) and pop two longs from the varargs. That would > make it clear something is missing and probably wrong. > > I don't like printing half and discarding half: it will be erroneous > with no warning if the upper half != 0. It would also have endian > complications since the half you want to discard depends on the > machine's endianness (not insurmountable). > > One possible enhancement is to special-case %ll[0-9]*[Xx] and treat it > as as two %08lx formats. Hmmm, this would need correct endian handling > too. :-/ All this would increase the code size for those boards not supporting the 64bit printf format. Not sure by how much, but I suggest to just fix the problem by supporting this format correctly instead of adding new code to print some warnings here. Best regards, Stefan ===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de =====================================================================